Node.JS (TypeScript) Practice
Build real HTTP APIs in Node, one skill at a time. Easy → Hard: routing, validation, responses, middleware, data access — up to auth, caching, jobs, concurrency, transactions, streaming, resilience. Every challenge is API-only and test-driven: implement the missing piece until the supertest suite (in-memory SQLite, seeded) passes.
Routing & Controllers
Map each verb and path to its handler, resolve ids from the URL, and return the status that matches the outcome - created, updated, deleted, not-found, method-not-allowed. Covers nested resources and route precedence.
Bike Hire Endpoints
A bike rental shop's web service. Staff list bikes, add one, and view, edit or remove a single bike. It must reply with the right "found / created / deleted / not-found" signals instead of misleading ones.
Course Catalogue Nested Routes
A training provider lists modules that live inside a course. A module is only valid under its own course, so asking for it through the wrong course returns "not found", and malformed ids are rejected before any lookup.
Analytics Report Route Precedence
A reporting service where a fixed page (`/reports/summary`) keeps being mistaken for a generic "report by id" page. Routes must be ordered so named pages win, with a clean JSON not-found for anything unmatched.
Meeting Room Booking Endpoints
An office room-booking service. Users filter rooms and request a reservation. It checks the times and party size make sense before accepting, and tells the user exactly which field was wrong.
Request Data & Validation
Read and check what comes in —-query params, JSON bodies, request headers. Apply defaults, coerce types, clamp limits, and reject bad input with the status that names the bad field (400/422) or header problem (401/403/415). Covers paging/filters/sort, schema validation with per-field errors, and request-header handling.
Invoice Search Filters
Sign up to see what this challenge asks.
Dental Appointment Payload
A dental booking form that currently saves whatever it's sent. It must check the submitted data against a set of rules, report every bad field at once, and quietly drop fields it doesn't recognise.
Print Shop Request Headers
A print-order service that ignores the metadata clients attach to a request. It must require an access key, accept only the right data format, and honour how the client wants the answer returned.
Vendor Onboarding Intake
A supplier sign-up that says "OK" to everything, so clients can't tell success from rejection. Each outcome - accepted, invalid, duplicate, too-large — gets its own clear signal in one consistent response shape.
Responses & Status Codes
Shape what goes out - map each outcome to its status and set the headers that go with it (Location, Accept, Cache-Control, request-id), with one consistent body and error shape. Covers redirects and idempotency, JSON/CSV content negotiation, and response-shaping middleware.
Allotment Plot Responses
A community-garden plot service that hides errors inside "success" replies. Every outcome must carry the correct signal, with one consistent error shape and no body where none belongs.
Work Order Creation Semantics
A maintenance work-order service where clients can't find an item after creating it. Replies must point clients to the new item's address, and repeating an action must not double it up.
Employee Directory Content Negotiation
An organisation wants the same employee directory as JSON for its intranet app and as a spreadsheet (CSV) for HR. The service returns whichever the client asks for, correctly formatted and escaped.
Public Pricing API
A pricing service that should shape every reply the same way - a tracking id, caching hints, a consistent wrapper - without each route repeating the code. Handlers return data; a shared step finishes the response.
Middleware Basics
Write the shared steps that wrap every request - logging, access control, timing through an injected dependency rather than a hard-coded one, and compose them in front of the routes. Log method/path/final-status/duration, gate writes by token and scope (401/403), stamp a latency header, and stack them all in front of a data-backed API with paged, injection-safe queries. Covers logging, authentication/authorization, timing, and middleware composition.
Request Audit Log
A billing service that logs nothing, so failures can't be traced. A shared step records who asked for what and how it ended errors included - while skipping the health-check noise.
Admin Console Access Gate
A back-office console whose write actions are open to anyone with the link. A shared gate checks the caller's token and permissions before the action runs, and lets read-only and public pages through.
Checkout Latency Header
An engineering team can't see which checkout steps are slow. A shared step times each request and reports the duration back on the response, for both successes and failures.
Contact Activity API
A sales CRM's contact-activity feed behind one guarded, logged surface. Reads are paged and safe from injection, writes are blocked unless authorised, and every call is recorded.
About this path
This path builds HTTP APIs in Node.js with TypeScript, starting with routing and controllers, request validation, status codes and middleware. You should be comfortable with basic TypeScript or JavaScript. No earlier backend experience is needed. The middleware module includes a request audit log and an access gate for an admin console.
From the blog
7Frequently asked questions
4>What will I practice in this path?
4 modules: Routing & Controllers, Request Data & Validation, Responses & Status Codes and Middleware Basics.
>How many challenges are there, and how hard are they?
16 challenges, all easy.
>What does this path run on?
Challenges run on Node.js 24.
>Do I need to install anything?
No. Every challenge runs in a browser-based IDE with everything already set up, and your code is graded automatically against a test suite.
