swagger-codegen

Generate API clients, server stubs, and docs from OpenAPI specs

brewmacoslinux
Try with needOr install directly
Source

About

Generate clients, server stubs, and docs from an OpenAPI spec

Commands

swagger-codegen

Examples

Generate a Python client from an OpenAPI specification$ swagger-codegen generate -l python -i openapi.yaml -o ./python-client
Generate a Node.js/JavaScript client library$ swagger-codegen generate -l javascript -i https://petstore.swagger.io/v2/swagger.json -o ./js-client
Generate a Java server stub with Spring framework$ swagger-codegen generate -l spring -i openapi.yaml -o ./java-server