Using the new Express 4.0 Router to build an API
- Node and npm
- Clone the repo:
git clone [email protected]:oresh/node-api.git - Install dependencies:
npm install - Start the server:
npm start
Run npm test to run tests. You'll need dev dependencies installed.
You can also test API methods with Postman
- add roles
- pager and results limit. http://stackoverflow.com/questions/5539955/how-to-paginate-with-mongoose-in-node-js/23640287#23640287
- create middleware function for role check. Ex: https://github.com/scotch-io/building-and-securing-a-modern-backend-api/blob/master/movieanalyst-api/server.js
- API methods documentation. Ex: https://scotch.io/tutorials/speed-up-your-restful-api-development-in-node-js-with-swagger
- use promises for password code and decode. Ex: https://github.com/AramilRey/arapi/blob/master/src/models/user.js
- add geolocation save and search. Ex: http://stackoverflow.com/questions/11288969/mongodb-node-js-geolocation
- add image upload. Ex: https://github.com/achingbrain/mongoose-crate-gm
- compress images. Ex: https://www.npmjs.com/package/compression
- image crop
- add comments m/c
- push notifications
- send emails. Ex: https://www.npmjs.com/package/nodemailer
- integrate babel
- integrate moment.js
- serve static files. Ex: https://www.npmjs.com/package/serve-static
- facebook connect
- pluralize. https://www.npmjs.com/package/pluralize
- cron. https://www.npmjs.com/package/cron
- minimath. https://www.npmjs.com/package/minimatch
- passport. https://www.npmjs.com/package/passport
- escape-html. https://www.npmjs.com/package/escape-html
- faker. Method for generating fake data for testing. https://www.npmjs.com/package/faker
- add lodash library