25
25
You will see a lot more of all this in practice in the Tutorial - User Guide.
With FastAPI you declare parameters with type hints and you get:
Editor support.
Type checks.
...and FastAPI uses the same declarations to:
The important thing is that by using standard Python types, in a single place
(instead of adding more classes, decorators, etc), FastAPI will do a lot of the
work for you.
Info
If you already went through all the tutorial and came back to see more about types,
a good resource is the "cheat sheet" from mypy.