How to Build a Simple Event Management API with Node.js, Express, and MongoDB
A simple API which can do CRUD operations on Events, also has authentication.
🔗 Links:
Checkout the complete code for this project here: https://github.com/thetechmaze/event-management-api
🔧 Technologies Used:
- Nodejs
- ExpressJs
- Mongodb
- Mongoose
🔔 Don't forget to subscribe!
If you found this tutorial helpful, please like the video, comment, and subscribe for more tech tutorials!
⏰ Timestamps:
00:00:00 - intro
00:04:50 - Initial Setup
00:19:13 - Creating DB in MongoDb
00:22:40 - Connecting to the DB
00:26:18 - Creating User Model
00:29:15 - Creating Event Model
00:32:30 - Creating UserController
00:33:16 - registerUser - UserController
00:38:49 - loginUser - UserController
00:44:28 - Creating EventController
00:46:19 - getAllEvents - EventController
00:47:09 - getEvent - EventController
00:48:50 - createEvent - EventController
00:50:51 - updateEvent - EventController
00:54:37 - deleteEvent - EventController
00:56:15 - Creating Routes for Users
00:57:26 - Creating Routes for Events
01:00:15 - Adding the routes to the api
01:04:12 - Creating Middleware for checking auth
01:09:25 - Adding Middleware to the routes
01:11:26 - Checking the api
01:24:05 - npm run start