This page provides some examples of specgen scripts configuration.
Express Service
The example below generates Express server with Superstruct models to ./src/spec and OpenAPI specification to ./docs/swagger.yaml. The command also scaffolds services (only if they don't exist yet) that should be implemented by developers and puts the code into ./src/services path.
Read service-ts documentation for command details.
Koa Service
The example below generates koa server with io-ts models to ./src/spec and OpenAPI specification to ./docs/swagger.yaml. The command also scaffolds services (only if they don't exist yet) that should be implemented by developers and puts the code into ./src/services path.