pub enum UpdateKind {
Show 24 variants
Message(Message),
EditedMessage(Message),
ChannelPost(Message),
EditedChannelPost(Message),
BusinessConnection(BusinessConnection),
BusinessMessage(Message),
EditedBusinessMessage(Message),
DeletedBusinessMessages(BusinessMessagesDeleted),
MessageReaction(MessageReactionUpdated),
MessageReactionCount(MessageReactionCountUpdated),
InlineQuery(InlineQuery),
ChosenInlineResult(ChosenInlineResult),
CallbackQuery(CallbackQuery),
ShippingQuery(ShippingQuery),
PreCheckoutQuery(PreCheckoutQuery),
PurchasedPaidMedia(PaidMediaPurchased),
Poll(Poll),
PollAnswer(PollAnswer),
MyChatMember(ChatMemberUpdated),
ChatMember(ChatMemberUpdated),
ChatJoinRequest(ChatJoinRequest),
ChatBoost(ChatBoostUpdated),
RemovedChatBoost(ChatBoostRemoved),
Error(Value),
}Variants§
Message(Message)
New incoming message of any kind — text, photo, sticker, etc.
EditedMessage(Message)
New version of a message that is known to the bot and was edited.
ChannelPost(Message)
New incoming channel post of any kind — text, photo, sticker, etc.
EditedChannelPost(Message)
New version of a channel post that is known to the bot and was edited.
BusinessConnection(BusinessConnection)
The bot was connected to or disconnected from a business account, or a user edited an existing connection with the bot
BusinessMessage(Message)
New non-service message from a connected business account
EditedBusinessMessage(Message)
New version of a message from a connected business account
DeletedBusinessMessages(BusinessMessagesDeleted)
Messages were deleted from a connected business account
MessageReaction(MessageReactionUpdated)
A reaction to a message was changed by a user. The bot must be an
administrator in the chat and must explicitly specify
AllowedUpdate::MessageReaction in the list of allowed_updates
to receive these updates. The update isn’t received for reactions
set by bots.
MessageReactionCount(MessageReactionCountUpdated)
Reactions to a message with anonymous reactions were changed. The bot
must be an administrator in the chat and must explicitly specify
AllowedUpdate::MessageReactionCount in the list of allowed_updates
to receive these updates. The updates are grouped and can be sent
with delay up to a few minutes.
InlineQuery(InlineQuery)
New incoming inline query.
ChosenInlineResult(ChosenInlineResult)
The result of an inline query that was chosen by a user and sent to their chat partner. Please see our documentation on the feedback collecting for details on how to enable these updates for your bot.
CallbackQuery(CallbackQuery)
New incoming callback query.
ShippingQuery(ShippingQuery)
New incoming shipping query. Only for invoices with flexible price.
PreCheckoutQuery(PreCheckoutQuery)
New incoming pre-checkout query. Contains full information about checkout.
PurchasedPaidMedia(PaidMediaPurchased)
A user purchased paid media with a non-empty payload sent by the bot in a non-channel chat
Poll(Poll)
New poll state. Bots receive only updates about stopped polls and polls, which are sent by the bot.
PollAnswer(PollAnswer)
A user changed their answer in a non-anonymous poll. Bots receive new votes only in polls that were sent by the bot itself.
MyChatMember(ChatMemberUpdated)
The bot’s chat member status was updated in a chat. For private chats, this update is received only when the bot is blocked or unblocked by the user.
ChatMember(ChatMemberUpdated)
A chat member’s status was updated in a chat. The bot must be an
administrator in the chat and must explicitly specify
AllowedUpdate::ChatMember in the list of allowed_updates to
receive these updates.
ChatJoinRequest(ChatJoinRequest)
A request to join the chat has been sent. The bot must have the can_invite_users administrator right in the chat to receive these updates.
ChatBoost(ChatBoostUpdated)
A chat boost was added or changed. The bot must be an administrator in the chat to receive these updates.
RemovedChatBoost(ChatBoostRemoved)
A boost was removed from a chat. The bot must be an administrator in the chat to receive these updates.
Error(Value)
An error that happened during deserialization.
This allows teloxide to continue working even if telegram adds a new
kinds of updates.
Note that deserialize implementation always returns an empty value, teloxide fills in the data when doing deserialization.
Trait Implementations§
Source§impl Clone for UpdateKind
impl Clone for UpdateKind
Source§fn clone(&self) -> UpdateKind
fn clone(&self) -> UpdateKind
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for UpdateKind
impl Debug for UpdateKind
Source§impl<'de> Deserialize<'de> for UpdateKind
impl<'de> Deserialize<'de> for UpdateKind
Source§fn deserialize<D>(
deserializer: D,
) -> Result<UpdateKind, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<UpdateKind, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Source§impl PartialEq for UpdateKind
impl PartialEq for UpdateKind
Source§impl Serialize for UpdateKind
impl Serialize for UpdateKind
Source§fn serialize<S>(
&self,
s: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
s: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
impl StructuralPartialEq for UpdateKind
Auto Trait Implementations§
impl Freeze for UpdateKind
impl RefUnwindSafe for UpdateKind
impl Send for UpdateKind
impl Sync for UpdateKind
impl Unpin for UpdateKind
impl UnwindSafe for UpdateKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Erasable for T
impl<T> Erasable for T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more