openapi-automatons
v1.0.259
Published
[![CI/CD](https://github.com/openapi-automatons/openapi-automatons/actions/workflows/ci-cd.yml/badge.svg)](https://github.com/openapi-automatons/openapi-automatons/actions/workflows/ci-cd.yml) [![codecov](https://codecov.io/gh/openapi-automatons/openapi-a
Downloads
59
Readme
OpenapiAutomatons
What OpenapiAutomatons
This library is a generator using openapi file.
What code can generate?
| name | language | type | | ---- | -------- | ---- | | @automatons/typescript-client-axios | typescript | client |
Get Started
- Install library to your project
yarn add -D openapi-automatons @automatons/typescript-client-axios
- Create settings in your project root
automatons.json
{
"openapi": "openapi.yml",
"automatons": [{
"automaton": "@automatons/typescript-client-axios",
"outDir": "src/clients"
}]
}
- Add generate command your package.json
{
"scripts": {
"generate": "openapi-automatons"
}
}
Automatons.json
| property | | type | required | description | | -------- | --- | ---- | -------- | ----------- | | openapi | | string | true | This is openapi path. It can be relative or absolute. Also, there is no problem with the url format.| | automatons | | array | true | This is the property that contains the module. | | automatons | automaton | string | true | This is the module name. You can embed your own module. It is also possible to include it with a relative path. | | automatons | outDir | string | true | This is the output directory of module. |