Skip to content

Latest commit

 

History

History
33 lines (25 loc) · 520 Bytes

README.md

File metadata and controls

33 lines (25 loc) · 520 Bytes

myretail-api

Installing

$ npm i

Running in debug mode

$ npm start

Running in production mode

$ npm run build
$ npm run production

Endpoints

Get details about a product: GET /products/v1/:sku

Example

$ curl localhost:3000/products/v1/13860428 | jq

Set a product's price: PUT /products/v1/:sku/price

Example

$ curl -X PUT localhost:3000/products/v1/13860428/price -d '{ "currentPrice": "20.00" }' -H "Content-Type: application/json" | jq