You can use this logging directory as an example of how to approach each API resource you want to define. This directory itself is not required for the continued use of the template.
- cp logging newApi
- define a new data/schema to account for the objects you wish to include in the openAPI spec and which you want to create types from
- add a reference to this new schema (newApi/data/schema) in the ./swagger.ts openApi generator class (line 27+)
- make note of your schema objects that require type definitions and use those names in the next step to auto generate your types form the schema
- yarn swag-type SCHEMA-NAME TYPE-NAME
- As an example, to generate the type example you see now, we would use "yarn swag-type Log LogObject"
- update your data/model definition to match your type
- change your api, logic, and dal files to handle your crud operations
- add your routes
- update ./routes/index to include your routes
- update ./app to include your routes (line 6 and line 26+)