pub enum MessageContent {
Show 69 variants
MessageText(MessageText),
MessageAnimation(MessageAnimation),
MessageAudio(MessageAudio),
MessageDocument(MessageDocument),
MessagePhoto(MessagePhoto),
MessageSticker(MessageSticker),
MessageVideo(MessageVideo),
MessageVideoNote(MessageVideoNote),
MessageVoiceNote(MessageVoiceNote),
MessageExpiredPhoto,
MessageExpiredVideo,
MessageExpiredVideoNote,
MessageExpiredVoiceNote,
MessageLocation(MessageLocation),
MessageVenue(MessageVenue),
MessageContact(MessageContact),
MessageAnimatedEmoji(MessageAnimatedEmoji),
MessageDice(MessageDice),
MessageGame(MessageGame),
MessagePoll(MessagePoll),
MessageStory(MessageStory),
MessageInvoice(MessageInvoice),
MessageCall(MessageCall),
MessageVideoChatScheduled(MessageVideoChatScheduled),
MessageVideoChatStarted(MessageVideoChatStarted),
MessageVideoChatEnded(MessageVideoChatEnded),
MessageInviteVideoChatParticipants(MessageInviteVideoChatParticipants),
MessageBasicGroupChatCreate(MessageBasicGroupChatCreate),
MessageSupergroupChatCreate(MessageSupergroupChatCreate),
MessageChatChangeTitle(MessageChatChangeTitle),
MessageChatChangePhoto(MessageChatChangePhoto),
MessageChatDeletePhoto,
MessageChatAddMembers(MessageChatAddMembers),
MessageChatJoinByLink,
MessageChatJoinByRequest,
MessageChatDeleteMember(MessageChatDeleteMember),
MessageChatUpgradeTo(MessageChatUpgradeTo),
MessageChatUpgradeFrom(MessageChatUpgradeFrom),
MessagePinMessage(MessagePinMessage),
MessageScreenshotTaken,
MessageChatSetBackground(MessageChatSetBackground),
MessageChatSetTheme(MessageChatSetTheme),
MessageChatSetMessageAutoDeleteTime(MessageChatSetMessageAutoDeleteTime),
MessageChatBoost(MessageChatBoost),
MessageForumTopicCreated(MessageForumTopicCreated),
MessageForumTopicEdited(MessageForumTopicEdited),
MessageForumTopicIsClosedToggled(MessageForumTopicIsClosedToggled),
MessageForumTopicIsHiddenToggled(MessageForumTopicIsHiddenToggled),
MessageSuggestProfilePhoto(MessageSuggestProfilePhoto),
MessageCustomServiceAction(MessageCustomServiceAction),
MessageGameScore(MessageGameScore),
MessagePaymentSuccessful(MessagePaymentSuccessful),
MessagePaymentSuccessfulBot(MessagePaymentSuccessfulBot),
MessageGiftedPremium(MessageGiftedPremium),
MessagePremiumGiftCode(MessagePremiumGiftCode),
MessagePremiumGiveawayCreated,
MessagePremiumGiveaway(MessagePremiumGiveaway),
MessagePremiumGiveawayCompleted(MessagePremiumGiveawayCompleted),
MessagePremiumGiveawayWinners(MessagePremiumGiveawayWinners),
MessageContactRegistered,
MessageUsersShared(MessageUsersShared),
MessageChatShared(MessageChatShared),
MessageBotWriteAccessAllowed(MessageBotWriteAccessAllowed),
MessageWebAppDataSent(MessageWebAppDataSent),
MessageWebAppDataReceived(MessageWebAppDataReceived),
MessagePassportDataSent(MessagePassportDataSent),
MessagePassportDataReceived(MessagePassportDataReceived),
MessageProximityAlertTriggered(MessageProximityAlertTriggered),
MessageUnsupported,
}
Variants§
MessageText(MessageText)
A text message
MessageAnimation(MessageAnimation)
An animation message (GIF-style).
MessageAudio(MessageAudio)
An audio message
MessageDocument(MessageDocument)
A document message (general file)
MessagePhoto(MessagePhoto)
A photo message
MessageSticker(MessageSticker)
A sticker message
MessageVideo(MessageVideo)
A video message
MessageVideoNote(MessageVideoNote)
A video note message
MessageVoiceNote(MessageVoiceNote)
A voice note message
MessageExpiredPhoto
A self-destructed photo message
MessageExpiredVideo
A self-destructed video message
MessageExpiredVideoNote
A self-destructed video note message
MessageExpiredVoiceNote
A self-destructed voice note message
MessageLocation(MessageLocation)
A message with a location
MessageVenue(MessageVenue)
A message with information about a venue
MessageContact(MessageContact)
A message with a user contact
MessageAnimatedEmoji(MessageAnimatedEmoji)
A message with an animated emoji
MessageDice(MessageDice)
A dice message. The dice value is randomly generated by the server
MessageGame(MessageGame)
A message with a game
MessagePoll(MessagePoll)
A message with a poll
MessageStory(MessageStory)
A message with a forwarded story
MessageInvoice(MessageInvoice)
A message with an invoice from a bot. Use getInternalLink with internalLinkTypeBotStart to share the invoice
MessageCall(MessageCall)
A message with information about an ended call
MessageVideoChatScheduled(MessageVideoChatScheduled)
A new video chat was scheduled
MessageVideoChatStarted(MessageVideoChatStarted)
A newly created video chat
MessageVideoChatEnded(MessageVideoChatEnded)
A message with information about an ended video chat
MessageInviteVideoChatParticipants(MessageInviteVideoChatParticipants)
A message with information about an invitation to a video chat
MessageBasicGroupChatCreate(MessageBasicGroupChatCreate)
A newly created basic group
MessageSupergroupChatCreate(MessageSupergroupChatCreate)
A newly created supergroup or channel
MessageChatChangeTitle(MessageChatChangeTitle)
An updated chat title
MessageChatChangePhoto(MessageChatChangePhoto)
An updated chat photo
MessageChatDeletePhoto
A deleted chat photo
MessageChatAddMembers(MessageChatAddMembers)
New chat members were added
MessageChatJoinByLink
A new member joined the chat via an invite link
MessageChatJoinByRequest
A new member was accepted to the chat by an administrator
MessageChatDeleteMember(MessageChatDeleteMember)
A chat member was deleted
MessageChatUpgradeTo(MessageChatUpgradeTo)
A basic group was upgraded to a supergroup and was deactivated as the result
MessageChatUpgradeFrom(MessageChatUpgradeFrom)
A supergroup has been created from a basic group
MessagePinMessage(MessagePinMessage)
A message has been pinned
MessageScreenshotTaken
A screenshot of a message in the chat has been taken
MessageChatSetBackground(MessageChatSetBackground)
A new background was set in the chat
MessageChatSetTheme(MessageChatSetTheme)
A theme in the chat has been changed
MessageChatSetMessageAutoDeleteTime(MessageChatSetMessageAutoDeleteTime)
The auto-delete or self-destruct timer for messages in the chat has been changed
MessageChatBoost(MessageChatBoost)
The chat was boosted by the sender of the message
MessageForumTopicCreated(MessageForumTopicCreated)
A forum topic has been created
MessageForumTopicEdited(MessageForumTopicEdited)
A forum topic has been edited
MessageForumTopicIsClosedToggled(MessageForumTopicIsClosedToggled)
A forum topic has been closed or opened
MessageForumTopicIsHiddenToggled(MessageForumTopicIsHiddenToggled)
A General forum topic has been hidden or unhidden
MessageSuggestProfilePhoto(MessageSuggestProfilePhoto)
A profile photo was suggested to a user in a private chat
MessageCustomServiceAction(MessageCustomServiceAction)
A non-standard action has happened in the chat
MessageGameScore(MessageGameScore)
A new high score was achieved in a game
MessagePaymentSuccessful(MessagePaymentSuccessful)
A payment has been completed
MessagePaymentSuccessfulBot(MessagePaymentSuccessfulBot)
A payment has been completed; for bots only
MessageGiftedPremium(MessageGiftedPremium)
Telegram Premium was gifted to the user
MessagePremiumGiftCode(MessagePremiumGiftCode)
A Telegram Premium gift code was created for the user
MessagePremiumGiveawayCreated
A Telegram Premium giveaway was created for the chat
MessagePremiumGiveaway(MessagePremiumGiveaway)
A Telegram Premium giveaway
MessagePremiumGiveawayCompleted(MessagePremiumGiveawayCompleted)
A Telegram Premium giveaway without public winners has been completed for the chat
MessagePremiumGiveawayWinners(MessagePremiumGiveawayWinners)
A Telegram Premium giveaway with public winners has been completed for the chat
MessageContactRegistered
A contact has registered with Telegram
The current user shared users, which were requested by the bot
The current user shared a chat, which was requested by the bot
MessageBotWriteAccessAllowed(MessageBotWriteAccessAllowed)
The user allowed the bot to send messages
MessageWebAppDataSent(MessageWebAppDataSent)
Data from a Web App has been sent to a bot
MessageWebAppDataReceived(MessageWebAppDataReceived)
Data from a Web App has been received; for bots only
MessagePassportDataSent(MessagePassportDataSent)
Telegram Passport data has been sent to a bot
MessagePassportDataReceived(MessagePassportDataReceived)
Telegram Passport data has been received; for bots only
MessageProximityAlertTriggered(MessageProximityAlertTriggered)
A user in the chat came within proximity alert range
MessageUnsupported
A message content that is not supported in the current TDLib version
Trait Implementations§
Source§impl Clone for MessageContent
impl Clone for MessageContent
Source§fn clone(&self) -> MessageContent
fn clone(&self) -> MessageContent
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more