swagger-to-typescript-client
Version:
Generate TypeScript axios client from Swagger & OpenAPI specification
34 lines (25 loc) • 1.1 kB
Markdown
# swagger-to-typescript-client
[](https://github.com/meabed/swagger-to-typescript-client/actions/workflows/ci.yml)
[](https://www.npmjs.com/package/swagger-to-typescript-client)
[](https://www.npmjs.com/package/swagger-to-typescript-client)
[](https://unpkg.com/browse/swagger-to-typescript-client@latest/)
### A CLI to Generate typescript axios client from swagger & openapi file
## Installation
NPM
```npm
npm install --save swagger-to-typescript-client
```
Yarn
```yarn
yarn add swagger-to-typescript-client
```
## Usage
```
node ./node_modules/swagger-to-typescript-client/dist/index.js --pkg client-name --output ./sdk --swagger ./swagger.json
```
Or use NPX
```
npx swagger-to-typescript-client --pkg client-name --output ./sdk --swagger ./swagger.json
```
## Example
TBA