{
  "name": "Message",
  "anchor": "message",
  "description": [
    "This object represents a message."
  ],
  "table": {
    "headers": [
      "Field",
      "Type",
      "Description"
    ],
    "rows": [
      {
        "field": "message_id",
        "type": "Integer",
        "description": "Unique message identifier inside this chat. In specific instances (e.g., message containing a video sent to a big chat), the server might automatically schedule a message instead of sending it immediately. In such cases, this field will be 0 and the relevant message will be unusable until it is actually sent"
      },
      {
        "field": "message_thread_id",
        "type": "Integer",
        "description": "Optional . Unique identifier of a message thread or forum topic to which the message belongs; for supergroups and private chats only"
      },
      {
        "field": "direct_messages_topic",
        "type": "DirectMessagesTopic",
        "description": "Optional . Information about the direct messages chat topic that contains the message"
      },
      {
        "field": "from",
        "type": "User",
        "description": "Optional . Sender of the message; may be empty for messages sent to channels. For backward compatibility, if the message was sent on behalf of a chat, the field contains a fake sender user in non-channel chats"
      },
      {
        "field": "sender_chat",
        "type": "Chat",
        "description": "Optional . Sender of the message when sent on behalf of a chat. For example, the supergroup itself for messages sent by its anonymous administrators or a linked channel for messages automatically forwarded to the channel's discussion group. For backward compatibility, if the message was sent on behalf of a chat, the field from contains a fake sender user in non-channel chats."
      },
      {
        "field": "sender_boost_count",
        "type": "Integer",
        "description": "Optional . If the sender of the message boosted the chat, the number of boosts added by the user"
      },
      {
        "field": "sender_business_bot",
        "type": "User",
        "description": "Optional . The bot that actually sent the message on behalf of the business account. Available only for outgoing messages sent on behalf of the connected business account."
      },
      {
        "field": "sender_tag",
        "type": "String",
        "description": "Optional . Tag or custom title of the sender of the message; for supergroups only"
      },
      {
        "field": "date",
        "type": "Integer",
        "description": "Date the message was sent in Unix time. It is always a positive number, representing a valid date."
      },
      {
        "field": "business_connection_id",
        "type": "String",
        "description": "Optional . Unique identifier of the business connection from which the message was received. If non-empty, the message belongs to a chat of the corresponding business account that is independent from any potential bot chat which might share the same identifier."
      },
      {
        "field": "chat",
        "type": "Chat",
        "description": "Chat the message belongs to"
      },
      {
        "field": "forward_origin",
        "type": "MessageOrigin",
        "description": "Optional . Information about the original message for forwarded messages"
      },
      {
        "field": "is_topic_message",
        "type": "True",
        "description": "Optional . True , if the message is sent to a topic in a forum supergroup or a private chat with the bot"
      },
      {
        "field": "is_automatic_forward",
        "type": "True",
        "description": "Optional . True , if the message is a channel post that was automatically forwarded to the connected discussion group"
      },
      {
        "field": "reply_to_message",
        "type": "Message",
        "description": "Optional . For replies in the same chat and message thread, 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."
      },
      {
        "field": "external_reply",
        "type": "ExternalReplyInfo",
        "description": "Optional . Information about the message that is being replied to, which may come from another chat or forum topic"
      },
      {
        "field": "quote",
        "type": "TextQuote",
        "description": "Optional . For replies that quote part of the original message, the quoted part of the message"
      },
      {
        "field": "reply_to_story",
        "type": "Story",
        "description": "Optional . For replies to a story, the original story"
      },
      {
        "field": "reply_to_checklist_task_id",
        "type": "Integer",
        "description": "Optional . Identifier of the specific checklist task that is being replied to"
      },
      {
        "field": "via_bot",
        "type": "User",
        "description": "Optional . Bot through which the message was sent"
      },
      {
        "field": "edit_date",
        "type": "Integer",
        "description": "Optional . Date the message was last edited in Unix time"
      },
      {
        "field": "has_protected_content",
        "type": "True",
        "description": "Optional . True , if the message can't be forwarded"
      },
      {
        "field": "is_from_offline",
        "type": "True",
        "description": "Optional . True , if the message was sent by an implicit action, for example, as an away or a greeting business message, or as a scheduled message"
      },
      {
        "field": "is_paid_post",
        "type": "True",
        "description": "Optional . True , if the message is a paid post. Note that such posts must not be deleted for 24 hours to receive the payment and can't be edited."
      },
      {
        "field": "media_group_id",
        "type": "String",
        "description": "Optional . The unique identifier inside this chat of a media message group this message belongs to"
      },
      {
        "field": "author_signature",
        "type": "String",
        "description": "Optional . Signature of the post author for messages in channels, or the custom title of an anonymous group administrator"
      },
      {
        "field": "paid_star_count",
        "type": "Integer",
        "description": "Optional . The number of Telegram Stars that were paid by the sender of the message to send it"
      },
      {
        "field": "text",
        "type": "String",
        "description": "Optional . For text messages, the actual UTF-8 text of the message"
      },
      {
        "field": "entities",
        "type": "Array of MessageEntity",
        "description": "Optional . For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text"
      },
      {
        "field": "link_preview_options",
        "type": "LinkPreviewOptions",
        "description": "Optional . Options used for link preview generation for the message, if it is a text message and link preview options were changed"
      },
      {
        "field": "suggested_post_info",
        "type": "SuggestedPostInfo",
        "description": "Optional . Information about suggested post parameters if the message is a suggested post in a channel direct messages chat. If the message is an approved or declined suggested post, then it can't be edited."
      },
      {
        "field": "effect_id",
        "type": "String",
        "description": "Optional . Unique identifier of the message effect added to the message"
      },
      {
        "field": "animation",
        "type": "Animation",
        "description": "Optional . Message is an animation, information about the animation. For backward compatibility, when this field is set, the document field will also be set"
      },
      {
        "field": "audio",
        "type": "Audio",
        "description": "Optional . Message is an audio file, information about the file"
      },
      {
        "field": "document",
        "type": "Document",
        "description": "Optional . Message is a general file, information about the file"
      },
      {
        "field": "paid_media",
        "type": "PaidMediaInfo",
        "description": "Optional . Message contains paid media; information about the paid media"
      },
      {
        "field": "photo",
        "type": "Array of PhotoSize",
        "description": "Optional . Message is a photo, available sizes of the photo"
      },
      {
        "field": "sticker",
        "type": "Sticker",
        "description": "Optional . Message is a sticker, information about the sticker"
      },
      {
        "field": "story",
        "type": "Story",
        "description": "Optional . Message is a forwarded story"
      },
      {
        "field": "video",
        "type": "Video",
        "description": "Optional . Message is a video, information about the video"
      },
      {
        "field": "video_note",
        "type": "VideoNote",
        "description": "Optional . Message is a video note , information about the video message"
      },
      {
        "field": "voice",
        "type": "Voice",
        "description": "Optional . Message is a voice message, information about the file"
      },
      {
        "field": "caption",
        "type": "String",
        "description": "Optional . Caption for the animation, audio, document, paid media, photo, video or voice"
      },
      {
        "field": "caption_entities",
        "type": "Array of MessageEntity",
        "description": "Optional . For messages with a caption, special entities like usernames, URLs, bot commands, etc. that appear in the caption"
      },
      {
        "field": "show_caption_above_media",
        "type": "True",
        "description": "Optional . True , if the caption must be shown above the message media"
      },
      {
        "field": "has_media_spoiler",
        "type": "True",
        "description": "Optional . True , if the message media is covered by a spoiler animation"
      },
      {
        "field": "checklist",
        "type": "Checklist",
        "description": "Optional . Message is a checklist"
      },
      {
        "field": "contact",
        "type": "Contact",
        "description": "Optional . Message is a shared contact, information about the contact"
      },
      {
        "field": "dice",
        "type": "Dice",
        "description": "Optional . Message is a dice with random value"
      },
      {
        "field": "game",
        "type": "Game",
        "description": "Optional . Message is a game, information about the game. More about games »"
      },
      {
        "field": "poll",
        "type": "Poll",
        "description": "Optional . Message is a native poll, information about the poll"
      },
      {
        "field": "venue",
        "type": "Venue",
        "description": "Optional . Message is a venue, information about the venue. For backward compatibility, when this field is set, the location field will also be set"
      },
      {
        "field": "location",
        "type": "Location",
        "description": "Optional . Message is a shared location, information about the location"
      },
      {
        "field": "new_chat_members",
        "type": "Array of User",
        "description": "Optional . New members that were added to the group or supergroup and information about them (the bot itself may be one of these members)"
      },
      {
        "field": "left_chat_member",
        "type": "User",
        "description": "Optional . A member was removed from the group, information about them (this member may be the bot itself)"
      },
      {
        "field": "chat_owner_left",
        "type": "ChatOwnerLeft",
        "description": "Optional . Service message: chat owner has left"
      },
      {
        "field": "chat_owner_changed",
        "type": "ChatOwnerChanged",
        "description": "Optional . Service message: chat owner has changed"
      },
      {
        "field": "new_chat_title",
        "type": "String",
        "description": "Optional . A chat title was changed to this value"
      },
      {
        "field": "new_chat_photo",
        "type": "Array of PhotoSize",
        "description": "Optional . A chat photo was change to this value"
      },
      {
        "field": "delete_chat_photo",
        "type": "True",
        "description": "Optional . Service message: the chat photo was deleted"
      },
      {
        "field": "group_chat_created",
        "type": "True",
        "description": "Optional . Service message: the group has been created"
      },
      {
        "field": "supergroup_chat_created",
        "type": "True",
        "description": "Optional . 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."
      },
      {
        "field": "channel_chat_created",
        "type": "True",
        "description": "Optional . 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."
      },
      {
        "field": "message_auto_delete_timer_changed",
        "type": "MessageAutoDeleteTimerChanged",
        "description": "Optional . Service message: auto-delete timer settings changed in the chat"
      },
      {
        "field": "migrate_to_chat_id",
        "type": "Integer",
        "description": "Optional . The group has been migrated to a supergroup with the specified identifier. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this identifier."
      },
      {
        "field": "migrate_from_chat_id",
        "type": "Integer",
        "description": "Optional . The supergroup has been migrated from a group with the specified identifier. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this identifier."
      },
      {
        "field": "pinned_message",
        "type": "MaybeInaccessibleMessage",
        "description": "Optional . Specified message was pinned. Note that the Message object in this field will not contain further reply_to_message fields even if it itself is a reply."
      },
      {
        "field": "invoice",
        "type": "Invoice",
        "description": "Optional . Message is an invoice for a payment , information about the invoice. More about payments »"
      },
      {
        "field": "successful_payment",
        "type": "SuccessfulPayment",
        "description": "Optional . Message is a service message about a successful payment, information about the payment. More about payments »"
      },
      {
        "field": "refunded_payment",
        "type": "RefundedPayment",
        "description": "Optional . Message is a service message about a refunded payment, information about the payment. More about payments »"
      },
      {
        "field": "users_shared",
        "type": "UsersShared",
        "description": "Optional . Service message: users were shared with the bot"
      },
      {
        "field": "chat_shared",
        "type": "ChatShared",
        "description": "Optional . Service message: a chat was shared with the bot"
      },
      {
        "field": "gift",
        "type": "GiftInfo",
        "description": "Optional . Service message: a regular gift was sent or received"
      },
      {
        "field": "unique_gift",
        "type": "UniqueGiftInfo",
        "description": "Optional . Service message: a unique gift was sent or received"
      },
      {
        "field": "gift_upgrade_sent",
        "type": "GiftInfo",
        "description": "Optional . Service message: upgrade of a gift was purchased after the gift was sent"
      },
      {
        "field": "connected_website",
        "type": "String",
        "description": "Optional . The domain name of the website on which the user has logged in. More about Telegram Login »"
      },
      {
        "field": "write_access_allowed",
        "type": "WriteAccessAllowed",
        "description": "Optional . Service message: the user allowed the bot to write messages after adding it to the attachment or side menu, launching a Web App from a link, or accepting an explicit request from a Web App sent by the method requestWriteAccess"
      },
      {
        "field": "passport_data",
        "type": "PassportData",
        "description": "Optional . Telegram Passport data"
      },
      {
        "field": "proximity_alert_triggered",
        "type": "ProximityAlertTriggered",
        "description": "Optional . Service message. A user in the chat triggered another user's proximity alert while sharing Live Location."
      },
      {
        "field": "boost_added",
        "type": "ChatBoostAdded",
        "description": "Optional . Service message: user boosted the chat"
      },
      {
        "field": "chat_background_set",
        "type": "ChatBackground",
        "description": "Optional . Service message: chat background set"
      },
      {
        "field": "checklist_tasks_done",
        "type": "ChecklistTasksDone",
        "description": "Optional . Service message: some tasks in a checklist were marked as done or not done"
      },
      {
        "field": "checklist_tasks_added",
        "type": "ChecklistTasksAdded",
        "description": "Optional . Service message: tasks were added to a checklist"
      },
      {
        "field": "direct_message_price_changed",
        "type": "DirectMessagePriceChanged",
        "description": "Optional . Service message: the price for paid messages in the corresponding direct messages chat of a channel has changed"
      },
      {
        "field": "forum_topic_created",
        "type": "ForumTopicCreated",
        "description": "Optional . Service message: forum topic created"
      },
      {
        "field": "forum_topic_edited",
        "type": "ForumTopicEdited",
        "description": "Optional . Service message: forum topic edited"
      },
      {
        "field": "forum_topic_closed",
        "type": "ForumTopicClosed",
        "description": "Optional . Service message: forum topic closed"
      },
      {
        "field": "forum_topic_reopened",
        "type": "ForumTopicReopened",
        "description": "Optional . Service message: forum topic reopened"
      },
      {
        "field": "general_forum_topic_hidden",
        "type": "GeneralForumTopicHidden",
        "description": "Optional . Service message: the 'General' forum topic hidden"
      },
      {
        "field": "general_forum_topic_unhidden",
        "type": "GeneralForumTopicUnhidden",
        "description": "Optional . Service message: the 'General' forum topic unhidden"
      },
      {
        "field": "giveaway_created",
        "type": "GiveawayCreated",
        "description": "Optional . Service message: a scheduled giveaway was created"
      },
      {
        "field": "giveaway",
        "type": "Giveaway",
        "description": "Optional . The message is a scheduled giveaway message"
      },
      {
        "field": "giveaway_winners",
        "type": "GiveawayWinners",
        "description": "Optional . A giveaway with public winners was completed"
      },
      {
        "field": "giveaway_completed",
        "type": "GiveawayCompleted",
        "description": "Optional . Service message: a giveaway without public winners was completed"
      },
      {
        "field": "paid_message_price_changed",
        "type": "PaidMessagePriceChanged",
        "description": "Optional . Service message: the price for paid messages has changed in the chat"
      },
      {
        "field": "suggested_post_approved",
        "type": "SuggestedPostApproved",
        "description": "Optional . Service message: a suggested post was approved"
      },
      {
        "field": "suggested_post_approval_failed",
        "type": "SuggestedPostApprovalFailed",
        "description": "Optional . Service message: approval of a suggested post has failed"
      },
      {
        "field": "suggested_post_declined",
        "type": "SuggestedPostDeclined",
        "description": "Optional . Service message: a suggested post was declined"
      },
      {
        "field": "suggested_post_paid",
        "type": "SuggestedPostPaid",
        "description": "Optional . Service message: payment for a suggested post was received"
      },
      {
        "field": "suggested_post_refunded",
        "type": "SuggestedPostRefunded",
        "description": "Optional . Service message: payment for a suggested post was refunded"
      },
      {
        "field": "video_chat_scheduled",
        "type": "VideoChatScheduled",
        "description": "Optional . Service message: video chat scheduled"
      },
      {
        "field": "video_chat_started",
        "type": "VideoChatStarted",
        "description": "Optional . Service message: video chat started"
      },
      {
        "field": "video_chat_ended",
        "type": "VideoChatEnded",
        "description": "Optional . Service message: video chat ended"
      },
      {
        "field": "video_chat_participants_invited",
        "type": "VideoChatParticipantsInvited",
        "description": "Optional . Service message: new participants invited to a video chat"
      },
      {
        "field": "web_app_data",
        "type": "WebAppData",
        "description": "Optional . Service message: data sent by a Web App"
      },
      {
        "field": "reply_markup",
        "type": "InlineKeyboardMarkup",
        "description": "Optional . Inline keyboard attached to the message. login_url buttons are represented as ordinary url buttons."
      }
    ]
  },
  "notes": []
}