Architecture Review
2 min read · Updated October 15, 2026
Table of Contents
1. The Final Project Structure
src/
├── generated/
│ └── prisma/ # generated Prisma Client (gitignored)
├── prisma/
│ ├── prisma.module.ts
│ └── prisma.service.ts
├── tasks/
│ ├── dto/
│ │ ├── create-task.dto.ts
│ │ └── update-task.dto.ts
│ ├── tasks.controller.ts
│ ├── tasks.service.ts
│ └── tasks.module.ts
├── app.module.ts
└── main.ts
prisma/
└── schema.prisma
prisma.config.ts
Every file here was built incrementally, in this order:
| Part | Added |
|---|---|
| 1 | The project itself, main.ts |
| 2 | tasks.module.ts |
| 3 | tasks.controller.ts |
| 4 | tasks.service.ts (in-memory) |
| 5 | dto/, ValidationPipe |
| 6 | prisma/, prisma.config.ts, tasks.service.ts rewritten against Prisma |
| 7 | NotFoundException / ConflictException usage |
| 8 | Swagger UI at /api |
2. The Request Lifecycle
Every request into /tasks now travels the same path:
Request → Controller → DTO Validation → Service → PrismaService → PostgreSQL → Service → Controller → Response
This is the core idea to take away from this whole crash course: Nest isn't a pile of decorators to memorize — it's this one consistent flow, with a clear, single-responsibility layer for each step.
3. What We Deliberately Skipped
This was a 1-hour crash course, not the whole framework. Left out on purpose, each worth its own dedicated learning time:
Guards, interceptors, middleware, pipes in depth, custom decorators, authentication/JWT, authorization/RBAC, WebSockets, microservices, queues, caching, testing, GraphQL, file upload, advanced database patterns.
4. Where to Go Next
If you want to go from "I can build a small API" to "I can build a production-style e-commerce API, live, with a cohort" — including proper authentication, authorization, payments (Bakong), and deployment (Sabay Cloud) — that's exactly what the paid, live cohort this crash course funnels into covers, over 3 months.
Was this chapter helpful?
You reached the end of this series
Well done. Pick what to learn next from the roadmap, or browse every series.
Get new tutorials
Join the Telegram channel to hear when a new chapter or series is published, or follow the feeds.
Buy Me a Coffee
Found this tutorial helpful? Consider buying me a coffee to support more free content!