
Explore the Node.js core http module to build a basic server, manage the request-response cycle with headers and body, and return json with status codes like 200 and 404.
Learn to respond with data using express; set content-type headers, return json data with res.send or stringify a data object, and understand request and response headers.
Learn common http methods such as get, post, put or patch, and delete; design restful routes like /todos; handle request bodies, statuses, and basic in-memory to dos.
Create and test express routes using app.get, res.send, and res.json, including status handling and route parameters for a versioned api like /api/v1/boot-camps with create, read, update, delete operations.
Create and export controller methods for each route, wire them to routes, and structure a neat Node.js API using boot camps, with public and private routes and middleware.
Enhance Node.js console output with the colors package, styling server and database messages in bold yellow and errors in red for easier log visibility.
Define a mongoose boot camp model with validated fields, a MapQuest geocoder-generated GeoJSON location and slug, and computed averages from reviews and tuition, plus data seeding.
Learn to catch Mongoose cast errors in a centralized error handler, return a 404 with a custom error response, and apply the pattern to get, update, and delete boot camps.
Build a route and controller to fetch boot camps within a zip code radius using geojson locations, geocoder geocoding, and a geo within center sphere query.
Learn how to filter, project, and sort data in a Node.js API using Express and MongoDB by implementing select fields, excluding query keys, and flexible sort options.
Use mongoose populate to enrich courses with boot camp data, implement virtuals for reverse course listings, and enable cascade delete so deleting a boot camp removes its courses.
Build a Node.js API with Express and boot camp associations, enabling get all courses, get single course by id, and add, update, or delete courses via routes and controllers.
Implement boot camp photo upload with express file upload, validating image presence and type, saving to public/uploads, updating the boot camp record, and serving images from the public folder.
Validate email and password, find the user by email, compare the entered password with the hashed one, and return a token containing the user id.
Build a protect middleware with JWT to require a bearer token in the authorization header for protected routes, decode the token to fetch the user and attach to the request.
Create an authorize middleware to grant access to specific roles, integrate it with the protect middleware, and enforce 403 forbidden when a user's role isn't authorized for a route.
Enforce boot camp ownership with owner and admin permissions for updating, deleting, and uploading photos, using token-based authentication and robust authorization for courses.
Enforces boot camp ownership by the logged-in user when adding courses. Validates permissions before updating or deleting courses.
Update the logged-in user's name and email via a protected put request, using specified fields to update; securely change password with current and new values and return a token.
create a review model with title, text, and a 1–10 rating linked to boot camps and users, then implement routes to get all reviews and boot camp reviews.
Calculate and persist the average rating for boot camps using a static method on the review schema and update the boot camp model to reflect the average after each change.
This is a project based course where we build an extensive, in-depth backend API for DevCamper, a bootcamp directory API. We will start from scratch and end up with a professional deployed API with documentation. We will dive deep into Node, Express and MongoDB. Here is some of what you will learn in this course and project...
HTTP Essentials
Postman Client
RESTful APIs
Express Framework
Routing & Controller Methods
MongoDB Atlas & Compass
Mongoose ODM
Advanced Query (Pagination, filter, etc)
Models & Relationships
Middleware (Express & Mongoose)
MongoDB Geospatial Index / GeoJSON
Geocoding
Custom Error Handling
User Roles & Permissions
Aggregation
Photo Upload
Authentication With JWT & Cookies
Emailing Password Reset Tokens
Custom Database Seeder Using JSON Files
Password & Token Hashing
Security: NoSQL Injection, XSS, etc
Creating Documentation
Deployment With PM2, NGINX, SSL
Web development is changing. We used to render all of our views and templates on the server, but since the rise of frontend frameworks like React, Angular and Vue, we are now splitting projects up into backend and frontend, where the backend is doing all of the database interaction and serving JSON and the frontend is fetching that data and creating the user interface to interact with. This course will teach you the entire backend side of things so that you can build extensive APIs and then use whatever you want on the frontend.
We will do a lot more than just build a simple CRUD REST API like many other Node.js and Express tutorials. We will be implementing authentication, roles and permissions, password reset tokens, email functionality, geocoding and much more. This course teaches what it's like to be a real backend engineer.