Integration Cheatsheet 01 — Full-Stack Project Skeleton
Cheatsheet: directory layout, pyproject, lifespan, db / settings / models / api wiring.
Cheatsheet: directory layout, pyproject, lifespan, db / settings / models / api wiring.
Cheatsheet: GET/POST/etc decorators, path/query/body/header/cookie/form/file params, APIRouter, prefixes, dependencies on routers, and url_path_for.
FastAPI architecture: ASGI, Starlette, Pydantic, dependency injection, and the design choices that make it tick.
Cheatsheet: trace a request from socket to response through all four libraries.
Cheatsheet: BaseModel, Field, validators, custom errors, nested, discriminated unions, strict mode at the boundary.
Path operations, parameter declaration (path / query / body / header / cookie / form / file), routers, prefixes, dependencies on routers, and request internals.
Cheatsheet: schema vs model separation, partial updates, ORM-to-API conversion, nested relations.
Cheatsheet: response_model, exclusion, custom encoders, JSON / HTML / Streaming / File responses, status codes, headers.
Request validation with Pydantic v2: BaseModel, Field, validators, custom types, error responses, nested models, discriminated unions, and the FastAPI integration.
Cheatsheet: model change → autogenerate → review → upgrade → ship.