Generate the API Client for Fetch or Axios from an OpenAPI Specification
4,117
stars
1,585
commits
TypeScript
primary language
Sep 5, 2026
updated
Any questions you can ask here: https://github.com/acacode/swagger-typescript-api/discussions
All examples you can find here: https://github.com/acacode/swagger-typescript-api/tree/main/tests
You can use this package in two ways:
npx swagger-typescript-api generate --path ./swagger.json
Or install locally in your project:
npm install --save-dev swagger-typescript-api
npx swagger-typescript-api generate --path ./swagger.json
npm install --save-dev swagger-typescript-api
import * as path from "node:path";
import * as process from "node:process";
import { generateApi } from "swagger-typescript-api";
await generateApi({ input: path.resolve(process.cwd(), "./swagger.json") });
For more detailed configuration options, please consult the documentation.
Licensed under the MIT License.
(top 30 of 58)
TypeScript
89.4%
EJS
8.0%
JavaScript
2.6%
Generate the API Client for Fetch or Axios from an OpenAPI Specification
4,117
stars
1,585
commits
TypeScript
primary language
Sep 5, 2026
updated
Any questions you can ask here: https://github.com/acacode/swagger-typescript-api/discussions
All examples you can find here: https://github.com/acacode/swagger-typescript-api/tree/main/tests
You can use this package in two ways:
npx swagger-typescript-api generate --path ./swagger.json
Or install locally in your project:
npm install --save-dev swagger-typescript-api
npx swagger-typescript-api generate --path ./swagger.json
npm install --save-dev swagger-typescript-api
import * as path from "node:path";
import * as process from "node:process";
import { generateApi } from "swagger-typescript-api";
await generateApi({ input: path.resolve(process.cwd(), "./swagger.json") });
For more detailed configuration options, please consult the documentation.
Licensed under the MIT License.
(top 30 of 58)
TypeScript
89.4%
EJS
8.0%
JavaScript
2.6%