Framework-challenge

To run this project follow the steps bellow:

for console


  • type the command npm install and npm run start-console

Run as Express API


  • Just run the command npm install and npm run start
  • use some rest API client like postman and access the url localhost:3000/calculator/:number as POST, where :number is the number will be passed to API to be calculated.

Unit tests and test coverage


  • To execute the unit tests run the command bellow: npm run test
  • To run the tests coverage report type the follow command in console: npm run coverage

Endpoints


calculator

POST /calculator/:number

Improvements

  • Configure this project to run with docker

  • implement some sort of authorization (maybe using jwt)

  • check for performance issues to escale the API without problems

  • Implement open API documentation(swagger)

  • deploy the project on heroku