@verdigado/sherpa-api
v1.0.0
Published
OpenAPI Spec for Sherpa
Readme
Sherpa API
OpenAPI specification for Sherpa.
Codegen
Run OpenAPI Tools Generator
npm run codegenTypescript Client
- Make sure to update the
npmVersioninopenapitools.json. - update axios dependency in
package.jsonof generated client
Login with npm
npm login
# ...Build client
cd out/typescript-sherpa-clientfix axios dependency in generated package.json
-> correct to axios": "^1.6.2
npm installPublish package
npm publish --access publicNotes
- tags are used group api endpoints
- Most code generators will produce a separate class for each tag. This way we can configure the apis with their corresponding client certificates.
- named schemas, operation ids and responses are all prefixed for their apis to prevent naming conflicts
SwaggerUI
Show spec in SwaggeUI on http://localhost:8000
docker run -p 8000:8080 -e SWAGGER_JSON=/spec/openapi.yaml -v ./openapi.yaml:/spec/openapi.yaml swaggerapi/swagger-ui