This Project serves the backend APIs required for Real Dev Squad web projects. This project is built in Express.js.
$ npm install
$ npm start
$ npm run dev
- Create a new file:
config/local.js
. Override the required config values fromconfig/development.js
andconfig/default.js
intoconfig/local.js
. - Register the application for GitHub OAuth to get the
clientId
andclientSecret
. Add the callback URL ashttp://<HOSTNAME>:<PORT>/auth/github/callback
- Create an application on FireStore and generate a service file. Add the service file with the name
firestore-private-key.json
in the project root.
- Run the server and navigate to
http://<HOSTNAME>:<PORT>/api-docs
to view the API documentation. - Alternatively, you can import the file API Schema to Postman or SwaggerHub.
- If any API changes have been made:
- Write JS Doc on top of your routes using YAML based annotations in OPEN API 3.0 format.
- Run
npm run generate-api-schema
to generate the API schema. A filepublic/apiSchema.json
will be created/updated.