- Develop a simple API to serve trip information
- API endpoints consists of
GET /trips
list all trips (only tripname
and_id
)POST /trips
create new tripGET /trips/:id
get trip detail (all fields)PUT /trips/:id
update tripDELETE /trips/:id
delete trip
- Trip data consists of
String
nameNumber
priceString
description
Bonus points
- Use promise instead of async callback
- Use ES2015 syntax
Question
What is the difference between MongoDB and MySql?
- MongoDB have a write to disk faster than MySql.
- if you don't read(write only) MongoDB use a resource less than MySql.