This is a straightforward boilerplate for building REST APIs with ES6 and Express.
- ES6 support via babel
- REST resources as middleware via resource-router-middleware
- CORS support via cors
- Body Parsing via body-parser
- PM2 Monitoring - Production via pm2
- NodeRestful via node-restful
# clone it
git clone https://github.com/caioorg/api-node.git
cd api-node
# Make it your own
rm -rf .git && git init && npm init
# Install dependencies
npm install
# Start project development
npm run dev
# If you want to start production
npm run build
If you want to validate the route operation by POSTMAN:
GET - List All -> /api/v1
GET - Search with Sort -> /api/v1/?sort=created
POST - Create Register -> /api/v1
PUT - Update Register -> /api/v1/:id
DELETE /api/v1/:id
This link was made available with the documentation, how to make the requests via POSTMAN.
MIT