JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 74
  • Score
    100M100P100Q76150F
  • License MIT

Zod Type Provider for Fastify@5

Package Exports

  • @marcalexiei/fastify-type-provider-zod

Readme

@marcalexiei/fastify-type-provider-zod

CI Checked with Biome npm version issues

By combining Zod with Fastify’s type providers, this package bridges the gap between static typing and runtime schema enforcement.

It supports automatic generation of JSON Schema from Zod, facilitating integration with OpenAPI 3.x via Fastify plugins like @fastify/swagger and @fastify/swagger-ui.

Getting started

https://marcalexiei.github.io/fastify-type-provider-zod/getting-started.html

Examples

https://marcalexiei.github.io/fastify-type-provider-zod/examples.html

Credits

This project is built upon turkerdev/fastify-type-provider-zod and wouldn’t be possible without the work of turkerdev and the contributions of the entire community behind it.

Reason

TL;DR; My contribution on the turkerdev/fastify-type-provider-zod repository are getting missed.

If this changes, I'm more than willing to merge the changes here back to the upstream repo.

As of 2025-08-31, no communication have come from the original repo maintainer. Also some merged PRs (e.g.: 205) make the upstream repository incompatible with this repo.

More details

My contribution are getting missed: https://github.com/turkerdev/fastify-type-provider-zod/pull/174#issuecomment-3023602822

Recent PRs not opened by me are reviewed before mine: https://github.com/turkerdev/fastify-type-provider-zod/pull/176#issuecomment-3018610310

This happened in the same way here:

Ignored PRs:

Ignored issues:

Differences from turkerdev/fastify-type-provider-zod

  1. Automated changelog using Changeset
  2. CI tests also Windows
  3. Less any in the source code
  4. oas-validator (last release 4 years ago) replaced by @seriousme/openapi-schema-validator (which supports 3.1)
  5. Using swagger object for OpenAPI standard throws an error instead of a warning
  6. Uses vitest typechecking rather than tsd
  7. Type tests are run on node, node16, bundler module resolutions
  8. createJsonSchemaTransform skipList option has been removed in favor of route.schema.hide

As of 2025-08-31 the implementation from the upstream repository have diverged so I'll stop updating this section.