In this tutorial I'm going to explain how to develop restful apis node js. I will be using MongoDB as database. I will be explaining simple apis which can add,fetch all, fetch by id, delete or destroy and update the records.
To start with we need to install mongoose by following command if we have not installed it yet.
To install the mongoose:
1
|
npm install mongoose
|
Here is the post route which contains all functions add,fetch all, fetch by id, delete or destroy and update the records. ...