MCPcopy Index your code
hub / github.com/acacode/swagger-typescript-api

github.com/acacode/swagger-typescript-api @v13.12.4

Chat with this repo
repository ↗ · DeepWiki ↗ · release v13.12.4 ↗ · + Follow
266 symbols 1,201 edges 145 files 4 documented · 2% 14 cross-repo links updated 2d agov13.12.4 · 2026-07-02★ 4,096169 open issues
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Swagger TypeScript API

  • Support for OpenAPI 3.0, 2.0, JSON and YAML
  • Generate the API Client for Fetch or Axios from an OpenAPI Specification

Any questions you can ask here: https://github.com/acacode/swagger-typescript-api/discussions

Examples

All examples you can find here: https://github.com/acacode/swagger-typescript-api/tree/main/tests

Usage

You can use this package in two ways:

CLI

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

Library

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.

Mass media

License

Licensed under the MIT License.

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Method 112
Class 70
Function 58
Interface 24
Enum 2

Languages

TypeScript100%

Modules by API surface

src/resolved-swagger-schema.ts34 symbols
src/schema-components-map.ts19 symbols
types/index.ts18 symbols
src/code-formatter.ts15 symbols
src/util/remote-schema-fetch.ts12 symbols
src/swagger-schema-resolver.ts11 symbols
src/util/name-resolver.ts7 symbols
src/util/parse-schema-content.ts6 symbols
src/schema-routes/schema-routes.ts6 symbols
src/translators/translator.ts5 symbols
src/schema-parser/mono-schema-parser.ts5 symbols
src/schema-parser/base-schema-parsers/enum.ts5 symbols

Dependencies from manifests, versioned

@biomejs/biome2.5.2 · 1×
@biomejs/js-api6.0.0 · 1×
@biomejs/wasm-nodejs2.5.2 · 1×
@changesets/changelog-github0.7.0 · 1×
@changesets/cli2.31.0 · 1×
@tsconfig/node2020.1.9 · 1×
@tsconfig/strictest2.0.8 · 1×
@types/node26.0.0 · 1×
@types/swagger-schema-official2.0.25 · 1×
@types/swagger2openapi7.0.4 · 1×
axios1.18.0 · 1×

For agents

$ claude mcp add swagger-typescript-api \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page