# hey-api/hey-api

👨‍🚀 Turn API specifications into production-ready SDKs, validators, mocks, and more. 20+ plugins. Millions of weekly npm downloads. Used by Vercel, OpenCode, PayPal, AWS, Autodesk, and many more.

Repository: https://github.com/hey-api/hey-api
Canonical: https://ross.abutalabs.com/products/hey-api
Homepage: https://heyapi.dev
Language: TypeScript
License: MIT
License Family: permissive
Topics: api-client, code-generation, codegen, developer-tools, openapi, python, sdk, swagger, typescript, sdk-generator
Last push: 2026-08-24T17:31:35+00:00

## Health v2 (maintenance only)
Score: 85/100 (v2, computed 2026-09-03T02:39:23.370411+00:00)
- activity 99, release rhythm 77, longevity 69
- inputs: {"age_days": 966, "days_push": 9, "days_rel": 72, "gap_med": 0, "n_releases_24m": 326}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 5316, forks 426 (observed 2026-08-28T04:09:15.541401+00:00)

## What it is
Hey API is an ecosystem of code generators that turn OpenAPI specifications into production-ready SDKs, types, validators, and mocks. Its flagship @hey-api/openapi-ts generates TypeScript clients with 20+ plugins (Zod schemas, TanStack Query hooks, multiple HTTP clients), with a Python generator also available.

## Use cases
- generate a typescript sdk from an openapi spec
- generate zod schemas from swagger json
- create typed api client for axios or fetch
- generate tanstack query hooks from openapi
- generate python sdk with pydantic models from openapi
- mock api responses from an openapi specification
- keep frontend api client in sync with backend spec

## When to choose
- you have an OpenAPI/Swagger spec and want typed, production-ready client code without hand-writing it
- you want generated validators (Zod, Valibot) and state-management hooks alongside your SDK
- you need multiple HTTP client targets (Axios, Fetch, Ky, Next.js, Nuxt, Angular) from one spec

## When to avoid
- your API has no OpenAPI specification to generate from
- you need a stable custom plugin API - the plugin interface is still in development
- you want a runtime API gateway or proxy rather than generated client code

## Facets
- artifact type: cli-tool
- maturity: active
- function: sdk, parser, http-client, mock-api, plugin-system, developer-tools
- domain: apis, web-development, developer-tools, frontend, backend
- platform: cli, cross-platform
- tags: openapi, swagger, typescript, zod, tanstack-query, sdk-generation, codegen, pydantic, python, code-generation, nodejs

## Member repositories
- hey-api/hey-api (main) score 85

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:09:15.541401+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:58:56.777080+00:00, confidence not recorded.
  - readme: https://github.com/hey-api/hey-api (fetched 2026-08-28T04:09:15.541401+00:00, sha 763e602ee850)
  - homepage: https://heyapi.dev (fetched 2026-08-29T08:54:01.422565+00:00, sha 654e62be1fed)
  - site_page: https://heyapi.dev/docs/openapi/typescript/get-started (fetched 2026-08-29T08:54:01.426563+00:00, sha f6f1ad8867e6)
  - site_page: https://heyapi.dev/docs/openapi/typescript/core (fetched 2026-08-29T08:54:01.428723+00:00, sha 227b86de690d)
  - site_page: https://heyapi.dev/docs/openapi/typescript/clients (fetched 2026-08-29T08:54:01.430407+00:00, sha dfa44b9d85a1)
  - site_page: https://heyapi.dev/docs/openapi/typescript/plugins/custom (fetched 2026-08-29T08:54:01.432095+00:00, sha bbfd69adec77)
  - site_page: https://heyapi.dev/docs (fetched 2026-08-29T08:54:01.433794+00:00, sha 9280f91d6e7c)
- Data as of 2026-08-30T08:39:29.467469+00:00.
