/learn-node

Node-Coding-Challange

Primary LanguageJavaScript

Product API

Tech Stack

  • Node
  • Sinon
  • expressjs
  • mocha
  • chai
  • supertest
  • swagger-ui-express

Solution Description

  • Get all products
  • Get Product by Id
  • Health Check
  • Error Handling

Installation and Setup Instructions

Clone down this repository. You will need node and npm installed globally on your machine.

  • Installation:

    $ npm install

  • To Run Test Suite:

    $ npm test

  • To Start Server:

    $ npm start

Git Repo

https://github.com/sankarms15/amp-node-test

Deploy the app in LOCAL via Docker

Open the preferred command prompt and run the docker command

  • docker build -t amp-node-test
  • docker run -p 3000:3000 amp-node-test

Use Swagger end point to Test the API behaviour

http://localhost:3000/product-api