Skip to content

Glossary: Building APIs with FastAPI

Counter

Also written: collections.Counter

A dict from the `collections` module that counts things and starts every count at 0. The orders router uses it to add up quantities per product, so two lines of 15 mugs become 30.

Where the book teaches it