Launching today

swaggerz
typed API clients compiled from OpenAPI
2 followers
typed API clients compiled from OpenAPI
2 followers
Generate fully typed, documented, tree-shakeable API clients from Swagger 2.0 and OpenAPI 3.0/3.1/3.2 specifications.

2 followers
2 followers
In every project I've worked on, the API client was the weak spot. Hand-written clients drift from the backend. Generated ones were often huge, typed with any, different on every run, and vague about errors. I built swaggerz to be the generator I'd trust in production:
• Everything is typed, errors included: checking error.status === 404 narrows error.body to the 404 response.
• The output is tree-shakeable, with no runtime dependency. One operation costs about 16 kB, not the whole API.
• It generates the same output on every run, so swaggerz generate --check can guard your CI.
• It reads Swagger 2.0 and OpenAPI 3.0 to 3.2. It works with fetch or axios, TanStack Query or SWR, and Zod, Valibot or ArkType.
0.2.0 adds Mock Service Worker handlers with realistic, seeded data, so you can build the UI before the backend exists.
What would help most:
Run it on your own spec. It's tested against 24 public APIs (GitHub, Stripe, Kubernetes, OpenAI and more), but private specs are where the odd cases live. If a type comes out wrong or awkward, open an issue with a snippet.
Tell me where setup or the generated code surprised you.
Tell me what should come next: a diff that reports breaking changes in terms of your client, typed streaming, pagination iterators, or a Vite plugin.