-
Open your preferred IDE (Integrated Development Environment).
-
Navigate to your project directory in the terminal or command prompt.
-
Install required dependencies:
- Run the following commands:
npm install express npm install body-parser
- Run the following commands:
-
Install Postman:
- Download and install Postman.
-
Configure Postman:
- Open Postman and select the HTTP method (GET, PUT, POST, DELETE).
-
Send a POST request:
- Set the request URL to
http://localhost:3000
. - Select
raw
andJSON
format in the body tab. - Input JSON data, e.g.,
{"title": "github"}
.
- Set the request URL to
-
Check if data is added:
- Send a GET request to
http://localhost:3000/
in Postman.
- Send a GET request to
Enjoy exploring your Express.js server with CRUD operations!