Struct telegram_typings::Message [] [src]

pub struct Message {
    pub message_id: i64,
    pub from: Option<Box<User>>,
    pub date: i64,
    pub chat: Box<Chat>,
    pub forward_from: Option<Box<User>>,
    pub forward_from_chat: Option<Box<Chat>>,
    pub forward_from_message_id: Option<i64>,
    pub forward_signature: Option<String>,
    pub forward_date: Option<i64>,
    pub reply_to_message: Option<Box<Message>>,
    pub edit_date: Option<i64>,
    pub media_group_id: Option<String>,
    pub author_signature: Option<String>,
    pub text: Option<String>,
    pub entities: Option<Vec<Box<MessageEntity>>>,
    pub caption_entities: Option<Vec<Box<MessageEntity>>>,
    pub audio: Option<Box<Audio>>,
    pub document: Option<Box<Document>>,
    pub game: Option<Box<Game>>,
    pub photo: Option<Vec<Box<PhotoSize>>>,
    pub sticker: Option<Box<Sticker>>,
    pub video: Option<Box<Video>>,
    pub voice: Option<Box<Voice>>,
    pub video_note: Option<Box<VideoNote>>,
    pub caption: Option<String>,
    pub contact: Option<Box<Contact>>,
    pub location: Option<Box<Location>>,
    pub venue: Option<Box<Venue>>,
    pub new_chat_members: Option<Vec<Box<User>>>,
    pub left_chat_member: Option<Box<User>>,
    pub new_chat_title: Option<String>,
    pub new_chat_photo: Option<Vec<Box<PhotoSize>>>,
    pub delete_chat_photo: Option<bool>,
    pub group_chat_created: Option<bool>,
    pub supergroup_chat_created: Option<bool>,
    pub channel_chat_created: Option<bool>,
    pub migrate_to_chat_id: Option<i64>,
    pub migrate_from_chat_id: Option<i64>,
    pub pinned_message: Option<Box<Message>>,
    pub invoice: Option<Box<Invoice>>,
    pub successful_payment: Option<Box<SuccessfulPayment>>,
    pub connected_website: Option<String>,
}

This object represents a message.

Fields

Unique message identifier inside this chat

Sender, empty for messages sent to channels

Date the message was sent in Unix time

Conversation the message belongs to

For forwarded messages, sender of the original message

For messages forwarded from channels, information about the original channel

For messages forwarded from channels, identifier of the original message in the channel

For messages forwarded from channels, signature of the post author if present

For forwarded messages, date the original message was sent in Unix time

For replies, the original message. Note that the Message object in this field will not contain further reply_to_message fields even if it itself is a reply.

Date the message was last edited in Unix time

The unique identifier of a media message group this message belongs to

Signature of the post author for messages in channels

For text messages, the actual UTF-8 text of the message, 0-4096 characters.

For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text

For messages with a caption, special entities like usernames, URLs, bot commands, etc. that appear in the caption

Message is an audio file, information about the file

Message is a general file, information about the file

Message is a game, information about the game. More about games » See https://core.telegram.org/bots/api#games

Message is a photo, available sizes of the photo

Message is a sticker, information about the sticker

Message is a video, information about the video

Message is a voice message, information about the file

Message is a video note, information about the video message See https://telegram.org/blog/video-messages-and-telescope

Caption for the audio, document, photo, video or voice, 0-200 characters

Message is a shared contact, information about the contact

Message is a shared location, information about the location

Message is a venue, information about the venue

New members that were added to the group or supergroup and information about them (the bot itself may be one of these members)

A member was removed from the group, information about them (this member may be the bot itself)

A chat title was changed to this value

A chat photo was change to this value

Service message: the chat photo was deleted

Service message: the group has been created

Service message: the supergroup has been created. This field can‘t be received in a message coming through updates, because bot can’t be a member of a supergroup when it is created. It can only be found in reply_to_message if someone replies to a very first message in a directly created supergroup.

Service message: the channel has been created. This field can‘t be received in a message coming through updates, because bot can’t be a member of a channel when it is created. It can only be found in reply_to_message if someone replies to a very first message in a channel.

The group has been migrated to a supergroup with the specified identifier. This number may be greater than 32 bits and some programming languages may have difficulty/silent defects in interpreting it. But it is smaller than 52 bits, so a signed 64 bit integer or double-precision float type are safe for storing this identifier.

The supergroup has been migrated from a group with the specified identifier. This number may be greater than 32 bits and some programming languages may have difficulty/silent defects in interpreting it. But it is smaller than 52 bits, so a signed 64 bit integer or double-precision float type are safe for storing this identifier.

Specified message was pinned. Note that the Message object in this field will not contain further reply_to_message fields even if it is itself a reply.

Message is an invoice for a payment, information about the invoice. More about payments » See https://core.telegram.org/bots/api#payments

Message is a service message about a successful payment, information about the payment. More about payments » See https://core.telegram.org/bots/api#payments

The domain name of the website on which the user has logged in. More about Telegram Login » See https://core.telegram.org/bots/api/widgets/login

Trait Implementations

impl Debug for Message
[src]

[src]

Formats the value using the given formatter. Read more

impl Clone for Message
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl Send for Message

impl Sync for Message