`_. If empty, one 'Play game_title' button will be shown. If not empty, the first button must launch the game. Not supported for messages sent on behalf of a business account.\n",
"name": "reply_markup"
}
],
diff --git a/.butcher/types/Birthdate/entity.json b/.butcher/types/Birthdate/entity.json
new file mode 100644
index 00000000..b70055c6
--- /dev/null
+++ b/.butcher/types/Birthdate/entity.json
@@ -0,0 +1,41 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "birthdate",
+ "name": "Birthdate",
+ "description": "",
+ "html_description": "",
+ "rst_description": "",
+ "annotations": [
+ {
+ "type": "Integer",
+ "description": "Day of the user's birth; 1-31",
+ "html_description": "| Day of the user's birth; 1-31 | ",
+ "rst_description": "Day of the user's birth; 1-31\n",
+ "name": "day",
+ "required": true
+ },
+ {
+ "type": "Integer",
+ "description": "Month of the user's birth; 1-12",
+ "html_description": "Month of the user's birth; 1-12 | ",
+ "rst_description": "Month of the user's birth; 1-12\n",
+ "name": "month",
+ "required": true
+ },
+ {
+ "type": "Integer",
+ "description": "Year of the user's birth",
+ "html_description": "Optional. Year of the user's birth | ",
+ "rst_description": "*Optional*. Year of the user's birth\n",
+ "name": "year",
+ "required": false
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/BusinessConnection/entity.json b/.butcher/types/BusinessConnection/entity.json
new file mode 100644
index 00000000..09b9a0ef
--- /dev/null
+++ b/.butcher/types/BusinessConnection/entity.json
@@ -0,0 +1,65 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "businessconnection",
+ "name": "BusinessConnection",
+ "description": "Describes the connection of the bot with a business account.",
+ "html_description": "Describes the connection of the bot with a business account.
",
+ "rst_description": "Describes the connection of the bot with a business account.",
+ "annotations": [
+ {
+ "type": "String",
+ "description": "Unique identifier of the business connection",
+ "html_description": "Unique identifier of the business connection | ",
+ "rst_description": "Unique identifier of the business connection\n",
+ "name": "id",
+ "required": true
+ },
+ {
+ "type": "User",
+ "description": "Business account user that created the business connection",
+ "html_description": "Business account user that created the business connection | ",
+ "rst_description": "Business account user that created the business connection\n",
+ "name": "user",
+ "required": true
+ },
+ {
+ "type": "Integer",
+ "description": "Identifier of a private chat with the user who created the business connection. 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.",
+ "html_description": "Identifier of a private chat with the user who created the business connection. 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. | ",
+ "rst_description": "Identifier of a private chat with the user who created the business connection. 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.\n",
+ "name": "user_chat_id",
+ "required": true
+ },
+ {
+ "type": "Integer",
+ "description": "Date the connection was established in Unix time",
+ "html_description": "Date the connection was established in Unix time | ",
+ "rst_description": "Date the connection was established in Unix time\n",
+ "name": "date",
+ "required": true
+ },
+ {
+ "type": "Boolean",
+ "description": "True, if the bot can act on behalf of the business account in chats that were active in the last 24 hours",
+ "html_description": "True, if the bot can act on behalf of the business account in chats that were active in the last 24 hours | ",
+ "rst_description": "True, if the bot can act on behalf of the business account in chats that were active in the last 24 hours\n",
+ "name": "can_reply",
+ "required": true
+ },
+ {
+ "type": "Boolean",
+ "description": "True, if the connection is active",
+ "html_description": "True, if the connection is active | ",
+ "rst_description": "True, if the connection is active\n",
+ "name": "is_enabled",
+ "required": true
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/BusinessConnection/replace.yml b/.butcher/types/BusinessConnection/replace.yml
new file mode 100644
index 00000000..80c48d76
--- /dev/null
+++ b/.butcher/types/BusinessConnection/replace.yml
@@ -0,0 +1,5 @@
+annotations:
+ date:
+ parsed_type:
+ type: std
+ name: DateTime
diff --git a/.butcher/types/BusinessIntro/entity.json b/.butcher/types/BusinessIntro/entity.json
new file mode 100644
index 00000000..4208d21f
--- /dev/null
+++ b/.butcher/types/BusinessIntro/entity.json
@@ -0,0 +1,41 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "businessintro",
+ "name": "BusinessIntro",
+ "description": "",
+ "html_description": "",
+ "rst_description": "",
+ "annotations": [
+ {
+ "type": "String",
+ "description": "Title text of the business intro",
+ "html_description": "Optional. Title text of the business intro | ",
+ "rst_description": "*Optional*. Title text of the business intro\n",
+ "name": "title",
+ "required": false
+ },
+ {
+ "type": "String",
+ "description": "Message text of the business intro",
+ "html_description": "Optional. Message text of the business intro | ",
+ "rst_description": "*Optional*. Message text of the business intro\n",
+ "name": "message",
+ "required": false
+ },
+ {
+ "type": "Sticker",
+ "description": "Sticker of the business intro",
+ "html_description": "Optional. Sticker of the business intro | ",
+ "rst_description": "*Optional*. Sticker of the business intro\n",
+ "name": "sticker",
+ "required": false
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/BusinessLocation/entity.json b/.butcher/types/BusinessLocation/entity.json
new file mode 100644
index 00000000..0d3ddac3
--- /dev/null
+++ b/.butcher/types/BusinessLocation/entity.json
@@ -0,0 +1,33 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "businesslocation",
+ "name": "BusinessLocation",
+ "description": "",
+ "html_description": "",
+ "rst_description": "",
+ "annotations": [
+ {
+ "type": "String",
+ "description": "Address of the business",
+ "html_description": "Address of the business | ",
+ "rst_description": "Address of the business\n",
+ "name": "address",
+ "required": true
+ },
+ {
+ "type": "Location",
+ "description": "Location of the business",
+ "html_description": "Optional. Location of the business | ",
+ "rst_description": "*Optional*. Location of the business\n",
+ "name": "location",
+ "required": false
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/BusinessMessagesDeleted/entity.json b/.butcher/types/BusinessMessagesDeleted/entity.json
new file mode 100644
index 00000000..3eb82a8d
--- /dev/null
+++ b/.butcher/types/BusinessMessagesDeleted/entity.json
@@ -0,0 +1,41 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "businessmessagesdeleted",
+ "name": "BusinessMessagesDeleted",
+ "description": "This object is received when messages are deleted from a connected business account.",
+ "html_description": "This object is received when messages are deleted from a connected business account.
",
+ "rst_description": "This object is received when messages are deleted from a connected business account.",
+ "annotations": [
+ {
+ "type": "String",
+ "description": "Unique identifier of the business connection",
+ "html_description": "Unique identifier of the business connection | ",
+ "rst_description": "Unique identifier of the business connection\n",
+ "name": "business_connection_id",
+ "required": true
+ },
+ {
+ "type": "Chat",
+ "description": "Information about a chat in the business account. The bot may not have access to the chat or the corresponding user.",
+ "html_description": "Information about a chat in the business account. The bot may not have access to the chat or the corresponding user. | ",
+ "rst_description": "Information about a chat in the business account. The bot may not have access to the chat or the corresponding user.\n",
+ "name": "chat",
+ "required": true
+ },
+ {
+ "type": "Array of Integer",
+ "description": "A JSON-serialized list of identifiers of deleted messages in the chat of the business account",
+ "html_description": "A JSON-serialized list of identifiers of deleted messages in the chat of the business account | ",
+ "rst_description": "A JSON-serialized list of identifiers of deleted messages in the chat of the business account\n",
+ "name": "message_ids",
+ "required": true
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/BusinessOpeningHours/entity.json b/.butcher/types/BusinessOpeningHours/entity.json
new file mode 100644
index 00000000..7632bbe0
--- /dev/null
+++ b/.butcher/types/BusinessOpeningHours/entity.json
@@ -0,0 +1,33 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "businessopeninghours",
+ "name": "BusinessOpeningHours",
+ "description": "",
+ "html_description": "",
+ "rst_description": "",
+ "annotations": [
+ {
+ "type": "String",
+ "description": "Unique name of the time zone for which the opening hours are defined",
+ "html_description": "Unique name of the time zone for which the opening hours are defined | ",
+ "rst_description": "Unique name of the time zone for which the opening hours are defined\n",
+ "name": "time_zone_name",
+ "required": true
+ },
+ {
+ "type": "Array of BusinessOpeningHoursInterval",
+ "description": "List of time intervals describing business opening hours",
+ "html_description": "List of time intervals describing business opening hours | ",
+ "rst_description": "List of time intervals describing business opening hours\n",
+ "name": "opening_hours",
+ "required": true
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/BusinessOpeningHoursInterval/entity.json b/.butcher/types/BusinessOpeningHoursInterval/entity.json
new file mode 100644
index 00000000..7c5dbf86
--- /dev/null
+++ b/.butcher/types/BusinessOpeningHoursInterval/entity.json
@@ -0,0 +1,33 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "businessopeninghoursinterval",
+ "name": "BusinessOpeningHoursInterval",
+ "description": "",
+ "html_description": "",
+ "rst_description": "",
+ "annotations": [
+ {
+ "type": "Integer",
+ "description": "The minute's sequence number in a week, starting on Monday, marking the start of the time interval during which the business is open; 0 - 7 * 24 * 60",
+ "html_description": "The minute's sequence number in a week, starting on Monday, marking the start of the time interval during which the business is open; 0 - 7 * 24 * 60 | ",
+ "rst_description": "The minute's sequence number in a week, starting on Monday, marking the start of the time interval during which the business is open; 0 - 7 * 24 * 60\n",
+ "name": "opening_minute",
+ "required": true
+ },
+ {
+ "type": "Integer",
+ "description": "The minute's sequence number in a week, starting on Monday, marking the end of the time interval during which the business is open; 0 - 8 * 24 * 60",
+ "html_description": "The minute's sequence number in a week, starting on Monday, marking the end of the time interval during which the business is open; 0 - 8 * 24 * 60 | ",
+ "rst_description": "The minute's sequence number in a week, starting on Monday, marking the end of the time interval during which the business is open; 0 - 8 * 24 * 60\n",
+ "name": "closing_minute",
+ "required": true
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/Chat/entity.json b/.butcher/types/Chat/entity.json
index 6bd7efd4..3a273c91 100644
--- a/.butcher/types/Chat/entity.json
+++ b/.butcher/types/Chat/entity.json
@@ -83,6 +83,46 @@
"name": "active_usernames",
"required": false
},
+ {
+ "type": "Birthdate",
+ "description": "For private chats, the date of birth of the user. Returned only in getChat.",
+ "html_description": "Optional. For private chats, the date of birth of the user. Returned only in getChat. | ",
+ "rst_description": "*Optional*. For private chats, the date of birth of the user. Returned only in :class:`aiogram.methods.get_chat.GetChat`.\n",
+ "name": "birthdate",
+ "required": false
+ },
+ {
+ "type": "BusinessIntro",
+ "description": "For private chats with business accounts, the intro of the business. Returned only in getChat.",
+ "html_description": "Optional. For private chats with business accounts, the intro of the business. Returned only in getChat. | ",
+ "rst_description": "*Optional*. For private chats with business accounts, the intro of the business. Returned only in :class:`aiogram.methods.get_chat.GetChat`.\n",
+ "name": "business_intro",
+ "required": false
+ },
+ {
+ "type": "BusinessLocation",
+ "description": "For private chats with business accounts, the location of the business. Returned only in getChat.",
+ "html_description": "Optional. For private chats with business accounts, the location of the business. Returned only in getChat. | ",
+ "rst_description": "*Optional*. For private chats with business accounts, the location of the business. Returned only in :class:`aiogram.methods.get_chat.GetChat`.\n",
+ "name": "business_location",
+ "required": false
+ },
+ {
+ "type": "BusinessOpeningHours",
+ "description": "For private chats with business accounts, the opening hours of the business. Returned only in getChat.",
+ "html_description": "Optional. For private chats with business accounts, the opening hours of the business. Returned only in getChat. | ",
+ "rst_description": "*Optional*. For private chats with business accounts, the opening hours of the business. Returned only in :class:`aiogram.methods.get_chat.GetChat`.\n",
+ "name": "business_opening_hours",
+ "required": false
+ },
+ {
+ "type": "Chat",
+ "description": "For private chats, the personal channel of the user. Returned only in getChat.",
+ "html_description": "Optional. For private chats, the personal channel of the user. Returned only in getChat. | ",
+ "rst_description": "*Optional*. For private chats, the personal channel of the user. Returned only in :class:`aiogram.methods.get_chat.GetChat`.\n",
+ "name": "personal_chat",
+ "required": false
+ },
{
"type": "Array of ReactionType",
"description": "List of available reactions allowed in the chat. If omitted, then all emoji reactions are allowed. Returned only in getChat.",
diff --git a/.butcher/types/ChatAdministratorRights/entity.json b/.butcher/types/ChatAdministratorRights/entity.json
index d45cda66..b242ed93 100644
--- a/.butcher/types/ChatAdministratorRights/entity.json
+++ b/.butcher/types/ChatAdministratorRights/entity.json
@@ -101,33 +101,33 @@
},
{
"type": "Boolean",
- "description": "True, if the administrator can post messages in the channel, or access channel statistics; channels only",
- "html_description": "Optional. True, if the administrator can post messages in the channel, or access channel statistics; channels only | ",
- "rst_description": "*Optional*. :code:`True`, if the administrator can post messages in the channel, or access channel statistics; channels only\n",
+ "description": "True, if the administrator can post messages in the channel, or access channel statistics; for channels only",
+ "html_description": "Optional. True, if the administrator can post messages in the channel, or access channel statistics; for channels only | ",
+ "rst_description": "*Optional*. :code:`True`, if the administrator can post messages in the channel, or access channel statistics; for channels only\n",
"name": "can_post_messages",
"required": false
},
{
"type": "Boolean",
- "description": "True, if the administrator can edit messages of other users and can pin messages; channels only",
- "html_description": "Optional. True, if the administrator can edit messages of other users and can pin messages; channels only | ",
- "rst_description": "*Optional*. :code:`True`, if the administrator can edit messages of other users and can pin messages; channels only\n",
+ "description": "True, if the administrator can edit messages of other users and can pin messages; for channels only",
+ "html_description": "Optional. True, if the administrator can edit messages of other users and can pin messages; for channels only | ",
+ "rst_description": "*Optional*. :code:`True`, if the administrator can edit messages of other users and can pin messages; for channels only\n",
"name": "can_edit_messages",
"required": false
},
{
"type": "Boolean",
- "description": "True, if the user is allowed to pin messages; groups and supergroups only",
- "html_description": "Optional. True, if the user is allowed to pin messages; groups and supergroups only | ",
- "rst_description": "*Optional*. :code:`True`, if the user is allowed to pin messages; groups and supergroups only\n",
+ "description": "True, if the user is allowed to pin messages; for groups and supergroups only",
+ "html_description": "Optional. True, if the user is allowed to pin messages; for groups and supergroups only | ",
+ "rst_description": "*Optional*. :code:`True`, if the user is allowed to pin messages; for groups and supergroups only\n",
"name": "can_pin_messages",
"required": false
},
{
"type": "Boolean",
- "description": "True, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only",
- "html_description": "Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only | ",
- "rst_description": "*Optional*. :code:`True`, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only\n",
+ "description": "True, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only",
+ "html_description": "Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only | ",
+ "rst_description": "*Optional*. :code:`True`, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only\n",
"name": "can_manage_topics",
"required": false
}
diff --git a/.butcher/types/ChatMemberAdministrator/entity.json b/.butcher/types/ChatMemberAdministrator/entity.json
index b0e4a00c..a52feb11 100644
--- a/.butcher/types/ChatMemberAdministrator/entity.json
+++ b/.butcher/types/ChatMemberAdministrator/entity.json
@@ -125,33 +125,33 @@
},
{
"type": "Boolean",
- "description": "True, if the administrator can post messages in the channel, or access channel statistics; channels only",
- "html_description": "Optional. True, if the administrator can post messages in the channel, or access channel statistics; channels only | ",
- "rst_description": "*Optional*. :code:`True`, if the administrator can post messages in the channel, or access channel statistics; channels only\n",
+ "description": "True, if the administrator can post messages in the channel, or access channel statistics; for channels only",
+ "html_description": "Optional. True, if the administrator can post messages in the channel, or access channel statistics; for channels only | ",
+ "rst_description": "*Optional*. :code:`True`, if the administrator can post messages in the channel, or access channel statistics; for channels only\n",
"name": "can_post_messages",
"required": false
},
{
"type": "Boolean",
- "description": "True, if the administrator can edit messages of other users and can pin messages; channels only",
- "html_description": "Optional. True, if the administrator can edit messages of other users and can pin messages; channels only | ",
- "rst_description": "*Optional*. :code:`True`, if the administrator can edit messages of other users and can pin messages; channels only\n",
+ "description": "True, if the administrator can edit messages of other users and can pin messages; for channels only",
+ "html_description": "Optional. True, if the administrator can edit messages of other users and can pin messages; for channels only | ",
+ "rst_description": "*Optional*. :code:`True`, if the administrator can edit messages of other users and can pin messages; for channels only\n",
"name": "can_edit_messages",
"required": false
},
{
"type": "Boolean",
- "description": "True, if the user is allowed to pin messages; groups and supergroups only",
- "html_description": "Optional. True, if the user is allowed to pin messages; groups and supergroups only | ",
- "rst_description": "*Optional*. :code:`True`, if the user is allowed to pin messages; groups and supergroups only\n",
+ "description": "True, if the user is allowed to pin messages; for groups and supergroups only",
+ "html_description": "Optional. True, if the user is allowed to pin messages; for groups and supergroups only | ",
+ "rst_description": "*Optional*. :code:`True`, if the user is allowed to pin messages; for groups and supergroups only\n",
"name": "can_pin_messages",
"required": false
},
{
"type": "Boolean",
- "description": "True, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only",
- "html_description": "Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only | ",
- "rst_description": "*Optional*. :code:`True`, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only\n",
+ "description": "True, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only",
+ "html_description": "Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only | ",
+ "rst_description": "*Optional*. :code:`True`, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only\n",
"name": "can_manage_topics",
"required": false
},
diff --git a/.butcher/types/ChatShared/entity.json b/.butcher/types/ChatShared/entity.json
index ceaeb604..eb8b6c17 100644
--- a/.butcher/types/ChatShared/entity.json
+++ b/.butcher/types/ChatShared/entity.json
@@ -7,9 +7,9 @@
"object": {
"anchor": "chatshared",
"name": "ChatShared",
- "description": "This object contains information about the chat whose identifier was shared with the bot using a KeyboardButtonRequestChat button.",
- "html_description": "This object contains information about the chat whose identifier was shared with the bot using a KeyboardButtonRequestChat button.
",
- "rst_description": "This object contains information about the chat whose identifier was shared with the bot using a :class:`aiogram.types.keyboard_button_request_chat.KeyboardButtonRequestChat` button.",
+ "description": "This object contains information about a chat that was shared with the bot using a KeyboardButtonRequestChat button.",
+ "html_description": "This object contains information about a chat that was shared with the bot using a KeyboardButtonRequestChat button.
",
+ "rst_description": "This object contains information about a chat that was shared with the bot using a :class:`aiogram.types.keyboard_button_request_chat.KeyboardButtonRequestChat` button.",
"annotations": [
{
"type": "Integer",
@@ -26,6 +26,30 @@
"rst_description": "Identifier of the shared chat. 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 chat and could be unable to use this identifier, unless the chat is already known to the bot by some other means.\n",
"name": "chat_id",
"required": true
+ },
+ {
+ "type": "String",
+ "description": "Title of the chat, if the title was requested by the bot.",
+ "html_description": "Optional. Title of the chat, if the title was requested by the bot. | ",
+ "rst_description": "*Optional*. Title of the chat, if the title was requested by the bot.\n",
+ "name": "title",
+ "required": false
+ },
+ {
+ "type": "String",
+ "description": "Username of the chat, if the username was requested by the bot and available.",
+ "html_description": "Optional. Username of the chat, if the username was requested by the bot and available. | ",
+ "rst_description": "*Optional*. Username of the chat, if the username was requested by the bot and available.\n",
+ "name": "username",
+ "required": false
+ },
+ {
+ "type": "Array of PhotoSize",
+ "description": "Available sizes of the chat photo, if the photo was requested by the bot",
+ "html_description": "Optional. Available sizes of the chat photo, if the photo was requested by the bot | ",
+ "rst_description": "*Optional*. Available sizes of the chat photo, if the photo was requested by the bot\n",
+ "name": "photo",
+ "required": false
}
],
"category": "types"
diff --git a/.butcher/types/EncryptedPassportElement/entity.json b/.butcher/types/EncryptedPassportElement/entity.json
index 33fd2827..2d969e3e 100644
--- a/.butcher/types/EncryptedPassportElement/entity.json
+++ b/.butcher/types/EncryptedPassportElement/entity.json
@@ -21,65 +21,65 @@
},
{
"type": "String",
- "description": "Base64-encoded encrypted Telegram Passport element data provided by the user, available for 'personal_details', 'passport', 'driver_license', 'identity_card', 'internal_passport' and 'address' types. Can be decrypted and verified using the accompanying EncryptedCredentials.",
- "html_description": "Optional. Base64-encoded encrypted Telegram Passport element data provided by the user, available for “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport” and “address” types. Can be decrypted and verified using the accompanying EncryptedCredentials. | ",
- "rst_description": "*Optional*. Base64-encoded encrypted Telegram Passport element data provided by the user, available for 'personal_details', 'passport', 'driver_license', 'identity_card', 'internal_passport' and 'address' types. Can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
+ "description": "Base64-encoded encrypted Telegram Passport element data provided by the user; available only for 'personal_details', 'passport', 'driver_license', 'identity_card', 'internal_passport' and 'address' types. Can be decrypted and verified using the accompanying EncryptedCredentials.",
+ "html_description": "Optional. Base64-encoded encrypted Telegram Passport element data provided by the user; available only for “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport” and “address” types. Can be decrypted and verified using the accompanying EncryptedCredentials. | ",
+ "rst_description": "*Optional*. Base64-encoded encrypted Telegram Passport element data provided by the user; available only for 'personal_details', 'passport', 'driver_license', 'identity_card', 'internal_passport' and 'address' types. Can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
"name": "data",
"required": false
},
{
"type": "String",
- "description": "User's verified phone number, available only for 'phone_number' type",
- "html_description": "Optional. User's verified phone number, available only for “phone_number” type | ",
- "rst_description": "*Optional*. User's verified phone number, available only for 'phone_number' type\n",
+ "description": "User's verified phone number; available only for 'phone_number' type",
+ "html_description": "Optional. User's verified phone number; available only for “phone_number” type | ",
+ "rst_description": "*Optional*. User's verified phone number; available only for 'phone_number' type\n",
"name": "phone_number",
"required": false
},
{
"type": "String",
- "description": "User's verified email address, available only for 'email' type",
- "html_description": "Optional. User's verified email address, available only for “email” type | ",
- "rst_description": "*Optional*. User's verified email address, available only for 'email' type\n",
+ "description": "User's verified email address; available only for 'email' type",
+ "html_description": "Optional. User's verified email address; available only for “email” type | ",
+ "rst_description": "*Optional*. User's verified email address; available only for 'email' type\n",
"name": "email",
"required": false
},
{
"type": "Array of PassportFile",
- "description": "Array of encrypted files with documents provided by the user, available for 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying EncryptedCredentials.",
- "html_description": "Optional. Array of encrypted files with documents provided by the user, available for “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. | ",
- "rst_description": "*Optional*. Array of encrypted files with documents provided by the user, available for 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
+ "description": "Array of encrypted files with documents provided by the user; available only for 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying EncryptedCredentials.",
+ "html_description": "Optional. Array of encrypted files with documents provided by the user; available only for “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. | ",
+ "rst_description": "*Optional*. Array of encrypted files with documents provided by the user; available only for 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
"name": "files",
"required": false
},
{
"type": "PassportFile",
- "description": "Encrypted file with the front side of the document, provided by the user. Available for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying EncryptedCredentials.",
- "html_description": "Optional. Encrypted file with the front side of the document, provided by the user. Available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. | ",
- "rst_description": "*Optional*. Encrypted file with the front side of the document, provided by the user. Available for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
+ "description": "Encrypted file with the front side of the document, provided by the user; available only for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying EncryptedCredentials.",
+ "html_description": "Optional. Encrypted file with the front side of the document, provided by the user; available only for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. | ",
+ "rst_description": "*Optional*. Encrypted file with the front side of the document, provided by the user; available only for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
"name": "front_side",
"required": false
},
{
"type": "PassportFile",
- "description": "Encrypted file with the reverse side of the document, provided by the user. Available for 'driver_license' and 'identity_card'. The file can be decrypted and verified using the accompanying EncryptedCredentials.",
- "html_description": "Optional. Encrypted file with the reverse side of the document, provided by the user. Available for “driver_license” and “identity_card”. The file can be decrypted and verified using the accompanying EncryptedCredentials. | ",
- "rst_description": "*Optional*. Encrypted file with the reverse side of the document, provided by the user. Available for 'driver_license' and 'identity_card'. The file can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
+ "description": "Encrypted file with the reverse side of the document, provided by the user; available only for 'driver_license' and 'identity_card'. The file can be decrypted and verified using the accompanying EncryptedCredentials.",
+ "html_description": "Optional. Encrypted file with the reverse side of the document, provided by the user; available only for “driver_license” and “identity_card”. The file can be decrypted and verified using the accompanying EncryptedCredentials. | ",
+ "rst_description": "*Optional*. Encrypted file with the reverse side of the document, provided by the user; available only for 'driver_license' and 'identity_card'. The file can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
"name": "reverse_side",
"required": false
},
{
"type": "PassportFile",
- "description": "Encrypted file with the selfie of the user holding a document, provided by the user; available for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying EncryptedCredentials.",
- "html_description": "Optional. Encrypted file with the selfie of the user holding a document, provided by the user; available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. | ",
- "rst_description": "*Optional*. Encrypted file with the selfie of the user holding a document, provided by the user; available for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
+ "description": "Encrypted file with the selfie of the user holding a document, provided by the user; available if requested for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying EncryptedCredentials.",
+ "html_description": "Optional. Encrypted file with the selfie of the user holding a document, provided by the user; available if requested for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. | ",
+ "rst_description": "*Optional*. Encrypted file with the selfie of the user holding a document, provided by the user; available if requested for 'passport', 'driver_license', 'identity_card' and 'internal_passport'. The file can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
"name": "selfie",
"required": false
},
{
"type": "Array of PassportFile",
- "description": "Array of encrypted files with translated versions of documents provided by the user. Available if requested for 'passport', 'driver_license', 'identity_card', 'internal_passport', 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying EncryptedCredentials.",
- "html_description": "Optional. Array of encrypted files with translated versions of documents provided by the user. Available if requested for “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. | ",
- "rst_description": "*Optional*. Array of encrypted files with translated versions of documents provided by the user. Available if requested for 'passport', 'driver_license', 'identity_card', 'internal_passport', 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
+ "description": "Array of encrypted files with translated versions of documents provided by the user; available if requested for 'passport', 'driver_license', 'identity_card', 'internal_passport', 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying EncryptedCredentials.",
+ "html_description": "Optional. Array of encrypted files with translated versions of documents provided by the user; available if requested for “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. | ",
+ "rst_description": "*Optional*. Array of encrypted files with translated versions of documents provided by the user; available if requested for 'passport', 'driver_license', 'identity_card', 'internal_passport', 'utility_bill', 'bank_statement', 'rental_agreement', 'passport_registration' and 'temporary_registration' types. Files can be decrypted and verified using the accompanying :class:`aiogram.types.encrypted_credentials.EncryptedCredentials`.\n",
"name": "translation",
"required": false
},
diff --git a/.butcher/types/InputSticker/entity.json b/.butcher/types/InputSticker/entity.json
index 9968d594..2df660ae 100644
--- a/.butcher/types/InputSticker/entity.json
+++ b/.butcher/types/InputSticker/entity.json
@@ -19,6 +19,14 @@
"name": "sticker",
"required": true
},
+ {
+ "type": "String",
+ "description": "Format of the added sticker, must be one of 'static' for a .WEBP or .PNG image, 'animated' for a .TGS animation, 'video' for a WEBM video",
+ "html_description": "Format of the added sticker, must be one of “static” for a .WEBP or .PNG image, “animated” for a .TGS animation, “video” for a WEBM video | ",
+ "rst_description": "Format of the added sticker, must be one of 'static' for a **.WEBP** or **.PNG** image, 'animated' for a **.TGS** animation, 'video' for a **WEBM** video\n",
+ "name": "format",
+ "required": true
+ },
{
"type": "Array of String",
"description": "List of 1-20 emoji associated with the sticker",
diff --git a/.butcher/types/KeyboardButtonRequestChat/entity.json b/.butcher/types/KeyboardButtonRequestChat/entity.json
index a8674be8..255df173 100644
--- a/.butcher/types/KeyboardButtonRequestChat/entity.json
+++ b/.butcher/types/KeyboardButtonRequestChat/entity.json
@@ -7,9 +7,9 @@
"object": {
"anchor": "keyboardbuttonrequestchat",
"name": "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.",
- "html_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 »
",
- "rst_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 » `_",
+ "description": "This object defines the criteria used to request a suitable chat. Information about the selected chat will be shared with the bot when the corresponding button is pressed. The bot will be granted requested rights in the сhat if appropriate",
+ "html_description": "This object defines the criteria used to request a suitable chat. Information about the selected chat will be shared with the bot when the corresponding button is pressed. The bot will be granted requested rights in the сhat if appropriate More about requesting chats »
",
+ "rst_description": "This object defines the criteria used to request a suitable chat. Information about the selected chat will be shared with the bot when the corresponding button is pressed. The bot will be granted requested rights in the сhat if appropriate `More about requesting chats » `_",
"annotations": [
{
"type": "Integer",
@@ -74,6 +74,30 @@
"rst_description": "*Optional*. Pass :code:`True` to request a chat with the bot as a member. Otherwise, no additional restrictions are applied.\n",
"name": "bot_is_member",
"required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "Pass True to request the chat's title",
+ "html_description": "Optional. Pass True to request the chat's title | ",
+ "rst_description": "*Optional*. Pass :code:`True` to request the chat's title\n",
+ "name": "request_title",
+ "required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "Pass True to request the chat's username",
+ "html_description": "Optional. Pass True to request the chat's username | ",
+ "rst_description": "*Optional*. Pass :code:`True` to request the chat's username\n",
+ "name": "request_username",
+ "required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "Pass True to request the chat's photo",
+ "html_description": "Optional. Pass True to request the chat's photo | ",
+ "rst_description": "*Optional*. Pass :code:`True` to request the chat's photo\n",
+ "name": "request_photo",
+ "required": false
}
],
"category": "types"
diff --git a/.butcher/types/KeyboardButtonRequestUsers/entity.json b/.butcher/types/KeyboardButtonRequestUsers/entity.json
index d49552ed..ed7a2141 100644
--- a/.butcher/types/KeyboardButtonRequestUsers/entity.json
+++ b/.butcher/types/KeyboardButtonRequestUsers/entity.json
@@ -7,9 +7,9 @@
"object": {
"anchor": "keyboardbuttonrequestusers",
"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.",
- "html_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 »
",
- "rst_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 » `_",
+ "description": "This object defines the criteria used to request suitable users. Information about the selected users will be shared with the bot when the corresponding button is pressed.",
+ "html_description": "This object defines the criteria used to request suitable users. Information about the selected users will be shared with the bot when the corresponding button is pressed. More about requesting users »
",
+ "rst_description": "This object defines the criteria used to request suitable users. Information about the selected users will be shared with the bot when the corresponding button is pressed. `More about requesting users » `_",
"annotations": [
{
"type": "Integer",
@@ -42,6 +42,30 @@
"rst_description": "*Optional*. The maximum number of users to be selected; 1-10. Defaults to 1.\n",
"name": "max_quantity",
"required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "Pass True to request the users' first and last name",
+ "html_description": "Optional. Pass True to request the users' first and last name | ",
+ "rst_description": "*Optional*. Pass :code:`True` to request the users' first and last name\n",
+ "name": "request_name",
+ "required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "Pass True to request the users' username",
+ "html_description": "Optional. Pass True to request the users' username | ",
+ "rst_description": "*Optional*. Pass :code:`True` to request the users' username\n",
+ "name": "request_username",
+ "required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "Pass True to request the users' photo",
+ "html_description": "Optional. Pass True to request the users' photo | ",
+ "rst_description": "*Optional*. Pass :code:`True` to request the users' photo\n",
+ "name": "request_photo",
+ "required": false
}
],
"category": "types"
diff --git a/.butcher/types/Location/entity.json b/.butcher/types/Location/entity.json
index 2551b11b..a62b44aa 100644
--- a/.butcher/types/Location/entity.json
+++ b/.butcher/types/Location/entity.json
@@ -11,14 +11,6 @@
"html_description": "This object represents a point on the map.
",
"rst_description": "This object represents a point on the map.",
"annotations": [
- {
- "type": "Float",
- "description": "Longitude as defined by sender",
- "html_description": "Longitude as defined by sender | ",
- "rst_description": "Longitude as defined by sender\n",
- "name": "longitude",
- "required": true
- },
{
"type": "Float",
"description": "Latitude as defined by sender",
@@ -27,6 +19,14 @@
"name": "latitude",
"required": true
},
+ {
+ "type": "Float",
+ "description": "Longitude as defined by sender",
+ "html_description": "Longitude as defined by sender | ",
+ "rst_description": "Longitude as defined by sender\n",
+ "name": "longitude",
+ "required": true
+ },
{
"type": "Float",
"description": "The radius of uncertainty for the location, measured in meters; 0-1500",
diff --git a/.butcher/types/Message/aliases.yml b/.butcher/types/Message/aliases.yml
index d0abce81..3168f30d 100644
--- a/.butcher/types/Message/aliases.yml
+++ b/.butcher/types/Message/aliases.yml
@@ -5,6 +5,7 @@ answer:
fill: &fill-answer
chat_id: self.chat.id
message_thread_id: self.message_thread_id if self.is_topic_message else None
+ business_connection_id: self.business_connection_id
reply:
method: sendMessage
diff --git a/.butcher/types/Message/entity.json b/.butcher/types/Message/entity.json
index ded375e3..c190dcbb 100644
--- a/.butcher/types/Message/entity.json
+++ b/.butcher/types/Message/entity.json
@@ -51,6 +51,14 @@
"name": "sender_boost_count",
"required": false
},
+ {
+ "type": "User",
+ "description": "The bot that actually sent the message on behalf of the business account. Available only for outgoing messages sent on behalf of the connected business account.",
+ "html_description": "Optional. The bot that actually sent the message on behalf of the business account. Available only for outgoing messages sent on behalf of the connected business account. | ",
+ "rst_description": "*Optional*. The bot that actually sent the message on behalf of the business account. Available only for outgoing messages sent on behalf of the connected business account.\n",
+ "name": "sender_business_bot",
+ "required": false
+ },
{
"type": "Integer",
"description": "Date the message was sent in Unix time. It is always a positive number, representing a valid date.",
@@ -59,6 +67,14 @@
"name": "date",
"required": true
},
+ {
+ "type": "String",
+ "description": "Unique identifier of the business connection from which the message was received. If non-empty, the message belongs to a chat of the corresponding business account that is independent from any potential bot chat which might share the same identifier.",
+ "html_description": "Optional. Unique identifier of the business connection from which the message was received. If non-empty, the message belongs to a chat of the corresponding business account that is independent from any potential bot chat which might share the same identifier. | ",
+ "rst_description": "*Optional*. Unique identifier of the business connection from which the message was received. If non-empty, the message belongs to a chat of the corresponding business account that is independent from any potential bot chat which might share the same identifier.\n",
+ "name": "business_connection_id",
+ "required": false
+ },
{
"type": "Chat",
"description": "Chat the message belongs to",
@@ -147,6 +163,14 @@
"name": "has_protected_content",
"required": false
},
+ {
+ "type": "True",
+ "description": "True, if the message was sent by an implicit action, for example, as an away or a greeting business message, or as a scheduled message",
+ "html_description": "Optional. True, if the message was sent by an implicit action, for example, as an away or a greeting business message, or as a scheduled message | ",
+ "rst_description": "*Optional*. True, if the message was sent by an implicit action, for example, as an away or a greeting business message, or as a scheduled message\n",
+ "name": "is_from_offline",
+ "required": false
+ },
{
"type": "String",
"description": "The unique identifier of a media message group this message belongs to",
diff --git a/.butcher/types/ReplyParameters/entity.json b/.butcher/types/ReplyParameters/entity.json
index 1e7e2778..94a43e43 100644
--- a/.butcher/types/ReplyParameters/entity.json
+++ b/.butcher/types/ReplyParameters/entity.json
@@ -21,17 +21,17 @@
},
{
"type": "Integer or String",
- "description": "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)",
- "html_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) | ",
- "rst_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 :code:`@channelusername`)\n",
+ "description": "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). Not supported for messages sent on behalf of a business account.",
+ "html_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). Not supported for messages sent on behalf of a business account. | ",
+ "rst_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 :code:`@channelusername`). Not supported for messages sent on behalf of a business account.\n",
"name": "chat_id",
"required": false
},
{
"type": "Boolean",
- "description": "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.",
- "html_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. | ",
- "rst_description": "*Optional*. Pass :code:`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.\n",
+ "description": "Pass True if the message should be sent even if the specified message to be replied to is not found. Always False for replies in another chat or forum topic. Always True for messages sent on behalf of a business account.",
+ "html_description": "Optional. Pass True if the message should be sent even if the specified message to be replied to is not found. Always False for replies in another chat or forum topic. Always True for messages sent on behalf of a business account. | ",
+ "rst_description": "*Optional*. Pass :code:`True` if the message should be sent even if the specified message to be replied to is not found. Always :code:`False` for replies in another chat or forum topic. Always :code:`True` for messages sent on behalf of a business account.\n",
"name": "allow_sending_without_reply",
"required": false
},
diff --git a/.butcher/types/SharedUser/entity.json b/.butcher/types/SharedUser/entity.json
new file mode 100644
index 00000000..6e33fe97
--- /dev/null
+++ b/.butcher/types/SharedUser/entity.json
@@ -0,0 +1,57 @@
+{
+ "meta": {},
+ "group": {
+ "title": "Available types",
+ "anchor": "available-types"
+ },
+ "object": {
+ "anchor": "shareduser",
+ "name": "SharedUser",
+ "description": "This object contains information about a user that was shared with the bot using a KeyboardButtonRequestUser button.",
+ "html_description": "This object contains information about a user that was shared with the bot using a KeyboardButtonRequestUser button.
",
+ "rst_description": "This object contains information about a user that was shared with the bot using a :class:`aiogram.types.keyboard_button_request_user.KeyboardButtonRequestUser` button.",
+ "annotations": [
+ {
+ "type": "Integer",
+ "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 64-bit integers or double-precision float types are safe for storing these identifiers. 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.",
+ "html_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 64-bit integers or double-precision float types are safe for storing these identifiers. 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. | ",
+ "rst_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 64-bit integers or double-precision float types are safe for storing these identifiers. 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.\n",
+ "name": "user_id",
+ "required": true
+ },
+ {
+ "type": "String",
+ "description": "First name of the user, if the name was requested by the bot",
+ "html_description": "Optional. First name of the user, if the name was requested by the bot | ",
+ "rst_description": "*Optional*. First name of the user, if the name was requested by the bot\n",
+ "name": "first_name",
+ "required": false
+ },
+ {
+ "type": "String",
+ "description": "Last name of the user, if the name was requested by the bot",
+ "html_description": "Optional. Last name of the user, if the name was requested by the bot | ",
+ "rst_description": "*Optional*. Last name of the user, if the name was requested by the bot\n",
+ "name": "last_name",
+ "required": false
+ },
+ {
+ "type": "String",
+ "description": "Username of the user, if the username was requested by the bot",
+ "html_description": "Optional. Username of the user, if the username was requested by the bot | ",
+ "rst_description": "*Optional*. Username of the user, if the username was requested by the bot\n",
+ "name": "username",
+ "required": false
+ },
+ {
+ "type": "Array of PhotoSize",
+ "description": "Available sizes of the chat photo, if the photo was requested by the bot",
+ "html_description": "Optional. Available sizes of the chat photo, if the photo was requested by the bot | ",
+ "rst_description": "*Optional*. Available sizes of the chat photo, if the photo was requested by the bot\n",
+ "name": "photo",
+ "required": false
+ }
+ ],
+ "category": "types"
+ }
+}
diff --git a/.butcher/types/StickerSet/entity.json b/.butcher/types/StickerSet/entity.json
index d74eb635..e9c1fe5b 100644
--- a/.butcher/types/StickerSet/entity.json
+++ b/.butcher/types/StickerSet/entity.json
@@ -35,22 +35,6 @@
"name": "sticker_type",
"required": true
},
- {
- "type": "Boolean",
- "description": "True, if the sticker set contains animated stickers",
- "html_description": "True, if the sticker set contains animated stickers | ",
- "rst_description": ":code:`True`, if the sticker set contains `animated stickers `_\n",
- "name": "is_animated",
- "required": true
- },
- {
- "type": "Boolean",
- "description": "True, if the sticker set contains video stickers",
- "html_description": "True, if the sticker set contains video stickers | ",
- "rst_description": ":code:`True`, if the sticker set contains `video stickers `_\n",
- "name": "is_video",
- "required": true
- },
{
"type": "Array of Sticker",
"description": "List of all set stickers",
@@ -66,6 +50,30 @@
"rst_description": "*Optional*. Sticker set thumbnail in the .WEBP, .TGS, or .WEBM format\n",
"name": "thumbnail",
"required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "True, if the sticker set contains animated stickers",
+ "html_description": "True, if the sticker set contains animated stickers | ",
+ "rst_description": ":code:`True`, if the sticker set contains `animated stickers `_\n",
+ "name": "is_animated",
+ "required": false,
+ "deprecated": {
+ "version": "7.2",
+ "release_date": "2024-03-31"
+ }
+ },
+ {
+ "type": "Boolean",
+ "description": "True, if the sticker set contains video stickers",
+ "html_description": "True, if the sticker set contains video stickers | ",
+ "rst_description": ":code:`True`, if the sticker set contains `video stickers `_\n",
+ "name": "is_video",
+ "required": false,
+ "deprecated": {
+ "version": "7.2",
+ "release_date": "2024-03-31"
+ }
}
],
"category": "types"
diff --git a/.butcher/types/Update/entity.json b/.butcher/types/Update/entity.json
index 756fcb01..e28a0d4e 100644
--- a/.butcher/types/Update/entity.json
+++ b/.butcher/types/Update/entity.json
@@ -51,6 +51,38 @@
"name": "edited_channel_post",
"required": false
},
+ {
+ "type": "BusinessConnection",
+ "description": "The bot was connected to or disconnected from a business account, or a user edited an existing connection with the bot",
+ "html_description": "Optional. The bot was connected to or disconnected from a business account, or a user edited an existing connection with the bot | ",
+ "rst_description": "*Optional*. The bot was connected to or disconnected from a business account, or a user edited an existing connection with the bot\n",
+ "name": "business_connection",
+ "required": false
+ },
+ {
+ "type": "Message",
+ "description": "New non-service message from a connected business account",
+ "html_description": "Optional. New non-service message from a connected business account | ",
+ "rst_description": "*Optional*. New non-service message from a connected business account\n",
+ "name": "business_message",
+ "required": false
+ },
+ {
+ "type": "Message",
+ "description": "New version of a message from a connected business account",
+ "html_description": "Optional. New version of a message from a connected business account | ",
+ "rst_description": "*Optional*. New version of a message from a connected business account\n",
+ "name": "edited_business_message",
+ "required": false
+ },
+ {
+ "type": "BusinessMessagesDeleted",
+ "description": "Messages were deleted from a connected business account",
+ "html_description": "Optional. Messages were deleted from a connected business account | ",
+ "rst_description": "*Optional*. Messages were deleted from a connected business account\n",
+ "name": "deleted_business_messages",
+ "required": false
+ },
{
"type": "MessageReactionUpdated",
"description": "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.",
diff --git a/.butcher/types/User/entity.json b/.butcher/types/User/entity.json
index a753bb16..f502c62b 100644
--- a/.butcher/types/User/entity.json
+++ b/.butcher/types/User/entity.json
@@ -98,6 +98,14 @@
"rst_description": "*Optional*. :code:`True`, if the bot supports inline queries. Returned only in :class:`aiogram.methods.get_me.GetMe`.\n",
"name": "supports_inline_queries",
"required": false
+ },
+ {
+ "type": "Boolean",
+ "description": "True, if the bot can be connected to a Telegram Business account to receive its messages. Returned only in getMe.",
+ "html_description": "Optional. True, if the bot can be connected to a Telegram Business account to receive its messages. Returned only in getMe. | ",
+ "rst_description": "*Optional*. :code:`True`, if the bot can be connected to a Telegram Business account to receive its messages. Returned only in :class:`aiogram.methods.get_me.GetMe`.\n",
+ "name": "can_connect_to_business",
+ "required": false
}
],
"category": "types"
diff --git a/.butcher/types/UsersShared/entity.json b/.butcher/types/UsersShared/entity.json
index a46f7ddf..e105e039 100644
--- a/.butcher/types/UsersShared/entity.json
+++ b/.butcher/types/UsersShared/entity.json
@@ -19,13 +19,25 @@
"name": "request_id",
"required": true
},
+ {
+ "type": "Array of SharedUser",
+ "description": "Information about users shared with the bot.",
+ "html_description": "Information about users shared with the bot. | ",
+ "rst_description": "Information about users shared with the bot.\n",
+ "name": "users",
+ "required": true
+ },
{
"type": "Array of Integer",
"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.",
"html_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. | ",
"rst_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.\n",
"name": "user_ids",
- "required": true
+ "required": false,
+ "deprecated": {
+ "version": "7.2",
+ "release_date": "2024-03-31"
+ }
}
],
"category": "types"
diff --git a/CHANGES/1444.misc.rst b/CHANGES/1444.misc.rst
new file mode 100644
index 00000000..35e82ca9
--- /dev/null
+++ b/CHANGES/1444.misc.rst
@@ -0,0 +1 @@
+Added full support of `Bot API 7.2 `_
diff --git a/README.rst b/README.rst
index 4ebf2f2d..e84e60e3 100644
--- a/README.rst
+++ b/README.rst
@@ -52,7 +52,7 @@ Features
- Asynchronous (`asyncio docs `_, :pep:`492`)
- Has type hints (:pep:`484`) and can be used with `mypy `_
- Supports `PyPy `_
-- Supports `Telegram Bot API 7.1 `_ and gets fast updates to the latest versions of the Bot API
+- Supports `Telegram Bot API 7.2 `_ and gets fast updates to the latest versions of the Bot API
- Telegram Bot API integration code was `autogenerated `_ and can be easily re-generated when API gets updated
- Updates router (Blueprints)
- Has Finite State Machine
diff --git a/aiogram/__meta__.py b/aiogram/__meta__.py
index 3e6d24e8..bdbcd36b 100644
--- a/aiogram/__meta__.py
+++ b/aiogram/__meta__.py
@@ -1,2 +1,2 @@
-__version__ = "3.4.1"
-__api_version__ = "7.1"
+__version__ = "3.5.0"
+__api_version__ = "7.2"
diff --git a/aiogram/client/bot.py b/aiogram/client/bot.py
index ab25a549..bf556d1d 100644
--- a/aiogram/client/bot.py
+++ b/aiogram/client/bot.py
@@ -61,6 +61,7 @@ from ..methods import (
ExportChatInviteLink,
ForwardMessage,
ForwardMessages,
+ GetBusinessConnection,
GetChat,
GetChatAdministrators,
GetChatMember,
@@ -88,6 +89,7 @@ from ..methods import (
PromoteChatMember,
ReopenForumTopic,
ReopenGeneralForumTopic,
+ ReplaceStickerInSet,
RestrictChatMember,
RevokeChatInviteLink,
SendAnimation,
@@ -155,6 +157,7 @@ from ..types import (
BotDescription,
BotName,
BotShortDescription,
+ BusinessConnection,
Chat,
ChatAdministratorRights,
ChatInviteLink,
@@ -518,7 +521,7 @@ class Bot:
request_timeout: Optional[int] = None,
) -> bool:
"""
- Use this method to add a new sticker to a set created by the bot. The format of the added sticker must match the format of the other stickers in the set. Emoji sticker sets can have up to 200 stickers. Animated and video sticker sets can have up to 50 stickers. Static sticker sets can have up to 120 stickers. Returns :code:`True` on success.
+ Use this method to add a new sticker to a set created by the bot. Emoji sticker sets can have up to 200 stickers. Other sticker sets can have up to 120 stickers. Returns :code:`True` on success.
Source: https://core.telegram.org/bots/api#addstickertoset
@@ -1051,9 +1054,9 @@ class Bot:
name: str,
title: str,
stickers: List[InputSticker],
- sticker_format: str,
sticker_type: Optional[str] = None,
needs_repainting: Optional[bool] = None,
+ sticker_format: Optional[str] = None,
request_timeout: Optional[int] = None,
) -> bool:
"""
@@ -1065,9 +1068,9 @@ class Bot:
:param name: Short name of sticker set, to be used in :code:`t.me/addstickers/` URLs (e.g., *animals*). Can contain only English letters, digits and underscores. Must begin with a letter, can't contain consecutive underscores and must end in :code:`"_by_"`. :code:`` is case insensitive. 1-64 characters.
:param title: Sticker set title, 1-64 characters
:param stickers: A JSON-serialized list of 1-50 initial stickers to be added to the sticker set
- :param sticker_format: Format of stickers in the set, must be one of 'static', 'animated', 'video'
:param sticker_type: Type of stickers in the set, pass 'regular', 'mask', or 'custom_emoji'. By default, a regular sticker set is created.
:param needs_repainting: Pass :code:`True` if stickers in the sticker set must be repainted to the color of text when used in messages, the accent color if used as emoji status, white on chat photos, or another appropriate color based on context; for custom emoji sticker sets only
+ :param sticker_format: Format of stickers in the set, must be one of 'static', 'animated', 'video'
:param request_timeout: Request timeout
:return: Returns :code:`True` on success.
"""
@@ -1077,9 +1080,9 @@ class Bot:
name=name,
title=title,
stickers=stickers,
- sticker_format=sticker_format,
sticker_type=sticker_type,
needs_repainting=needs_repainting,
+ sticker_format=sticker_format,
)
return await self(call, request_timeout=request_timeout)
@@ -1728,7 +1731,7 @@ class Bot:
Source: https://core.telegram.org/bots/api#getcustomemojistickers
- :param custom_emoji_ids: List of custom emoji identifiers. At most 200 custom emoji identifiers can be specified.
+ :param custom_emoji_ids: A JSON-serialized list of custom emoji identifiers. At most 200 custom emoji identifiers can be specified.
:param request_timeout: Request timeout
:return: Returns an Array of :class:`aiogram.types.sticker.Sticker` objects.
"""
@@ -2073,10 +2076,10 @@ class Bot:
:param can_post_stories: Pass :code:`True` if the administrator can post stories to the chat
:param can_edit_stories: Pass :code:`True` if the administrator can edit stories posted by other users
:param can_delete_stories: Pass :code:`True` if the administrator can delete stories posted by other users
- :param can_post_messages: Pass :code:`True` if the administrator can post messages in the channel, or access channel statistics; channels only
- :param can_edit_messages: Pass :code:`True` if the administrator can edit messages of other users and can pin messages; channels only
- :param can_pin_messages: Pass :code:`True` if the administrator can pin messages, supergroups only
- :param can_manage_topics: Pass :code:`True` if the user is allowed to create, rename, close, and reopen forum topics, supergroups only
+ :param can_post_messages: Pass :code:`True` if the administrator can post messages in the channel, or access channel statistics; for channels only
+ :param can_edit_messages: Pass :code:`True` if the administrator can edit messages of other users and can pin messages; for channels only
+ :param can_pin_messages: Pass :code:`True` if the administrator can pin messages; for supergroups only
+ :param can_manage_topics: Pass :code:`True` if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only
:param request_timeout: Request timeout
:return: Returns :code:`True` on success.
"""
@@ -2184,6 +2187,7 @@ class Bot:
self,
chat_id: Union[int, str],
animation: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
duration: Optional[int] = None,
width: Optional[int] = None,
@@ -2210,6 +2214,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param animation: Animation to send. Pass a file_id as String to send an animation that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get an animation from the Internet, or upload a new animation using multipart/form-data. :ref:`More information on Sending Files » `
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param duration: Duration of sent animation in seconds
:param width: Animation width
@@ -2222,7 +2227,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2232,6 +2237,7 @@ class Bot:
call = SendAnimation(
chat_id=chat_id,
animation=animation,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
duration=duration,
width=width,
@@ -2254,6 +2260,7 @@ class Bot:
self,
chat_id: Union[int, str],
audio: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
caption: Optional[str] = None,
parse_mode: Optional[Union[str, Default]] = Default("parse_mode"),
@@ -2280,6 +2287,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param audio: Audio file to send. Pass a file_id as String to send an audio file that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get an audio file from the Internet, or upload a new one using multipart/form-data. :ref:`More information on Sending Files » `
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param caption: Audio caption, 0-1024 characters after entities parsing
:param parse_mode: Mode for parsing entities in the audio caption. See `formatting options `_ for more details.
@@ -2291,7 +2299,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2301,6 +2309,7 @@ class Bot:
call = SendAudio(
chat_id=chat_id,
audio=audio,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
caption=caption,
parse_mode=parse_mode,
@@ -2322,6 +2331,7 @@ class Bot:
self,
chat_id: Union[int, str],
action: str,
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
request_timeout: Optional[int] = None,
) -> bool:
@@ -2336,7 +2346,8 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param action: 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 `_.
- :param message_thread_id: Unique identifier for the target message thread; supergroups only
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the action will be sent
+ :param message_thread_id: Unique identifier for the target message thread; for supergroups only
:param request_timeout: Request timeout
:return: The user will see a 'sending photo' status for the bot.
"""
@@ -2344,6 +2355,7 @@ class Bot:
call = SendChatAction(
chat_id=chat_id,
action=action,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
)
return await self(call, request_timeout=request_timeout)
@@ -2353,6 +2365,7 @@ class Bot:
chat_id: Union[int, str],
phone_number: str,
first_name: str,
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
last_name: Optional[str] = None,
vcard: Optional[str] = None,
@@ -2374,13 +2387,14 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param phone_number: Contact's phone number
:param first_name: Contact's first name
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param last_name: Contact's last name
:param vcard: Additional data about the contact in the form of a `vCard `_, 0-2048 bytes
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2391,6 +2405,7 @@ class Bot:
chat_id=chat_id,
phone_number=phone_number,
first_name=first_name,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
last_name=last_name,
vcard=vcard,
@@ -2406,6 +2421,7 @@ class Bot:
async def send_dice(
self,
chat_id: Union[int, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
emoji: Optional[str] = None,
disable_notification: Optional[bool] = None,
@@ -2424,12 +2440,13 @@ class Bot:
Source: https://core.telegram.org/bots/api#senddice
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param emoji: Emoji on which the dice throw animation is based. Currently, must be one of '🎲', '🎯', '🏀', '⚽', '🎳', or '🎰'. Dice can have values 1-6 for '🎲', '🎯' and '🎳', values 1-5 for '🏀' and '⚽', and values 1-64 for '🎰'. Defaults to '🎲'
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2438,6 +2455,7 @@ class Bot:
call = SendDice(
chat_id=chat_id,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
emoji=emoji,
disable_notification=disable_notification,
@@ -2453,6 +2471,7 @@ class Bot:
self,
chat_id: Union[int, str],
document: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
thumbnail: Optional[InputFile] = None,
caption: Optional[str] = None,
@@ -2476,6 +2495,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param document: File to send. Pass a file_id as String to send a file that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get a file from the Internet, or upload a new one using multipart/form-data. :ref:`More information on Sending Files » `
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param thumbnail: Thumbnail of the file sent; can be ignored if thumbnail generation for the file is supported server-side. The thumbnail should be in JPEG format and less than 200 kB in size. A thumbnail's width and height should not exceed 320. Ignored if the file is not uploaded using multipart/form-data. Thumbnails can't be reused and can be only uploaded as a new file, so you can pass 'attach://' if the thumbnail was uploaded using multipart/form-data under . :ref:`More information on Sending Files » `
:param caption: Document caption (may also be used when resending documents by *file_id*), 0-1024 characters after entities parsing
@@ -2485,7 +2505,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2495,6 +2515,7 @@ class Bot:
call = SendDocument(
chat_id=chat_id,
document=document,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
thumbnail=thumbnail,
caption=caption,
@@ -2514,6 +2535,7 @@ class Bot:
self,
chat_id: int,
game_short_name: str,
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
disable_notification: Optional[bool] = None,
protect_content: Optional[Union[bool, Default]] = Default("protect_content"),
@@ -2530,11 +2552,12 @@ class Bot:
:param chat_id: Unique identifier for the target chat
:param game_short_name: Short name of the game, serves as the unique identifier for the game. Set up your games via `@BotFather `_.
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: A JSON-serialized object for an `inline keyboard `_. If empty, one 'Play game_title' button will be shown. If not empty, the first button must launch the game.
+ :param reply_markup: A JSON-serialized object for an `inline keyboard `_. If empty, one 'Play game_title' button will be shown. If not empty, the first button must launch the game. Not supported for messages sent on behalf of a business account.
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2544,6 +2567,7 @@ class Bot:
call = SendGame(
chat_id=chat_id,
game_short_name=game_short_name,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
disable_notification=disable_notification,
protect_content=protect_content,
@@ -2663,6 +2687,7 @@ class Bot:
chat_id: Union[int, str],
latitude: float,
longitude: float,
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
horizontal_accuracy: Optional[float] = None,
live_period: Optional[int] = None,
@@ -2686,6 +2711,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param latitude: Latitude of the location
:param longitude: Longitude of the location
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param horizontal_accuracy: The radius of uncertainty for the location, measured in meters; 0-1500
:param live_period: Period in seconds for which the location will be updated (see `Live Locations `_, should be between 60 and 86400.
@@ -2694,7 +2720,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2705,6 +2731,7 @@ class Bot:
chat_id=chat_id,
latitude=latitude,
longitude=longitude,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
horizontal_accuracy=horizontal_accuracy,
live_period=live_period,
@@ -2723,6 +2750,7 @@ class Bot:
self,
chat_id: Union[int, str],
media: List[Union[InputMediaAudio, InputMediaDocument, InputMediaPhoto, InputMediaVideo]],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
disable_notification: Optional[bool] = None,
protect_content: Optional[Union[bool, Default]] = Default("protect_content"),
@@ -2738,6 +2766,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param media: A JSON-serialized array describing messages to be sent, must include 2-10 items
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param disable_notification: Sends messages `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent messages from forwarding and saving
@@ -2751,6 +2780,7 @@ class Bot:
call = SendMediaGroup(
chat_id=chat_id,
media=media,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
disable_notification=disable_notification,
protect_content=protect_content,
@@ -2764,6 +2794,7 @@ class Bot:
self,
chat_id: Union[int, str],
text: str,
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
parse_mode: Optional[Union[str, Default]] = Default("parse_mode"),
entities: Optional[List[MessageEntity]] = None,
@@ -2790,6 +2821,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param text: Text of the message to be sent, 1-4096 characters after entities parsing
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param parse_mode: Mode for parsing entities in the message text. See `formatting options `_ for more details.
:param entities: A JSON-serialized list of special entities that appear in message text, which can be specified instead of *parse_mode*
@@ -2797,7 +2829,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param disable_web_page_preview: Disables link previews for links in this message
:param reply_to_message_id: If the message is a reply, ID of the original message
@@ -2808,6 +2840,7 @@ class Bot:
call = SendMessage(
chat_id=chat_id,
text=text,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
parse_mode=parse_mode,
entities=entities,
@@ -2826,6 +2859,7 @@ class Bot:
self,
chat_id: Union[int, str],
photo: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
caption: Optional[str] = None,
parse_mode: Optional[Union[str, Default]] = Default("parse_mode"),
@@ -2848,6 +2882,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param photo: Photo to send. Pass a file_id as String to send a photo that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get a photo from the Internet, or upload a new photo using multipart/form-data. The photo must be at most 10 MB in size. The photo's width and height must not exceed 10000 in total. Width and height ratio must be at most 20. :ref:`More information on Sending Files » `
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param caption: Photo caption (may also be used when resending photos by *file_id*), 0-1024 characters after entities parsing
:param parse_mode: Mode for parsing entities in the photo caption. See `formatting options `_ for more details.
@@ -2856,7 +2891,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2866,6 +2901,7 @@ class Bot:
call = SendPhoto(
chat_id=chat_id,
photo=photo,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
caption=caption,
parse_mode=parse_mode,
@@ -2885,6 +2921,7 @@ class Bot:
chat_id: Union[int, str],
question: str,
options: List[str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
is_anonymous: Optional[bool] = None,
type: Optional[str] = None,
@@ -2914,6 +2951,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param question: Poll question, 1-300 characters
:param options: A JSON-serialized list of answer options, 2-10 strings 1-100 characters each
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param is_anonymous: :code:`True`, if the poll needs to be anonymous, defaults to :code:`True`
:param type: Poll type, 'quiz' or 'regular', defaults to 'regular'
@@ -2928,7 +2966,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2939,6 +2977,7 @@ class Bot:
chat_id=chat_id,
question=question,
options=options,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
is_anonymous=is_anonymous,
type=type,
@@ -2963,6 +3002,7 @@ class Bot:
self,
chat_id: Union[int, str],
sticker: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
emoji: Optional[str] = None,
disable_notification: Optional[bool] = None,
@@ -2981,13 +3021,14 @@ class Bot:
Source: https://core.telegram.org/bots/api#sendsticker
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
- :param sticker: Sticker to send. Pass a file_id as String to send a file that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get a .WEBP sticker from the Internet, or upload a new .WEBP or .TGS sticker using multipart/form-data. :ref:`More information on Sending Files » `. Video stickers can only be sent by a file_id. Animated stickers can't be sent via an HTTP URL.
+ :param sticker: Sticker to send. Pass a file_id as String to send a file that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get a .WEBP sticker from the Internet, or upload a new .WEBP, .TGS, or .WEBM sticker using multipart/form-data. :ref:`More information on Sending Files » `. Video and animated stickers can't be sent via an HTTP URL.
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param emoji: Emoji associated with the sticker; only for just uploaded stickers
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: 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. Not supported for messages sent on behalf of a business account.
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -2997,6 +3038,7 @@ class Bot:
call = SendSticker(
chat_id=chat_id,
sticker=sticker,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
emoji=emoji,
disable_notification=disable_notification,
@@ -3015,6 +3057,7 @@ class Bot:
longitude: float,
title: str,
address: str,
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
foursquare_id: Optional[str] = None,
foursquare_type: Optional[str] = None,
@@ -3040,6 +3083,7 @@ class Bot:
:param longitude: Longitude of the venue
:param title: Name of the venue
:param address: Address of the venue
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param foursquare_id: Foursquare identifier of the venue
:param foursquare_type: Foursquare type of the venue, if known. (For example, 'arts_entertainment/default', 'arts_entertainment/aquarium' or 'food/icecream'.)
@@ -3048,7 +3092,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -3061,6 +3105,7 @@ class Bot:
longitude=longitude,
title=title,
address=address,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
foursquare_id=foursquare_id,
foursquare_type=foursquare_type,
@@ -3079,6 +3124,7 @@ class Bot:
self,
chat_id: Union[int, str],
video: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
duration: Optional[int] = None,
width: Optional[int] = None,
@@ -3106,6 +3152,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param video: Video to send. Pass a file_id as String to send a video that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get a video from the Internet, or upload a new video using multipart/form-data. :ref:`More information on Sending Files » `
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param duration: Duration of sent video in seconds
:param width: Video width
@@ -3119,7 +3166,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -3129,6 +3176,7 @@ class Bot:
call = SendVideo(
chat_id=chat_id,
video=video,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
duration=duration,
width=width,
@@ -3152,6 +3200,7 @@ class Bot:
self,
chat_id: Union[int, str],
video_note: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
duration: Optional[int] = None,
length: Optional[int] = None,
@@ -3173,6 +3222,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param video_note: Video note to send. Pass a file_id as String to send a video note that exists on the Telegram servers (recommended) or upload a new video using multipart/form-data. :ref:`More information on Sending Files » `. Sending video notes by a URL is currently unsupported
+ :param business_connection_id: Unique identifier of the business connection on behalf of which the message will be sent
:param message_thread_id: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
:param duration: Duration of sent video in seconds
:param length: Video width and height, i.e. diameter of the video message
@@ -3180,7 +3230,7 @@ class Bot:
:param disable_notification: Sends the message `silently `_. Users will receive a notification with no sound.
:param protect_content: Protects the contents of the sent message from forwarding and saving
:param reply_parameters: Description of the message to reply to
- :param reply_markup: 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.
+ :param reply_markup: Additional interface options. A JSON-serialized object for an `inline keyboard `_, `custom reply keyboard `_, instructions to remove a reply keyboard or to force a reply from the user. Not supported for messages sent on behalf of a business account
:param allow_sending_without_reply: Pass :code:`True` if the message should be sent even if the specified replied-to message is not found
:param reply_to_message_id: If the message is a reply, ID of the original message
:param request_timeout: Request timeout
@@ -3190,6 +3240,7 @@ class Bot:
call = SendVideoNote(
chat_id=chat_id,
video_note=video_note,
+ business_connection_id=business_connection_id,
message_thread_id=message_thread_id,
duration=duration,
length=length,
@@ -3207,6 +3258,7 @@ class Bot:
self,
chat_id: Union[int, str],
voice: Union[InputFile, str],
+ business_connection_id: Optional[str] = None,
message_thread_id: Optional[int] = None,
caption: Optional[str] = None,
parse_mode: Optional[Union[str, Default]] = Default("parse_mode"),
@@ -3229,6 +3281,7 @@ class Bot:
:param chat_id: Unique identifier for the target chat or username of the target channel (in the format :code:`@channelusername`)
:param voice: Audio file to send. Pass a file_id as String to send a file that exists on the Telegram servers (recommended), pass an HTTP URL as a String for Telegram to get a file from the Internet, or upload a new one using multipart/form-data. :ref:`More information on Sending Files »