Logging an API
A server's code reports what it does through Python's logging module instead of print, with a logger per module, levels from DEBUG to ERROR, a format with the time and level, one line for every request written by a middleware, and a logging.Filter that keeps passwords and tokens out of every line.
Updated

- Category
- FastAPI
- Level
- Journeyman
- Tags
- fastapi, Log Redaction, Logging Levels, logging Module, Middleware (fastapi), rest-api