diff --git a/schemas/botapi.json b/schemas/botapi.json index 450f933..9688c34 100644 --- a/schemas/botapi.json +++ b/schemas/botapi.json @@ -1,5 +1,5 @@ { - "version": "6.9.0", + "version": "7.0.0", "types": [ { "name": "Update", @@ -45,6 +45,22 @@ "optional": true, "description": "Optional. New version of a channel post that is known to the bot and was edited" }, + { + "name": "message_reaction", + "types": [ + "MessageReactionUpdated" + ], + "optional": true, + "description": "Optional. A reaction to a message was changed by a user. The bot must be an administrator in the chat and must explicitly specify \"message_reaction\" in the list of allowed_updates to receive these updates. The update isn't received for reactions set by bots." + }, + { + "name": "message_reaction_count", + "types": [ + "MessageReactionCountUpdated" + ], + "optional": true, + "description": "Optional. Reactions to a message with anonymous reactions were changed. The bot must be an administrator in the chat and must explicitly specify \"message_reaction_count\" in the list of allowed_updates to receive these updates." + }, { "name": "inline_query", "types": [ @@ -115,7 +131,7 @@ "ChatMemberUpdated" ], "optional": true, - "description": "Optional. A chat member's status was updated in a chat. The bot must be an administrator in the chat and must explicitly specify “chat_member” in the list of allowed_updates to receive these updates." + "description": "Optional. A chat member's status was updated in a chat. The bot must be an administrator in the chat and must explicitly specify \"chat_member\" in the list of allowed_updates to receive these updates." }, { "name": "chat_join_request", @@ -124,6 +140,22 @@ ], "optional": true, "description": "Optional. 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." + }, + { + "name": "chat_boost", + "types": [ + "ChatBoostUpdated" + ], + "optional": true, + "description": "Optional. A chat boost was added or changed. The bot must be an administrator in the chat to receive these updates." + }, + { + "name": "removed_chat_boost", + "types": [ + "ChatBoostRemoved" + ], + "optional": true, + "description": "Optional. A boost was removed from a chat. The bot must be an administrator in the chat to receive these updates." } ], "extended_by": [] @@ -381,13 +413,53 @@ "optional": true, "description": "Optional. If non-empty, the list of all active chat usernames; for private chats, supergroups and channels. Returned only in getChat." }, + { + "name": "available_reactions", + "types": [ + "Array" + ], + "optional": true, + "description": "Optional. List of available reactions allowed in the chat. If omitted, then all emoji reactions are allowed. Returned only in getChat." + }, + { + "name": "accent_color_id", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. Identifier of the accent color for the chat name and backgrounds of the chat photo, reply header, and link preview. See accent colors for more details. Returned only in getChat. Always returned in getChat." + }, + { + "name": "background_custom_emoji_id", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. Custom emoji identifier of emoji chosen by the chat for the reply header and link preview background. Returned only in getChat." + }, + { + "name": "profile_accent_color_id", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. Identifier of the accent color for the chat's profile background. See profile accent colors for more details. Returned only in getChat." + }, + { + "name": "profile_background_custom_emoji_id", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. Custom emoji identifier of the emoji chosen by the chat for its profile background. Returned only in getChat." + }, { "name": "emoji_status_custom_emoji_id", "types": [ "string" ], "optional": true, - "description": "Optional. Custom emoji identifier of emoji status of the other party in a private chat. Returned only in getChat." + "description": "Optional. Custom emoji identifier of the emoji status of the chat or the other party in a private chat. Returned only in getChat." }, { "name": "emoji_status_expiration_date", @@ -395,7 +467,7 @@ "int" ], "optional": true, - "description": "Optional. Expiration date of the emoji status of the other party in a private chat in Unix time, if any. Returned only in getChat." + "description": "Optional. Expiration date of the emoji status of the chat or the other party in a private chat, in Unix time, if any. Returned only in getChat." }, { "name": "bio", @@ -516,6 +588,15 @@ "description": "Optional. True, if messages from the chat can't be forwarded to other chats. Returned only in getChat.", "default": true }, + { + "name": "has_visible_history", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if new chat members will have access to old messages; available only to chat administrators. Returned only in getChat.", + "default": true + }, { "name": "sticker_set_name", "types": [ @@ -594,7 +675,7 @@ "int" ], "optional": false, - "description": "Date the message was sent in Unix time" + "description": "Date the message was sent in Unix time. It is always a positive number, representing a valid date." }, { "name": "chat", @@ -602,55 +683,15 @@ "Chat" ], "optional": false, - "description": "Conversation the message belongs to" + "description": "Chat the message belongs to" }, { - "name": "forward_from", + "name": "forward_origin", "types": [ - "User" + "MessageOrigin" ], "optional": true, - "description": "Optional. For forwarded messages, sender of the original message" - }, - { - "name": "forward_from_chat", - "types": [ - "Chat" - ], - "optional": true, - "description": "Optional. For messages forwarded from channels or from anonymous administrators, information about the original sender chat" - }, - { - "name": "forward_from_message_id", - "types": [ - "int" - ], - "optional": true, - "description": "Optional. For messages forwarded from channels, identifier of the original message in the channel" - }, - { - "name": "forward_signature", - "types": [ - "string" - ], - "optional": true, - "description": "Optional. For forwarded messages that were originally sent in channels or by an anonymous chat administrator, signature of the message sender if present" - }, - { - "name": "forward_sender_name", - "types": [ - "string" - ], - "optional": true, - "description": "Optional. Sender's name for messages forwarded from users who disallow adding a link to their account in forwarded messages" - }, - { - "name": "forward_date", - "types": [ - "int" - ], - "optional": true, - "description": "Optional. For forwarded messages, date the original message was sent in Unix time" + "description": "Optional. Information about the original message for forwarded messages" }, { "name": "is_topic_message", @@ -676,7 +717,23 @@ "Message" ], "optional": true, - "description": "Optional. 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." + "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." + }, + { + "name": "external_reply", + "types": [ + "ExternalReplyInfo" + ], + "optional": true, + "description": "Optional. Information about the message that is being replied to, which may come from another chat or forum topic" + }, + { + "name": "quote", + "types": [ + "TextQuote" + ], + "optional": true, + "description": "Optional. For replies that quote part of the original message, the quoted part of the message" }, { "name": "via_bot", @@ -735,6 +792,14 @@ "optional": true, "description": "Optional. For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text" }, + { + "name": "link_preview_options", + "types": [ + "LinkPreviewOptions" + ], + "optional": true, + "description": "Optional. Options used for link preview generation for the message, if it is a text message and link preview options were changed" + }, { "name": "animation", "types": [ @@ -975,10 +1040,10 @@ { "name": "pinned_message", "types": [ - "Message" + "MaybeInaccessibleMessage" ], "optional": true, - "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 is itself a reply." + "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." }, { "name": "invoice", @@ -997,12 +1062,12 @@ "description": "Optional. Message is a service message about a successful payment, information about the payment. More about payments »" }, { - "name": "user_shared", + "name": "users_shared", "types": [ - "UserShared" + "UsersShared" ], "optional": true, - "description": "Optional. Service message: a user was shared with the bot" + "description": "Optional. Service message: users were shared with the bot" }, { "name": "chat_shared", @@ -1092,6 +1157,38 @@ "optional": true, "description": "Optional. Service message: the 'General' forum topic unhidden" }, + { + "name": "giveaway_created", + "types": [ + "GiveawayCreated" + ], + "optional": true, + "description": "Optional. Service message: a scheduled giveaway was created" + }, + { + "name": "giveaway", + "types": [ + "Giveaway" + ], + "optional": true, + "description": "Optional. The message is a scheduled giveaway message" + }, + { + "name": "giveaway_winners", + "types": [ + "GiveawayWinners" + ], + "optional": true, + "description": "Optional. A giveaway with public winners was completed" + }, + { + "name": "giveaway_completed", + "types": [ + "GiveawayCompleted" + ], + "optional": true, + "description": "Optional. Service message: a giveaway without public winners was completed" + }, { "name": "video_chat_scheduled", "types": [ @@ -1158,6 +1255,46 @@ ], "extended_by": [] }, + { + "name": "InaccessibleMessage", + "description": "This object describes a message that was deleted or is otherwise inaccessible to the bot.", + "fields": [ + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "Chat the message belonged to" + }, + { + "name": "message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Unique message identifier inside the chat" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Always 0. The field can be used to differentiate regular and inaccessible messages." + } + ], + "extended_by": [] + }, + { + "name": "MaybeInaccessibleMessage", + "description": "This object describes a message that can be inaccessible to the bot. It can be one of", + "fields": [], + "extended_by": [ + "Message", + "InaccessibleMessage" + ] + }, { "name": "MessageEntity", "description": "This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.", @@ -1168,7 +1305,7 @@ "string" ], "optional": false, - "description": "Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames), “custom_emoji” (for inline custom emoji stickers)" + "description": "Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “blockquote” (block quotation), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames), “custom_emoji” (for inline custom emoji stickers)" }, { "name": "offset", @@ -1221,6 +1358,461 @@ ], "extended_by": [] }, + { + "name": "TextQuote", + "description": "This object contains information about the quoted part of a message that is replied to by the given message.", + "fields": [ + { + "name": "text", + "types": [ + "string" + ], + "optional": false, + "description": "Text of the quoted part of a message that is replied to by the given message" + }, + { + "name": "entities", + "types": [ + "Array" + ], + "optional": true, + "description": "Optional. Special entities that appear in the quote. Currently, only bold, italic, underline, strikethrough, spoiler, and custom_emoji entities are kept in quotes." + }, + { + "name": "position", + "types": [ + "int" + ], + "optional": false, + "description": "Approximate quote position in the original message in UTF-16 code units as specified by the sender" + }, + { + "name": "is_manual", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the quote was chosen manually by the message sender. Otherwise, the quote was added automatically by the server.", + "default": true + } + ], + "extended_by": [] + }, + { + "name": "ExternalReplyInfo", + "description": "This object contains information about a message that is being replied to, which may come from another chat or forum topic.", + "fields": [ + { + "name": "origin", + "types": [ + "MessageOrigin" + ], + "optional": false, + "description": "Origin of the message replied to by the given message" + }, + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": true, + "description": "Optional. Chat the original message belongs to. Available only if the chat is a supergroup or a channel." + }, + { + "name": "message_id", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. Unique message identifier inside the original chat. Available only if the original chat is a supergroup or a channel." + }, + { + "name": "link_preview_options", + "types": [ + "LinkPreviewOptions" + ], + "optional": true, + "description": "Optional. Options used for link preview generation for the original message, if it is a text message" + }, + { + "name": "animation", + "types": [ + "Animation" + ], + "optional": true, + "description": "Optional. Message is an animation, information about the animation" + }, + { + "name": "audio", + "types": [ + "Audio" + ], + "optional": true, + "description": "Optional. Message is an audio file, information about the file" + }, + { + "name": "document", + "types": [ + "Document" + ], + "optional": true, + "description": "Optional. Message is a general file, information about the file" + }, + { + "name": "photo", + "types": [ + "Array" + ], + "optional": true, + "description": "Optional. Message is a photo, available sizes of the photo" + }, + { + "name": "sticker", + "types": [ + "Sticker" + ], + "optional": true, + "description": "Optional. Message is a sticker, information about the sticker" + }, + { + "name": "story", + "types": [ + "Story" + ], + "optional": true, + "description": "Optional. Message is a forwarded story" + }, + { + "name": "video", + "types": [ + "Video" + ], + "optional": true, + "description": "Optional. Message is a video, information about the video" + }, + { + "name": "video_note", + "types": [ + "VideoNote" + ], + "optional": true, + "description": "Optional. Message is a video note, information about the video message" + }, + { + "name": "voice", + "types": [ + "Voice" + ], + "optional": true, + "description": "Optional. Message is a voice message, information about the file" + }, + { + "name": "has_media_spoiler", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the message media is covered by a spoiler animation", + "default": true + }, + { + "name": "contact", + "types": [ + "Contact" + ], + "optional": true, + "description": "Optional. Message is a shared contact, information about the contact" + }, + { + "name": "dice", + "types": [ + "Dice" + ], + "optional": true, + "description": "Optional. Message is a dice with random value" + }, + { + "name": "game", + "types": [ + "Game" + ], + "optional": true, + "description": "Optional. Message is a game, information about the game. More about games »" + }, + { + "name": "giveaway", + "types": [ + "Giveaway" + ], + "optional": true, + "description": "Optional. Message is a scheduled giveaway, information about the giveaway" + }, + { + "name": "giveaway_winners", + "types": [ + "GiveawayWinners" + ], + "optional": true, + "description": "Optional. A giveaway with public winners was completed" + }, + { + "name": "invoice", + "types": [ + "Invoice" + ], + "optional": true, + "description": "Optional. Message is an invoice for a payment, information about the invoice. More about payments »" + }, + { + "name": "location", + "types": [ + "Location" + ], + "optional": true, + "description": "Optional. Message is a shared location, information about the location" + }, + { + "name": "poll", + "types": [ + "Poll" + ], + "optional": true, + "description": "Optional. Message is a native poll, information about the poll" + }, + { + "name": "venue", + "types": [ + "Venue" + ], + "optional": true, + "description": "Optional. Message is a venue, information about the venue" + } + ], + "extended_by": [] + }, + { + "name": "ReplyParameters", + "description": "Describes reply parameters for the message that is being sent.", + "fields": [ + { + "name": "message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Identifier of the message that will be replied to in the current chat, or in the chat chat_id if it is specified" + }, + { + "name": "chat_id", + "types": [ + "int", + "string" + ], + "optional": true, + "description": "Optional. If the message to be replied to is from a different chat, unique identifier for the chat or username of the channel (in the format @channelusername)" + }, + { + "name": "allow_sending_without_reply", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. Pass True if the message should be sent even if the specified message to be replied to is not found; can be used only for replies in the same chat and forum topic." + }, + { + "name": "quote", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. Quoted part of the message to be replied to; 0-1024 characters after entities parsing. The quote must be an exact substring of the message to be replied to, including bold, italic, underline, strikethrough, spoiler, and custom_emoji entities. The message will fail to send if the quote isn't found in the original message." + }, + { + "name": "quote_parse_mode", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. Mode for parsing entities in the quote. See formatting options for more details." + }, + { + "name": "quote_entities", + "types": [ + "Array" + ], + "optional": true, + "description": "Optional. A JSON-serialized list of special entities that appear in the quote. It can be specified instead of quote_parse_mode." + }, + { + "name": "quote_position", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. Position of the quote in the original message in UTF-16 code units" + } + ], + "extended_by": [] + }, + { + "name": "MessageOrigin", + "description": "This object describes the origin of a message. It can be one of", + "fields": [], + "extended_by": [ + "MessageOriginUser", + "MessageOriginHiddenUser", + "MessageOriginChat", + "MessageOriginChannel" + ] + }, + { + "name": "MessageOriginUser", + "description": "The message was originally sent by a known user.", + "fields": [ + { + "name": "type", + "types": [ + "string" + ], + "optional": false, + "description": "Type of the message origin, always “user”" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Date the message was sent originally in Unix time" + }, + { + "name": "sender_user", + "types": [ + "User" + ], + "optional": false, + "description": "User that sent the message originally" + } + ], + "extended_by": [] + }, + { + "name": "MessageOriginHiddenUser", + "description": "The message was originally sent by an unknown user.", + "fields": [ + { + "name": "type", + "types": [ + "string" + ], + "optional": false, + "description": "Type of the message origin, always “hidden_user”" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Date the message was sent originally in Unix time" + }, + { + "name": "sender_user_name", + "types": [ + "string" + ], + "optional": false, + "description": "Name of the user that sent the message originally" + } + ], + "extended_by": [] + }, + { + "name": "MessageOriginChat", + "description": "The message was originally sent on behalf of a chat to a group chat.", + "fields": [ + { + "name": "type", + "types": [ + "string" + ], + "optional": false, + "description": "Type of the message origin, always “chat”" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Date the message was sent originally in Unix time" + }, + { + "name": "sender_chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "Chat that sent the message originally" + }, + { + "name": "author_signature", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. For messages originally sent by an anonymous chat administrator, original message author signature" + } + ], + "extended_by": [] + }, + { + "name": "MessageOriginChannel", + "description": "The message was originally sent to a channel chat.", + "fields": [ + { + "name": "type", + "types": [ + "string" + ], + "optional": false, + "description": "Type of the message origin, always “channel”" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Date the message was sent originally in Unix time" + }, + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "Channel chat to which the message was originally sent" + }, + { + "name": "message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Unique message identifier inside the chat" + }, + { + "name": "author_signature", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. Signature of the original post author" + } + ], + "extended_by": [] + }, { "name": "PhotoSize", "description": "This object represents one size of a photo or a file / sticker thumbnail.", @@ -2177,8 +2769,8 @@ "extended_by": [] }, { - "name": "UserShared", - "description": "This object contains information about the user whose identifier was shared with the bot using a KeyboardButtonRequestUser button.", + "name": "UsersShared", + "description": "This object contains information about the users whose identifiers were shared with the bot using a KeyboardButtonRequestUsers button.", "fields": [ { "name": "request_id", @@ -2189,12 +2781,12 @@ "description": "Identifier of the request" }, { - "name": "user_id", + "name": "user_ids", "types": [ - "int" + "Array" ], "optional": false, - "description": "Identifier of the shared user. 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 64-bit integer or double-precision float type are safe for storing this identifier. The bot may not have access to the user and could be unable to use this identifier, unless the user is already known to the bot by some other means." + "description": "Identifiers of the shared users. These numbers may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting them. But they have at most 52 significant bits, so 64-bit integers or double-precision float types are safe for storing these identifiers. The bot may not have access to the users and could be unable to use these identifiers, unless the users are already known to the bot by some other means." } ], "extended_by": [] @@ -2304,6 +2896,260 @@ ], "extended_by": [] }, + { + "name": "GiveawayCreated", + "description": "This object represents a service message about the creation of a scheduled giveaway. Currently holds no information.", + "fields": [], + "extended_by": [] + }, + { + "name": "Giveaway", + "description": "This object represents a message about a scheduled giveaway.", + "fields": [ + { + "name": "chats", + "types": [ + "Array" + ], + "optional": false, + "description": "The list of chats which the user must join to participate in the giveaway" + }, + { + "name": "winners_selection_date", + "types": [ + "int" + ], + "optional": false, + "description": "Point in time (Unix timestamp) when winners of the giveaway will be selected" + }, + { + "name": "winner_count", + "types": [ + "int" + ], + "optional": false, + "description": "The number of users which are supposed to be selected as winners of the giveaway" + }, + { + "name": "only_new_members", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if only users who join the chats after the giveaway started should be eligible to win", + "default": true + }, + { + "name": "has_public_winners", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the list of giveaway winners will be visible to everyone", + "default": true + }, + { + "name": "prize_description", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. Description of additional giveaway prize" + }, + { + "name": "country_codes", + "types": [ + "Array" + ], + "optional": true, + "description": "Optional. A list of two-letter ISO 3166-1 alpha-2 country codes indicating the countries from which eligible users for the giveaway must come. If empty, then all users can participate in the giveaway. Users with a phone number that was bought on Fragment can always participate in giveaways." + }, + { + "name": "premium_subscription_month_count", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. The number of months the Telegram Premium subscription won from the giveaway will be active for" + } + ], + "extended_by": [] + }, + { + "name": "GiveawayWinners", + "description": "This object represents a message about the completion of a giveaway with public winners.", + "fields": [ + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "The chat that created the giveaway" + }, + { + "name": "giveaway_message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Identifier of the messsage with the giveaway in the chat" + }, + { + "name": "winners_selection_date", + "types": [ + "int" + ], + "optional": false, + "description": "Point in time (Unix timestamp) when winners of the giveaway were selected" + }, + { + "name": "winner_count", + "types": [ + "int" + ], + "optional": false, + "description": "Total number of winners in the giveaway" + }, + { + "name": "winners", + "types": [ + "Array" + ], + "optional": false, + "description": "List of up to 100 winners of the giveaway" + }, + { + "name": "additional_chat_count", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. The number of other chats the user had to join in order to be eligible for the giveaway" + }, + { + "name": "premium_subscription_month_count", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. The number of months the Telegram Premium subscription won from the giveaway will be active for" + }, + { + "name": "unclaimed_prize_count", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. Number of undistributed prizes" + }, + { + "name": "only_new_members", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if only users who had joined the chats after the giveaway started were eligible to win", + "default": true + }, + { + "name": "was_refunded", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the giveaway was canceled because the payment for it was refunded", + "default": true + }, + { + "name": "prize_description", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. Description of additional giveaway prize" + } + ], + "extended_by": [] + }, + { + "name": "GiveawayCompleted", + "description": "This object represents a service message about the completion of a giveaway without public winners.", + "fields": [ + { + "name": "winner_count", + "types": [ + "int" + ], + "optional": false, + "description": "Number of winners in the giveaway" + }, + { + "name": "unclaimed_prize_count", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. Number of undistributed prizes" + }, + { + "name": "giveaway_message", + "types": [ + "Message" + ], + "optional": true, + "description": "Optional. Message with the giveaway that was completed, if it wasn't deleted" + } + ], + "extended_by": [] + }, + { + "name": "LinkPreviewOptions", + "description": "Describes the options used for link preview generation.", + "fields": [ + { + "name": "is_disabled", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the link preview is disabled" + }, + { + "name": "url", + "types": [ + "string" + ], + "optional": true, + "description": "Optional. URL to use for the link preview. If empty, then the first URL found in the message text will be used" + }, + { + "name": "prefer_small_media", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the media in the link preview is suppposed to be shrunk; ignored if the URL isn't explicitly specified or media size change isn't supported for the preview" + }, + { + "name": "prefer_large_media", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the media in the link preview is suppposed to be enlarged; ignored if the URL isn't explicitly specified or media size change isn't supported for the preview" + }, + { + "name": "show_above_text", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the link preview must be shown above the message text; otherwise, the link preview will be shown below the message text" + } + ], + "extended_by": [] + }, { "name": "UserProfilePhotos", "description": "This object represent a user's profile pictures.", @@ -2441,7 +3287,7 @@ }, { "name": "KeyboardButton", - "description": "This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_user, request_chat, request_contact, request_location, and request_poll are mutually exclusive.", + "description": "This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_users, request_chat, request_contact, request_location, and request_poll are mutually exclusive.", "fields": [ { "name": "text", @@ -2452,12 +3298,12 @@ "description": "Text of the button. If none of the optional fields are used, it will be sent as a message when the button is pressed" }, { - "name": "request_user", + "name": "request_users", "types": [ - "KeyboardButtonRequestUser" + "KeyboardButtonRequestUsers" ], "optional": true, - "description": "Optional. If specified, pressing the button will open a list of suitable users. Tapping on any user will send their identifier to the bot in a “user_shared” service message. Available in private chats only." + "description": "Optional. If specified, pressing the button will open a list of suitable users. Identifiers of selected users will be sent to the bot in a “users_shared” service message. Available in private chats only." }, { "name": "request_chat", @@ -2503,8 +3349,8 @@ "extended_by": [] }, { - "name": "KeyboardButtonRequestUser", - "description": "This object defines the criteria used to request a suitable user. The identifier of the selected user will be shared with the bot when the corresponding button is pressed. More about requesting users »", + "name": "KeyboardButtonRequestUsers", + "description": "This object defines the criteria used to request suitable users. The identifiers of the selected users will be shared with the bot when the corresponding button is pressed. More about requesting users »", "fields": [ { "name": "request_id", @@ -2512,7 +3358,7 @@ "int" ], "optional": false, - "description": "Signed 32-bit identifier of the request, which will be received back in the UserShared object. Must be unique within the message" + "description": "Signed 32-bit identifier of the request that will be received back in the UsersShared object. Must be unique within the message" }, { "name": "user_is_bot", @@ -2520,7 +3366,7 @@ "bool" ], "optional": true, - "description": "Optional. Pass True to request a bot, pass False to request a regular user. If not specified, no additional restrictions are applied." + "description": "Optional. Pass True to request bots, pass False to request regular users. If not specified, no additional restrictions are applied." }, { "name": "user_is_premium", @@ -2528,7 +3374,16 @@ "bool" ], "optional": true, - "description": "Optional. Pass True to request a premium user, pass False to request a non-premium user. If not specified, no additional restrictions are applied." + "description": "Optional. Pass True to request premium users, pass False to request non-premium users. If not specified, no additional restrictions are applied." + }, + { + "name": "max_quantity", + "types": [ + "int" + ], + "optional": true, + "description": "Optional. The maximum number of users to be selected; 1-10. Defaults to 1.", + "default": 1 } ], "extended_by": [] @@ -2854,10 +3709,10 @@ { "name": "message", "types": [ - "Message" + "MaybeInaccessibleMessage" ], "optional": true, - "description": "Optional. Message with the callback button that originated the query. Note that message content and message date will not be available if the message is too old" + "description": "Optional. Message sent by the bot with the callback button that originated the query" }, { "name": "inline_message_id", @@ -3062,7 +3917,7 @@ "bool" ], "optional": false, - "description": "True, if the administrator can access the chat event log, chat statistics, boost list in channels, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege" + "description": "True, if the administrator can access the chat event log, boost list in channels, see channel members, report spam messages, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege" }, { "name": "can_delete_messages", @@ -3086,7 +3941,7 @@ "bool" ], "optional": false, - "description": "True, if the administrator can restrict, ban or unban chat members" + "description": "True, if the administrator can restrict, ban or unban chat members, or access supergroup statistics" }, { "name": "can_promote_members", @@ -3118,7 +3973,7 @@ "bool" ], "optional": true, - "description": "Optional. True, if the administrator can post messages in the channel; channels only" + "description": "Optional. True, if the administrator can post messages in the channel, or access channel statistics; channels only" }, { "name": "can_edit_messages", @@ -3158,7 +4013,7 @@ "bool" ], "optional": true, - "description": "Optional. True, if the administrator can delete stories posted by other users" + "description": "Optional. True, if the administrator can delete stories posted by other users; channels only" }, { "name": "can_manage_topics", @@ -3171,6 +4026,69 @@ ], "extended_by": [] }, + { + "name": "ChatMemberUpdated", + "description": "This object represents changes in the status of a chat member.", + "fields": [ + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "Chat the user belongs to" + }, + { + "name": "from", + "types": [ + "User" + ], + "optional": false, + "description": "Performer of the action, which resulted in the change" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Date the change was done in Unix time" + }, + { + "name": "old_chat_member", + "types": [ + "ChatMember" + ], + "optional": false, + "description": "Previous information about the chat member" + }, + { + "name": "new_chat_member", + "types": [ + "ChatMember" + ], + "optional": false, + "description": "New information about the chat member" + }, + { + "name": "invite_link", + "types": [ + "ChatInviteLink" + ], + "optional": true, + "description": "Optional. Chat invite link, which was used by the user to join the chat; for joining by invite link events only." + }, + { + "name": "via_chat_folder_invite_link", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the user joined the chat via a chat folder invite link" + } + ], + "extended_by": [] + }, { "name": "ChatMember", "description": "This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported:", @@ -3265,7 +4183,7 @@ "bool" ], "optional": false, - "description": "True, if the administrator can access the chat event log, chat statistics, boost list in channels, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege" + "description": "True, if the administrator can access the chat event log, boost list in channels, see channel members, report spam messages, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege" }, { "name": "can_delete_messages", @@ -3289,7 +4207,7 @@ "bool" ], "optional": false, - "description": "True, if the administrator can restrict, ban or unban chat members" + "description": "True, if the administrator can restrict, ban or unban chat members, or access supergroup statistics" }, { "name": "can_promote_members", @@ -3321,7 +4239,7 @@ "bool" ], "optional": true, - "description": "Optional. True, if the administrator can post messages in the channel; channels only" + "description": "Optional. True, if the administrator can post messages in the channel, or access channel statistics; channels only" }, { "name": "can_edit_messages", @@ -3361,7 +4279,7 @@ "bool" ], "optional": true, - "description": "Optional. True, if the administrator can delete stories posted by other users" + "description": "Optional. True, if the administrator can delete stories posted by other users; channels only" }, { "name": "can_manage_topics", @@ -3439,7 +4357,7 @@ "bool" ], "optional": false, - "description": "True, if the user is allowed to send text messages, contacts, invoices, locations and venues" + "description": "True, if the user is allowed to send text messages, contacts, giveaways, giveaway winners, invoices, locations and venues" }, { "name": "can_send_audios", @@ -3610,69 +4528,6 @@ ], "extended_by": [] }, - { - "name": "ChatMemberUpdated", - "description": "This object represents changes in the status of a chat member.", - "fields": [ - { - "name": "chat", - "types": [ - "Chat" - ], - "optional": false, - "description": "Chat the user belongs to" - }, - { - "name": "from", - "types": [ - "User" - ], - "optional": false, - "description": "Performer of the action, which resulted in the change" - }, - { - "name": "date", - "types": [ - "int" - ], - "optional": false, - "description": "Date the change was done in Unix time" - }, - { - "name": "old_chat_member", - "types": [ - "ChatMember" - ], - "optional": false, - "description": "Previous information about the chat member" - }, - { - "name": "new_chat_member", - "types": [ - "ChatMember" - ], - "optional": false, - "description": "New information about the chat member" - }, - { - "name": "invite_link", - "types": [ - "ChatInviteLink" - ], - "optional": true, - "description": "Optional. Chat invite link, which was used by the user to join the chat; for joining by invite link events only." - }, - { - "name": "via_chat_folder_invite_link", - "types": [ - "bool" - ], - "optional": true, - "description": "Optional. True, if the user joined the chat via a chat folder invite link" - } - ], - "extended_by": [] - }, { "name": "ChatJoinRequest", "description": "Represents a join request sent to a chat.", @@ -3699,7 +4554,7 @@ "int" ], "optional": false, - "description": "Identifier of a private chat with the user who sent the join request. 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 64-bit integer or double-precision float type are safe for storing this identifier. The bot can use this identifier for 24 hours to send messages until the join request is processed, assuming no other administrator contacted the user." + "description": "Identifier of a private chat with the user who sent the join request. 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 64-bit integer or double-precision float type are safe for storing this identifier. The bot can use this identifier for 5 minutes to send messages until the join request is processed, assuming no other administrator contacted the user." }, { "name": "date", @@ -3738,7 +4593,7 @@ "bool" ], "optional": true, - "description": "Optional. True, if the user is allowed to send text messages, contacts, invoices, locations and venues" + "description": "Optional. True, if the user is allowed to send text messages, contacts, giveaways, giveaway winners, invoices, locations and venues" }, { "name": "can_send_audios", @@ -3870,6 +4725,186 @@ ], "extended_by": [] }, + { + "name": "ReactionType", + "description": "This object describes the type of a reaction. Currently, it can be one of", + "fields": [], + "extended_by": [ + "ReactionTypeEmoji", + "ReactionTypeCustomEmoji" + ] + }, + { + "name": "ReactionTypeEmoji", + "description": "The reaction is based on an emoji.", + "fields": [ + { + "name": "type", + "types": [ + "string" + ], + "optional": false, + "description": "Type of the reaction, always “emoji”" + }, + { + "name": "emoji", + "types": [ + "string" + ], + "optional": false, + "description": "Reaction emoji. Currently, it can be one of \"👍\", \"👎\", \"❤\", \"🔥\", \"🥰\", \"👏\", \"😁\", \"🤔\", \"🤯\", \"😱\", \"🤬\", \"😢\", \"🎉\", \"🤩\", \"🤮\", \"💩\", \"🙏\", \"👌\", \"🕊\", \"🤡\", \"🥱\", \"🥴\", \"😍\", \"🐳\", \"❤‍🔥\", \"🌚\", \"🌭\", \"💯\", \"🤣\", \"⚡\", \"🍌\", \"🏆\", \"💔\", \"🤨\", \"😐\", \"🍓\", \"🍾\", \"💋\", \"🖕\", \"😈\", \"😴\", \"😭\", \"🤓\", \"👻\", \"👨‍💻\", \"👀\", \"🎃\", \"🙈\", \"😇\", \"😨\", \"🤝\", \"✍\", \"🤗\", \"🫡\", \"🎅\", \"🎄\", \"☃\", \"💅\", \"🤪\", \"🗿\", \"🆒\", \"💘\", \"🙉\", \"🦄\", \"😘\", \"💊\", \"🙊\", \"😎\", \"👾\", \"🤷‍♂\", \"🤷\", \"🤷‍♀\", \"😡\"" + } + ], + "extended_by": [] + }, + { + "name": "ReactionTypeCustomEmoji", + "description": "The reaction is based on a custom emoji.", + "fields": [ + { + "name": "type", + "types": [ + "string" + ], + "optional": false, + "description": "Type of the reaction, always “custom_emoji”" + }, + { + "name": "custom_emoji_id", + "types": [ + "string" + ], + "optional": false, + "description": "Custom emoji identifier" + } + ], + "extended_by": [] + }, + { + "name": "ReactionCount", + "description": "Represents a reaction added to a message along with the number of times it was added.", + "fields": [ + { + "name": "type", + "types": [ + "ReactionType" + ], + "optional": false, + "description": "Type of the reaction" + }, + { + "name": "total_count", + "types": [ + "int" + ], + "optional": false, + "description": "Number of times the reaction was added" + } + ], + "extended_by": [] + }, + { + "name": "MessageReactionUpdated", + "description": "This object represents a change of a reaction on a message performed by a user.", + "fields": [ + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "The chat containing the message the user reacted to" + }, + { + "name": "message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Unique identifier of the message inside the chat" + }, + { + "name": "user", + "types": [ + "User" + ], + "optional": true, + "description": "Optional. The user that changed the reaction, if the user isn't anonymous" + }, + { + "name": "actor_chat", + "types": [ + "Chat" + ], + "optional": true, + "description": "Optional. The chat on behalf of which the reaction was changed, if the user is anonymous" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Date of the change in Unix time" + }, + { + "name": "old_reaction", + "types": [ + "Array" + ], + "optional": false, + "description": "Previous list of reaction types that were set by the user" + }, + { + "name": "new_reaction", + "types": [ + "Array" + ], + "optional": false, + "description": "New list of reaction types that have been set by the user" + } + ], + "extended_by": [] + }, + { + "name": "MessageReactionCountUpdated", + "description": "This object represents reaction changes on a message with anonymous reactions.", + "fields": [ + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "The chat containing the message" + }, + { + "name": "message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Unique message identifier inside the chat" + }, + { + "name": "date", + "types": [ + "int" + ], + "optional": false, + "description": "Date of the change in Unix time" + }, + { + "name": "reactions", + "types": [ + "Array" + ], + "optional": false, + "description": "List of reactions that are present on the message" + } + ], + "extended_by": [] + }, { "name": "ForumTopic", "description": "This object represents a forum topic.", @@ -4212,6 +5247,218 @@ ], "extended_by": [] }, + { + "name": "ChatBoostSource", + "description": "This object describes the source of a chat boost. It can be one of", + "fields": [], + "extended_by": [ + "ChatBoostSourcePremium", + "ChatBoostSourceGiftCode", + "ChatBoostSourceGiveaway" + ] + }, + { + "name": "ChatBoostSourcePremium", + "description": "The boost was obtained by subscribing to Telegram Premium or by gifting a Telegram Premium subscription to another user.", + "fields": [ + { + "name": "source", + "types": [ + "string" + ], + "optional": false, + "description": "Source of the boost, always “premium”" + }, + { + "name": "user", + "types": [ + "User" + ], + "optional": false, + "description": "User that boosted the chat" + } + ], + "extended_by": [] + }, + { + "name": "ChatBoostSourceGiftCode", + "description": "The boost was obtained by the creation of Telegram Premium gift codes to boost a chat. Each such code boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.", + "fields": [ + { + "name": "source", + "types": [ + "string" + ], + "optional": false, + "description": "Source of the boost, always “gift_code”" + }, + { + "name": "user", + "types": [ + "User" + ], + "optional": false, + "description": "User for which the gift code was created" + } + ], + "extended_by": [] + }, + { + "name": "ChatBoostSourceGiveaway", + "description": "The boost was obtained by the creation of a Telegram Premium giveaway. This boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.", + "fields": [ + { + "name": "source", + "types": [ + "string" + ], + "optional": false, + "description": "Source of the boost, always “giveaway”" + }, + { + "name": "giveaway_message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Identifier of a message in the chat with the giveaway; the message could have been deleted already. May be 0 if the message isn't sent yet." + }, + { + "name": "user", + "types": [ + "User" + ], + "optional": true, + "description": "Optional. User that won the prize in the giveaway if any" + }, + { + "name": "is_unclaimed", + "types": [ + "bool" + ], + "optional": true, + "description": "Optional. True, if the giveaway was completed, but there was no user to win the prize", + "default": true + } + ], + "extended_by": [] + }, + { + "name": "ChatBoost", + "description": "This object contains information about a chat boost.", + "fields": [ + { + "name": "boost_id", + "types": [ + "string" + ], + "optional": false, + "description": "Unique identifier of the boost" + }, + { + "name": "add_date", + "types": [ + "int" + ], + "optional": false, + "description": "Point in time (Unix timestamp) when the chat was boosted" + }, + { + "name": "expiration_date", + "types": [ + "int" + ], + "optional": false, + "description": "Point in time (Unix timestamp) when the boost will automatically expire, unless the booster's Telegram Premium subscription is prolonged" + }, + { + "name": "source", + "types": [ + "ChatBoostSource" + ], + "optional": false, + "description": "Source of the added boost" + } + ], + "extended_by": [] + }, + { + "name": "ChatBoostUpdated", + "description": "This object represents a boost added to a chat or changed.", + "fields": [ + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "Chat which was boosted" + }, + { + "name": "boost", + "types": [ + "ChatBoost" + ], + "optional": false, + "description": "Infomation about the chat boost" + } + ], + "extended_by": [] + }, + { + "name": "ChatBoostRemoved", + "description": "This object represents a boost removed from a chat.", + "fields": [ + { + "name": "chat", + "types": [ + "Chat" + ], + "optional": false, + "description": "Chat which was boosted" + }, + { + "name": "boost_id", + "types": [ + "string" + ], + "optional": false, + "description": "Unique identifier of the boost" + }, + { + "name": "remove_date", + "types": [ + "int" + ], + "optional": false, + "description": "Point in time (Unix timestamp) when the boost was removed" + }, + { + "name": "source", + "types": [ + "ChatBoostSource" + ], + "optional": false, + "description": "Source of the removed boost" + } + ], + "extended_by": [] + }, + { + "name": "UserChatBoosts", + "description": "This object represents a list of boosts added to a chat by a user.", + "fields": [ + { + "name": "boosts", + "types": [ + "Array" + ], + "optional": false, + "description": "The list of boosts added to the chat by the user" + } + ], + "extended_by": [] + }, { "name": "ResponseParameters", "description": "Describes why a request was unsuccessful.", @@ -6955,12 +8202,12 @@ "description": "Optional. List of special entities that appear in message text, which can be specified instead of parse_mode" }, { - "name": "disable_web_page_preview", + "name": "link_preview_options", "types": [ - "bool" + "LinkPreviewOptions" ], "optional": true, - "description": "Optional. Disables link previews for links in the sent message" + "description": "Optional. Link preview generation options for the message" } ], "extended_by": [] @@ -8414,7 +9661,7 @@ "Array" ], "optional": true, - "description": "A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time." + "description": "A JSON-serialized list of the update types you want your bot to receive. For example, specify [\"message\", \"edited_channel_post\", \"callback_query\"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time." } ], "return_types": [ @@ -8464,7 +9711,7 @@ "Array" ], "optional": true, - "description": "A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time." + "description": "A JSON-serialized list of the update types you want your bot to receive. For example, specify [\"message\", \"edited_channel_post\", \"callback_query\"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time." }, { "name": "drop_pending_updates", @@ -8582,12 +9829,12 @@ "description": "A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode" }, { - "name": "disable_web_page_preview", + "name": "link_preview_options", "types": [ - "bool" + "LinkPreviewOptions" ], "optional": true, - "description": "Disables link previews for links in this message" + "description": "Link preview generation options for the message" }, { "name": "disable_notification", @@ -8606,20 +9853,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -8639,7 +9878,7 @@ }, { "name": "forwardMessage", - "description": "Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned.", + "description": "Use this method to forward messages of any kind. Service messages and messages with protected content can't be forwarded. On success, the sent Message is returned.", "fields": [ { "name": "chat_id", @@ -8696,9 +9935,68 @@ "Message" ] }, + { + "name": "forwardMessages", + "description": "Use this method to forward multiple messages of any kind. If some of the specified messages can't be found or forwarded, they are skipped. Service messages and messages with protected content can't be forwarded. Album grouping is kept for forwarded messages. On success, an array of MessageId of the sent messages is returned.", + "fields": [ + { + "name": "chat_id", + "types": [ + "int", + "string" + ], + "optional": false, + "description": "Unique identifier for the target chat or username of the target channel (in the format @channelusername)" + }, + { + "name": "message_thread_id", + "types": [ + "int" + ], + "optional": true, + "description": "Unique identifier for the target message thread (topic) of the forum; for forum supergroups only" + }, + { + "name": "from_chat_id", + "types": [ + "int", + "string" + ], + "optional": false, + "description": "Unique identifier for the chat where the original messages were sent (or channel username in the format @channelusername)" + }, + { + "name": "message_ids", + "types": [ + "Array" + ], + "optional": false, + "description": "Identifiers of 1-100 messages in the chat from_chat_id to forward. The identifiers must be specified in a strictly increasing order." + }, + { + "name": "disable_notification", + "types": [ + "bool" + ], + "optional": true, + "description": "Sends the messages silently. Users will receive a notification with no sound." + }, + { + "name": "protect_content", + "types": [ + "bool" + ], + "optional": true, + "description": "Protects the contents of the forwarded messages from forwarding and saving" + } + ], + "return_types": [ + "Array" + ] + }, { "name": "copyMessage", - "description": "Use this method to copy messages of any kind. Service messages and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success.", + "description": "Use this method to copy messages of any kind. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success.", "fields": [ { "name": "chat_id", @@ -8775,20 +10073,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -8806,6 +10096,73 @@ "MessageId" ] }, + { + "name": "copyMessages", + "description": "Use this method to copy messages of any kind. If some of the specified messages can't be found or copied, they are skipped. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessages, but the copied messages don't have a link to the original message. Album grouping is kept for copied messages. On success, an array of MessageId of the sent messages is returned.", + "fields": [ + { + "name": "chat_id", + "types": [ + "int", + "string" + ], + "optional": false, + "description": "Unique identifier for the target chat or username of the target channel (in the format @channelusername)" + }, + { + "name": "message_thread_id", + "types": [ + "int" + ], + "optional": true, + "description": "Unique identifier for the target message thread (topic) of the forum; for forum supergroups only" + }, + { + "name": "from_chat_id", + "types": [ + "int", + "string" + ], + "optional": false, + "description": "Unique identifier for the chat where the original messages were sent (or channel username in the format @channelusername)" + }, + { + "name": "message_ids", + "types": [ + "Array" + ], + "optional": false, + "description": "Identifiers of 1-100 messages in the chat from_chat_id to copy. The identifiers must be specified in a strictly increasing order." + }, + { + "name": "disable_notification", + "types": [ + "bool" + ], + "optional": true, + "description": "Sends the messages silently. Users will receive a notification with no sound." + }, + { + "name": "protect_content", + "types": [ + "bool" + ], + "optional": true, + "description": "Protects the contents of the sent messages from forwarding and saving" + }, + { + "name": "remove_caption", + "types": [ + "bool" + ], + "optional": true, + "description": "Pass True to copy the messages without their captions" + } + ], + "return_types": [ + "Array" + ] + }, { "name": "sendPhoto", "description": "Use this method to send photos. On success, the sent Message is returned.", @@ -8885,20 +10242,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9020,20 +10369,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9139,20 +10480,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9290,20 +10623,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9433,20 +10758,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9543,20 +10860,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9646,20 +10955,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9723,20 +11024,12 @@ "description": "Protects the contents of the sent messages from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the messages are a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" } ], "return_types": [ @@ -9829,20 +11122,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -9962,20 +11247,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -10063,20 +11340,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -10231,20 +11500,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -10309,20 +11570,12 @@ "description": "Protects the contents of the sent message from forwarding" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -10374,6 +11627,48 @@ "bool" ] }, + { + "name": "setMessageReaction", + "description": "Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. In albums, bots must react to the first message. Returns True on success.", + "fields": [ + { + "name": "chat_id", + "types": [ + "int", + "string" + ], + "optional": false, + "description": "Unique identifier for the target chat or username of the target channel (in the format @channelusername)" + }, + { + "name": "message_id", + "types": [ + "int" + ], + "optional": false, + "description": "Identifier of the target message" + }, + { + "name": "reaction", + "types": [ + "Array" + ], + "optional": true, + "description": "New list of reaction types to set on the message. Currently, as non-premium users, bots can set up to one reaction per message. A custom emoji reaction can be used if it is either already present on the message or explicitly allowed by chat administrators." + }, + { + "name": "is_big", + "types": [ + "bool" + ], + "optional": true, + "description": "Pass True to set the reaction with a big animation" + } + ], + "return_types": [ + "bool" + ] + }, { "name": "getUserProfilePhotos", "description": "Use this method to get a list of profile pictures for a user. Returns a UserProfilePhotos object.", @@ -10586,23 +11881,7 @@ "bool" ], "optional": true, - "description": "Pass True if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege" - }, - { - "name": "can_post_messages", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the administrator can create channel posts, channels only" - }, - { - "name": "can_edit_messages", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the administrator can edit messages of other users and can pin messages, channels only" + "description": "Pass True if the administrator can access the chat event log, boost list in channels, see channel members, report spam messages, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege" }, { "name": "can_delete_messages", @@ -10626,7 +11905,7 @@ "bool" ], "optional": true, - "description": "Pass True if the administrator can restrict, ban or unban chat members" + "description": "Pass True if the administrator can restrict, ban or unban chat members, or access supergroup statistics" }, { "name": "can_promote_members", @@ -10652,6 +11931,22 @@ "optional": true, "description": "Pass True if the administrator can invite new users to the chat" }, + { + "name": "can_post_messages", + "types": [ + "bool" + ], + "optional": true, + "description": "Pass True if the administrator can post messages in the channel, or access channel statistics; channels only" + }, + { + "name": "can_edit_messages", + "types": [ + "bool" + ], + "optional": true, + "description": "Pass True if the administrator can edit messages of other users and can pin messages; channels only" + }, { "name": "can_pin_messages", "types": [ @@ -10660,6 +11955,30 @@ "optional": true, "description": "Pass True if the administrator can pin messages, supergroups only" }, + { + "name": "can_post_stories", + "types": [ + "bool" + ], + "optional": true, + "description": "Pass True if the administrator can post stories in the channel; channels only" + }, + { + "name": "can_edit_stories", + "types": [ + "bool" + ], + "optional": true, + "description": "Pass True if the administrator can edit stories posted by other users; channels only" + }, + { + "name": "can_delete_stories", + "types": [ + "bool" + ], + "optional": true, + "description": "Pass True if the administrator can delete stories posted by other users; channels only" + }, { "name": "can_manage_topics", "types": [ @@ -11191,7 +12510,7 @@ }, { "name": "getChat", - "description": "Use this method to get up to date information about the chat (current name of the user for one-on-one conversations, current username of a user, group or channel, etc.). Returns a Chat object on success.", + "description": "Use this method to get up to date information about the chat. Returns a Chat object on success.", "fields": [ { "name": "chat_id", @@ -11676,6 +12995,32 @@ "bool" ] }, + { + "name": "getUserChatBoosts", + "description": "Use this method to get the list of boosts added to a chat by a user. Requires administrator rights in the chat. Returns a UserChatBoosts object.", + "fields": [ + { + "name": "chat_id", + "types": [ + "int", + "string" + ], + "optional": false, + "description": "Unique identifier for the chat or username of the channel (in the format @channelusername)" + }, + { + "name": "user_id", + "types": [ + "int" + ], + "optional": false, + "description": "Unique identifier of the target user" + } + ], + "return_types": [ + "UserChatBoosts" + ] + }, { "name": "setMyCommands", "description": "Use this method to change the list of the bot's commands. See this manual for more details about bot commands. Returns True on success.", @@ -12027,12 +13372,12 @@ "description": "A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode" }, { - "name": "disable_web_page_preview", + "name": "link_preview_options", "types": [ - "bool" + "LinkPreviewOptions" ], "optional": true, - "description": "Disables link previews for links in this message" + "description": "Link preview generation options for the message" }, { "name": "reply_markup", @@ -12395,6 +13740,32 @@ "bool" ] }, + { + "name": "deleteMessages", + "description": "Use this method to delete multiple messages simultaneously. If some of the specified messages can't be found, they are skipped. Returns True on success.", + "fields": [ + { + "name": "chat_id", + "types": [ + "int", + "string" + ], + "optional": false, + "description": "Unique identifier for the target chat or username of the target channel (in the format @channelusername)" + }, + { + "name": "message_ids", + "types": [ + "Array" + ], + "optional": false, + "description": "Identifiers of 1-100 messages to delete. See deleteMessage for limitations on which messages can be deleted" + } + ], + "return_types": [ + "bool" + ] + }, { "name": "sendSticker", "description": "Use this method to send static .WEBP, animated .TGS, or video .WEBM stickers. On success, the sent Message is returned.", @@ -12450,20 +13821,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -13154,20 +14517,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", @@ -13496,20 +14851,12 @@ "description": "Protects the contents of the sent message from forwarding and saving" }, { - "name": "reply_to_message_id", + "name": "reply_parameters", "types": [ - "int" + "ReplyParameters" ], "optional": true, - "description": "If the message is a reply, ID of the original message" - }, - { - "name": "allow_sending_without_reply", - "types": [ - "bool" - ], - "optional": true, - "description": "Pass True if the message should be sent even if the specified replied-to message is not found" + "description": "Description of the message to reply to" }, { "name": "reply_markup", diff --git a/schemas/botapi.yaml b/schemas/botapi.yaml index 354b509..24cd4ae 100644 --- a/schemas/botapi.yaml +++ b/schemas/botapi.yaml @@ -1,4 +1,4 @@ -version: 6.9.0 +version: 7.0.0 types: - name: Update @@ -34,6 +34,18 @@ types: - Message optional: true description: 'Optional. New version of a channel post that is known to the bot and was edited' + - + name: message_reaction + types: + - MessageReactionUpdated + optional: true + description: 'Optional. A reaction to a message was changed by a user. The bot must be an administrator in the chat and must explicitly specify "message_reaction" in the list of allowed_updates to receive these updates. The update isn''t received for reactions set by bots.' + - + name: message_reaction_count + types: + - MessageReactionCountUpdated + optional: true + description: 'Optional. Reactions to a message with anonymous reactions were changed. The bot must be an administrator in the chat and must explicitly specify "message_reaction_count" in the list of allowed_updates to receive these updates.' - name: inline_query types: @@ -87,13 +99,25 @@ types: types: - ChatMemberUpdated optional: true - description: "Optional. A chat member's status was updated in a chat. The bot must be an administrator in the chat and must explicitly specify “chat_member” in the list of allowed_updates to receive these updates." + description: 'Optional. A chat member''s status was updated in a chat. The bot must be an administrator in the chat and must explicitly specify "chat_member" in the list of allowed_updates to receive these updates.' - name: chat_join_request types: - ChatJoinRequest optional: true description: 'Optional. 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.' + - + name: chat_boost + types: + - ChatBoostUpdated + optional: true + description: 'Optional. A chat boost was added or changed. The bot must be an administrator in the chat to receive these updates.' + - + name: removed_chat_boost + types: + - ChatBoostRemoved + optional: true + description: 'Optional. A boost was removed from a chat. The bot must be an administrator in the chat to receive these updates.' extended_by: { } - name: WebhookInfo @@ -286,18 +310,48 @@ types: - Array optional: true description: 'Optional. If non-empty, the list of all active chat usernames; for private chats, supergroups and channels. Returned only in getChat.' + - + name: available_reactions + types: + - Array + optional: true + description: 'Optional. List of available reactions allowed in the chat. If omitted, then all emoji reactions are allowed. Returned only in getChat.' + - + name: accent_color_id + types: + - int + optional: true + description: 'Optional. Identifier of the accent color for the chat name and backgrounds of the chat photo, reply header, and link preview. See accent colors for more details. Returned only in getChat. Always returned in getChat.' + - + name: background_custom_emoji_id + types: + - string + optional: true + description: 'Optional. Custom emoji identifier of emoji chosen by the chat for the reply header and link preview background. Returned only in getChat.' + - + name: profile_accent_color_id + types: + - int + optional: true + description: "Optional. Identifier of the accent color for the chat's profile background. See profile accent colors for more details. Returned only in getChat." + - + name: profile_background_custom_emoji_id + types: + - string + optional: true + description: 'Optional. Custom emoji identifier of the emoji chosen by the chat for its profile background. Returned only in getChat.' - name: emoji_status_custom_emoji_id types: - string optional: true - description: 'Optional. Custom emoji identifier of emoji status of the other party in a private chat. Returned only in getChat.' + description: 'Optional. Custom emoji identifier of the emoji status of the chat or the other party in a private chat. Returned only in getChat.' - name: emoji_status_expiration_date types: - int optional: true - description: 'Optional. Expiration date of the emoji status of the other party in a private chat in Unix time, if any. Returned only in getChat.' + description: 'Optional. Expiration date of the emoji status of the chat or the other party in a private chat, in Unix time, if any. Returned only in getChat.' - name: bio types: @@ -389,6 +443,13 @@ types: optional: true description: "Optional. True, if messages from the chat can't be forwarded to other chats. Returned only in getChat." default: true + - + name: has_visible_history + types: + - bool + optional: true + description: 'Optional. True, if new chat members will have access to old messages; available only to chat administrators. Returned only in getChat.' + default: true - name: sticker_set_name types: @@ -448,49 +509,19 @@ types: types: - int optional: false - description: 'Date the message was sent in Unix time' + description: 'Date the message was sent in Unix time. It is always a positive number, representing a valid date.' - name: chat types: - Chat optional: false - description: 'Conversation the message belongs to' + description: 'Chat the message belongs to' - - name: forward_from + name: forward_origin types: - - User + - MessageOrigin optional: true - description: 'Optional. For forwarded messages, sender of the original message' - - - name: forward_from_chat - types: - - Chat - optional: true - description: 'Optional. For messages forwarded from channels or from anonymous administrators, information about the original sender chat' - - - name: forward_from_message_id - types: - - int - optional: true - description: 'Optional. For messages forwarded from channels, identifier of the original message in the channel' - - - name: forward_signature - types: - - string - optional: true - description: 'Optional. For forwarded messages that were originally sent in channels or by an anonymous chat administrator, signature of the message sender if present' - - - name: forward_sender_name - types: - - string - optional: true - description: "Optional. Sender's name for messages forwarded from users who disallow adding a link to their account in forwarded messages" - - - name: forward_date - types: - - int - optional: true - description: 'Optional. For forwarded messages, date the original message was sent in Unix time' + description: 'Optional. Information about the original message for forwarded messages' - name: is_topic_message types: @@ -510,7 +541,19 @@ types: types: - Message optional: true - description: 'Optional. 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.' + 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.' + - + name: external_reply + types: + - ExternalReplyInfo + optional: true + description: 'Optional. Information about the message that is being replied to, which may come from another chat or forum topic' + - + name: quote + types: + - TextQuote + optional: true + description: 'Optional. For replies that quote part of the original message, the quoted part of the message' - name: via_bot types: @@ -554,6 +597,12 @@ types: - Array optional: true description: 'Optional. For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text' + - + name: link_preview_options + types: + - LinkPreviewOptions + optional: true + description: 'Optional. Options used for link preview generation for the message, if it is a text message and link preview options were changed' - name: animation types: @@ -736,9 +785,9 @@ types: - name: pinned_message types: - - Message + - MaybeInaccessibleMessage optional: true - 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 is itself a reply.' + 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.' - name: invoice types: @@ -752,11 +801,11 @@ types: optional: true description: 'Optional. Message is a service message about a successful payment, information about the payment. More about payments »' - - name: user_shared + name: users_shared types: - - UserShared + - UsersShared optional: true - description: 'Optional. Service message: a user was shared with the bot' + description: 'Optional. Service message: users were shared with the bot' - name: chat_shared types: @@ -823,6 +872,30 @@ types: - GeneralForumTopicUnhidden optional: true description: "Optional. Service message: the 'General' forum topic unhidden" + - + name: giveaway_created + types: + - GiveawayCreated + optional: true + description: 'Optional. Service message: a scheduled giveaway was created' + - + name: giveaway + types: + - Giveaway + optional: true + description: 'Optional. The message is a scheduled giveaway message' + - + name: giveaway_winners + types: + - GiveawayWinners + optional: true + description: 'Optional. A giveaway with public winners was completed' + - + name: giveaway_completed + types: + - GiveawayCompleted + optional: true + description: 'Optional. Service message: a giveaway without public winners was completed' - name: video_chat_scheduled types: @@ -871,6 +944,36 @@ types: optional: false description: 'Unique message identifier' extended_by: { } + - + name: InaccessibleMessage + description: 'This object describes a message that was deleted or is otherwise inaccessible to the bot.' + fields: + - + name: chat + types: + - Chat + optional: false + description: 'Chat the message belonged to' + - + name: message_id + types: + - int + optional: false + description: 'Unique message identifier inside the chat' + - + name: date + types: + - int + optional: false + description: 'Always 0. The field can be used to differentiate regular and inaccessible messages.' + extended_by: { } + - + name: MaybeInaccessibleMessage + description: 'This object describes a message that can be inaccessible to the bot. It can be one of' + fields: { } + extended_by: + - Message + - InaccessibleMessage - name: MessageEntity description: 'This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.' @@ -880,7 +983,7 @@ types: types: - string optional: false - description: 'Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames), “custom_emoji” (for inline custom emoji stickers)' + description: 'Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “blockquote” (block quotation), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames), “custom_emoji” (for inline custom emoji stickers)' - name: offset types: @@ -918,6 +1021,347 @@ types: optional: true description: 'Optional. For “custom_emoji” only, unique identifier of the custom emoji. Use getCustomEmojiStickers to get full information about the sticker' extended_by: { } + - + name: TextQuote + description: 'This object contains information about the quoted part of a message that is replied to by the given message.' + fields: + - + name: text + types: + - string + optional: false + description: 'Text of the quoted part of a message that is replied to by the given message' + - + name: entities + types: + - Array + optional: true + description: 'Optional. Special entities that appear in the quote. Currently, only bold, italic, underline, strikethrough, spoiler, and custom_emoji entities are kept in quotes.' + - + name: position + types: + - int + optional: false + description: 'Approximate quote position in the original message in UTF-16 code units as specified by the sender' + - + name: is_manual + types: + - bool + optional: true + description: 'Optional. True, if the quote was chosen manually by the message sender. Otherwise, the quote was added automatically by the server.' + default: true + extended_by: { } + - + name: ExternalReplyInfo + description: 'This object contains information about a message that is being replied to, which may come from another chat or forum topic.' + fields: + - + name: origin + types: + - MessageOrigin + optional: false + description: 'Origin of the message replied to by the given message' + - + name: chat + types: + - Chat + optional: true + description: 'Optional. Chat the original message belongs to. Available only if the chat is a supergroup or a channel.' + - + name: message_id + types: + - int + optional: true + description: 'Optional. Unique message identifier inside the original chat. Available only if the original chat is a supergroup or a channel.' + - + name: link_preview_options + types: + - LinkPreviewOptions + optional: true + description: 'Optional. Options used for link preview generation for the original message, if it is a text message' + - + name: animation + types: + - Animation + optional: true + description: 'Optional. Message is an animation, information about the animation' + - + name: audio + types: + - Audio + optional: true + description: 'Optional. Message is an audio file, information about the file' + - + name: document + types: + - Document + optional: true + description: 'Optional. Message is a general file, information about the file' + - + name: photo + types: + - Array + optional: true + description: 'Optional. Message is a photo, available sizes of the photo' + - + name: sticker + types: + - Sticker + optional: true + description: 'Optional. Message is a sticker, information about the sticker' + - + name: story + types: + - Story + optional: true + description: 'Optional. Message is a forwarded story' + - + name: video + types: + - Video + optional: true + description: 'Optional. Message is a video, information about the video' + - + name: video_note + types: + - VideoNote + optional: true + description: 'Optional. Message is a video note, information about the video message' + - + name: voice + types: + - Voice + optional: true + description: 'Optional. Message is a voice message, information about the file' + - + name: has_media_spoiler + types: + - bool + optional: true + description: 'Optional. True, if the message media is covered by a spoiler animation' + default: true + - + name: contact + types: + - Contact + optional: true + description: 'Optional. Message is a shared contact, information about the contact' + - + name: dice + types: + - Dice + optional: true + description: 'Optional. Message is a dice with random value' + - + name: game + types: + - Game + optional: true + description: 'Optional. Message is a game, information about the game. More about games »' + - + name: giveaway + types: + - Giveaway + optional: true + description: 'Optional. Message is a scheduled giveaway, information about the giveaway' + - + name: giveaway_winners + types: + - GiveawayWinners + optional: true + description: 'Optional. A giveaway with public winners was completed' + - + name: invoice + types: + - Invoice + optional: true + description: 'Optional. Message is an invoice for a payment, information about the invoice. More about payments »' + - + name: location + types: + - Location + optional: true + description: 'Optional. Message is a shared location, information about the location' + - + name: poll + types: + - Poll + optional: true + description: 'Optional. Message is a native poll, information about the poll' + - + name: venue + types: + - Venue + optional: true + description: 'Optional. Message is a venue, information about the venue' + extended_by: { } + - + name: ReplyParameters + description: 'Describes reply parameters for the message that is being sent.' + fields: + - + name: message_id + types: + - int + optional: false + description: 'Identifier of the message that will be replied to in the current chat, or in the chat chat_id if it is specified' + - + name: chat_id + types: + - int + - string + optional: true + description: 'Optional. If the message to be replied to is from a different chat, unique identifier for the chat or username of the channel (in the format @channelusername)' + - + name: allow_sending_without_reply + types: + - bool + optional: true + description: 'Optional. Pass True if the message should be sent even if the specified message to be replied to is not found; can be used only for replies in the same chat and forum topic.' + - + name: quote + types: + - string + optional: true + description: "Optional. Quoted part of the message to be replied to; 0-1024 characters after entities parsing. The quote must be an exact substring of the message to be replied to, including bold, italic, underline, strikethrough, spoiler, and custom_emoji entities. The message will fail to send if the quote isn't found in the original message." + - + name: quote_parse_mode + types: + - string + optional: true + description: 'Optional. Mode for parsing entities in the quote. See formatting options for more details.' + - + name: quote_entities + types: + - Array + optional: true + description: 'Optional. A JSON-serialized list of special entities that appear in the quote. It can be specified instead of quote_parse_mode.' + - + name: quote_position + types: + - int + optional: true + description: 'Optional. Position of the quote in the original message in UTF-16 code units' + extended_by: { } + - + name: MessageOrigin + description: 'This object describes the origin of a message. It can be one of' + fields: { } + extended_by: + - MessageOriginUser + - MessageOriginHiddenUser + - MessageOriginChat + - MessageOriginChannel + - + name: MessageOriginUser + description: 'The message was originally sent by a known user.' + fields: + - + name: type + types: + - string + optional: false + description: 'Type of the message origin, always “user”' + - + name: date + types: + - int + optional: false + description: 'Date the message was sent originally in Unix time' + - + name: sender_user + types: + - User + optional: false + description: 'User that sent the message originally' + extended_by: { } + - + name: MessageOriginHiddenUser + description: 'The message was originally sent by an unknown user.' + fields: + - + name: type + types: + - string + optional: false + description: 'Type of the message origin, always “hidden_user”' + - + name: date + types: + - int + optional: false + description: 'Date the message was sent originally in Unix time' + - + name: sender_user_name + types: + - string + optional: false + description: 'Name of the user that sent the message originally' + extended_by: { } + - + name: MessageOriginChat + description: 'The message was originally sent on behalf of a chat to a group chat.' + fields: + - + name: type + types: + - string + optional: false + description: 'Type of the message origin, always “chat”' + - + name: date + types: + - int + optional: false + description: 'Date the message was sent originally in Unix time' + - + name: sender_chat + types: + - Chat + optional: false + description: 'Chat that sent the message originally' + - + name: author_signature + types: + - string + optional: true + description: 'Optional. For messages originally sent by an anonymous chat administrator, original message author signature' + extended_by: { } + - + name: MessageOriginChannel + description: 'The message was originally sent to a channel chat.' + fields: + - + name: type + types: + - string + optional: false + description: 'Type of the message origin, always “channel”' + - + name: date + types: + - int + optional: false + description: 'Date the message was sent originally in Unix time' + - + name: chat + types: + - Chat + optional: false + description: 'Channel chat to which the message was originally sent' + - + name: message_id + types: + - int + optional: false + description: 'Unique message identifier inside the chat' + - + name: author_signature + types: + - string + optional: true + description: 'Optional. Signature of the original post author' + extended_by: { } - name: PhotoSize description: 'This object represents one size of a photo or a file / sticker thumbnail.' @@ -1633,8 +2077,8 @@ types: fields: { } extended_by: { } - - name: UserShared - description: 'This object contains information about the user whose identifier was shared with the bot using a KeyboardButtonRequestUser button.' + name: UsersShared + description: 'This object contains information about the users whose identifiers were shared with the bot using a KeyboardButtonRequestUsers button.' fields: - name: request_id @@ -1643,11 +2087,11 @@ types: optional: false description: 'Identifier of the request' - - name: user_id + name: user_ids types: - - int + - Array optional: false - description: 'Identifier of the shared user. 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 64-bit integer or double-precision float type are safe for storing this identifier. The bot may not have access to the user and could be unable to use this identifier, unless the user is already known to the bot by some other means.' + description: 'Identifiers of the shared users. These numbers may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting them. But they have at most 52 significant bits, so 64-bit integers or double-precision float types are safe for storing these identifiers. The bot may not have access to the users and could be unable to use these identifiers, unless the users are already known to the bot by some other means.' extended_by: { } - name: ChatShared @@ -1727,6 +2171,197 @@ types: optional: false description: 'New members that were invited to the video chat' extended_by: { } + - + name: GiveawayCreated + description: 'This object represents a service message about the creation of a scheduled giveaway. Currently holds no information.' + fields: { } + extended_by: { } + - + name: Giveaway + description: 'This object represents a message about a scheduled giveaway.' + fields: + - + name: chats + types: + - Array + optional: false + description: 'The list of chats which the user must join to participate in the giveaway' + - + name: winners_selection_date + types: + - int + optional: false + description: 'Point in time (Unix timestamp) when winners of the giveaway will be selected' + - + name: winner_count + types: + - int + optional: false + description: 'The number of users which are supposed to be selected as winners of the giveaway' + - + name: only_new_members + types: + - bool + optional: true + description: 'Optional. True, if only users who join the chats after the giveaway started should be eligible to win' + default: true + - + name: has_public_winners + types: + - bool + optional: true + description: 'Optional. True, if the list of giveaway winners will be visible to everyone' + default: true + - + name: prize_description + types: + - string + optional: true + description: 'Optional. Description of additional giveaway prize' + - + name: country_codes + types: + - Array + optional: true + description: 'Optional. A list of two-letter ISO 3166-1 alpha-2 country codes indicating the countries from which eligible users for the giveaway must come. If empty, then all users can participate in the giveaway. Users with a phone number that was bought on Fragment can always participate in giveaways.' + - + name: premium_subscription_month_count + types: + - int + optional: true + description: 'Optional. The number of months the Telegram Premium subscription won from the giveaway will be active for' + extended_by: { } + - + name: GiveawayWinners + description: 'This object represents a message about the completion of a giveaway with public winners.' + fields: + - + name: chat + types: + - Chat + optional: false + description: 'The chat that created the giveaway' + - + name: giveaway_message_id + types: + - int + optional: false + description: 'Identifier of the messsage with the giveaway in the chat' + - + name: winners_selection_date + types: + - int + optional: false + description: 'Point in time (Unix timestamp) when winners of the giveaway were selected' + - + name: winner_count + types: + - int + optional: false + description: 'Total number of winners in the giveaway' + - + name: winners + types: + - Array + optional: false + description: 'List of up to 100 winners of the giveaway' + - + name: additional_chat_count + types: + - int + optional: true + description: 'Optional. The number of other chats the user had to join in order to be eligible for the giveaway' + - + name: premium_subscription_month_count + types: + - int + optional: true + description: 'Optional. The number of months the Telegram Premium subscription won from the giveaway will be active for' + - + name: unclaimed_prize_count + types: + - int + optional: true + description: 'Optional. Number of undistributed prizes' + - + name: only_new_members + types: + - bool + optional: true + description: 'Optional. True, if only users who had joined the chats after the giveaway started were eligible to win' + default: true + - + name: was_refunded + types: + - bool + optional: true + description: 'Optional. True, if the giveaway was canceled because the payment for it was refunded' + default: true + - + name: prize_description + types: + - string + optional: true + description: 'Optional. Description of additional giveaway prize' + extended_by: { } + - + name: GiveawayCompleted + description: 'This object represents a service message about the completion of a giveaway without public winners.' + fields: + - + name: winner_count + types: + - int + optional: false + description: 'Number of winners in the giveaway' + - + name: unclaimed_prize_count + types: + - int + optional: true + description: 'Optional. Number of undistributed prizes' + - + name: giveaway_message + types: + - Message + optional: true + description: "Optional. Message with the giveaway that was completed, if it wasn't deleted" + extended_by: { } + - + name: LinkPreviewOptions + description: 'Describes the options used for link preview generation.' + fields: + - + name: is_disabled + types: + - bool + optional: true + description: 'Optional. True, if the link preview is disabled' + - + name: url + types: + - string + optional: true + description: 'Optional. URL to use for the link preview. If empty, then the first URL found in the message text will be used' + - + name: prefer_small_media + types: + - bool + optional: true + description: "Optional. True, if the media in the link preview is suppposed to be shrunk; ignored if the URL isn't explicitly specified or media size change isn't supported for the preview" + - + name: prefer_large_media + types: + - bool + optional: true + description: "Optional. True, if the media in the link preview is suppposed to be enlarged; ignored if the URL isn't explicitly specified or media size change isn't supported for the preview" + - + name: show_above_text + types: + - bool + optional: true + description: 'Optional. True, if the link preview must be shown above the message text; otherwise, the link preview will be shown below the message text' + extended_by: { } - name: UserProfilePhotos description: "This object represent a user's profile pictures." @@ -1830,7 +2465,7 @@ types: extended_by: { } - name: KeyboardButton - description: 'This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_user, request_chat, request_contact, request_location, and request_poll are mutually exclusive.' + description: 'This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_users, request_chat, request_contact, request_location, and request_poll are mutually exclusive.' fields: - name: text @@ -1839,11 +2474,11 @@ types: optional: false description: 'Text of the button. If none of the optional fields are used, it will be sent as a message when the button is pressed' - - name: request_user + name: request_users types: - - KeyboardButtonRequestUser + - KeyboardButtonRequestUsers optional: true - description: 'Optional. If specified, pressing the button will open a list of suitable users. Tapping on any user will send their identifier to the bot in a “user_shared” service message. Available in private chats only.' + description: 'Optional. If specified, pressing the button will open a list of suitable users. Identifiers of selected users will be sent to the bot in a “users_shared” service message. Available in private chats only.' - name: request_chat types: @@ -1876,27 +2511,34 @@ types: description: 'Optional. If specified, the described Web App will be launched when the button is pressed. The Web App will be able to send a “web_app_data” service message. Available in private chats only.' extended_by: { } - - name: KeyboardButtonRequestUser - description: 'This object defines the criteria used to request a suitable user. The identifier of the selected user will be shared with the bot when the corresponding button is pressed. More about requesting users »' + name: KeyboardButtonRequestUsers + description: 'This object defines the criteria used to request suitable users. The identifiers of the selected users will be shared with the bot when the corresponding button is pressed. More about requesting users »' fields: - name: request_id types: - int optional: false - description: 'Signed 32-bit identifier of the request, which will be received back in the UserShared object. Must be unique within the message' + description: 'Signed 32-bit identifier of the request that will be received back in the UsersShared object. Must be unique within the message' - name: user_is_bot types: - bool optional: true - description: 'Optional. Pass True to request a bot, pass False to request a regular user. If not specified, no additional restrictions are applied.' + description: 'Optional. Pass True to request bots, pass False to request regular users. If not specified, no additional restrictions are applied.' - name: user_is_premium types: - bool optional: true - description: 'Optional. Pass True to request a premium user, pass False to request a non-premium user. If not specified, no additional restrictions are applied.' + description: 'Optional. Pass True to request premium users, pass False to request non-premium users. If not specified, no additional restrictions are applied.' + - + name: max_quantity + types: + - int + optional: true + description: 'Optional. The maximum number of users to be selected; 1-10. Defaults to 1.' + default: 1 extended_by: { } - name: KeyboardButtonRequestChat @@ -2139,9 +2781,9 @@ types: - name: message types: - - Message + - MaybeInaccessibleMessage optional: true - description: 'Optional. Message with the callback button that originated the query. Note that message content and message date will not be available if the message is too old' + description: 'Optional. Message sent by the bot with the callback button that originated the query' - name: inline_message_id types: @@ -2294,7 +2936,7 @@ types: types: - bool optional: false - description: 'True, if the administrator can access the chat event log, chat statistics, boost list in channels, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege' + description: 'True, if the administrator can access the chat event log, boost list in channels, see channel members, report spam messages, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege' - name: can_delete_messages types: @@ -2312,7 +2954,7 @@ types: types: - bool optional: false - description: 'True, if the administrator can restrict, ban or unban chat members' + description: 'True, if the administrator can restrict, ban or unban chat members, or access supergroup statistics' - name: can_promote_members types: @@ -2336,7 +2978,7 @@ types: types: - bool optional: true - description: 'Optional. True, if the administrator can post messages in the channel; channels only' + description: 'Optional. True, if the administrator can post messages in the channel, or access channel statistics; channels only' - name: can_edit_messages types: @@ -2366,7 +3008,7 @@ types: types: - bool optional: true - description: 'Optional. True, if the administrator can delete stories posted by other users' + description: 'Optional. True, if the administrator can delete stories posted by other users; channels only' - name: can_manage_topics types: @@ -2374,6 +3016,53 @@ types: optional: true description: 'Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only' extended_by: { } + - + name: ChatMemberUpdated + description: 'This object represents changes in the status of a chat member.' + fields: + - + name: chat + types: + - Chat + optional: false + description: 'Chat the user belongs to' + - + name: from + types: + - User + optional: false + description: 'Performer of the action, which resulted in the change' + - + name: date + types: + - int + optional: false + description: 'Date the change was done in Unix time' + - + name: old_chat_member + types: + - ChatMember + optional: false + description: 'Previous information about the chat member' + - + name: new_chat_member + types: + - ChatMember + optional: false + description: 'New information about the chat member' + - + name: invite_link + types: + - ChatInviteLink + optional: true + description: 'Optional. Chat invite link, which was used by the user to join the chat; for joining by invite link events only.' + - + name: via_chat_folder_invite_link + types: + - bool + optional: true + description: 'Optional. True, if the user joined the chat via a chat folder invite link' + extended_by: { } - name: ChatMember description: 'This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported:' @@ -2447,7 +3136,7 @@ types: types: - bool optional: false - description: 'True, if the administrator can access the chat event log, chat statistics, boost list in channels, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege' + description: 'True, if the administrator can access the chat event log, boost list in channels, see channel members, report spam messages, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege' - name: can_delete_messages types: @@ -2465,7 +3154,7 @@ types: types: - bool optional: false - description: 'True, if the administrator can restrict, ban or unban chat members' + description: 'True, if the administrator can restrict, ban or unban chat members, or access supergroup statistics' - name: can_promote_members types: @@ -2489,7 +3178,7 @@ types: types: - bool optional: true - description: 'Optional. True, if the administrator can post messages in the channel; channels only' + description: 'Optional. True, if the administrator can post messages in the channel, or access channel statistics; channels only' - name: can_edit_messages types: @@ -2519,7 +3208,7 @@ types: types: - bool optional: true - description: 'Optional. True, if the administrator can delete stories posted by other users' + description: 'Optional. True, if the administrator can delete stories posted by other users; channels only' - name: can_manage_topics types: @@ -2577,7 +3266,7 @@ types: types: - bool optional: false - description: 'True, if the user is allowed to send text messages, contacts, invoices, locations and venues' + description: 'True, if the user is allowed to send text messages, contacts, giveaways, giveaway winners, invoices, locations and venues' - name: can_send_audios types: @@ -2703,53 +3392,6 @@ types: optional: false description: 'Date when restrictions will be lifted for this user; Unix time. If 0, then the user is banned forever' extended_by: { } - - - name: ChatMemberUpdated - description: 'This object represents changes in the status of a chat member.' - fields: - - - name: chat - types: - - Chat - optional: false - description: 'Chat the user belongs to' - - - name: from - types: - - User - optional: false - description: 'Performer of the action, which resulted in the change' - - - name: date - types: - - int - optional: false - description: 'Date the change was done in Unix time' - - - name: old_chat_member - types: - - ChatMember - optional: false - description: 'Previous information about the chat member' - - - name: new_chat_member - types: - - ChatMember - optional: false - description: 'New information about the chat member' - - - name: invite_link - types: - - ChatInviteLink - optional: true - description: 'Optional. Chat invite link, which was used by the user to join the chat; for joining by invite link events only.' - - - name: via_chat_folder_invite_link - types: - - bool - optional: true - description: 'Optional. True, if the user joined the chat via a chat folder invite link' - extended_by: { } - name: ChatJoinRequest description: 'Represents a join request sent to a chat.' @@ -2771,7 +3413,7 @@ types: types: - int optional: false - description: 'Identifier of a private chat with the user who sent the join request. 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 64-bit integer or double-precision float type are safe for storing this identifier. The bot can use this identifier for 24 hours to send messages until the join request is processed, assuming no other administrator contacted the user.' + description: 'Identifier of a private chat with the user who sent the join request. 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 64-bit integer or double-precision float type are safe for storing this identifier. The bot can use this identifier for 5 minutes to send messages until the join request is processed, assuming no other administrator contacted the user.' - name: date types: @@ -2800,7 +3442,7 @@ types: types: - bool optional: true - description: 'Optional. True, if the user is allowed to send text messages, contacts, invoices, locations and venues' + description: 'Optional. True, if the user is allowed to send text messages, contacts, giveaways, giveaway winners, invoices, locations and venues' - name: can_send_audios types: @@ -2897,6 +3539,140 @@ types: optional: false description: 'Location address; 1-64 characters, as defined by the chat owner' extended_by: { } + - + name: ReactionType + description: 'This object describes the type of a reaction. Currently, it can be one of' + fields: { } + extended_by: + - ReactionTypeEmoji + - ReactionTypeCustomEmoji + - + name: ReactionTypeEmoji + description: 'The reaction is based on an emoji.' + fields: + - + name: type + types: + - string + optional: false + description: 'Type of the reaction, always “emoji”' + - + name: emoji + types: + - string + optional: false + description: 'Reaction emoji. Currently, it can be one of "👍", "👎", "❤", "🔥", "🥰", "👏", "😁", "🤔", "🤯", "😱", "🤬", "😢", "🎉", "🤩", "🤮", "💩", "🙏", "👌", "🕊", "🤡", "🥱", "🥴", "😍", "🐳", "❤‍🔥", "🌚", "🌭", "💯", "🤣", "⚡", "🍌", "🏆", "💔", "🤨", "😐", "🍓", "🍾", "💋", "🖕", "😈", "😴", "😭", "🤓", "👻", "👨‍💻", "👀", "🎃", "🙈", "😇", "😨", "🤝", "✍", "🤗", "🫡", "🎅", "🎄", "☃", "💅", "🤪", "🗿", "🆒", "💘", "🙉", "🦄", "😘", "💊", "🙊", "😎", "👾", "🤷‍♂", "🤷", "🤷‍♀", "😡"' + extended_by: { } + - + name: ReactionTypeCustomEmoji + description: 'The reaction is based on a custom emoji.' + fields: + - + name: type + types: + - string + optional: false + description: 'Type of the reaction, always “custom_emoji”' + - + name: custom_emoji_id + types: + - string + optional: false + description: 'Custom emoji identifier' + extended_by: { } + - + name: ReactionCount + description: 'Represents a reaction added to a message along with the number of times it was added.' + fields: + - + name: type + types: + - ReactionType + optional: false + description: 'Type of the reaction' + - + name: total_count + types: + - int + optional: false + description: 'Number of times the reaction was added' + extended_by: { } + - + name: MessageReactionUpdated + description: 'This object represents a change of a reaction on a message performed by a user.' + fields: + - + name: chat + types: + - Chat + optional: false + description: 'The chat containing the message the user reacted to' + - + name: message_id + types: + - int + optional: false + description: 'Unique identifier of the message inside the chat' + - + name: user + types: + - User + optional: true + description: "Optional. The user that changed the reaction, if the user isn't anonymous" + - + name: actor_chat + types: + - Chat + optional: true + description: 'Optional. The chat on behalf of which the reaction was changed, if the user is anonymous' + - + name: date + types: + - int + optional: false + description: 'Date of the change in Unix time' + - + name: old_reaction + types: + - Array + optional: false + description: 'Previous list of reaction types that were set by the user' + - + name: new_reaction + types: + - Array + optional: false + description: 'New list of reaction types that have been set by the user' + extended_by: { } + - + name: MessageReactionCountUpdated + description: 'This object represents reaction changes on a message with anonymous reactions.' + fields: + - + name: chat + types: + - Chat + optional: false + description: 'The chat containing the message' + - + name: message_id + types: + - int + optional: false + description: 'Unique message identifier inside the chat' + - + name: date + types: + - int + optional: false + description: 'Date of the change in Unix time' + - + name: reactions + types: + - Array + optional: false + description: 'List of reactions that are present on the message' + extended_by: { } - name: ForumTopic description: 'This object represents a forum topic.' @@ -3155,6 +3931,164 @@ types: description: 'Type of the button, must be default' default: default extended_by: { } + - + name: ChatBoostSource + description: 'This object describes the source of a chat boost. It can be one of' + fields: { } + extended_by: + - ChatBoostSourcePremium + - ChatBoostSourceGiftCode + - ChatBoostSourceGiveaway + - + name: ChatBoostSourcePremium + description: 'The boost was obtained by subscribing to Telegram Premium or by gifting a Telegram Premium subscription to another user.' + fields: + - + name: source + types: + - string + optional: false + description: 'Source of the boost, always “premium”' + - + name: user + types: + - User + optional: false + description: 'User that boosted the chat' + extended_by: { } + - + name: ChatBoostSourceGiftCode + description: 'The boost was obtained by the creation of Telegram Premium gift codes to boost a chat. Each such code boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.' + fields: + - + name: source + types: + - string + optional: false + description: 'Source of the boost, always “gift_code”' + - + name: user + types: + - User + optional: false + description: 'User for which the gift code was created' + extended_by: { } + - + name: ChatBoostSourceGiveaway + description: 'The boost was obtained by the creation of a Telegram Premium giveaway. This boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.' + fields: + - + name: source + types: + - string + optional: false + description: 'Source of the boost, always “giveaway”' + - + name: giveaway_message_id + types: + - int + optional: false + description: "Identifier of a message in the chat with the giveaway; the message could have been deleted already. May be 0 if the message isn't sent yet." + - + name: user + types: + - User + optional: true + description: 'Optional. User that won the prize in the giveaway if any' + - + name: is_unclaimed + types: + - bool + optional: true + description: 'Optional. True, if the giveaway was completed, but there was no user to win the prize' + default: true + extended_by: { } + - + name: ChatBoost + description: 'This object contains information about a chat boost.' + fields: + - + name: boost_id + types: + - string + optional: false + description: 'Unique identifier of the boost' + - + name: add_date + types: + - int + optional: false + description: 'Point in time (Unix timestamp) when the chat was boosted' + - + name: expiration_date + types: + - int + optional: false + description: "Point in time (Unix timestamp) when the boost will automatically expire, unless the booster's Telegram Premium subscription is prolonged" + - + name: source + types: + - ChatBoostSource + optional: false + description: 'Source of the added boost' + extended_by: { } + - + name: ChatBoostUpdated + description: 'This object represents a boost added to a chat or changed.' + fields: + - + name: chat + types: + - Chat + optional: false + description: 'Chat which was boosted' + - + name: boost + types: + - ChatBoost + optional: false + description: 'Infomation about the chat boost' + extended_by: { } + - + name: ChatBoostRemoved + description: 'This object represents a boost removed from a chat.' + fields: + - + name: chat + types: + - Chat + optional: false + description: 'Chat which was boosted' + - + name: boost_id + types: + - string + optional: false + description: 'Unique identifier of the boost' + - + name: remove_date + types: + - int + optional: false + description: 'Point in time (Unix timestamp) when the boost was removed' + - + name: source + types: + - ChatBoostSource + optional: false + description: 'Source of the removed boost' + extended_by: { } + - + name: UserChatBoosts + description: 'This object represents a list of boosts added to a chat by a user.' + fields: + - + name: boosts + types: + - Array + optional: false + description: 'The list of boosts added to the chat by the user' + extended_by: { } - name: ResponseParameters description: 'Describes why a request was unsuccessful.' @@ -5221,11 +6155,11 @@ types: optional: true description: 'Optional. List of special entities that appear in message text, which can be specified instead of parse_mode' - - name: disable_web_page_preview + name: link_preview_options types: - - bool + - LinkPreviewOptions optional: true - description: 'Optional. Disables link previews for links in the sent message' + description: 'Optional. Link preview generation options for the message' extended_by: { } - name: InputLocationMessageContent @@ -6313,7 +7247,7 @@ methods: types: - Array optional: true - description: "A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time." + description: 'A JSON-serialized list of the update types you want your bot to receive. For example, specify ["message", "edited_channel_post", "callback_query"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.Please note that this parameter doesn''t affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time.' return_types: - Array - @@ -6350,7 +7284,7 @@ methods: types: - Array optional: true - description: "A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time." + description: 'A JSON-serialized list of the update types you want your bot to receive. For example, specify ["message", "edited_channel_post", "callback_query"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.Please note that this parameter doesn''t affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time.' - name: drop_pending_updates types: @@ -6437,11 +7371,11 @@ methods: optional: true description: 'A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode' - - name: disable_web_page_preview + name: link_preview_options types: - - bool + - LinkPreviewOptions optional: true - description: 'Disables link previews for links in this message' + description: 'Link preview generation options for the message' - name: disable_notification types: @@ -6455,17 +7389,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -6479,7 +7407,7 @@ methods: - Message - name: forwardMessage - description: "Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned." + description: "Use this method to forward messages of any kind. Service messages and messages with protected content can't be forwarded. On success, the sent Message is returned." fields: - name: chat_id @@ -6521,9 +7449,53 @@ methods: description: 'Message identifier in the chat specified in from_chat_id' return_types: - Message + - + name: forwardMessages + description: "Use this method to forward multiple messages of any kind. If some of the specified messages can't be found or forwarded, they are skipped. Service messages and messages with protected content can't be forwarded. Album grouping is kept for forwarded messages. On success, an array of MessageId of the sent messages is returned." + fields: + - + name: chat_id + types: + - int + - string + optional: false + description: 'Unique identifier for the target chat or username of the target channel (in the format @channelusername)' + - + name: message_thread_id + types: + - int + optional: true + description: 'Unique identifier for the target message thread (topic) of the forum; for forum supergroups only' + - + name: from_chat_id + types: + - int + - string + optional: false + description: 'Unique identifier for the chat where the original messages were sent (or channel username in the format @channelusername)' + - + name: message_ids + types: + - Array + optional: false + description: 'Identifiers of 1-100 messages in the chat from_chat_id to forward. The identifiers must be specified in a strictly increasing order.' + - + name: disable_notification + types: + - bool + optional: true + description: 'Sends the messages silently. Users will receive a notification with no sound.' + - + name: protect_content + types: + - bool + optional: true + description: 'Protects the contents of the forwarded messages from forwarding and saving' + return_types: + - Array - name: copyMessage - description: "Use this method to copy messages of any kind. Service messages and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success." + description: "Use this method to copy messages of any kind. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success." fields: - name: chat_id @@ -6582,17 +7554,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -6604,6 +7570,56 @@ methods: description: 'Additional interface options. A JSON-serialized object for an inline keyboard, custom reply keyboard, instructions to remove reply keyboard or to force a reply from the user.' return_types: - MessageId + - + name: copyMessages + description: "Use this method to copy messages of any kind. If some of the specified messages can't be found or copied, they are skipped. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessages, but the copied messages don't have a link to the original message. Album grouping is kept for copied messages. On success, an array of MessageId of the sent messages is returned." + fields: + - + name: chat_id + types: + - int + - string + optional: false + description: 'Unique identifier for the target chat or username of the target channel (in the format @channelusername)' + - + name: message_thread_id + types: + - int + optional: true + description: 'Unique identifier for the target message thread (topic) of the forum; for forum supergroups only' + - + name: from_chat_id + types: + - int + - string + optional: false + description: 'Unique identifier for the chat where the original messages were sent (or channel username in the format @channelusername)' + - + name: message_ids + types: + - Array + optional: false + description: 'Identifiers of 1-100 messages in the chat from_chat_id to copy. The identifiers must be specified in a strictly increasing order.' + - + name: disable_notification + types: + - bool + optional: true + description: 'Sends the messages silently. Users will receive a notification with no sound.' + - + name: protect_content + types: + - bool + optional: true + description: 'Protects the contents of the sent messages from forwarding and saving' + - + name: remove_caption + types: + - bool + optional: true + description: 'Pass True to copy the messages without their captions' + return_types: + - Array - name: sendPhoto description: 'Use this method to send photos. On success, the sent Message is returned.' @@ -6665,17 +7681,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -6767,17 +7777,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -6857,17 +7861,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -6971,17 +7969,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7079,17 +8071,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7162,17 +8148,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7240,17 +8220,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7298,17 +8272,11 @@ methods: optional: true description: 'Protects the contents of the sent messages from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the messages are a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' return_types: - Array - @@ -7377,17 +8345,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7477,17 +8439,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7553,17 +8509,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7680,17 +8630,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7739,17 +8683,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -7786,6 +8724,37 @@ methods: description: 'Type of action to broadcast. Choose one, depending on what the user is about to receive: typing for text messages, upload_photo for photos, record_video or upload_video for videos, record_voice or upload_voice for voice notes, upload_document for general files, choose_sticker for stickers, find_location for location data, record_video_note or upload_video_note for video notes.' return_types: - bool + - + name: setMessageReaction + description: "Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. In albums, bots must react to the first message. Returns True on success." + fields: + - + name: chat_id + types: + - int + - string + optional: false + description: 'Unique identifier for the target chat or username of the target channel (in the format @channelusername)' + - + name: message_id + types: + - int + optional: false + description: 'Identifier of the target message' + - + name: reaction + types: + - Array + optional: true + description: 'New list of reaction types to set on the message. Currently, as non-premium users, bots can set up to one reaction per message. A custom emoji reaction can be used if it is either already present on the message or explicitly allowed by chat administrators.' + - + name: is_big + types: + - bool + optional: true + description: 'Pass True to set the reaction with a big animation' + return_types: + - bool - name: getUserProfilePhotos description: 'Use this method to get a list of profile pictures for a user. Returns a UserProfilePhotos object.' @@ -7944,19 +8913,7 @@ methods: types: - bool optional: true - description: 'Pass True if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege' - - - name: can_post_messages - types: - - bool - optional: true - description: 'Pass True if the administrator can create channel posts, channels only' - - - name: can_edit_messages - types: - - bool - optional: true - description: 'Pass True if the administrator can edit messages of other users and can pin messages, channels only' + description: 'Pass True if the administrator can access the chat event log, boost list in channels, see channel members, report spam messages, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege' - name: can_delete_messages types: @@ -7974,7 +8931,7 @@ methods: types: - bool optional: true - description: 'Pass True if the administrator can restrict, ban or unban chat members' + description: 'Pass True if the administrator can restrict, ban or unban chat members, or access supergroup statistics' - name: can_promote_members types: @@ -7993,12 +8950,42 @@ methods: - bool optional: true description: 'Pass True if the administrator can invite new users to the chat' + - + name: can_post_messages + types: + - bool + optional: true + description: 'Pass True if the administrator can post messages in the channel, or access channel statistics; channels only' + - + name: can_edit_messages + types: + - bool + optional: true + description: 'Pass True if the administrator can edit messages of other users and can pin messages; channels only' - name: can_pin_messages types: - bool optional: true description: 'Pass True if the administrator can pin messages, supergroups only' + - + name: can_post_stories + types: + - bool + optional: true + description: 'Pass True if the administrator can post stories in the channel; channels only' + - + name: can_edit_stories + types: + - bool + optional: true + description: 'Pass True if the administrator can edit stories posted by other users; channels only' + - + name: can_delete_stories + types: + - bool + optional: true + description: 'Pass True if the administrator can delete stories posted by other users; channels only' - name: can_manage_topics types: @@ -8387,7 +9374,7 @@ methods: - bool - name: getChat - description: 'Use this method to get up to date information about the chat (current name of the user for one-on-one conversations, current username of a user, group or channel, etc.). Returns a Chat object on success.' + description: 'Use this method to get up to date information about the chat. Returns a Chat object on success.' fields: - name: chat_id @@ -8741,6 +9728,25 @@ methods: default: 0 return_types: - bool + - + name: getUserChatBoosts + description: 'Use this method to get the list of boosts added to a chat by a user. Requires administrator rights in the chat. Returns a UserChatBoosts object.' + fields: + - + name: chat_id + types: + - int + - string + optional: false + description: 'Unique identifier for the chat or username of the channel (in the format @channelusername)' + - + name: user_id + types: + - int + optional: false + description: 'Unique identifier of the target user' + return_types: + - UserChatBoosts - name: setMyCommands description: "Use this method to change the list of the bot's commands. See this manual for more details about bot commands. Returns True on success." @@ -8997,11 +10003,11 @@ methods: optional: true description: 'A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode' - - name: disable_web_page_preview + name: link_preview_options types: - - bool + - LinkPreviewOptions optional: true - description: 'Disables link previews for links in this message' + description: 'Link preview generation options for the message' - name: reply_markup types: @@ -9269,6 +10275,25 @@ methods: description: 'Identifier of the message to delete' return_types: - bool + - + name: deleteMessages + description: "Use this method to delete multiple messages simultaneously. If some of the specified messages can't be found, they are skipped. Returns True on success." + fields: + - + name: chat_id + types: + - int + - string + optional: false + description: 'Unique identifier for the target chat or username of the target channel (in the format @channelusername)' + - + name: message_ids + types: + - Array + optional: false + description: 'Identifiers of 1-100 messages to delete. See deleteMessage for limitations on which messages can be deleted' + return_types: + - bool - name: sendSticker description: 'Use this method to send static .WEBP, animated .TGS, or video .WEBM stickers. On success, the sent Message is returned.' @@ -9312,17 +10337,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -9829,17 +10848,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: @@ -10082,17 +11095,11 @@ methods: optional: true description: 'Protects the contents of the sent message from forwarding and saving' - - name: reply_to_message_id + name: reply_parameters types: - - int + - ReplyParameters optional: true - description: 'If the message is a reply, ID of the original message' - - - name: allow_sending_without_reply - types: - - bool - optional: true - description: 'Pass True if the message should be sent even if the specified replied-to message is not found' + description: 'Description of the message to reply to' - name: reply_markup types: diff --git a/schemas/botapi_openapi.json b/schemas/botapi_openapi.json index 28d97c6..04c7cde 100644 --- a/schemas/botapi_openapi.json +++ b/schemas/botapi_openapi.json @@ -3,7 +3,7 @@ "info": { "title": "Telegram Bot API", "description": "Auto-generated OpenAPI schema by TGScraper.", - "version": "6.9.0" + "version": "7.0.0" }, "servers": [ { @@ -182,6 +182,12 @@ "edited_channel_post": { "$ref": "#/components/schemas/Message" }, + "message_reaction": { + "$ref": "#/components/schemas/MessageReactionUpdated" + }, + "message_reaction_count": { + "$ref": "#/components/schemas/MessageReactionCountUpdated" + }, "inline_query": { "$ref": "#/components/schemas/InlineQuery" }, @@ -211,6 +217,12 @@ }, "chat_join_request": { "$ref": "#/components/schemas/ChatJoinRequest" + }, + "chat_boost": { + "$ref": "#/components/schemas/ChatBoostUpdated" + }, + "removed_chat_boost": { + "$ref": "#/components/schemas/ChatBoostRemoved" } }, "type": "object" @@ -340,6 +352,24 @@ "type": "string" } }, + "available_reactions": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReactionType" + } + }, + "accent_color_id": { + "type": "integer" + }, + "background_custom_emoji_id": { + "type": "string" + }, + "profile_accent_color_id": { + "type": "integer" + }, + "profile_background_custom_emoji_id": { + "type": "string" + }, "emoji_status_custom_emoji_id": { "type": "string" }, @@ -395,6 +425,10 @@ "type": "boolean", "default": true }, + "has_visible_history": { + "type": "boolean", + "default": true + }, "sticker_set_name": { "type": "string" }, @@ -437,23 +471,8 @@ "chat": { "$ref": "#/components/schemas/Chat" }, - "forward_from": { - "$ref": "#/components/schemas/User" - }, - "forward_from_chat": { - "$ref": "#/components/schemas/Chat" - }, - "forward_from_message_id": { - "type": "integer" - }, - "forward_signature": { - "type": "string" - }, - "forward_sender_name": { - "type": "string" - }, - "forward_date": { - "type": "integer" + "forward_origin": { + "$ref": "#/components/schemas/MessageOrigin" }, "is_topic_message": { "type": "boolean", @@ -466,6 +485,12 @@ "reply_to_message": { "$ref": "#/components/schemas/Message" }, + "external_reply": { + "$ref": "#/components/schemas/ExternalReplyInfo" + }, + "quote": { + "$ref": "#/components/schemas/TextQuote" + }, "via_bot": { "$ref": "#/components/schemas/User" }, @@ -491,6 +516,9 @@ "$ref": "#/components/schemas/MessageEntity" } }, + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" + }, "animation": { "$ref": "#/components/schemas/Animation" }, @@ -596,7 +624,7 @@ "type": "integer" }, "pinned_message": { - "$ref": "#/components/schemas/Message" + "$ref": "#/components/schemas/MaybeInaccessibleMessage" }, "invoice": { "$ref": "#/components/schemas/Invoice" @@ -604,8 +632,8 @@ "successful_payment": { "$ref": "#/components/schemas/SuccessfulPayment" }, - "user_shared": { - "$ref": "#/components/schemas/UserShared" + "users_shared": { + "$ref": "#/components/schemas/UsersShared" }, "chat_shared": { "$ref": "#/components/schemas/ChatShared" @@ -640,6 +668,18 @@ "general_forum_topic_unhidden": { "$ref": "#/components/schemas/GeneralForumTopicUnhidden" }, + "giveaway_created": { + "$ref": "#/components/schemas/GiveawayCreated" + }, + "giveaway": { + "$ref": "#/components/schemas/Giveaway" + }, + "giveaway_winners": { + "$ref": "#/components/schemas/GiveawayWinners" + }, + "giveaway_completed": { + "$ref": "#/components/schemas/GiveawayCompleted" + }, "video_chat_scheduled": { "$ref": "#/components/schemas/VideoChatScheduled" }, @@ -673,6 +713,37 @@ }, "type": "object" }, + "InaccessibleMessage": { + "description": "This object describes a message that was deleted or is otherwise inaccessible to the bot.", + "required": [ + "chat", + "message_id", + "date" + ], + "properties": { + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "message_id": { + "type": "integer" + }, + "date": { + "type": "integer" + } + }, + "type": "object" + }, + "MaybeInaccessibleMessage": { + "description": "This object describes a message that can be inaccessible to the bot. It can be one of", + "anyOf": [ + { + "$ref": "#/components/schemas/Message" + }, + { + "$ref": "#/components/schemas/InaccessibleMessage" + } + ] + }, "MessageEntity": { "description": "This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.", "required": [ @@ -705,6 +776,261 @@ }, "type": "object" }, + "TextQuote": { + "description": "This object contains information about the quoted part of a message that is replied to by the given message.", + "required": [ + "text", + "position" + ], + "properties": { + "text": { + "type": "string" + }, + "entities": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MessageEntity" + } + }, + "position": { + "type": "integer" + }, + "is_manual": { + "type": "boolean", + "default": true + } + }, + "type": "object" + }, + "ExternalReplyInfo": { + "description": "This object contains information about a message that is being replied to, which may come from another chat or forum topic.", + "required": [ + "origin" + ], + "properties": { + "origin": { + "$ref": "#/components/schemas/MessageOrigin" + }, + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "message_id": { + "type": "integer" + }, + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" + }, + "animation": { + "$ref": "#/components/schemas/Animation" + }, + "audio": { + "$ref": "#/components/schemas/Audio" + }, + "document": { + "$ref": "#/components/schemas/Document" + }, + "photo": { + "type": "array", + "items": { + "$ref": "#/components/schemas/PhotoSize" + } + }, + "sticker": { + "$ref": "#/components/schemas/Sticker" + }, + "story": { + "$ref": "#/components/schemas/Story" + }, + "video": { + "$ref": "#/components/schemas/Video" + }, + "video_note": { + "$ref": "#/components/schemas/VideoNote" + }, + "voice": { + "$ref": "#/components/schemas/Voice" + }, + "has_media_spoiler": { + "type": "boolean", + "default": true + }, + "contact": { + "$ref": "#/components/schemas/Contact" + }, + "dice": { + "$ref": "#/components/schemas/Dice" + }, + "game": { + "$ref": "#/components/schemas/Game" + }, + "giveaway": { + "$ref": "#/components/schemas/Giveaway" + }, + "giveaway_winners": { + "$ref": "#/components/schemas/GiveawayWinners" + }, + "invoice": { + "$ref": "#/components/schemas/Invoice" + }, + "location": { + "$ref": "#/components/schemas/Location" + }, + "poll": { + "$ref": "#/components/schemas/Poll" + }, + "venue": { + "$ref": "#/components/schemas/Venue" + } + }, + "type": "object" + }, + "ReplyParameters": { + "description": "Describes reply parameters for the message that is being sent.", + "required": [ + "message_id" + ], + "properties": { + "message_id": { + "type": "integer" + }, + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "allow_sending_without_reply": { + "type": "boolean" + }, + "quote": { + "type": "string" + }, + "quote_parse_mode": { + "type": "string" + }, + "quote_entities": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MessageEntity" + } + }, + "quote_position": { + "type": "integer" + } + }, + "type": "object" + }, + "MessageOrigin": { + "description": "This object describes the origin of a message. It can be one of", + "anyOf": [ + { + "$ref": "#/components/schemas/MessageOriginUser" + }, + { + "$ref": "#/components/schemas/MessageOriginHiddenUser" + }, + { + "$ref": "#/components/schemas/MessageOriginChat" + }, + { + "$ref": "#/components/schemas/MessageOriginChannel" + } + ] + }, + "MessageOriginUser": { + "description": "The message was originally sent by a known user.", + "required": [ + "type", + "date", + "sender_user" + ], + "properties": { + "type": { + "type": "string" + }, + "date": { + "type": "integer" + }, + "sender_user": { + "$ref": "#/components/schemas/User" + } + }, + "type": "object" + }, + "MessageOriginHiddenUser": { + "description": "The message was originally sent by an unknown user.", + "required": [ + "type", + "date", + "sender_user_name" + ], + "properties": { + "type": { + "type": "string" + }, + "date": { + "type": "integer" + }, + "sender_user_name": { + "type": "string" + } + }, + "type": "object" + }, + "MessageOriginChat": { + "description": "The message was originally sent on behalf of a chat to a group chat.", + "required": [ + "type", + "date", + "sender_chat" + ], + "properties": { + "type": { + "type": "string" + }, + "date": { + "type": "integer" + }, + "sender_chat": { + "$ref": "#/components/schemas/Chat" + }, + "author_signature": { + "type": "string" + } + }, + "type": "object" + }, + "MessageOriginChannel": { + "description": "The message was originally sent to a channel chat.", + "required": [ + "type", + "date", + "chat", + "message_id" + ], + "properties": { + "type": { + "type": "string" + }, + "date": { + "type": "integer" + }, + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "message_id": { + "type": "integer" + }, + "author_signature": { + "type": "string" + } + }, + "type": "object" + }, "PhotoSize": { "description": "This object represents one size of a photo or a file / sticker thumbnail.", "required": [ @@ -1236,18 +1562,21 @@ "description": "This object represents a service message about General forum topic unhidden in the chat. Currently holds no information.", "type": "object" }, - "UserShared": { - "description": "This object contains information about the user whose identifier was shared with the bot using a KeyboardButtonRequestUser button.", + "UsersShared": { + "description": "This object contains information about the users whose identifiers were shared with the bot using a KeyboardButtonRequestUsers button.", "required": [ "request_id", - "user_id" + "user_ids" ], "properties": { "request_id": { "type": "integer" }, - "user_id": { - "type": "integer" + "user_ids": { + "type": "array", + "items": { + "type": "integer" + } } }, "type": "object" @@ -1326,6 +1655,143 @@ }, "type": "object" }, + "GiveawayCreated": { + "description": "This object represents a service message about the creation of a scheduled giveaway. Currently holds no information.", + "type": "object" + }, + "Giveaway": { + "description": "This object represents a message about a scheduled giveaway.", + "required": [ + "chats", + "winners_selection_date", + "winner_count" + ], + "properties": { + "chats": { + "type": "array", + "items": { + "$ref": "#/components/schemas/Chat" + } + }, + "winners_selection_date": { + "type": "integer" + }, + "winner_count": { + "type": "integer" + }, + "only_new_members": { + "type": "boolean", + "default": true + }, + "has_public_winners": { + "type": "boolean", + "default": true + }, + "prize_description": { + "type": "string" + }, + "country_codes": { + "type": "array", + "items": { + "type": "string" + } + }, + "premium_subscription_month_count": { + "type": "integer" + } + }, + "type": "object" + }, + "GiveawayWinners": { + "description": "This object represents a message about the completion of a giveaway with public winners.", + "required": [ + "chat", + "giveaway_message_id", + "winners_selection_date", + "winner_count", + "winners" + ], + "properties": { + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "giveaway_message_id": { + "type": "integer" + }, + "winners_selection_date": { + "type": "integer" + }, + "winner_count": { + "type": "integer" + }, + "winners": { + "type": "array", + "items": { + "$ref": "#/components/schemas/User" + } + }, + "additional_chat_count": { + "type": "integer" + }, + "premium_subscription_month_count": { + "type": "integer" + }, + "unclaimed_prize_count": { + "type": "integer" + }, + "only_new_members": { + "type": "boolean", + "default": true + }, + "was_refunded": { + "type": "boolean", + "default": true + }, + "prize_description": { + "type": "string" + } + }, + "type": "object" + }, + "GiveawayCompleted": { + "description": "This object represents a service message about the completion of a giveaway without public winners.", + "required": [ + "winner_count" + ], + "properties": { + "winner_count": { + "type": "integer" + }, + "unclaimed_prize_count": { + "type": "integer" + }, + "giveaway_message": { + "$ref": "#/components/schemas/Message" + } + }, + "type": "object" + }, + "LinkPreviewOptions": { + "description": "Describes the options used for link preview generation.", + "properties": { + "is_disabled": { + "type": "boolean" + }, + "url": { + "type": "string" + }, + "prefer_small_media": { + "type": "boolean" + }, + "prefer_large_media": { + "type": "boolean" + }, + "show_above_text": { + "type": "boolean" + } + }, + "type": "object" + }, "UserProfilePhotos": { "description": "This object represent a user's profile pictures.", "required": [ @@ -1416,7 +1882,7 @@ "type": "object" }, "KeyboardButton": { - "description": "This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_user, request_chat, request_contact, request_location, and request_poll are mutually exclusive.", + "description": "This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_users, request_chat, request_contact, request_location, and request_poll are mutually exclusive.", "required": [ "text" ], @@ -1424,8 +1890,8 @@ "text": { "type": "string" }, - "request_user": { - "$ref": "#/components/schemas/KeyboardButtonRequestUser" + "request_users": { + "$ref": "#/components/schemas/KeyboardButtonRequestUsers" }, "request_chat": { "$ref": "#/components/schemas/KeyboardButtonRequestChat" @@ -1445,8 +1911,8 @@ }, "type": "object" }, - "KeyboardButtonRequestUser": { - "description": "This object defines the criteria used to request a suitable user. The identifier of the selected user will be shared with the bot when the corresponding button is pressed. More about requesting users »", + "KeyboardButtonRequestUsers": { + "description": "This object defines the criteria used to request suitable users. The identifiers of the selected users will be shared with the bot when the corresponding button is pressed. More about requesting users »", "required": [ "request_id" ], @@ -1459,6 +1925,10 @@ }, "user_is_premium": { "type": "boolean" + }, + "max_quantity": { + "type": "integer", + "default": 1 } }, "type": "object" @@ -1636,7 +2106,7 @@ "$ref": "#/components/schemas/User" }, "message": { - "$ref": "#/components/schemas/Message" + "$ref": "#/components/schemas/MaybeInaccessibleMessage" }, "inline_message_id": { "type": "string" @@ -1797,6 +2267,40 @@ }, "type": "object" }, + "ChatMemberUpdated": { + "description": "This object represents changes in the status of a chat member.", + "required": [ + "chat", + "from", + "date", + "old_chat_member", + "new_chat_member" + ], + "properties": { + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "from": { + "$ref": "#/components/schemas/User" + }, + "date": { + "type": "integer" + }, + "old_chat_member": { + "$ref": "#/components/schemas/ChatMember" + }, + "new_chat_member": { + "$ref": "#/components/schemas/ChatMember" + }, + "invite_link": { + "$ref": "#/components/schemas/ChatInviteLink" + }, + "via_chat_folder_invite_link": { + "type": "boolean" + } + }, + "type": "object" + }, "ChatMember": { "description": "This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported:", "anyOf": [ @@ -2051,40 +2555,6 @@ }, "type": "object" }, - "ChatMemberUpdated": { - "description": "This object represents changes in the status of a chat member.", - "required": [ - "chat", - "from", - "date", - "old_chat_member", - "new_chat_member" - ], - "properties": { - "chat": { - "$ref": "#/components/schemas/Chat" - }, - "from": { - "$ref": "#/components/schemas/User" - }, - "date": { - "type": "integer" - }, - "old_chat_member": { - "$ref": "#/components/schemas/ChatMember" - }, - "new_chat_member": { - "$ref": "#/components/schemas/ChatMember" - }, - "invite_link": { - "$ref": "#/components/schemas/ChatInviteLink" - }, - "via_chat_folder_invite_link": { - "type": "boolean" - } - }, - "type": "object" - }, "ChatJoinRequest": { "description": "Represents a join request sent to a chat.", "required": [ @@ -2179,6 +2649,132 @@ }, "type": "object" }, + "ReactionType": { + "description": "This object describes the type of a reaction. Currently, it can be one of", + "anyOf": [ + { + "$ref": "#/components/schemas/ReactionTypeEmoji" + }, + { + "$ref": "#/components/schemas/ReactionTypeCustomEmoji" + } + ] + }, + "ReactionTypeEmoji": { + "description": "The reaction is based on an emoji.", + "required": [ + "type", + "emoji" + ], + "properties": { + "type": { + "type": "string" + }, + "emoji": { + "type": "string" + } + }, + "type": "object" + }, + "ReactionTypeCustomEmoji": { + "description": "The reaction is based on a custom emoji.", + "required": [ + "type", + "custom_emoji_id" + ], + "properties": { + "type": { + "type": "string" + }, + "custom_emoji_id": { + "type": "string" + } + }, + "type": "object" + }, + "ReactionCount": { + "description": "Represents a reaction added to a message along with the number of times it was added.", + "required": [ + "type", + "total_count" + ], + "properties": { + "type": { + "$ref": "#/components/schemas/ReactionType" + }, + "total_count": { + "type": "integer" + } + }, + "type": "object" + }, + "MessageReactionUpdated": { + "description": "This object represents a change of a reaction on a message performed by a user.", + "required": [ + "chat", + "message_id", + "date", + "old_reaction", + "new_reaction" + ], + "properties": { + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "message_id": { + "type": "integer" + }, + "user": { + "$ref": "#/components/schemas/User" + }, + "actor_chat": { + "$ref": "#/components/schemas/Chat" + }, + "date": { + "type": "integer" + }, + "old_reaction": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReactionType" + } + }, + "new_reaction": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReactionType" + } + } + }, + "type": "object" + }, + "MessageReactionCountUpdated": { + "description": "This object represents reaction changes on a message with anonymous reactions.", + "required": [ + "chat", + "message_id", + "date", + "reactions" + ], + "properties": { + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "message_id": { + "type": "integer" + }, + "date": { + "type": "integer" + }, + "reactions": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReactionCount" + } + } + }, + "type": "object" + }, "ForumTopic": { "description": "This object represents a forum topic.", "required": [ @@ -2469,6 +3065,154 @@ }, "type": "object" }, + "ChatBoostSource": { + "description": "This object describes the source of a chat boost. It can be one of", + "anyOf": [ + { + "$ref": "#/components/schemas/ChatBoostSourcePremium" + }, + { + "$ref": "#/components/schemas/ChatBoostSourceGiftCode" + }, + { + "$ref": "#/components/schemas/ChatBoostSourceGiveaway" + } + ] + }, + "ChatBoostSourcePremium": { + "description": "The boost was obtained by subscribing to Telegram Premium or by gifting a Telegram Premium subscription to another user.", + "required": [ + "source", + "user" + ], + "properties": { + "source": { + "type": "string" + }, + "user": { + "$ref": "#/components/schemas/User" + } + }, + "type": "object" + }, + "ChatBoostSourceGiftCode": { + "description": "The boost was obtained by the creation of Telegram Premium gift codes to boost a chat. Each such code boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.", + "required": [ + "source", + "user" + ], + "properties": { + "source": { + "type": "string" + }, + "user": { + "$ref": "#/components/schemas/User" + } + }, + "type": "object" + }, + "ChatBoostSourceGiveaway": { + "description": "The boost was obtained by the creation of a Telegram Premium giveaway. This boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.", + "required": [ + "source", + "giveaway_message_id" + ], + "properties": { + "source": { + "type": "string" + }, + "giveaway_message_id": { + "type": "integer" + }, + "user": { + "$ref": "#/components/schemas/User" + }, + "is_unclaimed": { + "type": "boolean", + "default": true + } + }, + "type": "object" + }, + "ChatBoost": { + "description": "This object contains information about a chat boost.", + "required": [ + "boost_id", + "add_date", + "expiration_date", + "source" + ], + "properties": { + "boost_id": { + "type": "string" + }, + "add_date": { + "type": "integer" + }, + "expiration_date": { + "type": "integer" + }, + "source": { + "$ref": "#/components/schemas/ChatBoostSource" + } + }, + "type": "object" + }, + "ChatBoostUpdated": { + "description": "This object represents a boost added to a chat or changed.", + "required": [ + "chat", + "boost" + ], + "properties": { + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "boost": { + "$ref": "#/components/schemas/ChatBoost" + } + }, + "type": "object" + }, + "ChatBoostRemoved": { + "description": "This object represents a boost removed from a chat.", + "required": [ + "chat", + "boost_id", + "remove_date", + "source" + ], + "properties": { + "chat": { + "$ref": "#/components/schemas/Chat" + }, + "boost_id": { + "type": "string" + }, + "remove_date": { + "type": "integer" + }, + "source": { + "$ref": "#/components/schemas/ChatBoostSource" + } + }, + "type": "object" + }, + "UserChatBoosts": { + "description": "This object represents a list of boosts added to a chat by a user.", + "required": [ + "boosts" + ], + "properties": { + "boosts": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ChatBoost" + } + } + }, + "type": "object" + }, "ResponseParameters": { "description": "Describes why a request was unsuccessful.", "properties": { @@ -3993,8 +4737,8 @@ "$ref": "#/components/schemas/MessageEntity" } }, - "disable_web_page_preview": { - "type": "boolean" + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" } }, "type": "object" @@ -5553,8 +6297,8 @@ "$ref": "#/components/schemas/MessageEntity" } }, - "disable_web_page_preview": { - "type": "boolean" + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" }, "disable_notification": { "type": "boolean" @@ -5562,11 +6306,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -5620,8 +6361,8 @@ "$ref": "#/components/schemas/MessageEntity" } }, - "disable_web_page_preview": { - "type": "boolean" + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" }, "disable_notification": { "type": "boolean" @@ -5629,11 +6370,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -5687,8 +6425,8 @@ "$ref": "#/components/schemas/MessageEntity" } }, - "disable_web_page_preview": { - "type": "boolean" + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" }, "disable_notification": { "type": "boolean" @@ -5696,11 +6434,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -5774,7 +6509,7 @@ } }, "/forwardMessage": { - "description": "Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned.", + "description": "Use this method to forward messages of any kind. Service messages and messages with protected content can't be forwarded. On success, the sent Message is returned.", "post": { "requestBody": { "required": true, @@ -5963,8 +6698,210 @@ } } }, + "/forwardMessages": { + "description": "Use this method to forward multiple messages of any kind. If some of the specified messages can't be found or forwarded, they are skipped. Service messages and messages with protected content can't be forwarded. Album grouping is kept for forwarded messages. On success, an array of MessageId of the sent messages is returned.", + "post": { + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "from_chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_thread_id": { + "type": "integer" + }, + "from_chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + }, + "disable_notification": { + "type": "boolean" + }, + "protect_content": { + "type": "boolean" + } + } + } + }, + "application/x-www-form-urlencoded": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "from_chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_thread_id": { + "type": "integer" + }, + "from_chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + }, + "disable_notification": { + "type": "boolean" + }, + "protect_content": { + "type": "boolean" + } + } + } + }, + "multipart/form-data": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "from_chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_thread_id": { + "type": "integer" + }, + "from_chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + }, + "disable_notification": { + "type": "boolean" + }, + "protect_content": { + "type": "boolean" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Request was successful, the result is returned.", + "content": { + "application/json": { + "schema": { + "allOf": [ + { + "$ref": "#/components/schemas/Success" + }, + { + "type": "object", + "properties": { + "result": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MessageId" + } + } + } + } + ] + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/Unauthorized" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "409": { + "$ref": "#/components/responses/Conflict" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "5XX": { + "$ref": "#/components/responses/ServerError" + }, + "default": { + "$ref": "#/components/responses/UnknownError" + } + } + } + }, "/copyMessage": { - "description": "Use this method to copy messages of any kind. Service messages and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success.", + "description": "Use this method to copy messages of any kind. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success.", "post": { "requestBody": { "required": true, @@ -6022,11 +6959,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6100,11 +7034,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6178,11 +7109,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6255,6 +7183,217 @@ } } }, + "/copyMessages": { + "description": "Use this method to copy messages of any kind. If some of the specified messages can't be found or copied, they are skipped. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessages, but the copied messages don't have a link to the original message. Album grouping is kept for copied messages. On success, an array of MessageId of the sent messages is returned.", + "post": { + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "from_chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_thread_id": { + "type": "integer" + }, + "from_chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + }, + "disable_notification": { + "type": "boolean" + }, + "protect_content": { + "type": "boolean" + }, + "remove_caption": { + "type": "boolean" + } + } + } + }, + "application/x-www-form-urlencoded": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "from_chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_thread_id": { + "type": "integer" + }, + "from_chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + }, + "disable_notification": { + "type": "boolean" + }, + "protect_content": { + "type": "boolean" + }, + "remove_caption": { + "type": "boolean" + } + } + } + }, + "multipart/form-data": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "from_chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_thread_id": { + "type": "integer" + }, + "from_chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + }, + "disable_notification": { + "type": "boolean" + }, + "protect_content": { + "type": "boolean" + }, + "remove_caption": { + "type": "boolean" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Request was successful, the result is returned.", + "content": { + "application/json": { + "schema": { + "allOf": [ + { + "$ref": "#/components/schemas/Success" + }, + { + "type": "object", + "properties": { + "result": { + "type": "array", + "items": { + "$ref": "#/components/schemas/MessageId" + } + } + } + } + ] + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/Unauthorized" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "409": { + "$ref": "#/components/responses/Conflict" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "5XX": { + "$ref": "#/components/responses/ServerError" + }, + "default": { + "$ref": "#/components/responses/UnknownError" + } + } + } + }, "/sendPhoto": { "description": "Use this method to send photos. On success, the sent Message is returned.", "post": { @@ -6313,11 +7452,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6390,11 +7526,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6467,11 +7600,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6618,11 +7748,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6711,11 +7838,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6804,11 +7928,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -6949,11 +8070,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7036,11 +8154,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7123,11 +8238,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7280,11 +8392,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7379,11 +8488,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7478,11 +8584,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7632,11 +8735,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7728,11 +8828,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7824,11 +8921,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -7959,11 +9053,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8036,11 +9127,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8113,11 +9201,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8249,11 +9334,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8327,11 +9409,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8405,11 +9484,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8534,11 +9610,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" } } } @@ -8589,11 +9662,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" } } } @@ -8644,11 +9714,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" } } } @@ -8760,11 +9827,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8831,11 +9895,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -8902,11 +9963,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9039,11 +10097,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9118,11 +10173,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9197,11 +10249,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9320,11 +10369,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9385,11 +10431,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9450,11 +10493,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9605,11 +10645,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9702,11 +10739,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9799,11 +10833,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9912,11 +10943,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -9967,11 +10995,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -10022,11 +11047,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -10238,6 +11260,163 @@ } } }, + "/setMessageReaction": { + "description": "Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. In albums, bots must react to the first message. Returns True on success.", + "post": { + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "message_id" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_id": { + "type": "integer" + }, + "reaction": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReactionType" + } + }, + "is_big": { + "type": "boolean" + } + } + } + }, + "application/x-www-form-urlencoded": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "message_id" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_id": { + "type": "integer" + }, + "reaction": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReactionType" + } + }, + "is_big": { + "type": "boolean" + } + } + } + }, + "multipart/form-data": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "message_id" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_id": { + "type": "integer" + }, + "reaction": { + "type": "array", + "items": { + "$ref": "#/components/schemas/ReactionType" + } + }, + "is_big": { + "type": "boolean" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Request was successful, the result is returned.", + "content": { + "application/json": { + "schema": { + "allOf": [ + { + "$ref": "#/components/schemas/Success" + }, + { + "type": "object", + "properties": { + "result": { + "type": "boolean" + } + } + } + ] + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/Unauthorized" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "409": { + "$ref": "#/components/responses/Conflict" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "5XX": { + "$ref": "#/components/responses/ServerError" + }, + "default": { + "$ref": "#/components/responses/UnknownError" + } + } + } + }, "/getUserProfilePhotos": { "description": "Use this method to get a list of profile pictures for a user. Returns a UserProfilePhotos object.", "post": { @@ -10933,12 +12112,6 @@ "can_manage_chat": { "type": "boolean" }, - "can_post_messages": { - "type": "boolean" - }, - "can_edit_messages": { - "type": "boolean" - }, "can_delete_messages": { "type": "boolean" }, @@ -10957,9 +12130,24 @@ "can_invite_users": { "type": "boolean" }, + "can_post_messages": { + "type": "boolean" + }, + "can_edit_messages": { + "type": "boolean" + }, "can_pin_messages": { "type": "boolean" }, + "can_post_stories": { + "type": "boolean" + }, + "can_edit_stories": { + "type": "boolean" + }, + "can_delete_stories": { + "type": "boolean" + }, "can_manage_topics": { "type": "boolean" } @@ -10993,12 +12181,6 @@ "can_manage_chat": { "type": "boolean" }, - "can_post_messages": { - "type": "boolean" - }, - "can_edit_messages": { - "type": "boolean" - }, "can_delete_messages": { "type": "boolean" }, @@ -11017,9 +12199,24 @@ "can_invite_users": { "type": "boolean" }, + "can_post_messages": { + "type": "boolean" + }, + "can_edit_messages": { + "type": "boolean" + }, "can_pin_messages": { "type": "boolean" }, + "can_post_stories": { + "type": "boolean" + }, + "can_edit_stories": { + "type": "boolean" + }, + "can_delete_stories": { + "type": "boolean" + }, "can_manage_topics": { "type": "boolean" } @@ -11053,12 +12250,6 @@ "can_manage_chat": { "type": "boolean" }, - "can_post_messages": { - "type": "boolean" - }, - "can_edit_messages": { - "type": "boolean" - }, "can_delete_messages": { "type": "boolean" }, @@ -11077,9 +12268,24 @@ "can_invite_users": { "type": "boolean" }, + "can_post_messages": { + "type": "boolean" + }, + "can_edit_messages": { + "type": "boolean" + }, "can_pin_messages": { "type": "boolean" }, + "can_post_stories": { + "type": "boolean" + }, + "can_edit_stories": { + "type": "boolean" + }, + "can_delete_stories": { + "type": "boolean" + }, "can_manage_topics": { "type": "boolean" } @@ -13515,7 +14721,7 @@ } }, "/getChat": { - "description": "Use this method to get up to date information about the chat (current name of the user for one-on-one conversations, current username of a user, group or channel, etc.). Returns a Chat object on success.", + "description": "Use this method to get up to date information about the chat. Returns a Chat object on success.", "post": { "requestBody": { "required": true, @@ -15993,6 +17199,136 @@ } } }, + "/getUserChatBoosts": { + "description": "Use this method to get the list of boosts added to a chat by a user. Requires administrator rights in the chat. Returns a UserChatBoosts object.", + "post": { + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "user_id" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "user_id": { + "type": "integer" + } + } + } + }, + "application/x-www-form-urlencoded": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "user_id" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "user_id": { + "type": "integer" + } + } + } + }, + "multipart/form-data": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "user_id" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "user_id": { + "type": "integer" + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Request was successful, the result is returned.", + "content": { + "application/json": { + "schema": { + "allOf": [ + { + "$ref": "#/components/schemas/Success" + }, + { + "type": "object", + "properties": { + "result": { + "$ref": "#/components/schemas/UserChatBoosts" + } + } + } + ] + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/Unauthorized" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "409": { + "$ref": "#/components/responses/Conflict" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "5XX": { + "$ref": "#/components/responses/ServerError" + }, + "default": { + "$ref": "#/components/responses/UnknownError" + } + } + } + }, "/setMyCommands": { "description": "Use this method to change the list of the bot's commands. See this manual for more details about bot commands. Returns True on success.", "post": { @@ -17277,8 +18613,8 @@ "$ref": "#/components/schemas/MessageEntity" } }, - "disable_web_page_preview": { - "type": "boolean" + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -17321,8 +18657,8 @@ "$ref": "#/components/schemas/MessageEntity" } }, - "disable_web_page_preview": { - "type": "boolean" + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -17365,8 +18701,8 @@ "$ref": "#/components/schemas/MessageEntity" } }, - "disable_web_page_preview": { - "type": "boolean" + "link_preview_options": { + "$ref": "#/components/schemas/LinkPreviewOptions" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -18528,6 +19864,145 @@ } } }, + "/deleteMessages": { + "description": "Use this method to delete multiple messages simultaneously. If some of the specified messages can't be found, they are skipped. Returns True on success.", + "post": { + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + } + } + } + }, + "application/x-www-form-urlencoded": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + } + } + } + }, + "multipart/form-data": { + "schema": { + "type": "object", + "required": [ + "chat_id", + "message_ids" + ], + "properties": { + "chat_id": { + "anyOf": [ + { + "type": "integer" + }, + { + "type": "string" + } + ] + }, + "message_ids": { + "type": "array", + "items": { + "type": "integer" + } + } + } + } + } + } + }, + "responses": { + "200": { + "description": "Request was successful, the result is returned.", + "content": { + "application/json": { + "schema": { + "allOf": [ + { + "$ref": "#/components/schemas/Success" + }, + { + "type": "object", + "properties": { + "result": { + "type": "boolean" + } + } + } + ] + } + } + } + }, + "400": { + "$ref": "#/components/responses/BadRequest" + }, + "401": { + "$ref": "#/components/responses/Unauthorized" + }, + "403": { + "$ref": "#/components/responses/Forbidden" + }, + "404": { + "$ref": "#/components/responses/NotFound" + }, + "409": { + "$ref": "#/components/responses/Conflict" + }, + "429": { + "$ref": "#/components/responses/TooManyRequests" + }, + "5XX": { + "$ref": "#/components/responses/ServerError" + }, + "default": { + "$ref": "#/components/responses/UnknownError" + } + } + } + }, "/sendSticker": { "description": "Use this method to send static .WEBP, animated .TGS, or video .WEBM stickers. On success, the sent Message is returned.", "post": { @@ -18574,11 +20049,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -18639,11 +20111,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -18704,11 +20173,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "anyOf": [ @@ -20770,11 +22236,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -20883,11 +22346,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -20996,11 +22456,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -21762,11 +23219,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -21797,11 +23251,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" @@ -21832,11 +23283,8 @@ "protect_content": { "type": "boolean" }, - "reply_to_message_id": { - "type": "integer" - }, - "allow_sending_without_reply": { - "type": "boolean" + "reply_parameters": { + "$ref": "#/components/schemas/ReplyParameters" }, "reply_markup": { "$ref": "#/components/schemas/InlineKeyboardMarkup" diff --git a/schemas/botapi_openapi.yaml b/schemas/botapi_openapi.yaml index 4fac27d..48f7386 100644 --- a/schemas/botapi_openapi.yaml +++ b/schemas/botapi_openapi.yaml @@ -2,7 +2,7 @@ openapi: 3.0.0 info: title: 'Telegram Bot API' description: 'Auto-generated OpenAPI schema by TGScraper.' - version: 6.9.0 + version: 7.0.0 servers: - url: 'https://api.telegram.org/bot{token}' @@ -116,6 +116,10 @@ components: $ref: '#/components/schemas/Message' edited_channel_post: $ref: '#/components/schemas/Message' + message_reaction: + $ref: '#/components/schemas/MessageReactionUpdated' + message_reaction_count: + $ref: '#/components/schemas/MessageReactionCountUpdated' inline_query: $ref: '#/components/schemas/InlineQuery' chosen_inline_result: @@ -136,6 +140,10 @@ components: $ref: '#/components/schemas/ChatMemberUpdated' chat_join_request: $ref: '#/components/schemas/ChatJoinRequest' + chat_boost: + $ref: '#/components/schemas/ChatBoostUpdated' + removed_chat_boost: + $ref: '#/components/schemas/ChatBoostRemoved' type: object WebhookInfo: description: 'Describes the current status of a webhook.' @@ -224,6 +232,18 @@ components: type: array items: type: string + available_reactions: + type: array + items: + $ref: '#/components/schemas/ReactionType' + accent_color_id: + type: integer + background_custom_emoji_id: + type: string + profile_accent_color_id: + type: integer + profile_background_custom_emoji_id: + type: string emoji_status_custom_emoji_id: type: string emoji_status_expiration_date: @@ -263,6 +283,9 @@ components: has_protected_content: type: boolean default: true + has_visible_history: + type: boolean + default: true sticker_set_name: type: string can_set_sticker_set: @@ -292,18 +315,8 @@ components: type: integer chat: $ref: '#/components/schemas/Chat' - forward_from: - $ref: '#/components/schemas/User' - forward_from_chat: - $ref: '#/components/schemas/Chat' - forward_from_message_id: - type: integer - forward_signature: - type: string - forward_sender_name: - type: string - forward_date: - type: integer + forward_origin: + $ref: '#/components/schemas/MessageOrigin' is_topic_message: type: boolean default: true @@ -312,6 +325,10 @@ components: default: true reply_to_message: $ref: '#/components/schemas/Message' + external_reply: + $ref: '#/components/schemas/ExternalReplyInfo' + quote: + $ref: '#/components/schemas/TextQuote' via_bot: $ref: '#/components/schemas/User' edit_date: @@ -329,6 +346,8 @@ components: type: array items: $ref: '#/components/schemas/MessageEntity' + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' animation: $ref: '#/components/schemas/Animation' audio: @@ -401,13 +420,13 @@ components: migrate_from_chat_id: type: integer pinned_message: - $ref: '#/components/schemas/Message' + $ref: '#/components/schemas/MaybeInaccessibleMessage' invoice: $ref: '#/components/schemas/Invoice' successful_payment: $ref: '#/components/schemas/SuccessfulPayment' - user_shared: - $ref: '#/components/schemas/UserShared' + users_shared: + $ref: '#/components/schemas/UsersShared' chat_shared: $ref: '#/components/schemas/ChatShared' connected_website: @@ -430,6 +449,14 @@ components: $ref: '#/components/schemas/GeneralForumTopicHidden' general_forum_topic_unhidden: $ref: '#/components/schemas/GeneralForumTopicUnhidden' + giveaway_created: + $ref: '#/components/schemas/GiveawayCreated' + giveaway: + $ref: '#/components/schemas/Giveaway' + giveaway_winners: + $ref: '#/components/schemas/GiveawayWinners' + giveaway_completed: + $ref: '#/components/schemas/GiveawayCompleted' video_chat_scheduled: $ref: '#/components/schemas/VideoChatScheduled' video_chat_started: @@ -451,6 +478,27 @@ components: message_id: type: integer type: object + InaccessibleMessage: + description: 'This object describes a message that was deleted or is otherwise inaccessible to the bot.' + required: + - chat + - message_id + - date + properties: + chat: + $ref: '#/components/schemas/Chat' + message_id: + type: integer + date: + type: integer + type: object + MaybeInaccessibleMessage: + description: 'This object describes a message that can be inaccessible to the bot. It can be one of' + anyOf: + - + $ref: '#/components/schemas/Message' + - + $ref: '#/components/schemas/InaccessibleMessage' MessageEntity: description: 'This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.' required: @@ -473,6 +521,179 @@ components: custom_emoji_id: type: string type: object + TextQuote: + description: 'This object contains information about the quoted part of a message that is replied to by the given message.' + required: + - text + - position + properties: + text: + type: string + entities: + type: array + items: + $ref: '#/components/schemas/MessageEntity' + position: + type: integer + is_manual: + type: boolean + default: true + type: object + ExternalReplyInfo: + description: 'This object contains information about a message that is being replied to, which may come from another chat or forum topic.' + required: + - origin + properties: + origin: + $ref: '#/components/schemas/MessageOrigin' + chat: + $ref: '#/components/schemas/Chat' + message_id: + type: integer + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' + animation: + $ref: '#/components/schemas/Animation' + audio: + $ref: '#/components/schemas/Audio' + document: + $ref: '#/components/schemas/Document' + photo: + type: array + items: + $ref: '#/components/schemas/PhotoSize' + sticker: + $ref: '#/components/schemas/Sticker' + story: + $ref: '#/components/schemas/Story' + video: + $ref: '#/components/schemas/Video' + video_note: + $ref: '#/components/schemas/VideoNote' + voice: + $ref: '#/components/schemas/Voice' + has_media_spoiler: + type: boolean + default: true + contact: + $ref: '#/components/schemas/Contact' + dice: + $ref: '#/components/schemas/Dice' + game: + $ref: '#/components/schemas/Game' + giveaway: + $ref: '#/components/schemas/Giveaway' + giveaway_winners: + $ref: '#/components/schemas/GiveawayWinners' + invoice: + $ref: '#/components/schemas/Invoice' + location: + $ref: '#/components/schemas/Location' + poll: + $ref: '#/components/schemas/Poll' + venue: + $ref: '#/components/schemas/Venue' + type: object + ReplyParameters: + description: 'Describes reply parameters for the message that is being sent.' + required: + - message_id + properties: + message_id: + type: integer + chat_id: + anyOf: + - + type: integer + - + type: string + allow_sending_without_reply: + type: boolean + quote: + type: string + quote_parse_mode: + type: string + quote_entities: + type: array + items: + $ref: '#/components/schemas/MessageEntity' + quote_position: + type: integer + type: object + MessageOrigin: + description: 'This object describes the origin of a message. It can be one of' + anyOf: + - + $ref: '#/components/schemas/MessageOriginUser' + - + $ref: '#/components/schemas/MessageOriginHiddenUser' + - + $ref: '#/components/schemas/MessageOriginChat' + - + $ref: '#/components/schemas/MessageOriginChannel' + MessageOriginUser: + description: 'The message was originally sent by a known user.' + required: + - type + - date + - sender_user + properties: + type: + type: string + date: + type: integer + sender_user: + $ref: '#/components/schemas/User' + type: object + MessageOriginHiddenUser: + description: 'The message was originally sent by an unknown user.' + required: + - type + - date + - sender_user_name + properties: + type: + type: string + date: + type: integer + sender_user_name: + type: string + type: object + MessageOriginChat: + description: 'The message was originally sent on behalf of a chat to a group chat.' + required: + - type + - date + - sender_chat + properties: + type: + type: string + date: + type: integer + sender_chat: + $ref: '#/components/schemas/Chat' + author_signature: + type: string + type: object + MessageOriginChannel: + description: 'The message was originally sent to a channel chat.' + required: + - type + - date + - chat + - message_id + properties: + type: + type: string + date: + type: integer + chat: + $ref: '#/components/schemas/Chat' + message_id: + type: integer + author_signature: + type: string + type: object PhotoSize: description: 'This object represents one size of a photo or a file / sticker thumbnail.' required: @@ -841,16 +1062,18 @@ components: GeneralForumTopicUnhidden: description: 'This object represents a service message about General forum topic unhidden in the chat. Currently holds no information.' type: object - UserShared: - description: 'This object contains information about the user whose identifier was shared with the bot using a KeyboardButtonRequestUser button.' + UsersShared: + description: 'This object contains information about the users whose identifiers were shared with the bot using a KeyboardButtonRequestUsers button.' required: - request_id - - user_id + - user_ids properties: request_id: type: integer - user_id: - type: integer + user_ids: + type: array + items: + type: integer type: object ChatShared: description: 'This object contains information about the chat whose identifier was shared with the bot using a KeyboardButtonRequestChat button.' @@ -902,6 +1125,101 @@ components: items: $ref: '#/components/schemas/User' type: object + GiveawayCreated: + description: 'This object represents a service message about the creation of a scheduled giveaway. Currently holds no information.' + type: object + Giveaway: + description: 'This object represents a message about a scheduled giveaway.' + required: + - chats + - winners_selection_date + - winner_count + properties: + chats: + type: array + items: + $ref: '#/components/schemas/Chat' + winners_selection_date: + type: integer + winner_count: + type: integer + only_new_members: + type: boolean + default: true + has_public_winners: + type: boolean + default: true + prize_description: + type: string + country_codes: + type: array + items: + type: string + premium_subscription_month_count: + type: integer + type: object + GiveawayWinners: + description: 'This object represents a message about the completion of a giveaway with public winners.' + required: + - chat + - giveaway_message_id + - winners_selection_date + - winner_count + - winners + properties: + chat: + $ref: '#/components/schemas/Chat' + giveaway_message_id: + type: integer + winners_selection_date: + type: integer + winner_count: + type: integer + winners: + type: array + items: + $ref: '#/components/schemas/User' + additional_chat_count: + type: integer + premium_subscription_month_count: + type: integer + unclaimed_prize_count: + type: integer + only_new_members: + type: boolean + default: true + was_refunded: + type: boolean + default: true + prize_description: + type: string + type: object + GiveawayCompleted: + description: 'This object represents a service message about the completion of a giveaway without public winners.' + required: + - winner_count + properties: + winner_count: + type: integer + unclaimed_prize_count: + type: integer + giveaway_message: + $ref: '#/components/schemas/Message' + type: object + LinkPreviewOptions: + description: 'Describes the options used for link preview generation.' + properties: + is_disabled: + type: boolean + url: + type: string + prefer_small_media: + type: boolean + prefer_large_media: + type: boolean + show_above_text: + type: boolean + type: object UserProfilePhotos: description: "This object represent a user's profile pictures." required: @@ -963,14 +1281,14 @@ components: type: boolean type: object KeyboardButton: - description: 'This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_user, request_chat, request_contact, request_location, and request_poll are mutually exclusive.' + description: 'This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_users, request_chat, request_contact, request_location, and request_poll are mutually exclusive.' required: - text properties: text: type: string - request_user: - $ref: '#/components/schemas/KeyboardButtonRequestUser' + request_users: + $ref: '#/components/schemas/KeyboardButtonRequestUsers' request_chat: $ref: '#/components/schemas/KeyboardButtonRequestChat' request_contact: @@ -982,8 +1300,8 @@ components: web_app: $ref: '#/components/schemas/WebAppInfo' type: object - KeyboardButtonRequestUser: - description: 'This object defines the criteria used to request a suitable user. The identifier of the selected user will be shared with the bot when the corresponding button is pressed. More about requesting users »' + KeyboardButtonRequestUsers: + description: 'This object defines the criteria used to request suitable users. The identifiers of the selected users will be shared with the bot when the corresponding button is pressed. More about requesting users »' required: - request_id properties: @@ -993,6 +1311,9 @@ components: type: boolean user_is_premium: type: boolean + max_quantity: + type: integer + default: 1 type: object KeyboardButtonRequestChat: description: 'This object defines the criteria used to request a suitable chat. The identifier of the selected chat will be shared with the bot when the corresponding button is pressed. More about requesting chats »' @@ -1112,7 +1433,7 @@ components: from: $ref: '#/components/schemas/User' message: - $ref: '#/components/schemas/Message' + $ref: '#/components/schemas/MaybeInaccessibleMessage' inline_message_id: type: string chat_instance: @@ -1223,6 +1544,30 @@ components: can_manage_topics: type: boolean type: object + ChatMemberUpdated: + description: 'This object represents changes in the status of a chat member.' + required: + - chat + - from + - date + - old_chat_member + - new_chat_member + properties: + chat: + $ref: '#/components/schemas/Chat' + from: + $ref: '#/components/schemas/User' + date: + type: integer + old_chat_member: + $ref: '#/components/schemas/ChatMember' + new_chat_member: + $ref: '#/components/schemas/ChatMember' + invite_link: + $ref: '#/components/schemas/ChatInviteLink' + via_chat_folder_invite_link: + type: boolean + type: object ChatMember: description: 'This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported:' anyOf: @@ -1403,30 +1748,6 @@ components: until_date: type: integer type: object - ChatMemberUpdated: - description: 'This object represents changes in the status of a chat member.' - required: - - chat - - from - - date - - old_chat_member - - new_chat_member - properties: - chat: - $ref: '#/components/schemas/Chat' - from: - $ref: '#/components/schemas/User' - date: - type: integer - old_chat_member: - $ref: '#/components/schemas/ChatMember' - new_chat_member: - $ref: '#/components/schemas/ChatMember' - invite_link: - $ref: '#/components/schemas/ChatInviteLink' - via_chat_folder_invite_link: - type: boolean - type: object ChatJoinRequest: description: 'Represents a join request sent to a chat.' required: @@ -1491,6 +1812,93 @@ components: address: type: string type: object + ReactionType: + description: 'This object describes the type of a reaction. Currently, it can be one of' + anyOf: + - + $ref: '#/components/schemas/ReactionTypeEmoji' + - + $ref: '#/components/schemas/ReactionTypeCustomEmoji' + ReactionTypeEmoji: + description: 'The reaction is based on an emoji.' + required: + - type + - emoji + properties: + type: + type: string + emoji: + type: string + type: object + ReactionTypeCustomEmoji: + description: 'The reaction is based on a custom emoji.' + required: + - type + - custom_emoji_id + properties: + type: + type: string + custom_emoji_id: + type: string + type: object + ReactionCount: + description: 'Represents a reaction added to a message along with the number of times it was added.' + required: + - type + - total_count + properties: + type: + $ref: '#/components/schemas/ReactionType' + total_count: + type: integer + type: object + MessageReactionUpdated: + description: 'This object represents a change of a reaction on a message performed by a user.' + required: + - chat + - message_id + - date + - old_reaction + - new_reaction + properties: + chat: + $ref: '#/components/schemas/Chat' + message_id: + type: integer + user: + $ref: '#/components/schemas/User' + actor_chat: + $ref: '#/components/schemas/Chat' + date: + type: integer + old_reaction: + type: array + items: + $ref: '#/components/schemas/ReactionType' + new_reaction: + type: array + items: + $ref: '#/components/schemas/ReactionType' + type: object + MessageReactionCountUpdated: + description: 'This object represents reaction changes on a message with anonymous reactions.' + required: + - chat + - message_id + - date + - reactions + properties: + chat: + $ref: '#/components/schemas/Chat' + message_id: + type: integer + date: + type: integer + reactions: + type: array + items: + $ref: '#/components/schemas/ReactionCount' + type: object ForumTopic: description: 'This object represents a forum topic.' required: @@ -1688,6 +2096,108 @@ components: type: string default: default type: object + ChatBoostSource: + description: 'This object describes the source of a chat boost. It can be one of' + anyOf: + - + $ref: '#/components/schemas/ChatBoostSourcePremium' + - + $ref: '#/components/schemas/ChatBoostSourceGiftCode' + - + $ref: '#/components/schemas/ChatBoostSourceGiveaway' + ChatBoostSourcePremium: + description: 'The boost was obtained by subscribing to Telegram Premium or by gifting a Telegram Premium subscription to another user.' + required: + - source + - user + properties: + source: + type: string + user: + $ref: '#/components/schemas/User' + type: object + ChatBoostSourceGiftCode: + description: 'The boost was obtained by the creation of Telegram Premium gift codes to boost a chat. Each such code boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.' + required: + - source + - user + properties: + source: + type: string + user: + $ref: '#/components/schemas/User' + type: object + ChatBoostSourceGiveaway: + description: 'The boost was obtained by the creation of a Telegram Premium giveaway. This boosts the chat 4 times for the duration of the corresponding Telegram Premium subscription.' + required: + - source + - giveaway_message_id + properties: + source: + type: string + giveaway_message_id: + type: integer + user: + $ref: '#/components/schemas/User' + is_unclaimed: + type: boolean + default: true + type: object + ChatBoost: + description: 'This object contains information about a chat boost.' + required: + - boost_id + - add_date + - expiration_date + - source + properties: + boost_id: + type: string + add_date: + type: integer + expiration_date: + type: integer + source: + $ref: '#/components/schemas/ChatBoostSource' + type: object + ChatBoostUpdated: + description: 'This object represents a boost added to a chat or changed.' + required: + - chat + - boost + properties: + chat: + $ref: '#/components/schemas/Chat' + boost: + $ref: '#/components/schemas/ChatBoost' + type: object + ChatBoostRemoved: + description: 'This object represents a boost removed from a chat.' + required: + - chat + - boost_id + - remove_date + - source + properties: + chat: + $ref: '#/components/schemas/Chat' + boost_id: + type: string + remove_date: + type: integer + source: + $ref: '#/components/schemas/ChatBoostSource' + type: object + UserChatBoosts: + description: 'This object represents a list of boosts added to a chat by a user.' + required: + - boosts + properties: + boosts: + type: array + items: + $ref: '#/components/schemas/ChatBoost' + type: object ResponseParameters: description: 'Describes why a request was unsuccessful.' properties: @@ -2738,8 +3248,8 @@ components: type: array items: $ref: '#/components/schemas/MessageEntity' - disable_web_page_preview: - type: boolean + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' type: object InputLocationMessageContent: description: 'Represents the content of a location message to be sent as the result of an inline query.' @@ -3778,16 +4288,14 @@ paths: type: array items: $ref: '#/components/schemas/MessageEntity' - disable_web_page_preview: - type: boolean + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' disable_notification: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -3821,16 +4329,14 @@ paths: type: array items: $ref: '#/components/schemas/MessageEntity' - disable_web_page_preview: - type: boolean + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' disable_notification: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -3864,16 +4370,14 @@ paths: type: array items: $ref: '#/components/schemas/MessageEntity' - disable_web_page_preview: - type: boolean + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' disable_notification: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -3915,7 +4419,7 @@ paths: default: $ref: '#/components/responses/UnknownError' /forwardMessage: - description: "Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned." + description: "Use this method to forward messages of any kind. Service messages and messages with protected content can't be forwarded. On success, the sent Message is returned." post: requestBody: required: true @@ -4034,8 +4538,136 @@ paths: $ref: '#/components/responses/ServerError' default: $ref: '#/components/responses/UnknownError' + /forwardMessages: + description: "Use this method to forward multiple messages of any kind. If some of the specified messages can't be found or forwarded, they are skipped. Service messages and messages with protected content can't be forwarded. Album grouping is kept for forwarded messages. On success, an array of MessageId of the sent messages is returned." + post: + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - chat_id + - from_chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_thread_id: + type: integer + from_chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + disable_notification: + type: boolean + protect_content: + type: boolean + application/x-www-form-urlencoded: + schema: + type: object + required: + - chat_id + - from_chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_thread_id: + type: integer + from_chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + disable_notification: + type: boolean + protect_content: + type: boolean + multipart/form-data: + schema: + type: object + required: + - chat_id + - from_chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_thread_id: + type: integer + from_chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + disable_notification: + type: boolean + protect_content: + type: boolean + responses: + 200: + description: 'Request was successful, the result is returned.' + content: + application/json: + schema: + allOf: + - + $ref: '#/components/schemas/Success' + - + type: object + properties: + result: + type: array + items: + $ref: '#/components/schemas/MessageId' + 400: + $ref: '#/components/responses/BadRequest' + 401: + $ref: '#/components/responses/Unauthorized' + 403: + $ref: '#/components/responses/Forbidden' + 404: + $ref: '#/components/responses/NotFound' + 409: + $ref: '#/components/responses/Conflict' + 429: + $ref: '#/components/responses/TooManyRequests' + 5XX: + $ref: '#/components/responses/ServerError' + default: + $ref: '#/components/responses/UnknownError' /copyMessage: - description: "Use this method to copy messages of any kind. Service messages and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success." + description: "Use this method to copy messages of any kind. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success." post: requestBody: required: true @@ -4076,10 +4708,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4126,10 +4756,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4176,10 +4804,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4220,6 +4846,140 @@ paths: $ref: '#/components/responses/ServerError' default: $ref: '#/components/responses/UnknownError' + /copyMessages: + description: "Use this method to copy messages of any kind. If some of the specified messages can't be found or copied, they are skipped. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessages, but the copied messages don't have a link to the original message. Album grouping is kept for copied messages. On success, an array of MessageId of the sent messages is returned." + post: + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - chat_id + - from_chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_thread_id: + type: integer + from_chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + disable_notification: + type: boolean + protect_content: + type: boolean + remove_caption: + type: boolean + application/x-www-form-urlencoded: + schema: + type: object + required: + - chat_id + - from_chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_thread_id: + type: integer + from_chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + disable_notification: + type: boolean + protect_content: + type: boolean + remove_caption: + type: boolean + multipart/form-data: + schema: + type: object + required: + - chat_id + - from_chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_thread_id: + type: integer + from_chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + disable_notification: + type: boolean + protect_content: + type: boolean + remove_caption: + type: boolean + responses: + 200: + description: 'Request was successful, the result is returned.' + content: + application/json: + schema: + allOf: + - + $ref: '#/components/schemas/Success' + - + type: object + properties: + result: + type: array + items: + $ref: '#/components/schemas/MessageId' + 400: + $ref: '#/components/responses/BadRequest' + 401: + $ref: '#/components/responses/Unauthorized' + 403: + $ref: '#/components/responses/Forbidden' + 404: + $ref: '#/components/responses/NotFound' + 409: + $ref: '#/components/responses/Conflict' + 429: + $ref: '#/components/responses/TooManyRequests' + 5XX: + $ref: '#/components/responses/ServerError' + default: + $ref: '#/components/responses/UnknownError' /sendPhoto: description: 'Use this method to send photos. On success, the sent Message is returned.' post: @@ -4261,10 +5021,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4310,10 +5068,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4359,10 +5115,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4454,10 +5208,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4513,10 +5265,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4572,10 +5322,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4663,10 +5411,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4718,10 +5464,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4773,10 +5517,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4872,10 +5614,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4935,10 +5675,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -4998,10 +5736,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5095,10 +5831,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5156,10 +5890,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5217,10 +5949,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5302,10 +6032,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5351,10 +6079,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5400,10 +6126,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5485,10 +6209,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5534,10 +6256,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5583,10 +6303,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5664,10 +6382,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' application/x-www-form-urlencoded: schema: type: object @@ -5699,10 +6415,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' multipart/form-data: schema: type: object @@ -5734,10 +6448,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' responses: 200: description: 'Request was successful, the result is returned.' @@ -5808,10 +6520,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5854,10 +6564,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5900,10 +6608,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -5988,10 +6694,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6040,10 +6744,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6092,10 +6794,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6170,10 +6870,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6212,10 +6910,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6254,10 +6950,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6354,10 +7048,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6418,10 +7110,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6482,10 +7172,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6553,10 +7241,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6588,10 +7274,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6623,10 +7307,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -6754,6 +7436,105 @@ paths: $ref: '#/components/responses/ServerError' default: $ref: '#/components/responses/UnknownError' + /setMessageReaction: + description: "Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. In albums, bots must react to the first message. Returns True on success." + post: + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - chat_id + - message_id + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_id: + type: integer + reaction: + type: array + items: + $ref: '#/components/schemas/ReactionType' + is_big: + type: boolean + application/x-www-form-urlencoded: + schema: + type: object + required: + - chat_id + - message_id + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_id: + type: integer + reaction: + type: array + items: + $ref: '#/components/schemas/ReactionType' + is_big: + type: boolean + multipart/form-data: + schema: + type: object + required: + - chat_id + - message_id + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_id: + type: integer + reaction: + type: array + items: + $ref: '#/components/schemas/ReactionType' + is_big: + type: boolean + responses: + 200: + description: 'Request was successful, the result is returned.' + content: + application/json: + schema: + allOf: + - + $ref: '#/components/schemas/Success' + - + type: object + properties: + result: + type: boolean + 400: + $ref: '#/components/responses/BadRequest' + 401: + $ref: '#/components/responses/Unauthorized' + 403: + $ref: '#/components/responses/Forbidden' + 404: + $ref: '#/components/responses/NotFound' + 409: + $ref: '#/components/responses/Conflict' + 429: + $ref: '#/components/responses/TooManyRequests' + 5XX: + $ref: '#/components/responses/ServerError' + default: + $ref: '#/components/responses/UnknownError' /getUserProfilePhotos: description: 'Use this method to get a list of profile pictures for a user. Returns a UserProfilePhotos object.' post: @@ -7196,10 +7977,6 @@ paths: type: boolean can_manage_chat: type: boolean - can_post_messages: - type: boolean - can_edit_messages: - type: boolean can_delete_messages: type: boolean can_manage_video_chats: @@ -7212,8 +7989,18 @@ paths: type: boolean can_invite_users: type: boolean + can_post_messages: + type: boolean + can_edit_messages: + type: boolean can_pin_messages: type: boolean + can_post_stories: + type: boolean + can_edit_stories: + type: boolean + can_delete_stories: + type: boolean can_manage_topics: type: boolean application/x-www-form-urlencoded: @@ -7235,10 +8022,6 @@ paths: type: boolean can_manage_chat: type: boolean - can_post_messages: - type: boolean - can_edit_messages: - type: boolean can_delete_messages: type: boolean can_manage_video_chats: @@ -7251,8 +8034,18 @@ paths: type: boolean can_invite_users: type: boolean + can_post_messages: + type: boolean + can_edit_messages: + type: boolean can_pin_messages: type: boolean + can_post_stories: + type: boolean + can_edit_stories: + type: boolean + can_delete_stories: + type: boolean can_manage_topics: type: boolean multipart/form-data: @@ -7274,10 +8067,6 @@ paths: type: boolean can_manage_chat: type: boolean - can_post_messages: - type: boolean - can_edit_messages: - type: boolean can_delete_messages: type: boolean can_manage_video_chats: @@ -7290,8 +8079,18 @@ paths: type: boolean can_invite_users: type: boolean + can_post_messages: + type: boolean + can_edit_messages: + type: boolean can_pin_messages: type: boolean + can_post_stories: + type: boolean + can_edit_stories: + type: boolean + can_delete_stories: + type: boolean can_manage_topics: type: boolean responses: @@ -8801,7 +9600,7 @@ paths: default: $ref: '#/components/responses/UnknownError' /getChat: - description: 'Use this method to get up to date information about the chat (current name of the user for one-on-one conversations, current username of a user, group or channel, etc.). Returns a Chat object on success.' + description: 'Use this method to get up to date information about the chat. Returns a Chat object on success.' post: requestBody: required: true @@ -10333,6 +11132,87 @@ paths: $ref: '#/components/responses/ServerError' default: $ref: '#/components/responses/UnknownError' + /getUserChatBoosts: + description: 'Use this method to get the list of boosts added to a chat by a user. Requires administrator rights in the chat. Returns a UserChatBoosts object.' + post: + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - chat_id + - user_id + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + user_id: + type: integer + application/x-www-form-urlencoded: + schema: + type: object + required: + - chat_id + - user_id + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + user_id: + type: integer + multipart/form-data: + schema: + type: object + required: + - chat_id + - user_id + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + user_id: + type: integer + responses: + 200: + description: 'Request was successful, the result is returned.' + content: + application/json: + schema: + allOf: + - + $ref: '#/components/schemas/Success' + - + type: object + properties: + result: + $ref: '#/components/schemas/UserChatBoosts' + 400: + $ref: '#/components/responses/BadRequest' + 401: + $ref: '#/components/responses/Unauthorized' + 403: + $ref: '#/components/responses/Forbidden' + 404: + $ref: '#/components/responses/NotFound' + 409: + $ref: '#/components/responses/Conflict' + 429: + $ref: '#/components/responses/TooManyRequests' + 5XX: + $ref: '#/components/responses/ServerError' + default: + $ref: '#/components/responses/UnknownError' /setMyCommands: description: "Use this method to change the list of the bot's commands. See this manual for more details about bot commands. Returns True on success." post: @@ -11131,8 +12011,8 @@ paths: type: array items: $ref: '#/components/schemas/MessageEntity' - disable_web_page_preview: - type: boolean + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' required: @@ -11159,8 +12039,8 @@ paths: type: array items: $ref: '#/components/schemas/MessageEntity' - disable_web_page_preview: - type: boolean + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' required: @@ -11187,8 +12067,8 @@ paths: type: array items: $ref: '#/components/schemas/MessageEntity' - disable_web_page_preview: - type: boolean + link_preview_options: + $ref: '#/components/schemas/LinkPreviewOptions' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' required: @@ -11907,6 +12787,93 @@ paths: $ref: '#/components/responses/ServerError' default: $ref: '#/components/responses/UnknownError' + /deleteMessages: + description: "Use this method to delete multiple messages simultaneously. If some of the specified messages can't be found, they are skipped. Returns True on success." + post: + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + application/x-www-form-urlencoded: + schema: + type: object + required: + - chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + multipart/form-data: + schema: + type: object + required: + - chat_id + - message_ids + properties: + chat_id: + anyOf: + - + type: integer + - + type: string + message_ids: + type: array + items: + type: integer + responses: + 200: + description: 'Request was successful, the result is returned.' + content: + application/json: + schema: + allOf: + - + $ref: '#/components/schemas/Success' + - + type: object + properties: + result: + type: boolean + 400: + $ref: '#/components/responses/BadRequest' + 401: + $ref: '#/components/responses/Unauthorized' + 403: + $ref: '#/components/responses/Forbidden' + 404: + $ref: '#/components/responses/NotFound' + 409: + $ref: '#/components/responses/Conflict' + 429: + $ref: '#/components/responses/TooManyRequests' + 5XX: + $ref: '#/components/responses/ServerError' + default: + $ref: '#/components/responses/UnknownError' /sendSticker: description: 'Use this method to send static .WEBP, animated .TGS, or video .WEBM stickers. On success, the sent Message is returned.' post: @@ -11940,10 +12907,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -11981,10 +12946,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -12022,10 +12985,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: anyOf: - @@ -13335,10 +14296,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' application/x-www-form-urlencoded: @@ -13411,10 +14370,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' multipart/form-data: @@ -13487,10 +14444,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' responses: @@ -13984,10 +14939,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' application/x-www-form-urlencoded: @@ -14007,10 +14960,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' multipart/form-data: @@ -14030,10 +14981,8 @@ paths: type: boolean protect_content: type: boolean - reply_to_message_id: - type: integer - allow_sending_without_reply: - type: boolean + reply_parameters: + $ref: '#/components/schemas/ReplyParameters' reply_markup: $ref: '#/components/schemas/InlineKeyboardMarkup' responses: diff --git a/schemas/botapi_postman.json b/schemas/botapi_postman.json index 7f627a0..2cfd8ff 100644 --- a/schemas/botapi_postman.json +++ b/schemas/botapi_postman.json @@ -3,7 +3,7 @@ "name": "Telegram Bot API", "description": "Auto-generated Postman collection by TGScraper.", "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json", - "version": "6.9.0" + "version": "7.0.0" }, "variable": { "key": "token", @@ -41,7 +41,7 @@ { "key": "allowed_updates", "disabled": true, - "description": "Optional. A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time.", + "description": "Optional. A JSON-serialized list of the update types you want your bot to receive. For example, specify [\"message\", \"edited_channel_post\", \"callback_query\"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time.", "type": "text" } ] @@ -97,7 +97,7 @@ { "key": "allowed_updates", "disabled": true, - "description": "Optional. A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time.", + "description": "Optional. A JSON-serialized list of the update types you want your bot to receive. For example, specify [\"message\", \"edited_channel_post\", \"callback_query\"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.Please note that this parameter doesn't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time.", "type": "text" }, { @@ -295,9 +295,9 @@ "type": "text" }, { - "key": "disable_web_page_preview", + "key": "link_preview_options", "disabled": true, - "description": "Optional. Disables link previews for links in this message", + "description": "Optional. Link preview generation options for the message", "type": "text" }, { @@ -313,15 +313,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -406,7 +400,68 @@ "forwardMessage" ] }, - "description": "Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned." + "description": "Use this method to forward messages of any kind. Service messages and messages with protected content can't be forwarded. On success, the sent Message is returned." + } + }, + { + "name": "forwardMessages", + "request": { + "method": "POST", + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "chat_id", + "disabled": false, + "description": "Required. Unique identifier for the target chat or username of the target channel (in the format @channelusername)", + "type": "text" + }, + { + "key": "message_thread_id", + "disabled": true, + "description": "Optional. Unique identifier for the target message thread (topic) of the forum; for forum supergroups only", + "type": "text" + }, + { + "key": "from_chat_id", + "disabled": false, + "description": "Required. Unique identifier for the chat where the original messages were sent (or channel username in the format @channelusername)", + "type": "text" + }, + { + "key": "message_ids", + "disabled": false, + "description": "Required. Identifiers of 1-100 messages in the chat from_chat_id to forward. The identifiers must be specified in a strictly increasing order.", + "type": "text" + }, + { + "key": "disable_notification", + "disabled": true, + "description": "Optional. Sends the messages silently. Users will receive a notification with no sound.", + "type": "text" + }, + { + "key": "protect_content", + "disabled": true, + "description": "Optional. Protects the contents of the forwarded messages from forwarding and saving", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.telegram.org/bot{{token}}/forwardMessages", + "protocol": "https", + "host": [ + "api", + "telegram", + "org" + ], + "path": [ + "bot{{token}}", + "forwardMessages" + ] + }, + "description": "Use this method to forward multiple messages of any kind. If some of the specified messages can't be found or forwarded, they are skipped. Service messages and messages with protected content can't be forwarded. Album grouping is kept for forwarded messages. On success, an array of MessageId of the sent messages is returned." } }, { @@ -471,15 +526,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -503,7 +552,74 @@ "copyMessage" ] }, - "description": "Use this method to copy messages of any kind. Service messages and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success." + "description": "Use this method to copy messages of any kind. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success." + } + }, + { + "name": "copyMessages", + "request": { + "method": "POST", + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "chat_id", + "disabled": false, + "description": "Required. Unique identifier for the target chat or username of the target channel (in the format @channelusername)", + "type": "text" + }, + { + "key": "message_thread_id", + "disabled": true, + "description": "Optional. Unique identifier for the target message thread (topic) of the forum; for forum supergroups only", + "type": "text" + }, + { + "key": "from_chat_id", + "disabled": false, + "description": "Required. Unique identifier for the chat where the original messages were sent (or channel username in the format @channelusername)", + "type": "text" + }, + { + "key": "message_ids", + "disabled": false, + "description": "Required. Identifiers of 1-100 messages in the chat from_chat_id to copy. The identifiers must be specified in a strictly increasing order.", + "type": "text" + }, + { + "key": "disable_notification", + "disabled": true, + "description": "Optional. Sends the messages silently. Users will receive a notification with no sound.", + "type": "text" + }, + { + "key": "protect_content", + "disabled": true, + "description": "Optional. Protects the contents of the sent messages from forwarding and saving", + "type": "text" + }, + { + "key": "remove_caption", + "disabled": true, + "description": "Optional. Pass True to copy the messages without their captions", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.telegram.org/bot{{token}}/copyMessages", + "protocol": "https", + "host": [ + "api", + "telegram", + "org" + ], + "path": [ + "bot{{token}}", + "copyMessages" + ] + }, + "description": "Use this method to copy messages of any kind. If some of the specified messages can't be found or copied, they are skipped. Service messages, giveaway messages, giveaway winners messages, and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessages, but the copied messages don't have a link to the original message. Album grouping is kept for copied messages. On success, an array of MessageId of the sent messages is returned." } }, { @@ -568,15 +684,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -683,15 +793,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -786,15 +890,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -913,15 +1011,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1034,15 +1126,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1131,15 +1217,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1222,15 +1302,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1295,15 +1369,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the messages are a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" } ] @@ -1392,15 +1460,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1507,15 +1569,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1598,15 +1654,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1739,15 +1789,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1813,15 +1857,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -1891,6 +1929,55 @@ "description": "Use this method when you need to tell the user that something is happening on the bot's side. The status is set for 5 seconds or less (when a message arrives from your bot, Telegram clients clear its typing status). Returns True on success.\nWe only recommend using this method when a response from the bot will take a noticeable amount of time to arrive." } }, + { + "name": "setMessageReaction", + "request": { + "method": "POST", + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "chat_id", + "disabled": false, + "description": "Required. Unique identifier for the target chat or username of the target channel (in the format @channelusername)", + "type": "text" + }, + { + "key": "message_id", + "disabled": false, + "description": "Required. Identifier of the target message", + "type": "text" + }, + { + "key": "reaction", + "disabled": true, + "description": "Optional. New list of reaction types to set on the message. Currently, as non-premium users, bots can set up to one reaction per message. A custom emoji reaction can be used if it is either already present on the message or explicitly allowed by chat administrators.", + "type": "text" + }, + { + "key": "is_big", + "disabled": true, + "description": "Optional. Pass True to set the reaction with a big animation", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.telegram.org/bot{{token}}/setMessageReaction", + "protocol": "https", + "host": [ + "api", + "telegram", + "org" + ], + "path": [ + "bot{{token}}", + "setMessageReaction" + ] + }, + "description": "Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. In albums, bots must react to the first message. Returns True on success." + } + }, { "name": "getUserProfilePhotos", "request": { @@ -2141,19 +2228,7 @@ { "key": "can_manage_chat", "disabled": true, - "description": "Optional. Pass True if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege", - "type": "text" - }, - { - "key": "can_post_messages", - "disabled": true, - "description": "Optional. Pass True if the administrator can create channel posts, channels only", - "type": "text" - }, - { - "key": "can_edit_messages", - "disabled": true, - "description": "Optional. Pass True if the administrator can edit messages of other users and can pin messages, channels only", + "description": "Optional. Pass True if the administrator can access the chat event log, boost list in channels, see channel members, report spam messages, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege", "type": "text" }, { @@ -2171,7 +2246,7 @@ { "key": "can_restrict_members", "disabled": true, - "description": "Optional. Pass True if the administrator can restrict, ban or unban chat members", + "description": "Optional. Pass True if the administrator can restrict, ban or unban chat members, or access supergroup statistics", "type": "text" }, { @@ -2192,12 +2267,42 @@ "description": "Optional. Pass True if the administrator can invite new users to the chat", "type": "text" }, + { + "key": "can_post_messages", + "disabled": true, + "description": "Optional. Pass True if the administrator can post messages in the channel, or access channel statistics; channels only", + "type": "text" + }, + { + "key": "can_edit_messages", + "disabled": true, + "description": "Optional. Pass True if the administrator can edit messages of other users and can pin messages; channels only", + "type": "text" + }, { "key": "can_pin_messages", "disabled": true, "description": "Optional. Pass True if the administrator can pin messages, supergroups only", "type": "text" }, + { + "key": "can_post_stories", + "disabled": true, + "description": "Optional. Pass True if the administrator can post stories in the channel; channels only", + "type": "text" + }, + { + "key": "can_edit_stories", + "disabled": true, + "description": "Optional. Pass True if the administrator can edit stories posted by other users; channels only", + "type": "text" + }, + { + "key": "can_delete_stories", + "disabled": true, + "description": "Optional. Pass True if the administrator can delete stories posted by other users; channels only", + "type": "text" + }, { "key": "can_manage_topics", "disabled": true, @@ -2952,7 +3057,7 @@ "getChat" ] }, - "description": "Use this method to get up to date information about the chat (current name of the user for one-on-one conversations, current username of a user, group or channel, etc.). Returns a Chat object on success." + "description": "Use this method to get up to date information about the chat. Returns a Chat object on success." } }, { @@ -3639,6 +3744,43 @@ "description": "Use this method to send answers to callback queries sent from inline keyboards. The answer will be displayed to the user as a notification at the top of the chat screen or as an alert. On success, True is returned." } }, + { + "name": "getUserChatBoosts", + "request": { + "method": "POST", + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "chat_id", + "disabled": false, + "description": "Required. Unique identifier for the chat or username of the channel (in the format @channelusername)", + "type": "text" + }, + { + "key": "user_id", + "disabled": false, + "description": "Required. Unique identifier of the target user", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.telegram.org/bot{{token}}/getUserChatBoosts", + "protocol": "https", + "host": [ + "api", + "telegram", + "org" + ], + "path": [ + "bot{{token}}", + "getUserChatBoosts" + ] + }, + "description": "Use this method to get the list of boosts added to a chat by a user. Requires administrator rights in the chat. Returns a UserChatBoosts object." + } + }, { "name": "setMyCommands", "request": { @@ -4144,9 +4286,9 @@ "type": "text" }, { - "key": "disable_web_page_preview", + "key": "link_preview_options", "disabled": true, - "description": "Optional. Disables link previews for links in this message", + "description": "Optional. Link preview generation options for the message", "type": "text" }, { @@ -4552,6 +4694,43 @@ "description": "Use this method to delete a message, including service messages, with the following limitations:- A message can only be deleted if it was sent less than 48 hours ago.- Service messages about a supergroup, channel, or forum topic creation can't be deleted.- A dice message in a private chat can only be deleted if it was sent more than 24 hours ago.- Bots can delete outgoing messages in private chats, groups, and supergroups.- Bots can delete incoming messages in private chats.- Bots granted can_post_messages permissions can delete outgoing messages in channels.- If the bot is an administrator of a group, it can delete any message there.- If the bot has can_delete_messages permission in a supergroup or a channel, it can delete any message there.Returns True on success." } }, + { + "name": "deleteMessages", + "request": { + "method": "POST", + "body": { + "mode": "formdata", + "formdata": [ + { + "key": "chat_id", + "disabled": false, + "description": "Required. Unique identifier for the target chat or username of the target channel (in the format @channelusername)", + "type": "text" + }, + { + "key": "message_ids", + "disabled": false, + "description": "Required. Identifiers of 1-100 messages to delete. See deleteMessage for limitations on which messages can be deleted", + "type": "text" + } + ] + }, + "url": { + "raw": "https://api.telegram.org/bot{{token}}/deleteMessages", + "protocol": "https", + "host": [ + "api", + "telegram", + "org" + ], + "path": [ + "bot{{token}}", + "deleteMessages" + ] + }, + "description": "Use this method to delete multiple messages simultaneously. If some of the specified messages can't be found, they are skipped. Returns True on success." + } + }, { "name": "sendSticker", "request": { @@ -4596,15 +4775,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -5430,15 +5603,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, { @@ -5777,15 +5944,9 @@ "type": "text" }, { - "key": "reply_to_message_id", + "key": "reply_parameters", "disabled": true, - "description": "Optional. If the message is a reply, ID of the original message", - "type": "text" - }, - { - "key": "allow_sending_without_reply", - "disabled": true, - "description": "Optional. Pass True if the message should be sent even if the specified replied-to message is not found", + "description": "Optional. Description of the message to reply to", "type": "text" }, {