What it is
Hey API is an open-source ecosystem for turning API specifications into production-ready code. It is distributed as a monorepo containing all of the project's open source packages, with the two primary generators being openapi-ts for TypeScript and openapi-python for Python. The TypeScript generator ships with more than twenty plugins covering SDKs, Zod schemas, and TanStack Query hooks, while the Python generator produces SDKs and Pydantic models. A supporting library, spec-types, provides TypeScript definitions for OpenAPI and JSON Schema specifications with complete inline documentation. The project lives in the JavaScript and TypeScript ecosystem, is written in TypeScript, and is released under the MIT License.
The concrete problem it solves is the manual, repetitive work of translating an OpenAPI specification into client code that a team can actually ship. Rather than hand-writing request functions, response types, validation schemas, and framework-specific data-fetching hooks, a developer points a generator at an existing specification and receives code that compiles and runs. Because the generators accept any OpenAPI specification and expose HTTP clients for the Fetch API, Axios, Angular, Next.js, Nuxt, and HTTPX, the output can be adapted to the stack a project already uses instead of forcing a rewrite around a single runtime.
Key capabilities
- Generates TypeScript SDKs from any OpenAPI specification through the
openapi-ts package.
- Generates Python SDKs and Pydantic models through the
openapi-python package.
- Provides more than twenty plugins, including Zod schemas and TanStack Query hooks, to reduce third-party boilerplate.
- Emits production-grade code that compiles, rather than partial or illustrative output.
- Runs in any Node.js 22 or later environment.
- Supports HTTP clients for the Fetch API, Axios, Angular, Next.js, Nuxt, and HTTPX.
- Remains highly customizable through its plugin system.
- Publishes
spec-types, TypeScript definitions for OpenAPI and JSON Schema with inline documentation.
Who uses it and how
- Teams adopt it to replace hand-written API clients with generated SDKs that stay in sync with the specification.
- Frontend projects use the TanStack Query hooks plugin to generate data-fetching code alongside the client.
- Projects needing runtime validation pair the SDK output with generated Zod schemas.
- Python services use
openapi-python to produce SDKs and Pydantic models from the same specification.
- The project reports use by Vercel, OpenCode, PayPal, AWS, and Autodesk, and millions of weekly npm downloads.
Getting started
Install the relevant package from npm β openapi-ts for TypeScript or openapi-python for Python β and follow the package-specific quick start guides linked from the monorepo. Documentation and manuals are hosted at heyapi.dev.
When to use it β and when not to
Hey API is a reasonable fit when a project already maintains an OpenAPI specification and wants generated clients, validators, or framework hooks instead of hand-written equivalents. Self-hosters should note that the generators run locally or in CI and the README does not describe a hosted service, so no database, storage, or SMTP component is mentioned as required. The repository carries 630 open issues, which is worth weighing against the maturity implied by its adoption.
project readme (upstream, from github) β read inline
Hey API
"OpenAPI codegen that just works."
β Guillermo Rauch, CEO of Vercel
Manual
β’
Issues
β’
Contribute
About
Hey API is an ecosystem for turning API specifications into production-ready code. It's trusted by thousands of companies β from YC startups to Fortune 500 enterprises β and powers products used by millions worldwide.
This is the monorepo containing all open source Hey API packages. For package-specific documentation and quick start guides, see the individual repositories below.
Packages
Highlights
- production-grade code that compiles
- runs in any Node.js 22+ environment
- accepts any OpenAPI specification
- core plugins for SDKs
- HTTP clients for Fetch API, Axios, Angular, Next.js, Nuxt, HTTPX, and more
- Zod schemas, TanStack Query hooks, Pydantic models, and 20+ plugins to reduce third-party boilerplate
- highly customizable via plugins
Libraries
Contributing
Want to see your code in products used by millions?
Start with our Contributing guide and release your first feature.
Sponsors
Partners behind the future of API tooling. Become a sponsor.
Gold