Middlewares
Table of Contents
Classes
- BaseMiddleware
- Abstract base class for dispatcher-side middlewares (mirrors aiogram's
`aiogram.dispatcher.middlewares.base.BaseMiddleware`).
- ErrorsMiddleware
- Top-of-chain dispatcher middleware (mirror of aiogram's
`aiogram.dispatcher.middlewares.error.ErrorsMiddleware`) that **routes real
exceptions to the `errors` observer**.
- EventContext
- Readonly DTO carrying the user/chat/thread context extracted from any
incoming update by `UserContextMiddleware` (mirror of
`aiogram.dispatcher.middlewares.user_context.EventContext`).
- MiddlewareManager
- Ordered registry of dispatcher-side `BaseMiddleware` instances for a single
update type (mirrors aiogram's `aiogram.dispatcher.middlewares.manager.MiddlewareManager`).
- UserContextMiddleware
- Dispatcher-side middleware that resolves the user/chat/thread context for
the incoming event and writes the canonical kwargs into `$data` so that
downstream handlers, filters, and inner middlewares can bind them via
reflection.