Build production APIs with Node.js & Express
A hands-on backend path in TypeScript — Express fundamentals, REST API design, Prisma, authentication, testing, real-time features and deployment — then into the territory that separates "I built a CRUD API" from "I can run this in production": gRPC, distributed sagas, GraphQL, serverless and edge functions, and profiling the event loop. It ends with a two-week capstone API you architect, secure, test and deploy yourself. The natural backend pairing for the React course.
Prerequisites & tooling
What you should already know
- Comfortable with JavaScript fundamentals — variables, functions, arrays/objects
- No prior Node.js, Express or backend experience required
- Comfortable installing a package manager and using a code editor
- Node.js 20 LTS and a code editor; PostgreSQL locally or via Docker
Stack you'll work with
The same JavaScript backend stack behind a huge share of production APIs — and the natural complement to the React course.
Your 26-week learning path
Twenty-two modules, from your first Express route through gRPC, sagas, GraphQL and serverless, to a two-week capstone API you deploy yourself.
Node.js & TypeScript Fundamentals
The runtime model and tooling every later week assumes.
- The event loop, call stack & non-blocking I/O
- Modules, npm/pnpm & project structure
- TypeScript setup:
tsconfig, types & compiling for Node
Express Fundamentals & Routing
The request lifecycle every route handler in this course builds on.
- Middleware, the request/response cycle & routers
- Route parameters, query strings & request validation basics
- Centralized error-handling middleware
REST API Design & Validation
Design a resource model an API consumer can predict.
- Resource modeling & HTTP semantics done right
- Schema validation with Zod
- Consistent error responses & status codes
Databases with Node & Prisma
Persist data safely, including under concurrent writes.
- Schema design & migrations with Prisma
- Queries, relations & the N+1 problem
- Transactions & handling concurrent writes safely
Authentication & Authorization
Know who's calling your API, and what they're allowed to do.
- Password hashing with bcrypt & JWT-based auth
- Role-based access control & protecting routes
- OAuth / social login with Passport.js
Testing Node & Express Apps
Prove your API works before a client finds out it doesn't.
- Unit testing with Vitest/Jest
- API testing with Supertest
- Mocking dependencies & a test-database strategy
Async Patterns & Real-Time
Master async control flow, then push data to clients instead of waiting to be asked.
- Promises, async/await & error handling in async code
- Streams & backpressure
- WebSockets & Socket.IO for real-time features
Caching & Performance
Find and fix the endpoint that's actually slow.
- Redis caching patterns for a Node API
- Connection pooling & query performance
- Profiling & fixing a slow endpoint
Background Jobs & Queues
Move slow work off the request/response cycle.
- BullMQ & Redis-backed job queues
- Scheduled/cron jobs & retry strategies
- Email & notification workers
Observability & Production Readiness
Know what your API is doing once it's live.
- Structured logging with correlation IDs
- Health checks & readiness probes
- Metrics & basic tracing
Containerization & Deployment
Package and ship the way production Node services actually run.
- Multi-stage
Dockerfilefor a Node/TypeScript service - CI/CD with GitHub Actions
- Running Node in production: PM2/clustering & graceful shutdown
Advanced Prisma — Complex Queries, N+1 & Migrations at Scale
Move past basic queries into the patterns real production repositories need.
- Dynamic filters & composing
whereclauses at runtime include/selecttuning & solving N+1 for real- Batch operations & zero-downtime migrations
API Design at Scale — Versioning, Pagination & OpenAPI
Design an API surface that can evolve without breaking every client.
- API versioning strategies & deprecation headers
- Cursor-based pagination, filtering & sorting conventions
- OpenAPI docs with
zod-to-openapi& per-client rate limiting
gRPC & Protocol Buffers for Service-to-Service Calls
A faster, strongly-typed alternative to REST for internal service communication.
- Defining a service contract with Protocol Buffers
- Building a server and client with
@grpc/grpc-js - Streaming RPCs & when gRPC beats REST between your own services
Distributed Transactions & the Saga Pattern
Keep data consistent across services without a distributed database transaction.
- Why two-phase commit doesn't fit microservices
- A choreographed saga with BullMQ & compensating actions
- The transactional outbox pattern for reliable event publishing
Advanced Auth — OAuth2 Provider, API Keys & Multi-Tenancy
Go from consuming OAuth2 to issuing your own tokens, and isolating tenants correctly.
- Running your own OAuth2/OIDC provider with
node-oidc-provider - API keys & service-to-service client-credentials auth
- Multi-tenant data isolation strategies
Serverless & Edge Functions
Ship compute that scales to zero, right at the network edge.
- AWS Lambda with Node: handlers, cold starts & event sources
- Cloudflare Workers & Vercel Edge Functions
- What changes when your code doesn't run in plain Node anymore
GraphQL with Apollo Server
Give clients a query language instead of a fixed set of REST shapes.
- Schema-first design with GraphQL SDL & Apollo Server
- Query & mutation resolvers over your existing Prisma models
- Solving GraphQL's own N+1 problem with
DataLoader
Contract Testing & Advanced Test Strategy
Test the boundary between services, not just the code inside one.
- Consumer-driven contract testing with Pact
- Mutation testing with Stryker to check what your tests actually catch
- Testing resilience under deliberate fault injection
Node.js Performance — Profiling, Worker Threads & the Event Loop
Understand what Node is actually doing when your service gets slow.
- Profiling with the built-in inspector & clinic.js
- Detecting event loop lag & what actually blocks it
- Worker threads for genuine CPU-bound parallelism
CI/CD & Progressive Delivery for Node Services
Take deployment from "push and hope" to a pipeline with a real safety net.
- Multi-stage pipelines: test, build, scan, deploy
- Blue-green & canary deploys for a Node service
- Feature flags for decoupling deploy from release
Capstone: Ship a Production Node & Express API
Combine every module into one deployed, portfolio-ready service.
- A complete REST API with auth, persistence & a real-time feature
- A real CI/CD pipeline with a progressive rollout
- Containerized, deployed, and documented with a portfolio write-up