Skip to main content

Crate aiogram

Crate aiogram 

Source
Expand description

An asynchronous Telegram Bot API framework for Rust.

The crate follows aiogram’s architecture: Bot executes typed Telegram methods, Router selects handlers, Dispatcher consumes updates, and fsm provides pluggable finite-state-machine storage.

Re-exports§

pub use bot::Bot;
pub use bot::BotBuilder;
pub use client::BotRequest;
pub use client::DefaultBotProperties;
pub use client::RequestLogging;
pub use client::RequestMiddleware;
pub use client::RequestNext;
pub use client::TelegramApiServer;
pub use dispatcher::ClassHandler;
pub use dispatcher::Dispatcher;
pub use dispatcher::EventContext;
pub use dispatcher::HandlerFlags;
pub use dispatcher::Middleware;
pub use dispatcher::Next;
pub use dispatcher::OuterMiddleware;
pub use dispatcher::OuterNext;
pub use dispatcher::Router;
pub use dispatcher::UpdateContext;
pub use error::Error;
pub use error::Result;
pub use version::AIogramCompatibility;
pub use version::COMPATIBILITY;

Modules§

bot
client
Bot client configuration shared by all typed Telegram methods.
dispatcher
enums
Constants exposed by Python aiogram as enums.
error
filters
Common dispatcher filters and a closure-based extension point.
fsm
Finite-state-machine context, strategies, key builders, storage, and event isolation.
i18n
Lightweight internationalization catalogs and dispatcher middleware.
methods
Typed Telegram Bot API method payloads generated from upstream metadata.
types
Telegram Bot API types generated from the pinned upstream schema.
utils
Ergonomic helpers corresponding to commonly used aiogram.utils features.
version
Version and compatibility information for this port.
webhook
Framework-neutral webhook handling and optional Axum integration.

Macros§

callback_data
Declares strongly typed callback data with aiogram’s compact prefix protocol.
states_group
Declares an idiomatic Rust state group while preserving aiogram state names.