- Clone the repo and install dependencies:
git clone <repo-url>
cd student-crud-api
npm install- Create a
.envfile with:
MONGO_URI=your-mongodb-uri
PORT=5000
- Run the app:
npm run devPOST /api/studentsGET /api/studentsGET /api/students/countPUT /api/students/:idDELETE /api/students/:id
Import the postman_collection.json in Postman to test endpoints.
- Email must be unique
- Returns appropriate HTTP status codes for validation and errors