As mentioned in the earlier section, this section will use version 2 of the YAML file, which can generate a server using the official tooling. There are, however, other tools out there that can generate some code, but not complete enough to be easy to use:
- If using OpenAPI 3.0 on the project folder, execute the following command:
$ npx swagger-node-codegen swagger.oas3.yaml -o ./server...Done! Check out your shiny new API at C:\dev\lemon-mart-swagger-server\server.
Under a new folder, called server, you should now have a Node Express server generated.
- Install dependencies for the server:
$ cd server$ npm install
You must then manually implement the missing stubs to complete the implementation of the ...