Skip to main content

Crate rustigram_types

Crate rustigram_types 

Source
Expand description

Type definitions for the Telegram Bot API.

This crate contains every struct, enum, and type alias described in the official Bot API documentation. All types implement serde::Serialize and serde::Deserialize and map directly to the JSON objects Telegram sends and receives.

You rarely need to depend on this crate directly — the rustigram facade re-exports everything you need for day-to-day bot development.

§Organisation

ModuleContents
chatchat::Chat, chat::ChatFullInfo, chat::ChatPermissions, locations, venues
chat_memberAll six chat_member::ChatMember variants
checklistchecklist::Checklist, checklist::ChecklistTask, checklist::InputChecklist, service messages
direct_messagesdirect_messages::DirectMessagesTopic, price-changed service messages
filefile::File, file::PhotoSize, file::InputFile, file::VideoQuality, media types
managed_botmanaged_bot::ManagedBotCreated
messagemessage::Message, message::MessageEntity, message::ParseMode, reply types
updateupdate::Update, update::UpdateKind, update::CallbackQuery, update::BusinessBotRights
useruser::User, user::ChatId, user::BotCommand
keyboardInline and reply keyboards, keyboard::ReplyMarkup
paymentspayments::LabeledPrice, invoices, Star transactions, payments::TransactionPartner, payments::OwnedGift
pollpoll::Poll, poll::PollAnswer, poll::InputPollOption
stickersticker::Sticker, sticker::StickerSet, sticker::InputSticker
suggested_postsuggested_post::SuggestedPostInfo, suggested_post::SuggestedPostParameters, service messages
inlineinline::InlineQuery, all InlineQueryResult variants
storyStory types and area definitions
forumforum::ForumTopic
passportTelegram Passport types and error variants
gamesgames::GameHighScore
giftsgifts::Gift, gifts::Gifts
reactionRe-exports message::ReactionType
webhookwebhook::WebhookInfo

Re-exports§

pub use chat::Chat;
pub use chat::ChatFullInfo;
pub use chat::ChatPermissions;
pub use chat::ChatType;
pub use chat_member::ChatMember;
pub use chat_member::ChatMemberAdministrator;
pub use chat_member::ChatMemberBanned;
pub use chat_member::ChatMemberLeft;
pub use chat_member::ChatMemberMember;
pub use chat_member::ChatMemberOwner;
pub use chat_member::ChatMemberRestricted;
pub use checklist::Checklist;
pub use checklist::ChecklistTask;
pub use checklist::ChecklistTasksAdded;
pub use checklist::ChecklistTasksDone;
pub use checklist::InputChecklist;
pub use checklist::InputChecklistTask;
pub use direct_messages::DirectMessagePriceChanged;
pub use direct_messages::DirectMessagesTopic;
pub use direct_messages::PaidMessagePriceChanged;
pub use file::File;
pub use file::InputMedia;
pub use file::InputMediaAnimation;
pub use file::InputMediaAudio;
pub use file::InputMediaDocument;
pub use file::InputMediaPhoto;
pub use file::InputMediaVideo;
pub use file::InputPaidMedia;
pub use file::InputPaidMediaPhoto;
pub use file::InputPaidMediaVideo;
pub use file::InputProfilePhoto;
pub use file::InputProfilePhotoAnimated;
pub use file::InputProfilePhotoStatic;
pub use file::PhotoSize;
pub use file::VideoQuality;
pub use inline::ChosenInlineResult;
pub use inline::InlineQuery;
pub use inline::InlineQueryResult;
pub use inline::SentGuestMessage;
pub use keyboard::ForceReply;
pub use keyboard::InlineKeyboardButton;
pub use keyboard::InlineKeyboardMarkup;
pub use keyboard::KeyboardButton;
pub use keyboard::ReplyKeyboardMarkup;
pub use keyboard::ReplyKeyboardRemove;
pub use managed_bot::ManagedBotCreated;
pub use message::ChatOwnerChanged;
pub use message::ChatOwnerLeft;
pub use message::Message;
pub use message::MessageEntity;
pub use message::MessageEntityKind;
pub use message::MessageOrigin;
pub use message::ReactionType;
pub use message::ReplyParameters;
pub use payments::AcceptedGiftTypes;
pub use payments::AffiliateInfo;
pub use payments::LabeledPrice;
pub use payments::OrderInfo;
pub use payments::OwnedGift;
pub use payments::OwnedGiftRegular;
pub use payments::OwnedGiftUnique;
pub use payments::OwnedGifts;
pub use payments::PreCheckoutQuery;
pub use payments::ShippingAddress;
pub use payments::ShippingOption;
pub use payments::ShippingQuery;
pub use payments::StarTransaction;
pub use payments::StarTransactions;
pub use payments::TransactionPartner;
pub use poll::InputPollOption;
pub use poll::Poll;
pub use poll::PollAnswer;
pub use poll::PollOption;
pub use poll::PollOptionAdded;
pub use poll::PollOptionDeleted;
pub use sticker::MaskPosition;
pub use sticker::Sticker;
pub use sticker::StickerSet;
pub use sticker::StickerType;
pub use story::InputStoryContent;
pub use story::InputStoryContentPhoto;
pub use story::InputStoryContentVideo;
pub use story::LocationAddress;
pub use story::Story;
pub use story::StoryArea;
pub use story::StoryAreaPosition;
pub use story::StoryAreaType;
pub use suggested_post::SuggestedPostApprovalFailed;
pub use suggested_post::SuggestedPostApproved;
pub use suggested_post::SuggestedPostDeclined;
pub use suggested_post::SuggestedPostInfo;
pub use suggested_post::SuggestedPostPaid;
pub use suggested_post::SuggestedPostParameters;
pub use suggested_post::SuggestedPostPrice;
pub use suggested_post::SuggestedPostRefunded;
pub use update::BusinessBotRights;
pub use update::CallbackQuery;
pub use update::Update;
pub use update::UpdateKind;
pub use update::UserChatBoosts;
pub use user::BotAccessSettings;
pub use user::BotCommand;
pub use user::BotDescription;
pub use user::BotName;
pub use user::BotShortDescription;
pub use user::ChatAdministratorRights;
pub use user::ChatId;
pub use user::User;
pub use user::UserProfileAudios;
pub use user::UserProfilePhotos;
pub use webhook::WebhookInfo;

Modules§

chat
Chat and location types.
chat_member
Chat member status types.
checklist
Checklist content type and related service messages.
direct_messages
Direct messages topic and channel pricing service messages.
file
File and media types.
forum
Forum topic types.
games
Game types.
gifts
Gift types.
inline
Inline query and result types.
keyboard
Keyboard and markup types.
managed_bot
Managed bot service message types.
message
Message and entity types.
passport
Telegram Passport types.
payments
Payment and invoice types.
poll
Poll types.
reaction
Reaction types.
sticker
Sticker types.
story
Story types.
suggested_post
Suggested post types and service messages.
update
Update and event types.
user
User and bot command types.
webhook
Webhook info types.