FastAPI, by Calling It

Routes, validation and documentation that come from the same annotations - each one runnable on the page.

26 modules Free, no login Updated 31 August 2026

About this track

FastAPI is a thin, well-chosen layer over two ideas you can learn separately: ASGI, which is what a Python web application actually is, and Pydantic, which turns your annotations into validation. Almost everything that looks like framework magic is one of those two doing its job.

This track works up from a first route to dependencies, middleware and testing. There is no server on these pages - a browser tab cannot listen on a port - so a test client calls the app the way a server would, which means routing, validation, status codes and the generated schema all behave exactly as they do in production.

Every example runs a real FastAPI application in the browser against a test client, so a request and its response are both on the page - including the requests that are rejected, which is where most of the framework's behaviour is visible.

What you will be able to do

How the track is ordered

The first endpoint comes first, then the request - path parameters, query parameters, bodies, headers, forms and files - because everything else assumes you can read the input. Responses and status codes follow. Dependencies get the largest share of the track, since they are the mechanism FastAPI is built around and the thing that makes an application testable. The track closes with structure, security, testing and the async question, which is where most production problems actually live.

Where this leads

FastAPI is Pydantic applied to HTTP, so the Pydantic track explains the validation layer these pages rely on. Beyond it lie deployment, databases and the operational material a running service needs.

All 26 modules, in teaching order

  1. 01What FastAPI Is
  2. 02Your First Endpoint
  3. 03Path Parameters
  4. 04Query Parameters
  5. 05Request Bodies
  6. 06Response Models
  7. 07Reading a 422
  8. 08HTTP Methods and Routing
  9. 09Headers and Cookies
  10. 10Form Data and File Uploads
  11. 11Status Codes
  12. 12Error Handling
  13. 13APIRouter
  14. 14Dependency Injection
  15. 15Dependencies with yield
  16. 16Sub-dependencies
  17. 17Class Dependencies
  18. 18Router and Global Dependencies
  19. 19Dependency Overrides
  20. 20async def or def
  21. 21Background Tasks
  22. 22Lifespan Events
  23. 23Testing
  24. 24OpenAPI and the Docs
  25. 25Security Basics
  26. 26Project Structure

Other tracks