tgbot 0.3.2 → 0.4.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (6) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE.txt +1 -1
  3. data/README.md +2 -2
  4. data/lib/api.yaml +2015 -630
  5. data/lib/tgbot/version.rb +1 -1
  6. metadata +3 -3
data/lib/api.yaml CHANGED
@@ -3,144 +3,90 @@ name: Telegram Bot API
3
3
  children:
4
4
  - name: Recent changes
5
5
  children:
6
- - name: April 26, 2021
6
+ - name: March 9, 2023
7
7
  children: []
8
8
  desc:
9
9
  - name: p
10
- content: Bot API 5.2
10
+ content: Bot API 6.6
11
11
  - name: ul
12
12
  content:
13
- - Support for Payments 2.0, see this manual for more details about the Bot Payments API.
14
- - Added the type InputInvoiceMessageContent to support sending invoices as inline query results.
15
- - Allowed sending invoices to group, supergroup and channel chats.
16
- - Added the fields max_tip_amount and suggested_tip_amounts to the method sendInvoice to allow adding optional tips to the payment.
17
- - The parameter start_parameter of the method sendInvoice became optional. If the parameter isn't specified, the invoice can be paid directly from forwarded messages.
18
- - Added the field chat_type to the class InlineQuery, containing the type of the chat, from which the inline request was sent.
19
- - Added the type VoiceChatScheduled and the field voice_chat_scheduled to the class Message.
20
- - Fixed an error in sendChatAction documentation to correctly mention “record_voice” and “upload_voice” instead of “record_audio” and “upload_audio” for related to voice note actions. Old action names will still work for backward compatibility.
21
- - name: blockquote
22
- content: WARNING! After the next Bot API update (Bot API 5.3) there will be a one-time change of the value of the field file_unique_id in objects of the type PhotoSize and of the fields small_file_unique_id and big_file_unique_id in objects of the type ChatPhoto.
23
- - name: blockquote
24
- content: WARNING! Service messages about non-bot users joining the chat will be soon removed from large groups. We recommend using the “chat_member” update as a replacement.
25
- - name: blockquote
26
- content: WARNING! After one of the upcoming Bot API updates, user identifiers will become bigger than 2^31 - 1 and it will be no longer possible to store them in a signed 32-bit integer type. User identifiers will have up to 52 significant bits, so a 64-bit integer or double-precision float type would still be safe for storing them. Please make sure that your code can correctly handle such user identifiers.
27
- - name: March 9, 2021
28
- children: []
29
- desc:
30
- - name: p
31
- content: Bot API 5.1
32
- - name: p
33
- content: Added two new update types
34
- - name: ul
35
- content:
36
- - Added updates about member status changes in chats, represented by the class ChatMemberUpdated and the fields my_chat_member and chat_member in the Update class. The bot must be an administrator in the chat to receive chat_member updates about other chat members. By default, only my_chat_member updates about the bot itself are received.
37
- - name: p
38
- content: Improved Invite Links
39
- - name: ul
40
- content:
41
- - Added the class ChatInviteLink, representing an invite link to a chat.
42
- - Added the method createChatInviteLink, which can be used to create new invite links in addition to the primary invite link.
43
- - Added the method editChatInviteLink, which can be used to edit non-primary invite links created by the bot.
44
- - Added the method revokeChatInviteLink, which can be used to revoke invite links created by the bot.
45
- - name: p
46
- content: Voice Chat Info
47
- - name: ul
48
- content:
49
- - Added the type VoiceChatStarted and the field voice_chat_started to the class Message.
50
- - Added the type VoiceChatEnded and the field voice_chat_ended to the class Message.
51
- - Added the type VoiceChatParticipantsInvited and the field voice_chat_participants_invited to the class Message.
52
- - Added the new administrator privilege can_manage_voice_chats to the class ChatMember and parameter can_manage_voice_chats to the method promoteChatMember. For now, bots can use this privilege only for passing to other administrators.
53
- - name: p
54
- content: And More
13
+ - Added the ability to set different bot descriptions for different user languages using the method setMyDescription.
14
+ - Added the ability to get the current bot description in the given language as the class BotDescription using the method getMyDescription.
15
+ - Added the ability to set different bot short descriptions for different user languages using the method setMyShortDescription.
16
+ - Added the ability to get the current bot short description in the given language as the class BotShortDescription using the method getMyShortDescription.
17
+ - Added the parameter emoji to the method sendSticker to specify an emoji for just uploaded stickers.
18
+ - Added support for the creation of custom emoji sticker sets in createNewStickerSet.
19
+ - Added the parameter needs_repainting to the method createNewStickerSet to automatically change the color of emoji based on context (e.g., use text color in messages, accent color in statuses, etc.).
20
+ - Added the field needs_repainting to the class Sticker.
21
+ - Replaced the parameters png_sticker, tgs_sticker, webm_sticker, emojis and mask_position in the method addStickerToSet with the parameter sticker of the type InputSticker.
22
+ - Added support for the creation of sticker sets with multiple initial stickers in createNewStickerSet by replacing the parameters png_sticker, tgs_sticker, webm_sticker, emojis and mask_position with the parameters stickers and sticker_format.
23
+ - Added support for .WEBP files in createNewStickerSet and addStickerToSet.
24
+ - Added support for .WEBP, .TGS, and .WEBM files in uploadStickerFile by replacing the parameter png_sticker in the method uploadStickerFile with the parameters sticker and sticker_format.
25
+ - Added the ability to specify search keywords for stickers added to sticker sets.
26
+ - Added the method setCustomEmojiStickerSetThumbnail for editing the thumbnail of custom emoji sticker sets created by the bot.
27
+ - Added the method setStickerSetTitle for editing the title of sticker sets created by the bot.
28
+ - Added the method deleteStickerSet for complete deletion of a given sticker set that was created by the bot.
29
+ - Added the method setStickerEmojiList for changing the list of emoji associated with a sticker.
30
+ - Added the method setStickerKeywords for changing the search keywords assigned to a sticker.
31
+ - Added the method setStickerMaskPosition for changing the mask position of a mask sticker.
32
+ - Renamed the field thumb in the classes Animation, Audio, Document, Sticker, Video, VideoNote, InputMediaAnimation, InputMediaAudio, InputMediaDocument, InputMediaVideo, StickerSet to thumbnail.
33
+ - Renamed the parameter thumb in the methods sendAnimation, sendAudio, sendDocument, sendVideo, sendVideoNote to thumbnail.
34
+ - Renamed the method setStickerSetThumb to setStickerSetThumbnail and its parameter thumb to thumbnail.
35
+ - Renamed the fields thumb_url, thumb_width, and thumb_height in the classes InlineQueryResultArticle, InlineQueryResultContact, InlineQueryResultDocument, InlineQueryResultLocation, and InlineQueryResultVenue to thumbnail_url, thumbnail_width, and thumbnail_height respectively.
36
+ - Renamed the field thumb_url in the classes InlineQueryResultPhoto and InlineQueryResultVideo to thumbnail_url.
37
+ - Renamed the fields thumb_url and thumb_mime_type in the classes InlineQueryResultGif, and InlineQueryResultMpeg4Gif to thumbnail_url and thumbnail_mime_type respectively.
38
+ - name: February 3, 2023
39
+ children: []
40
+ desc:
41
+ - name: p
42
+ content: Bot API 6.5
55
43
  - name: ul
56
44
  content:
57
- - Added the type MessageAutoDeleteTimerChanged and the field message_auto_delete_timer_changed to the class Message.
58
- - Added the parameter revoke_messages to the method kickChatMember, allowing to delete all messages from a group for the user who is being removed.
59
- - Added the new administrator privilege can_manage_chat to the class ChatMember and parameter can_manage_chat to the method promoteChatMember. This administrator right is implied by any other administrator privilege.
60
- - Supported the new bowling animation for the random dice. Choose between different animations (dice, darts, basketball, football, bowling, slot machine) by specifying the emoji parameter in the method sendDice.
61
- - name: blockquote
62
- content: WARNING! After one of the upcoming Bot API updates, some user identifiers will become bigger than 2^31 - 1 and it will be no longer possible to store them in a signed 32-bit integer type. User identifiers will have up to 52 significant bits, so a 64-bit integer or double-precision float type would still be safe for storing them. Please make sure that your code can correctly handle such user identifiers.
63
- - name: November 4, 2020
45
+ - Added requests for users and chats and support for granular media permissions.
46
+ - Added the class KeyboardButtonRequestUser and the field request_user to the class KeyboardButton.
47
+ - Added the class KeyboardButtonRequestChat and the field request_chat to the class KeyboardButton.
48
+ - Added the classes UserShared, ChatShared and the fields user_shared, and chat_shared to the class Message.
49
+ - Replaced the fields can_send_media_messages in the classes ChatMemberRestricted and ChatPermissions with separate fields can_send_audios, can_send_documents, can_send_photos, can_send_videos, can_send_video_notes, and can_send_voice_notes for different media types.
50
+ - Added the parameter use_independent_chat_permissions to the methods restrictChatMember and setChatPermissions.
51
+ - Added the field user_chat_id to the class ChatJoinRequest.
52
+ - name: December 30, 2022
64
53
  children: []
65
54
  desc:
66
55
  - name: p
67
- content: Introducing Bot API 5.0
68
- - name: p
69
- content: Run Your Own Bot API Server
70
- - name: ul
71
- content:
72
- - Bot API source code is now available at telegram-bot-api. You can now run your own Bot API server locally, boosting your bots' performance (check this out to see if this will benefit your project).
73
- - Added the method logOut, which can be used to log out from the cloud Bot API server before launching your bot locally. You must log out the bot before running it locally, otherwise there is no guarantee that the bot will receive all updates.
74
- - Added the method close, which can be used to close the bot instance before moving it from one local server to another.
75
- - name: p
76
- content: Transfer Bot Ownership
77
- - name: ul
78
- content:
79
- - You can now use @BotFather to transfer your existing bots to another Telegram account.
80
- - name: p
81
- content: Webhooks
82
- - name: ul
83
- content:
84
- - Added the parameter ip_address to the method setWebhook, allowing to bypass DNS resolving and use the specified fixed IP address to send webhook requests.
85
- - Added the field ip_address to the class WebhookInfo, containing the current IP address used for webhook connections creation.
86
- - Added the ability to drop all pending updates when changing webhook URL using the parameter drop_pending_updates in the methods setWebhook and deleteWebhook.
87
- - name: p
88
- content: Working with Groups
89
- - name: ul
90
- content:
91
- - The getChat request now returns the user's bio for private chats if available.
92
- - The getChat request now returns the identifier of the linked chat for supergroups and channels, i.e. the discussion group identifier for a channel and vice versa.
93
- - The getChat request now returns the location to which the supergroup is connected (see Local Groups). Added the class ChatLocation to represent the location.
94
- - Added the parameter only_if_banned to the method unbanChatMember to allow safe unban.
95
- - name: p
96
- content: Working with Files
97
- - name: ul
98
- content:
99
- - Added the field file_name to the classes Audio and Video, containing the name of the original file.
100
- - Added the ability to disable server-side file content type detection using the parameter disable_content_type_detection in the method sendDocument and the class inputMediaDocument.
101
- - name: p
102
- content: Multiple Pinned Messages
103
- - name: ul
104
- content:
105
- - Added the ability to pin messages in private chats.
106
- - Added the parameter message_id to the method unpinChatMessage to allow unpinning of the specific pinned message.
107
- - Added the method unpinAllChatMessages, which can be used to unpin all pinned messages in a chat.
108
- - name: p
109
- content: File Albums
110
- - name: ul
111
- content:
112
- - Added support for sending and receiving audio and document albums in the method sendMediaGroup.
113
- - name: p
114
- content: Live Locations
115
- - name: ul
116
- content:
117
- - Added the field live_period to the class Location, representing a maximum period for which the live location can be updated.
118
- - 'Added support for live location heading: added the field heading to the classes Location, InlineQueryResultLocation, InputLocationMessageContent and the parameter heading to the methods sendLocation and editMessageLiveLocation.'
119
- - 'Added support for proximity alerts in live locations: added the field proximity_alert_radius to the classes Location, InlineQueryResultLocation, InputLocationMessageContent and the parameter proximity_alert_radius to the methods sendLocation and editMessageLiveLocation.'
120
- - Added the type ProximityAlertTriggered and the field proximity_alert_triggered to the class Message.
121
- - Added possibility to specify the horizontal accuracy of a location. Added the field horizontal_accuracy to the classes Location, InlineQueryResultLocation, InputLocationMessageContent and the parameter horizontal_accuracy to the methods sendLocation and editMessageLiveLocation.
122
- - name: p
123
- content: Anonymous Admins
124
- - name: ul
125
- content:
126
- - Added the field sender_chat to the class Message, containing the sender of a message which is a chat (group or channel). For backward compatibility in non-channel chats, the field from in such messages will contain the user 777000 for messages automatically forwarded to the discussion group and the user 1087968824 (@GroupAnonymousBot) for messages from anonymous group administrators.
127
- - Added the field is_anonymous to the class chatMember, which can be used to distinguish anonymous chat administrators.
128
- - Added the parameter is_anonymous to the method promoteChatMember, which allows to promote anonymous chat administrators. The bot itself should have the is_anonymous right to do this. Despite the fact that bots can have the is_anonymous right, they will never appear as anonymous in the chat. Bots can use the right only for passing to other administrators.
129
- - Added the custom title of an anonymous message sender to the class Message as author_signature.
130
- - name: p
131
- content: And More
56
+ content: Bot API 6.4
132
57
  - name: ul
133
58
  content:
134
- - Added the method copyMessage, which sends a copy of any message.
135
- - Maximum poll question length increased to 300.
136
- - Added the ability to manually specify text entities instead of specifying the parse_mode in the classes InputMediaPhoto, InputMediaVideo, InputMediaAnimation, InputMediaAudio, InputMediaDocument, InlineQueryResultPhoto, InlineQueryResultGif, InlineQueryResultMpeg4Gif, InlineQueryResultVideo, InlineQueryResultAudio, InlineQueryResultVoice, InlineQueryResultDocument, InlineQueryResultCachedPhoto, InlineQueryResultCachedGif, InlineQueryResultCachedMpeg4Gif, InlineQueryResultCachedVideo, InlineQueryResultCachedAudio, InlineQueryResultCachedVoice, InlineQueryResultCachedDocument, InputTextMessageContent and the methods sendMessage, sendPhoto, sendVideo, sendAnimation, sendAudio, sendDocument, sendVoice, sendPoll, editMessageText, editMessageCaption.
137
- - Added the fields google_place_id and google_place_type to the classes Venue, InlineQueryResultVenue, InputVenueMessageContent and the optional parameters google_place_id and google_place_type to the method sendVenue to support Google Places as a venue API provider.
138
- - Added the field allow_sending_without_reply to the methods sendMessage, sendPhoto, sendVideo, sendAnimation, sendAudio, sendDocument, sendSticker, sendVideoNote, sendVoice, sendLocation, sendVenue, sendContact, sendPoll, sendDice, sendInvoice, sendGame, sendMediaGroup to allow sending messages not a as reply if the replied-to message has already been deleted.
139
- - name: p
140
- content: And Last but bot Least
59
+ - Added the field is_persistent to the class ReplyKeyboardMarkup, allowing to control when the keyboard is shown.
60
+ - Added the parameter has_spoiler to the methods sendPhoto, sendVideo, and sendAnimation.
61
+ - Added the field has_spoiler to the classes InputMediaPhoto, InputMediaVideo, and InputMediaAnimation.
62
+ - Added the field has_media_spoiler to the class Message.
63
+ - The parameters name and icon_custom_emoji_id of the method editForumTopic are now optional. If they are omitted, the existing values are kept.
64
+ - Added the classes ForumTopicEdited, GeneralForumTopicHidden, GeneralForumTopicUnhidden, and WriteAccessAllowed and the fields forum_topic_edited, general_forum_topic_hidden, general_forum_topic_unhidden, and write_access_allowed to the class Message.
65
+ - Added the methods editGeneralForumTopic, closeGeneralForumTopic, reopenGeneralForumTopic, hideGeneralForumTopic, unhideGeneralForumTopic for managing the General topic in forums.
66
+ - Added the parameter message_thread_id to the method sendChatAction for sending chat actions to a specific message thread or a forum topic.
67
+ - Added the field has_hidden_members to the class Chat. Note that the method getChatMember is only guaranteed to work if the bot is an administrator in the chat.
68
+ - Added the field has_aggressive_anti_spam_enabled to the class Chat.
69
+ - Added Web App events qrTextReceived and clipboardTextReceived.
70
+ - Added the field platform to the class WebApp.
71
+ - Added the methods showScanQrPopup, closeScanQrPopup, and readTextFromClipboard to the class WebApp.
72
+ - Added the parameter options to the method openLink of the class WebApp.
73
+ - name: November 5, 2022
74
+ children: []
75
+ desc:
76
+ - name: p
77
+ content: Bot API 6.3
141
78
  - name: ul
142
79
  content:
143
- - Supported the new football and slot machine animations for the random dice. Choose between different animations (dice, darts, basketball, football, slot machine) by specifying the emoji parameter in the method sendDice.
80
+ - Added support for Topics in Groups.
81
+ - Added the field is_forum to the class Chat.
82
+ - Added the fields is_topic_message and message_thread_id to the class Message to allow detection of messages belonging to a forum topic and their message thread identifier.
83
+ - Added the classes ForumTopicCreated, ForumTopicClosed, and ForumTopicReopened and the fields forum_topic_created, forum_topic_closed, and forum_topic_reopened to the class Message. Note that service messages about forum topic creation can't be deleted with the deleteMessage method.
84
+ - Added the field can_manage_topics to the classes ChatAdministratorRights, ChatPermissions, ChatMemberAdministrator, and ChatMemberRestricted.
85
+ - Added the parameter can_manage_topics to the method promoteChatMember.
86
+ - Added the methods createForumTopic, editForumTopic, closeForumTopic, reopenForumTopic, deleteForumTopic, unpinAllForumTopicMessages, and getForumTopicIconStickers for forum topic management.
87
+ - Added the parameter message_thread_id to the methods sendMessage, sendPhoto, sendVideo, sendAnimation, sendAudio, sendDocument, sendSticker, sendVideoNote, sendVoice, sendLocation, sendVenue, sendContact, sendPoll, sendDice, sendInvoice, sendGame, sendMediaGroup, copyMessage, forwardMessage to support sending of messages to a forum topic.
88
+ - Added support for Multiple Usernames via the field active_usernames in the class Chat.
89
+ - Added the field emoji_status_custom_emoji_id to the class Chat.
144
90
  - name: p
145
91
  content: See earlier changes »
146
92
  desc:
@@ -174,7 +120,7 @@ children:
174
120
  - application/json (except for uploading files)
175
121
  - multipart/form-data (use to upload files)
176
122
  - name: p
177
- content: The response contains a JSON object, which always has a Boolean field 'ok' and may have an optional String field 'description' with a human-readable description of the result. If 'ok' equals true, the request was successful and the result of the query can be found in the 'result' field. In case of an unsuccessful request, 'ok' equals false and the error is explained in the 'description'. An Integer 'error_code' field is also returned, but its contents are subject to change in the future. Some errors may also have an optional field 'parameters' of the type ResponseParameters, which can help to automatically handle the error.
123
+ content: The response contains a JSON object, which always has a Boolean field 'ok' and may have an optional String field 'description' with a human-readable description of the result. If 'ok' equals True, the request was successful and the result of the query can be found in the 'result' field. In case of an unsuccessful request, 'ok' equals false and the error is explained in the 'description'. An Integer 'error_code' field is also returned, but its contents are subject to change in the future. Some errors may also have an optional field 'parameters' of the type ResponseParameters, which can help to automatically handle the error.
178
124
  - name: ul
179
125
  content:
180
126
  - All methods in the Bot API are case-insensitive.
@@ -209,16 +155,16 @@ children:
209
155
  table:
210
156
  - Field: update_id
211
157
  Type: Integer
212
- Description: The update's unique identifier. Update identifiers start from a certain positive number and increase sequentially. This ID becomes especially handy if you're using Webhooks, since it allows you to ignore repeated updates or to restore the correct update sequence, should they get out of order. If there are no new updates for at least a week, then identifier of the next update will be chosen randomly instead of sequentially.
158
+ Description: The update's unique identifier. Update identifiers start from a certain positive number and increase sequentially. This ID becomes especially handy if you're using webhooks, since it allows you to ignore repeated updates or to restore the correct update sequence, should they get out of order. If there are no new updates for at least a week, then identifier of the next update will be chosen randomly instead of sequentially.
213
159
  - Field: message
214
160
  Type: Message
215
- Description: Optional. New incoming message of any kind text, photo, sticker, etc.
161
+ Description: Optional. New incoming message of any kind - text, photo, sticker, etc.
216
162
  - Field: edited_message
217
163
  Type: Message
218
164
  Description: Optional. New version of a message that is known to the bot and was edited
219
165
  - Field: channel_post
220
166
  Type: Message
221
- Description: Optional. New incoming channel post of any kind text, photo, sticker, etc.
167
+ Description: Optional. New incoming channel post of any kind - text, photo, sticker, etc.
222
168
  - Field: edited_channel_post
223
169
  Type: Message
224
170
  Description: Optional. New version of a channel post that is known to the bot and was edited
@@ -249,18 +195,21 @@ children:
249
195
  - Field: chat_member
250
196
  Type: ChatMemberUpdated
251
197
  Description: Optional. A chat member's status was updated in a chat. The bot must be an administrator in the chat and must explicitly specify “chat_member” in the list of allowed_updates to receive these updates.
198
+ - Field: chat_join_request
199
+ Type: ChatJoinRequest
200
+ Description: Optional. A request to join the chat has been sent. The bot must have the can_invite_users administrator right in the chat to receive these updates.
252
201
  - name: getUpdates
253
202
  children: []
254
203
  desc:
255
204
  - name: p
256
- content: Use this method to receive incoming updates using long polling (wiki). An Array of Update objects is returned.
205
+ content: Use this method to receive incoming updates using long polling (wiki). Returns an Array of Update objects.
257
206
  - name: blockquote
258
207
  content: Notes1. This method will not work if an outgoing webhook is set up.2. In order to avoid getting duplicate updates, recalculate offset after each server response.
259
208
  table:
260
209
  - Parameter: offset
261
210
  Type: Integer
262
211
  Required: Optional
263
- Description: Identifier of the first update to be returned. Must be greater by one than the highest among the identifiers of previously received updates. By default, updates starting with the earliest unconfirmed update are returned. An update is considered confirmed as soon as getUpdates is called with an offset higher than its update_id. The negative offset can be specified to retrieve updates starting from -offset update from the end of the updates queue. All previous updates will forgotten.
212
+ Description: Identifier of the first update to be returned. Must be greater by one than the highest among the identifiers of previously received updates. By default, updates starting with the earliest unconfirmed update are returned. An update is considered confirmed as soon as getUpdates is called with an offset higher than its update_id. The negative offset can be specified to retrieve updates starting from -offset update from the end of the updates queue. All previous updates will be forgotten.
264
213
  - Parameter: limit
265
214
  Type: Integer
266
215
  Required: Optional
@@ -277,18 +226,18 @@ children:
277
226
  children: []
278
227
  desc:
279
228
  - name: p
280
- content: Use this method to specify a url and receive incoming updates via an outgoing webhook. Whenever there is an update for the bot, we will send an HTTPS POST request to the specified url, containing a JSON-serialized Update. In case of an unsuccessful request, we will give up after a reasonable amount of attempts. Returns True on success.
229
+ content: Use this method to specify a URL and receive incoming updates via an outgoing webhook. Whenever there is an update for the bot, we will send an HTTPS POST request to the specified URL, containing a JSON-serialized Update. In case of an unsuccessful request, we will give up after a reasonable amount of attempts. Returns True on success.
281
230
  - name: p
282
- content: If you'd like to make sure that the Webhook request comes from Telegram, we recommend using a secret path in the URL, e.g. https://www.example.com/<token>. Since nobody else knows your bot's token, you can be pretty sure it's us.
231
+ content: If you'd like to make sure that the webhook was set by you, you can specify secret data in the parameter secret_token. If specified, the request will contain a header “X-Telegram-Bot-Api-Secret-Token” with the secret token as content.
283
232
  - name: blockquote
284
233
  content: |-
285
- Notes1. You will not be able to receive updates using getUpdates for as long as an outgoing webhook is set up.2. To use a self-signed certificate, you need to upload your public key certificate using certificate parameter. Please upload as InputFile, sending a String will not work.3. Ports currently supported for Webhooks: 443, 80, 88, 8443.
286
- NEW! If you're having any trouble setting up webhooks, please check out this amazing guide to Webhooks.
234
+ Notes1. You will not be able to receive updates using getUpdates for as long as an outgoing webhook is set up.2. To use a self-signed certificate, you need to upload your public key certificate using certificate parameter. Please upload as InputFile, sending a String will not work.3. Ports currently supported for webhooks: 443, 80, 88, 8443.
235
+ If you're having any trouble setting up webhooks, please check out this amazing guide to webhooks.
287
236
  table:
288
237
  - Parameter: url
289
238
  Type: String
290
239
  Required: 'Yes'
291
- Description: HTTPS url to send updates to. Use an empty string to remove webhook integration
240
+ Description: HTTPS URL to send updates to. Use an empty string to remove webhook integration
292
241
  - Parameter: certificate
293
242
  Type: InputFile
294
243
  Required: Optional
@@ -300,7 +249,7 @@ children:
300
249
  - Parameter: max_connections
301
250
  Type: Integer
302
251
  Required: Optional
303
- Description: Maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery, 1-100. Defaults to 40. Use lower values to limit the load on your bot's server, and higher values to increase your bot's throughput.
252
+ Description: The maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery, 1-100. Defaults to 40. Use lower values to limit the load on your bot's server, and higher values to increase your bot's throughput.
304
253
  - Parameter: allowed_updates
305
254
  Type: Array of String
306
255
  Required: Optional
@@ -309,6 +258,10 @@ children:
309
258
  Type: Boolean
310
259
  Required: Optional
311
260
  Description: Pass True to drop all pending updates
261
+ - Parameter: secret_token
262
+ Type: String
263
+ Required: Optional
264
+ Description: A secret token to be sent in a header “X-Telegram-Bot-Api-Secret-Token” in every webhook request, 1-256 characters. Only characters A-Z, a-z, 0-9, _ and - are allowed. The header is useful to ensure that the request comes from a webhook set by you.
312
265
  - name: deleteWebhook
313
266
  children: []
314
267
  desc:
@@ -328,7 +281,7 @@ children:
328
281
  children: []
329
282
  desc:
330
283
  - name: p
331
- content: Contains information about the current status of a webhook.
284
+ content: Describes the current status of a webhook.
332
285
  table:
333
286
  - Field: url
334
287
  Type: String
@@ -348,15 +301,18 @@ children:
348
301
  - Field: last_error_message
349
302
  Type: String
350
303
  Description: Optional. Error message in human-readable format for the most recent error that happened when trying to deliver an update via webhook
304
+ - Field: last_synchronization_error_date
305
+ Type: Integer
306
+ Description: Optional. Unix time of the most recent error that happened when trying to synchronize available updates with Telegram datacenters
351
307
  - Field: max_connections
352
308
  Type: Integer
353
- Description: Optional. Maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery
309
+ Description: Optional. The maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery
354
310
  - Field: allowed_updates
355
311
  Type: Array of String
356
312
  Description: Optional. A list of update types the bot is subscribed to. Defaults to all update types except chat_member
357
313
  desc:
358
314
  - name: p
359
- content: There are two mutually exclusive ways of receiving updates for your bot the getUpdates method on one hand and Webhooks on the other. Incoming updates are stored on the server until the bot receives them either way, but they will not be kept longer than 24 hours.
315
+ content: There are two mutually exclusive ways of receiving updates for your bot - the getUpdates method on one hand and webhooks on the other. Incoming updates are stored on the server until the bot receives them either way, but they will not be kept longer than 24 hours.
360
316
  - name: p
361
317
  content: Regardless of which option you choose, you will receive JSON-serialized Update objects as a result.
362
318
  - name: Available types
@@ -385,6 +341,12 @@ children:
385
341
  - Field: language_code
386
342
  Type: String
387
343
  Description: Optional. IETF language tag of the user's language
344
+ - Field: is_premium
345
+ Type: 'True'
346
+ Description: Optional. True, if this user is a Telegram Premium user
347
+ - Field: added_to_attachment_menu
348
+ Type: 'True'
349
+ Description: Optional. True, if this user added the bot to the attachment menu
388
350
  - Field: can_join_groups
389
351
  Type: Boolean
390
352
  Description: Optional. True, if the bot can be invited to groups. Returned only in getMe.
@@ -418,12 +380,33 @@ children:
418
380
  - Field: last_name
419
381
  Type: String
420
382
  Description: Optional. Last name of the other party in a private chat
383
+ - Field: is_forum
384
+ Type: 'True'
385
+ Description: Optional. True, if the supergroup chat is a forum (has topics enabled)
421
386
  - Field: photo
422
387
  Type: ChatPhoto
423
388
  Description: Optional. Chat photo. Returned only in getChat.
389
+ - Field: active_usernames
390
+ Type: Array of String
391
+ Description: Optional. If non-empty, the list of all active chat usernames; for private chats, supergroups and channels. Returned only in getChat.
392
+ - Field: emoji_status_custom_emoji_id
393
+ Type: String
394
+ Description: Optional. Custom emoji identifier of emoji status of the other party in a private chat. Returned only in getChat.
424
395
  - Field: bio
425
396
  Type: String
426
397
  Description: Optional. Bio of the other party in a private chat. Returned only in getChat.
398
+ - Field: has_private_forwards
399
+ Type: 'True'
400
+ Description: Optional. True, if privacy settings of the other party in the private chat allows to use tg://user?id=<user_id> links only in chats with the user. Returned only in getChat.
401
+ - Field: has_restricted_voice_and_video_messages
402
+ Type: 'True'
403
+ Description: Optional. True, if the privacy settings of the other party restrict sending voice and video note messages in the private chat. Returned only in getChat.
404
+ - Field: join_to_send_messages
405
+ Type: 'True'
406
+ Description: Optional. True, if users need to join the supergroup before they can send messages. Returned only in getChat.
407
+ - Field: join_by_request
408
+ Type: 'True'
409
+ Description: Optional. True, if all users directly joining the supergroup need to be approved by supergroup administrators. Returned only in getChat.
427
410
  - Field: description
428
411
  Type: String
429
412
  Description: Optional. Description, for groups, supergroups and channel chats. Returned only in getChat.
@@ -438,15 +421,24 @@ children:
438
421
  Description: Optional. Default chat member permissions, for groups and supergroups. Returned only in getChat.
439
422
  - Field: slow_mode_delay
440
423
  Type: Integer
441
- Description: Optional. For supergroups, the minimum allowed delay between consecutive messages sent by each unpriviledged user. Returned only in getChat.
424
+ Description: Optional. For supergroups, the minimum allowed delay between consecutive messages sent by each unpriviledged user; in seconds. Returned only in getChat.
442
425
  - Field: message_auto_delete_time
443
426
  Type: Integer
444
427
  Description: Optional. The time after which all messages sent to the chat will be automatically deleted; in seconds. Returned only in getChat.
428
+ - Field: has_aggressive_anti_spam_enabled
429
+ Type: 'True'
430
+ Description: Optional. True, if aggressive anti-spam checks are enabled in the supergroup. The field is only available to chat administrators. Returned only in getChat.
431
+ - Field: has_hidden_members
432
+ Type: 'True'
433
+ Description: Optional. True, if non-administrators can only get the list of bots and administrators in the chat. Returned only in getChat.
434
+ - Field: has_protected_content
435
+ Type: 'True'
436
+ Description: Optional. True, if messages from the chat can't be forwarded to other chats. Returned only in getChat.
445
437
  - Field: sticker_set_name
446
438
  Type: String
447
439
  Description: Optional. For supergroups, name of group sticker set. Returned only in getChat.
448
440
  - Field: can_set_sticker_set
449
- Type: Boolean
441
+ Type: 'True'
450
442
  Description: Optional. True, if the bot can change the group sticker set. Returned only in getChat.
451
443
  - Field: linked_chat_id
452
444
  Type: Integer
@@ -463,12 +455,15 @@ children:
463
455
  - Field: message_id
464
456
  Type: Integer
465
457
  Description: Unique message identifier inside this chat
458
+ - Field: message_thread_id
459
+ Type: Integer
460
+ Description: Optional. Unique identifier of a message thread to which the message belongs; for supergroups only
466
461
  - Field: from
467
462
  Type: User
468
- Description: Optional. Sender, empty for messages sent to channels
463
+ Description: Optional. Sender of the message; empty for messages sent to channels. For backward compatibility, the field contains a fake sender user in non-channel chats, if the message was sent on behalf of a chat.
469
464
  - Field: sender_chat
470
465
  Type: Chat
471
- Description: Optional. Sender of the message, sent on behalf of a chat. The channel itself for channel messages. The supergroup itself for messages from anonymous group administrators. The linked channel for messages automatically forwarded to the discussion group
466
+ Description: Optional. Sender of the message, sent on behalf of a chat. For example, the channel itself for channel posts, the supergroup itself for messages from anonymous group administrators, the linked channel for messages automatically forwarded to the discussion group. For backward compatibility, the field from contains a fake sender user in non-channel chats, if the message was sent on behalf of a chat.
472
467
  - Field: date
473
468
  Type: Integer
474
469
  Description: Date the message was sent in Unix time
@@ -486,13 +481,19 @@ children:
486
481
  Description: Optional. For messages forwarded from channels, identifier of the original message in the channel
487
482
  - Field: forward_signature
488
483
  Type: String
489
- Description: Optional. For messages forwarded from channels, signature of the post author if present
484
+ Description: Optional. For forwarded messages that were originally sent in channels or by an anonymous chat administrator, signature of the message sender if present
490
485
  - Field: forward_sender_name
491
486
  Type: String
492
487
  Description: Optional. Sender's name for messages forwarded from users who disallow adding a link to their account in forwarded messages
493
488
  - Field: forward_date
494
489
  Type: Integer
495
490
  Description: Optional. For forwarded messages, date the original message was sent in Unix time
491
+ - Field: is_topic_message
492
+ Type: 'True'
493
+ Description: Optional. True, if the message is sent to a forum topic
494
+ - Field: is_automatic_forward
495
+ Type: 'True'
496
+ Description: Optional. True, if the message is a channel post that was automatically forwarded to the connected discussion group
496
497
  - Field: reply_to_message
497
498
  Type: Message
498
499
  Description: Optional. For replies, the original message. Note that the Message object in this field will not contain further reply_to_message fields even if it itself is a reply.
@@ -502,6 +503,9 @@ children:
502
503
  - Field: edit_date
503
504
  Type: Integer
504
505
  Description: Optional. Date the message was last edited in Unix time
506
+ - Field: has_protected_content
507
+ Type: 'True'
508
+ Description: Optional. True, if the message can't be forwarded
505
509
  - Field: media_group_id
506
510
  Type: String
507
511
  Description: Optional. The unique identifier of a media message group this message belongs to
@@ -510,7 +514,7 @@ children:
510
514
  Description: Optional. Signature of the post author for messages in channels, or the custom title of an anonymous group administrator
511
515
  - Field: text
512
516
  Type: String
513
- Description: Optional. For text messages, the actual UTF-8 text of the message, 0-4096 characters
517
+ Description: Optional. For text messages, the actual UTF-8 text of the message
514
518
  - Field: entities
515
519
  Type: Array of MessageEntity
516
520
  Description: Optional. For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text
@@ -540,10 +544,13 @@ children:
540
544
  Description: Optional. Message is a voice message, information about the file
541
545
  - Field: caption
542
546
  Type: String
543
- Description: Optional. Caption for the animation, audio, document, photo, video or voice, 0-1024 characters
547
+ Description: Optional. Caption for the animation, audio, document, photo, video or voice
544
548
  - Field: caption_entities
545
549
  Type: Array of MessageEntity
546
550
  Description: Optional. For messages with a caption, special entities like usernames, URLs, bot commands, etc. that appear in the caption
551
+ - Field: has_media_spoiler
552
+ Type: 'True'
553
+ Description: Optional. True, if the message media is covered by a spoiler animation
547
554
  - Field: contact
548
555
  Type: Contact
549
556
  Description: Optional. Message is a shared contact, information about the contact
@@ -604,27 +611,57 @@ children:
604
611
  - Field: successful_payment
605
612
  Type: SuccessfulPayment
606
613
  Description: Optional. Message is a service message about a successful payment, information about the payment. More about payments »
614
+ - Field: user_shared
615
+ Type: UserShared
616
+ Description: 'Optional. Service message: a user was shared with the bot'
617
+ - Field: chat_shared
618
+ Type: ChatShared
619
+ Description: 'Optional. Service message: a chat was shared with the bot'
607
620
  - Field: connected_website
608
621
  Type: String
609
622
  Description: Optional. The domain name of the website on which the user has logged in. More about Telegram Login »
623
+ - Field: write_access_allowed
624
+ Type: WriteAccessAllowed
625
+ Description: 'Optional. Service message: the user allowed the bot added to the attachment menu to write messages'
610
626
  - Field: passport_data
611
627
  Type: PassportData
612
628
  Description: Optional. Telegram Passport data
613
629
  - Field: proximity_alert_triggered
614
630
  Type: ProximityAlertTriggered
615
631
  Description: Optional. Service message. A user in the chat triggered another user's proximity alert while sharing Live Location.
616
- - Field: voice_chat_scheduled
617
- Type: VoiceChatScheduled
618
- Description: 'Optional. Service message: voice chat scheduled'
619
- - Field: voice_chat_started
620
- Type: VoiceChatStarted
621
- Description: 'Optional. Service message: voice chat started'
622
- - Field: voice_chat_ended
623
- Type: VoiceChatEnded
624
- Description: 'Optional. Service message: voice chat ended'
625
- - Field: voice_chat_participants_invited
626
- Type: VoiceChatParticipantsInvited
627
- Description: 'Optional. Service message: new participants invited to a voice chat'
632
+ - Field: forum_topic_created
633
+ Type: ForumTopicCreated
634
+ Description: 'Optional. Service message: forum topic created'
635
+ - Field: forum_topic_edited
636
+ Type: ForumTopicEdited
637
+ Description: 'Optional. Service message: forum topic edited'
638
+ - Field: forum_topic_closed
639
+ Type: ForumTopicClosed
640
+ Description: 'Optional. Service message: forum topic closed'
641
+ - Field: forum_topic_reopened
642
+ Type: ForumTopicReopened
643
+ Description: 'Optional. Service message: forum topic reopened'
644
+ - Field: general_forum_topic_hidden
645
+ Type: GeneralForumTopicHidden
646
+ Description: 'Optional. Service message: the ''General'' forum topic hidden'
647
+ - Field: general_forum_topic_unhidden
648
+ Type: GeneralForumTopicUnhidden
649
+ Description: 'Optional. Service message: the ''General'' forum topic unhidden'
650
+ - Field: video_chat_scheduled
651
+ Type: VideoChatScheduled
652
+ Description: 'Optional. Service message: video chat scheduled'
653
+ - Field: video_chat_started
654
+ Type: VideoChatStarted
655
+ Description: 'Optional. Service message: video chat started'
656
+ - Field: video_chat_ended
657
+ Type: VideoChatEnded
658
+ Description: 'Optional. Service message: video chat ended'
659
+ - Field: video_chat_participants_invited
660
+ Type: VideoChatParticipantsInvited
661
+ Description: 'Optional. Service message: new participants invited to a video chat'
662
+ - Field: web_app_data
663
+ Type: WebAppData
664
+ Description: 'Optional. Service message: data sent by a Web App'
628
665
  - Field: reply_markup
629
666
  Type: InlineKeyboardMarkup
630
667
  Description: Optional. Inline keyboard attached to the message. login_url buttons are represented as ordinary url buttons.
@@ -645,7 +682,7 @@ children:
645
682
  table:
646
683
  - Field: type
647
684
  Type: String
648
- Description: Type of the entity. Can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames)
685
+ Description: Type of the entity. Currently, can be “mention” (@username), “hashtag” (#hashtag), “cashtag” ($USD), “bot_command” (/start@jobs_bot), “url” (https://telegram.org), “email” (do-not-reply@telegram.org), “phone_number” (+1-212-555-0123), “bold” (bold text), “italic” (italic text), “underline” (underlined text), “strikethrough” (strikethrough text), “spoiler” (spoiler message), “code” (monowidth string), “pre” (monowidth block), “text_link” (for clickable text URLs), “text_mention” (for users without usernames), “custom_emoji” (for inline custom emoji stickers)
649
686
  - Field: offset
650
687
  Type: Integer
651
688
  Description: Offset in UTF-16 code units to the start of the entity
@@ -654,13 +691,16 @@ children:
654
691
  Description: Length of the entity in UTF-16 code units
655
692
  - Field: url
656
693
  Type: String
657
- Description: Optional. For “text_link” only, url that will be opened after user taps on the text
694
+ Description: Optional. For “text_link” only, URL that will be opened after user taps on the text
658
695
  - Field: user
659
696
  Type: User
660
697
  Description: Optional. For “text_mention” only, the mentioned user
661
698
  - Field: language
662
699
  Type: String
663
700
  Description: Optional. For “pre” only, the programming language of the entity text
701
+ - Field: custom_emoji_id
702
+ Type: String
703
+ Description: Optional. For “custom_emoji” only, unique identifier of the custom emoji. Use getCustomEmojiStickers to get full information about the sticker
664
704
  - name: PhotoSize
665
705
  children: []
666
706
  desc:
@@ -681,7 +721,7 @@ children:
681
721
  Description: Photo height
682
722
  - Field: file_size
683
723
  Type: Integer
684
- Description: Optional. File size
724
+ Description: Optional. File size in bytes
685
725
  - name: Animation
686
726
  children: []
687
727
  desc:
@@ -703,7 +743,7 @@ children:
703
743
  - Field: duration
704
744
  Type: Integer
705
745
  Description: Duration of the video in seconds as defined by sender
706
- - Field: thumb
746
+ - Field: thumbnail
707
747
  Type: PhotoSize
708
748
  Description: Optional. Animation thumbnail as defined by sender
709
749
  - Field: file_name
@@ -714,7 +754,7 @@ children:
714
754
  Description: Optional. MIME type of the file as defined by sender
715
755
  - Field: file_size
716
756
  Type: Integer
717
- Description: Optional. File size
757
+ Description: Optional. File size in bytes. It can be bigger than 2^31 and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this value.
718
758
  - name: Audio
719
759
  children: []
720
760
  desc:
@@ -744,8 +784,8 @@ children:
744
784
  Description: Optional. MIME type of the file as defined by sender
745
785
  - Field: file_size
746
786
  Type: Integer
747
- Description: Optional. File size
748
- - Field: thumb
787
+ Description: Optional. File size in bytes. It can be bigger than 2^31 and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this value.
788
+ - Field: thumbnail
749
789
  Type: PhotoSize
750
790
  Description: Optional. Thumbnail of the album cover to which the music file belongs
751
791
  - name: Document
@@ -760,7 +800,7 @@ children:
760
800
  - Field: file_unique_id
761
801
  Type: String
762
802
  Description: Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.
763
- - Field: thumb
803
+ - Field: thumbnail
764
804
  Type: PhotoSize
765
805
  Description: Optional. Document thumbnail as defined by sender
766
806
  - Field: file_name
@@ -771,7 +811,7 @@ children:
771
811
  Description: Optional. MIME type of the file as defined by sender
772
812
  - Field: file_size
773
813
  Type: Integer
774
- Description: Optional. File size
814
+ Description: Optional. File size in bytes. It can be bigger than 2^31 and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this value.
775
815
  - name: Video
776
816
  children: []
777
817
  desc:
@@ -793,7 +833,7 @@ children:
793
833
  - Field: duration
794
834
  Type: Integer
795
835
  Description: Duration of the video in seconds as defined by sender
796
- - Field: thumb
836
+ - Field: thumbnail
797
837
  Type: PhotoSize
798
838
  Description: Optional. Video thumbnail
799
839
  - Field: file_name
@@ -801,10 +841,10 @@ children:
801
841
  Description: Optional. Original filename as defined by sender
802
842
  - Field: mime_type
803
843
  Type: String
804
- Description: Optional. Mime type of a file as defined by sender
844
+ Description: Optional. MIME type of the file as defined by sender
805
845
  - Field: file_size
806
846
  Type: Integer
807
- Description: Optional. File size
847
+ Description: Optional. File size in bytes. It can be bigger than 2^31 and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this value.
808
848
  - name: VideoNote
809
849
  children: []
810
850
  desc:
@@ -823,12 +863,12 @@ children:
823
863
  - Field: duration
824
864
  Type: Integer
825
865
  Description: Duration of the video in seconds as defined by sender
826
- - Field: thumb
866
+ - Field: thumbnail
827
867
  Type: PhotoSize
828
868
  Description: Optional. Video thumbnail
829
869
  - Field: file_size
830
870
  Type: Integer
831
- Description: Optional. File size
871
+ Description: Optional. File size in bytes
832
872
  - name: Voice
833
873
  children: []
834
874
  desc:
@@ -849,7 +889,7 @@ children:
849
889
  Description: Optional. MIME type of the file as defined by sender
850
890
  - Field: file_size
851
891
  Type: Integer
852
- Description: Optional. File size
892
+ Description: Optional. File size in bytes. It can be bigger than 2^31 and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this value.
853
893
  - name: Contact
854
894
  children: []
855
895
  desc:
@@ -972,13 +1012,13 @@ children:
972
1012
  Description: Optional. The radius of uncertainty for the location, measured in meters; 0-1500
973
1013
  - Field: live_period
974
1014
  Type: Integer
975
- Description: Optional. Time relative to the message sending date, during which the location can be updated, in seconds. For active live locations only.
1015
+ Description: Optional. Time relative to the message sending date, during which the location can be updated; in seconds. For active live locations only.
976
1016
  - Field: heading
977
1017
  Type: Integer
978
1018
  Description: Optional. The direction in which user is moving, in degrees; 1-360. For active live locations only.
979
1019
  - Field: proximity_alert_radius
980
1020
  Type: Integer
981
- Description: Optional. Maximum distance for proximity alerts about approaching another chat member, in meters. For sent live locations only.
1021
+ Description: Optional. The maximum distance for proximity alerts about approaching another chat member, in meters. For sent live locations only.
982
1022
  - name: Venue
983
1023
  children: []
984
1024
  desc:
@@ -1006,6 +1046,18 @@ children:
1006
1046
  - Field: google_place_type
1007
1047
  Type: String
1008
1048
  Description: Optional. Google Places type of the venue. (See supported types.)
1049
+ - name: WebAppData
1050
+ children: []
1051
+ desc:
1052
+ - name: p
1053
+ content: Describes data sent from a Web App to the bot.
1054
+ table:
1055
+ - Field: data
1056
+ Type: String
1057
+ Description: The data. Be aware that a bad client can send arbitrary data in this field.
1058
+ - Field: button_text
1059
+ Type: String
1060
+ Description: Text of the web_app keyboard button from which the Web App was opened. Be aware that a bad client can send arbitrary data in this field.
1009
1061
  - name: ProximityAlertTriggered
1010
1062
  children: []
1011
1063
  desc:
@@ -1029,39 +1081,115 @@ children:
1029
1081
  table:
1030
1082
  - Field: message_auto_delete_time
1031
1083
  Type: Integer
1032
- Description: New auto-delete time for messages in the chat
1033
- - name: VoiceChatScheduled
1084
+ Description: New auto-delete time for messages in the chat; in seconds
1085
+ - name: ForumTopicCreated
1086
+ children: []
1087
+ desc:
1088
+ - name: p
1089
+ content: This object represents a service message about a new forum topic created in the chat.
1090
+ table:
1091
+ - Field: name
1092
+ Type: String
1093
+ Description: Name of the topic
1094
+ - Field: icon_color
1095
+ Type: Integer
1096
+ Description: Color of the topic icon in RGB format
1097
+ - Field: icon_custom_emoji_id
1098
+ Type: String
1099
+ Description: Optional. Unique identifier of the custom emoji shown as the topic icon
1100
+ - name: ForumTopicClosed
1101
+ children: []
1102
+ desc:
1103
+ - name: p
1104
+ content: This object represents a service message about a forum topic closed in the chat. Currently holds no information.
1105
+ - name: ForumTopicEdited
1106
+ children: []
1107
+ desc:
1108
+ - name: p
1109
+ content: This object represents a service message about an edited forum topic.
1110
+ table:
1111
+ - Field: name
1112
+ Type: String
1113
+ Description: Optional. New name of the topic, if it was edited
1114
+ - Field: icon_custom_emoji_id
1115
+ Type: String
1116
+ Description: Optional. New identifier of the custom emoji shown as the topic icon, if it was edited; an empty string if the icon was removed
1117
+ - name: ForumTopicReopened
1118
+ children: []
1119
+ desc:
1120
+ - name: p
1121
+ content: This object represents a service message about a forum topic reopened in the chat. Currently holds no information.
1122
+ - name: GeneralForumTopicHidden
1123
+ children: []
1124
+ desc:
1125
+ - name: p
1126
+ content: This object represents a service message about General forum topic hidden in the chat. Currently holds no information.
1127
+ - name: GeneralForumTopicUnhidden
1128
+ children: []
1129
+ desc:
1130
+ - name: p
1131
+ content: This object represents a service message about General forum topic unhidden in the chat. Currently holds no information.
1132
+ - name: UserShared
1133
+ children: []
1134
+ desc:
1135
+ - name: p
1136
+ content: This object contains information about the user whose identifier was shared with the bot using a KeyboardButtonRequestUser button.
1137
+ table:
1138
+ - Field: request_id
1139
+ Type: Integer
1140
+ Description: Identifier of the request
1141
+ - Field: user_id
1142
+ Type: Integer
1143
+ Description: Identifier of the shared user. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a 64-bit integer or double-precision float type are safe for storing this identifier. The bot may not have access to the user and could be unable to use this identifier, unless the user is already known to the bot by some other means.
1144
+ - name: ChatShared
1145
+ children: []
1146
+ desc:
1147
+ - name: p
1148
+ content: This object contains information about the chat whose identifier was shared with the bot using a KeyboardButtonRequestChat button.
1149
+ table:
1150
+ - Field: request_id
1151
+ Type: Integer
1152
+ Description: Identifier of the request
1153
+ - Field: chat_id
1154
+ Type: Integer
1155
+ 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.
1156
+ - name: WriteAccessAllowed
1157
+ children: []
1158
+ desc:
1159
+ - name: p
1160
+ content: This object represents a service message about a user allowing a bot added to the attachment menu to write messages. Currently holds no information.
1161
+ - name: VideoChatScheduled
1034
1162
  children: []
1035
1163
  desc:
1036
1164
  - name: p
1037
- content: This object represents a service message about a voice chat scheduled in the chat.
1165
+ content: This object represents a service message about a video chat scheduled in the chat.
1038
1166
  table:
1039
1167
  - Field: start_date
1040
1168
  Type: Integer
1041
- Description: Point in time (Unix timestamp) when the voice chat is supposed to be started by a chat administrator
1042
- - name: VoiceChatStarted
1169
+ Description: Point in time (Unix timestamp) when the video chat is supposed to be started by a chat administrator
1170
+ - name: VideoChatStarted
1043
1171
  children: []
1044
1172
  desc:
1045
1173
  - name: p
1046
- content: This object represents a service message about a voice chat started in the chat. Currently holds no information.
1047
- - name: VoiceChatEnded
1174
+ content: This object represents a service message about a video chat started in the chat. Currently holds no information.
1175
+ - name: VideoChatEnded
1048
1176
  children: []
1049
1177
  desc:
1050
1178
  - name: p
1051
- content: This object represents a service message about a voice chat ended in the chat.
1179
+ content: This object represents a service message about a video chat ended in the chat.
1052
1180
  table:
1053
1181
  - Field: duration
1054
1182
  Type: Integer
1055
- Description: Voice chat duration; in seconds
1056
- - name: VoiceChatParticipantsInvited
1183
+ Description: Video chat duration in seconds
1184
+ - name: VideoChatParticipantsInvited
1057
1185
  children: []
1058
1186
  desc:
1059
1187
  - name: p
1060
- content: This object represents a service message about new members invited to a voice chat.
1188
+ content: This object represents a service message about new members invited to a video chat.
1061
1189
  table:
1062
1190
  - Field: users
1063
1191
  Type: Array of User
1064
- Description: Optional. New members that were invited to the voice chat
1192
+ Description: New members that were invited to the video chat
1065
1193
  - name: UserProfilePhotos
1066
1194
  children: []
1067
1195
  desc:
@@ -1080,7 +1208,7 @@ children:
1080
1208
  - name: p
1081
1209
  content: This object represents a file ready to be downloaded. The file can be downloaded via the link https://api.telegram.org/file/bot<token>/<file_path>. It is guaranteed that the link will be valid for at least 1 hour. When the link expires, a new one can be requested by calling getFile.
1082
1210
  - name: blockquote
1083
- content: Maximum file size to download is 20 MB
1211
+ content: The maximum file size to download is 20 MB
1084
1212
  table:
1085
1213
  - Field: file_id
1086
1214
  Type: String
@@ -1090,10 +1218,19 @@ children:
1090
1218
  Description: Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.
1091
1219
  - Field: file_size
1092
1220
  Type: Integer
1093
- Description: Optional. File size, if known
1221
+ Description: Optional. File size in bytes. It can be bigger than 2^31 and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for storing this value.
1094
1222
  - Field: file_path
1095
1223
  Type: String
1096
1224
  Description: Optional. File path. Use https://api.telegram.org/file/bot<token>/<file_path> to get the file.
1225
+ - name: WebAppInfo
1226
+ children: []
1227
+ desc:
1228
+ - name: p
1229
+ content: Describes a Web App.
1230
+ table:
1231
+ - Field: url
1232
+ Type: String
1233
+ Description: An HTTPS URL of a Web App to be opened with additional data as specified in Initializing Web Apps
1097
1234
  - name: ReplyKeyboardMarkup
1098
1235
  children: []
1099
1236
  desc:
@@ -1103,12 +1240,18 @@ children:
1103
1240
  - Field: keyboard
1104
1241
  Type: Array of Array of KeyboardButton
1105
1242
  Description: Array of button rows, each represented by an Array of KeyboardButton objects
1243
+ - Field: is_persistent
1244
+ Type: Boolean
1245
+ Description: Optional. Requests clients to always show the keyboard when the regular keyboard is hidden. Defaults to false, in which case the custom keyboard can be hidden and opened with a keyboard icon.
1106
1246
  - Field: resize_keyboard
1107
1247
  Type: Boolean
1108
1248
  Description: Optional. Requests clients to resize the keyboard vertically for optimal fit (e.g., make the keyboard smaller if there are just two rows of buttons). Defaults to false, in which case the custom keyboard is always of the same height as the app's standard keyboard.
1109
1249
  - Field: one_time_keyboard
1110
1250
  Type: Boolean
1111
- Description: Optional. Requests clients to hide the keyboard as soon as it's been used. The keyboard will still be available, but clients will automatically display the usual letter-keyboard in the chat the user can press a special button in the input field to see the custom keyboard again. Defaults to false.
1251
+ Description: Optional. Requests clients to hide the keyboard as soon as it's been used. The keyboard will still be available, but clients will automatically display the usual letter-keyboard in the chat - the user can press a special button in the input field to see the custom keyboard again. Defaults to false.
1252
+ - Field: input_field_placeholder
1253
+ Type: String
1254
+ Description: Optional. The placeholder to be shown in the input field when the keyboard is active; 1-64 characters
1112
1255
  - Field: selective
1113
1256
  Type: Boolean
1114
1257
  Description: 'Optional. Use this parameter if you want to show the keyboard to specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot''s message is a reply (has reply_to_message_id), sender of the original message.Example: A user requests to change the bot''s language, bot replies to the request with a keyboard to select the new language. Other users in the group don''t see the keyboard.'
@@ -1116,22 +1259,76 @@ children:
1116
1259
  children: []
1117
1260
  desc:
1118
1261
  - name: p
1119
- content: This object represents one button of the reply keyboard. For simple text buttons String can be used instead of this object to specify text of the button. Optional fields request_contact, request_location, and request_poll are mutually exclusive.
1262
+ content: This object represents one button of the reply keyboard. For simple text buttons, String can be used instead of this object to specify the button text. The optional fields web_app, request_user, request_chat, request_contact, request_location, and request_poll are mutually exclusive.
1120
1263
  - name: p
1121
- content: 'Note: request_contact and request_location options will only work in Telegram versions released after 9 April, 2016. Older clients will display unsupported message.Note: request_poll option will only work in Telegram versions released after 23 January, 2020. Older clients will display unsupported message.'
1264
+ content: 'Note: request_contact and request_location options will only work in Telegram versions released after 9 April, 2016. Older clients will display unsupported message.Note: request_poll option will only work in Telegram versions released after 23 January, 2020. Older clients will display unsupported message.Note: web_app option will only work in Telegram versions released after 16 April, 2022. Older clients will display unsupported message.Note: request_user and request_chat options will only work in Telegram versions released after 3 February, 2023. Older clients will display unsupported message.'
1122
1265
  table:
1123
1266
  - Field: text
1124
1267
  Type: String
1125
1268
  Description: Text of the button. If none of the optional fields are used, it will be sent as a message when the button is pressed
1269
+ - Field: request_user
1270
+ Type: KeyboardButtonRequestUser
1271
+ Description: Optional. If specified, pressing the button will open a list of suitable users. Tapping on any user will send their identifier to the bot in a “user_shared” service message. Available in private chats only.
1272
+ - Field: request_chat
1273
+ Type: KeyboardButtonRequestChat
1274
+ Description: Optional. If specified, pressing the button will open a list of suitable chats. Tapping on a chat will send its identifier to the bot in a “chat_shared” service message. Available in private chats only.
1126
1275
  - Field: request_contact
1127
1276
  Type: Boolean
1128
- Description: Optional. If True, the user's phone number will be sent as a contact when the button is pressed. Available in private chats only
1277
+ Description: Optional. If True, the user's phone number will be sent as a contact when the button is pressed. Available in private chats only.
1129
1278
  - Field: request_location
1130
1279
  Type: Boolean
1131
- Description: Optional. If True, the user's current location will be sent when the button is pressed. Available in private chats only
1280
+ Description: Optional. If True, the user's current location will be sent when the button is pressed. Available in private chats only.
1132
1281
  - Field: request_poll
1133
1282
  Type: KeyboardButtonPollType
1134
- Description: Optional. If specified, the user will be asked to create a poll and send it to the bot when the button is pressed. Available in private chats only
1283
+ Description: Optional. If specified, the user will be asked to create a poll and send it to the bot when the button is pressed. Available in private chats only.
1284
+ - Field: web_app
1285
+ Type: WebAppInfo
1286
+ Description: Optional. If specified, the described Web App will be launched when the button is pressed. The Web App will be able to send a “web_app_data” service message. Available in private chats only.
1287
+ - name: KeyboardButtonRequestUser
1288
+ children: []
1289
+ desc:
1290
+ - name: p
1291
+ content: This object defines the criteria used to request a suitable user. The identifier of the selected user will be shared with the bot when the corresponding button is pressed. More about requesting users »
1292
+ table:
1293
+ - Field: request_id
1294
+ Type: Integer
1295
+ Description: Signed 32-bit identifier of the request, which will be received back in the UserShared object. Must be unique within the message
1296
+ - Field: user_is_bot
1297
+ Type: Boolean
1298
+ Description: Optional. Pass True to request a bot, pass False to request a regular user. If not specified, no additional restrictions are applied.
1299
+ - Field: user_is_premium
1300
+ Type: Boolean
1301
+ Description: Optional. Pass True to request a premium user, pass False to request a non-premium user. If not specified, no additional restrictions are applied.
1302
+ - name: KeyboardButtonRequestChat
1303
+ children: []
1304
+ desc:
1305
+ - name: p
1306
+ content: 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 »
1307
+ table:
1308
+ - Field: request_id
1309
+ Type: Integer
1310
+ Description: Signed 32-bit identifier of the request, which will be received back in the ChatShared object. Must be unique within the message
1311
+ - Field: chat_is_channel
1312
+ Type: Boolean
1313
+ Description: Pass True to request a channel chat, pass False to request a group or a supergroup chat.
1314
+ - Field: chat_is_forum
1315
+ Type: Boolean
1316
+ Description: Optional. Pass True to request a forum supergroup, pass False to request a non-forum chat. If not specified, no additional restrictions are applied.
1317
+ - Field: chat_has_username
1318
+ Type: Boolean
1319
+ Description: Optional. Pass True to request a supergroup or a channel with a username, pass False to request a chat without a username. If not specified, no additional restrictions are applied.
1320
+ - Field: chat_is_created
1321
+ Type: Boolean
1322
+ Description: Optional. Pass True to request a chat owned by the user. Otherwise, no additional restrictions are applied.
1323
+ - Field: user_administrator_rights
1324
+ Type: ChatAdministratorRights
1325
+ Description: Optional. A JSON-serialized object listing the required administrator rights of the user in the chat. The rights must be a superset of bot_administrator_rights. If not specified, no additional restrictions are applied.
1326
+ - Field: bot_administrator_rights
1327
+ Type: ChatAdministratorRights
1328
+ Description: Optional. A JSON-serialized object listing the required administrator rights of the bot in the chat. The rights must be a subset of user_administrator_rights. If not specified, no additional restrictions are applied.
1329
+ - Field: bot_is_member
1330
+ Type: Boolean
1331
+ Description: Optional. Pass True to request a chat with the bot as a member. Otherwise, no additional restrictions are applied.
1135
1332
  - name: KeyboardButtonPollType
1136
1333
  children: []
1137
1334
  desc:
@@ -1175,25 +1372,28 @@ children:
1175
1372
  Description: Label text on the button
1176
1373
  - Field: url
1177
1374
  Type: String
1178
- Description: Optional. HTTP or tg:// url to be opened when button is pressed
1179
- - Field: login_url
1180
- Type: LoginUrl
1181
- Description: Optional. An HTTP URL used to automatically authorize the user. Can be used as a replacement for the Telegram Login Widget.
1375
+ Description: Optional. HTTP or tg:// URL to be opened when the button is pressed. Links tg://user?id=<user_id> can be used to mention a user by their ID without using a username, if this is allowed by their privacy settings.
1182
1376
  - Field: callback_data
1183
1377
  Type: String
1184
1378
  Description: Optional. Data to be sent in a callback query to the bot when button is pressed, 1-64 bytes
1379
+ - Field: web_app
1380
+ Type: WebAppInfo
1381
+ Description: Optional. Description of the Web App that will be launched when the user presses the button. The Web App will be able to send an arbitrary message on behalf of the user using the method answerWebAppQuery. Available only in private chats between a user and the bot.
1382
+ - Field: login_url
1383
+ Type: LoginUrl
1384
+ Description: Optional. An HTTPS URL used to automatically authorize the user. Can be used as a replacement for the Telegram Login Widget.
1185
1385
  - Field: switch_inline_query
1186
1386
  Type: String
1187
- Description: 'Optional. If set, pressing the button will prompt the user to select one of their chats, open that chat and insert the bot''s username and the specified inline query in the input field. Can be empty, in which case just the bot''s username will be inserted.Note: This offers an easy way for users to start using your bot in inline mode when they are currently in a private chat with it. Especially useful when combined with switch_pm… actions in this case the user will be automatically returned to the chat they switched from, skipping the chat selection screen.'
1387
+ Description: 'Optional. If set, pressing the button will prompt the user to select one of their chats, open that chat and insert the bot''s username and the specified inline query in the input field. May be empty, in which case just the bot''s username will be inserted.Note: This offers an easy way for users to start using your bot in inline mode when they are currently in a private chat with it. Especially useful when combined with switch_pm… actions - in this case the user will be automatically returned to the chat they switched from, skipping the chat selection screen.'
1188
1388
  - Field: switch_inline_query_current_chat
1189
1389
  Type: String
1190
- Description: Optional. If set, pressing the button will insert the bot's username and the specified inline query in the current chat's input field. Can be empty, in which case only the bot's username will be inserted.This offers a quick way for the user to open your bot in inline mode in the same chat good for selecting something from multiple options.
1390
+ Description: Optional. If set, pressing the button will insert the bot's username and the specified inline query in the current chat's input field. May be empty, in which case only the bot's username will be inserted.This offers a quick way for the user to open your bot in inline mode in the same chat - good for selecting something from multiple options.
1191
1391
  - Field: callback_game
1192
1392
  Type: CallbackGame
1193
1393
  Description: 'Optional. Description of the game that will be launched when the user presses the button.NOTE: This type of button must always be the first button in the first row.'
1194
1394
  - Field: pay
1195
1395
  Type: Boolean
1196
- Description: 'Optional. Specify True, to send a Pay button.NOTE: This type of button must always be the first button in the first row.'
1396
+ Description: 'Optional. Specify True, to send a Pay button.NOTE: This type of button must always be the first button in the first row and can only be used in invoice messages.'
1197
1397
  - name: LoginUrl
1198
1398
  children: []
1199
1399
  desc:
@@ -1206,7 +1406,7 @@ children:
1206
1406
  table:
1207
1407
  - Field: url
1208
1408
  Type: String
1209
- Description: 'An HTTP URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in Receiving authorization data.NOTE: You must always check the hash of the received data to verify the authentication and the integrity of the data as described in Checking authorization.'
1409
+ Description: 'An HTTPS URL to be opened with user authorization data added to the query string when the button is pressed. If the user refuses to provide authorization data, the original URL without information about the user will be opened. The data added is the same as described in Receiving authorization data.NOTE: You must always check the hash of the received data to verify the authentication and the integrity of the data as described in Checking authorization.'
1210
1410
  - Field: forward_text
1211
1411
  Type: String
1212
1412
  Description: Optional. New text of the button in forwarded messages.
@@ -1241,7 +1441,7 @@ children:
1241
1441
  Description: Global identifier, uniquely corresponding to the chat to which the message with the callback button was sent. Useful for high scores in games.
1242
1442
  - Field: data
1243
1443
  Type: String
1244
- Description: Optional. Data associated with the callback button. Be aware that a bad client can send arbitrary data in this field.
1444
+ Description: Optional. Data associated with the callback button. Be aware that the message originated the query can contain no callback buttons with this data.
1245
1445
  - Field: game_short_name
1246
1446
  Type: String
1247
1447
  Description: Optional. Short name of a Game to be returned, serves as the unique identifier for the game
@@ -1257,11 +1457,14 @@ children:
1257
1457
  Explain the user how to send a command with parameters (e.g. /newpoll question answer1 answer2). May be appealing for hardcore users but lacks modern day polish.
1258
1458
  Guide the user through a step-by-step process. 'Please send me your question', 'Cool, now let's add the first answer option', 'Great. Keep adding answer options, then send /done when you're ready'.
1259
1459
 
1260
- The last option is definitely more attractive. And if you use ForceReply in your bot's questions, it will receive the user's answers even if it only receives replies, commands and mentions without any extra work for the user.
1460
+ The last option is definitely more attractive. And if you use ForceReply in your bot's questions, it will receive the user's answers even if it only receives replies, commands and mentions - without any extra work for the user.
1261
1461
  table:
1262
1462
  - Field: force_reply
1263
1463
  Type: 'True'
1264
1464
  Description: Shows reply interface to the user, as if they manually selected the bot's message and tapped 'Reply'
1465
+ - Field: input_field_placeholder
1466
+ Type: String
1467
+ Description: Optional. The placeholder to be shown in the input field when the reply is active; 1-64 characters
1265
1468
  - Field: selective
1266
1469
  Type: Boolean
1267
1470
  Description: 'Optional. Use this parameter if you want to force reply from specific users only. Targets: 1) users that are @mentioned in the text of the Message object; 2) if the bot''s message is a reply (has reply_to_message_id), sender of the original message.'
@@ -1295,157 +1498,380 @@ children:
1295
1498
  - Field: creator
1296
1499
  Type: User
1297
1500
  Description: Creator of the link
1501
+ - Field: creates_join_request
1502
+ Type: Boolean
1503
+ Description: True, if users joining the chat via the link need to be approved by chat administrators
1298
1504
  - Field: is_primary
1299
1505
  Type: Boolean
1300
1506
  Description: True, if the link is primary
1301
1507
  - Field: is_revoked
1302
1508
  Type: Boolean
1303
1509
  Description: True, if the link is revoked
1510
+ - Field: name
1511
+ Type: String
1512
+ Description: Optional. Invite link name
1304
1513
  - Field: expire_date
1305
1514
  Type: Integer
1306
1515
  Description: Optional. Point in time (Unix timestamp) when the link will expire or has been expired
1307
1516
  - Field: member_limit
1308
1517
  Type: Integer
1309
- Description: Optional. Maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
1310
- - name: ChatMember
1518
+ Description: Optional. The maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
1519
+ - Field: pending_join_request_count
1520
+ Type: Integer
1521
+ Description: Optional. Number of pending join requests created using this link
1522
+ - name: ChatAdministratorRights
1311
1523
  children: []
1312
1524
  desc:
1313
1525
  - name: p
1314
- content: This object contains information about one member of a chat.
1526
+ content: Represents the rights of an administrator in a chat.
1315
1527
  table:
1316
- - Field: user
1317
- Type: User
1318
- Description: Information about the user
1319
- - Field: status
1320
- Type: String
1321
- Description: The member's status in the chat. Can be “creator”, “administrator”, “member”, “restricted”, “left” or “kicked”
1322
- - Field: custom_title
1323
- Type: String
1324
- Description: Optional. Owner and administrators only. Custom title for this user
1325
1528
  - Field: is_anonymous
1326
1529
  Type: Boolean
1327
- Description: Optional. Owner and administrators only. True, if the user's presence in the chat is hidden
1328
- - Field: can_be_edited
1329
- Type: Boolean
1330
- Description: Optional. Administrators only. True, if the bot is allowed to edit administrator privileges of that user
1530
+ Description: True, if the user's presence in the chat is hidden
1331
1531
  - Field: can_manage_chat
1332
1532
  Type: Boolean
1333
- Description: Optional. Administrators only. True, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
1334
- - Field: can_post_messages
1335
- Type: Boolean
1336
- Description: Optional. Administrators only. True, if the administrator can post in the channel; channels only
1337
- - Field: can_edit_messages
1338
- Type: Boolean
1339
- Description: Optional. Administrators only. True, if the administrator can edit messages of other users and can pin messages; channels only
1533
+ Description: True, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
1340
1534
  - Field: can_delete_messages
1341
1535
  Type: Boolean
1342
- Description: Optional. Administrators only. True, if the administrator can delete messages of other users
1343
- - Field: can_manage_voice_chats
1536
+ Description: True, if the administrator can delete messages of other users
1537
+ - Field: can_manage_video_chats
1344
1538
  Type: Boolean
1345
- Description: Optional. Administrators only. True, if the administrator can manage voice chats
1539
+ Description: True, if the administrator can manage video chats
1346
1540
  - Field: can_restrict_members
1347
1541
  Type: Boolean
1348
- Description: Optional. Administrators only. True, if the administrator can restrict, ban or unban chat members
1542
+ Description: True, if the administrator can restrict, ban or unban chat members
1349
1543
  - Field: can_promote_members
1350
1544
  Type: Boolean
1351
- Description: Optional. Administrators only. True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that he has promoted, directly or indirectly (promoted by administrators that were appointed by the user)
1545
+ Description: True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that they have promoted, directly or indirectly (promoted by administrators that were appointed by the user)
1352
1546
  - Field: can_change_info
1353
1547
  Type: Boolean
1354
- Description: Optional. Administrators and restricted only. True, if the user is allowed to change the chat title, photo and other settings
1548
+ Description: True, if the user is allowed to change the chat title, photo and other settings
1355
1549
  - Field: can_invite_users
1356
1550
  Type: Boolean
1357
- Description: Optional. Administrators and restricted only. True, if the user is allowed to invite new users to the chat
1358
- - Field: can_pin_messages
1359
- Type: Boolean
1360
- Description: Optional. Administrators and restricted only. True, if the user is allowed to pin messages; groups and supergroups only
1361
- - Field: is_member
1362
- Type: Boolean
1363
- Description: Optional. Restricted only. True, if the user is a member of the chat at the moment of the request
1364
- - Field: can_send_messages
1365
- Type: Boolean
1366
- Description: Optional. Restricted only. True, if the user is allowed to send text messages, contacts, locations and venues
1367
- - Field: can_send_media_messages
1551
+ Description: True, if the user is allowed to invite new users to the chat
1552
+ - Field: can_post_messages
1368
1553
  Type: Boolean
1369
- Description: Optional. Restricted only. True, if the user is allowed to send audios, documents, photos, videos, video notes and voice notes
1370
- - Field: can_send_polls
1554
+ Description: Optional. True, if the administrator can post in the channel; channels only
1555
+ - Field: can_edit_messages
1371
1556
  Type: Boolean
1372
- Description: Optional. Restricted only. True, if the user is allowed to send polls
1373
- - Field: can_send_other_messages
1557
+ Description: Optional. True, if the administrator can edit messages of other users and can pin messages; channels only
1558
+ - Field: can_pin_messages
1374
1559
  Type: Boolean
1375
- Description: Optional. Restricted only. True, if the user is allowed to send animations, games, stickers and use inline bots
1376
- - Field: can_add_web_page_previews
1560
+ Description: Optional. True, if the user is allowed to pin messages; groups and supergroups only
1561
+ - Field: can_manage_topics
1377
1562
  Type: Boolean
1378
- Description: Optional. Restricted only. True, if the user is allowed to add web page previews to their messages
1379
- - Field: until_date
1380
- Type: Integer
1381
- Description: Optional. Restricted and kicked only. Date when restrictions will be lifted for this user; unix time
1382
- - name: ChatMemberUpdated
1563
+ Description: Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only
1564
+ - name: ChatMember
1383
1565
  children: []
1384
1566
  desc:
1385
1567
  - name: p
1386
- content: This object represents changes in the status of a chat member.
1568
+ content: 'This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported:'
1569
+ - name: ul
1570
+ content:
1571
+ - ChatMemberOwner
1572
+ - ChatMemberAdministrator
1573
+ - ChatMemberMember
1574
+ - ChatMemberRestricted
1575
+ - ChatMemberLeft
1576
+ - ChatMemberBanned
1577
+ - name: ChatMemberOwner
1578
+ children: []
1579
+ desc:
1580
+ - name: p
1581
+ content: Represents a chat member that owns the chat and has all administrator privileges.
1387
1582
  table:
1388
- - Field: chat
1389
- Type: Chat
1390
- Description: Chat the user belongs to
1391
- - Field: from
1583
+ - Field: status
1584
+ Type: String
1585
+ Description: The member's status in the chat, always “creator”
1586
+ - Field: user
1392
1587
  Type: User
1393
- Description: Performer of the action, which resulted in the change
1394
- - Field: date
1395
- Type: Integer
1396
- Description: Date the change was done in Unix time
1397
- - Field: old_chat_member
1398
- Type: ChatMember
1399
- Description: Previous information about the chat member
1400
- - Field: new_chat_member
1401
- Type: ChatMember
1402
- Description: New information about the chat member
1403
- - Field: invite_link
1404
- Type: ChatInviteLink
1405
- Description: Optional. Chat invite link, which was used by the user to join the chat; for joining by invite link events only.
1406
- - name: ChatPermissions
1588
+ Description: Information about the user
1589
+ - Field: is_anonymous
1590
+ Type: Boolean
1591
+ Description: True, if the user's presence in the chat is hidden
1592
+ - Field: custom_title
1593
+ Type: String
1594
+ Description: Optional. Custom title for this user
1595
+ - name: ChatMemberAdministrator
1407
1596
  children: []
1408
1597
  desc:
1409
1598
  - name: p
1410
- content: Describes actions that a non-administrator user is allowed to take in a chat.
1599
+ content: Represents a chat member that has some additional privileges.
1411
1600
  table:
1412
- - Field: can_send_messages
1601
+ - Field: status
1602
+ Type: String
1603
+ Description: The member's status in the chat, always “administrator”
1604
+ - Field: user
1605
+ Type: User
1606
+ Description: Information about the user
1607
+ - Field: can_be_edited
1413
1608
  Type: Boolean
1414
- Description: Optional. True, if the user is allowed to send text messages, contacts, locations and venues
1415
- - Field: can_send_media_messages
1609
+ Description: True, if the bot is allowed to edit administrator privileges of that user
1610
+ - Field: is_anonymous
1416
1611
  Type: Boolean
1417
- Description: Optional. True, if the user is allowed to send audios, documents, photos, videos, video notes and voice notes, implies can_send_messages
1418
- - Field: can_send_polls
1612
+ Description: True, if the user's presence in the chat is hidden
1613
+ - Field: can_manage_chat
1419
1614
  Type: Boolean
1420
- Description: Optional. True, if the user is allowed to send polls, implies can_send_messages
1421
- - Field: can_send_other_messages
1615
+ Description: True, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
1616
+ - Field: can_delete_messages
1422
1617
  Type: Boolean
1423
- Description: Optional. True, if the user is allowed to send animations, games, stickers and use inline bots, implies can_send_media_messages
1424
- - Field: can_add_web_page_previews
1618
+ Description: True, if the administrator can delete messages of other users
1619
+ - Field: can_manage_video_chats
1620
+ Type: Boolean
1621
+ Description: True, if the administrator can manage video chats
1622
+ - Field: can_restrict_members
1425
1623
  Type: Boolean
1426
- Description: Optional. True, if the user is allowed to add web page previews to their messages, implies can_send_media_messages
1624
+ Description: True, if the administrator can restrict, ban or unban chat members
1625
+ - Field: can_promote_members
1626
+ Type: Boolean
1627
+ Description: True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that they have promoted, directly or indirectly (promoted by administrators that were appointed by the user)
1427
1628
  - Field: can_change_info
1428
1629
  Type: Boolean
1429
- Description: Optional. True, if the user is allowed to change the chat title, photo and other settings. Ignored in public supergroups
1630
+ Description: True, if the user is allowed to change the chat title, photo and other settings
1430
1631
  - Field: can_invite_users
1431
1632
  Type: Boolean
1432
- Description: Optional. True, if the user is allowed to invite new users to the chat
1633
+ Description: True, if the user is allowed to invite new users to the chat
1634
+ - Field: can_post_messages
1635
+ Type: Boolean
1636
+ Description: Optional. True, if the administrator can post in the channel; channels only
1637
+ - Field: can_edit_messages
1638
+ Type: Boolean
1639
+ Description: Optional. True, if the administrator can edit messages of other users and can pin messages; channels only
1433
1640
  - Field: can_pin_messages
1434
1641
  Type: Boolean
1435
- Description: Optional. True, if the user is allowed to pin messages. Ignored in public supergroups
1436
- - name: ChatLocation
1642
+ Description: Optional. True, if the user is allowed to pin messages; groups and supergroups only
1643
+ - Field: can_manage_topics
1644
+ Type: Boolean
1645
+ Description: Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only
1646
+ - Field: custom_title
1647
+ Type: String
1648
+ Description: Optional. Custom title for this user
1649
+ - name: ChatMemberMember
1437
1650
  children: []
1438
1651
  desc:
1439
1652
  - name: p
1440
- content: Represents a location to which a chat is connected.
1653
+ content: Represents a chat member that has no additional privileges or restrictions.
1441
1654
  table:
1442
- - Field: location
1443
- Type: Location
1444
- Description: The location to which the supergroup is connected. Can't be a live location.
1445
- - Field: address
1655
+ - Field: status
1446
1656
  Type: String
1447
- Description: Location address; 1-64 characters, as defined by the chat owner
1448
- - name: BotCommand
1657
+ Description: The member's status in the chat, always “member”
1658
+ - Field: user
1659
+ Type: User
1660
+ Description: Information about the user
1661
+ - name: ChatMemberRestricted
1662
+ children: []
1663
+ desc:
1664
+ - name: p
1665
+ content: Represents a chat member that is under certain restrictions in the chat. Supergroups only.
1666
+ table:
1667
+ - Field: status
1668
+ Type: String
1669
+ Description: The member's status in the chat, always “restricted”
1670
+ - Field: user
1671
+ Type: User
1672
+ Description: Information about the user
1673
+ - Field: is_member
1674
+ Type: Boolean
1675
+ Description: True, if the user is a member of the chat at the moment of the request
1676
+ - Field: can_send_messages
1677
+ Type: Boolean
1678
+ Description: True, if the user is allowed to send text messages, contacts, invoices, locations and venues
1679
+ - Field: can_send_audios
1680
+ Type: Boolean
1681
+ Description: True, if the user is allowed to send audios
1682
+ - Field: can_send_documents
1683
+ Type: Boolean
1684
+ Description: True, if the user is allowed to send documents
1685
+ - Field: can_send_photos
1686
+ Type: Boolean
1687
+ Description: True, if the user is allowed to send photos
1688
+ - Field: can_send_videos
1689
+ Type: Boolean
1690
+ Description: True, if the user is allowed to send videos
1691
+ - Field: can_send_video_notes
1692
+ Type: Boolean
1693
+ Description: True, if the user is allowed to send video notes
1694
+ - Field: can_send_voice_notes
1695
+ Type: Boolean
1696
+ Description: True, if the user is allowed to send voice notes
1697
+ - Field: can_send_polls
1698
+ Type: Boolean
1699
+ Description: True, if the user is allowed to send polls
1700
+ - Field: can_send_other_messages
1701
+ Type: Boolean
1702
+ Description: True, if the user is allowed to send animations, games, stickers and use inline bots
1703
+ - Field: can_add_web_page_previews
1704
+ Type: Boolean
1705
+ Description: True, if the user is allowed to add web page previews to their messages
1706
+ - Field: can_change_info
1707
+ Type: Boolean
1708
+ Description: True, if the user is allowed to change the chat title, photo and other settings
1709
+ - Field: can_invite_users
1710
+ Type: Boolean
1711
+ Description: True, if the user is allowed to invite new users to the chat
1712
+ - Field: can_pin_messages
1713
+ Type: Boolean
1714
+ Description: True, if the user is allowed to pin messages
1715
+ - Field: can_manage_topics
1716
+ Type: Boolean
1717
+ Description: True, if the user is allowed to create forum topics
1718
+ - Field: until_date
1719
+ Type: Integer
1720
+ Description: Date when restrictions will be lifted for this user; unix time. If 0, then the user is restricted forever
1721
+ - name: ChatMemberLeft
1722
+ children: []
1723
+ desc:
1724
+ - name: p
1725
+ content: Represents a chat member that isn't currently a member of the chat, but may join it themselves.
1726
+ table:
1727
+ - Field: status
1728
+ Type: String
1729
+ Description: The member's status in the chat, always “left”
1730
+ - Field: user
1731
+ Type: User
1732
+ Description: Information about the user
1733
+ - name: ChatMemberBanned
1734
+ children: []
1735
+ desc:
1736
+ - name: p
1737
+ content: Represents a chat member that was banned in the chat and can't return to the chat or view chat messages.
1738
+ table:
1739
+ - Field: status
1740
+ Type: String
1741
+ Description: The member's status in the chat, always “kicked”
1742
+ - Field: user
1743
+ Type: User
1744
+ Description: Information about the user
1745
+ - Field: until_date
1746
+ Type: Integer
1747
+ Description: Date when restrictions will be lifted for this user; unix time. If 0, then the user is banned forever
1748
+ - name: ChatMemberUpdated
1749
+ children: []
1750
+ desc:
1751
+ - name: p
1752
+ content: This object represents changes in the status of a chat member.
1753
+ table:
1754
+ - Field: chat
1755
+ Type: Chat
1756
+ Description: Chat the user belongs to
1757
+ - Field: from
1758
+ Type: User
1759
+ Description: Performer of the action, which resulted in the change
1760
+ - Field: date
1761
+ Type: Integer
1762
+ Description: Date the change was done in Unix time
1763
+ - Field: old_chat_member
1764
+ Type: ChatMember
1765
+ Description: Previous information about the chat member
1766
+ - Field: new_chat_member
1767
+ Type: ChatMember
1768
+ Description: New information about the chat member
1769
+ - Field: invite_link
1770
+ Type: ChatInviteLink
1771
+ Description: Optional. Chat invite link, which was used by the user to join the chat; for joining by invite link events only.
1772
+ - name: ChatJoinRequest
1773
+ children: []
1774
+ desc:
1775
+ - name: p
1776
+ content: Represents a join request sent to a chat.
1777
+ table:
1778
+ - Field: chat
1779
+ Type: Chat
1780
+ Description: Chat to which the request was sent
1781
+ - Field: from
1782
+ Type: User
1783
+ Description: User that sent the join request
1784
+ - Field: user_chat_id
1785
+ Type: Integer
1786
+ Description: Identifier of a private chat with the user who sent the join request. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a 64-bit integer or double-precision float type are safe for storing this identifier. The bot can use this identifier for 24 hours to send messages until the join request is processed, assuming no other administrator contacted the user.
1787
+ - Field: date
1788
+ Type: Integer
1789
+ Description: Date the request was sent in Unix time
1790
+ - Field: bio
1791
+ Type: String
1792
+ Description: Optional. Bio of the user.
1793
+ - Field: invite_link
1794
+ Type: ChatInviteLink
1795
+ Description: Optional. Chat invite link that was used by the user to send the join request
1796
+ - name: ChatPermissions
1797
+ children: []
1798
+ desc:
1799
+ - name: p
1800
+ content: Describes actions that a non-administrator user is allowed to take in a chat.
1801
+ table:
1802
+ - Field: can_send_messages
1803
+ Type: Boolean
1804
+ Description: Optional. True, if the user is allowed to send text messages, contacts, invoices, locations and venues
1805
+ - Field: can_send_audios
1806
+ Type: Boolean
1807
+ Description: Optional. True, if the user is allowed to send audios
1808
+ - Field: can_send_documents
1809
+ Type: Boolean
1810
+ Description: Optional. True, if the user is allowed to send documents
1811
+ - Field: can_send_photos
1812
+ Type: Boolean
1813
+ Description: Optional. True, if the user is allowed to send photos
1814
+ - Field: can_send_videos
1815
+ Type: Boolean
1816
+ Description: Optional. True, if the user is allowed to send videos
1817
+ - Field: can_send_video_notes
1818
+ Type: Boolean
1819
+ Description: Optional. True, if the user is allowed to send video notes
1820
+ - Field: can_send_voice_notes
1821
+ Type: Boolean
1822
+ Description: Optional. True, if the user is allowed to send voice notes
1823
+ - Field: can_send_polls
1824
+ Type: Boolean
1825
+ Description: Optional. True, if the user is allowed to send polls
1826
+ - Field: can_send_other_messages
1827
+ Type: Boolean
1828
+ Description: Optional. True, if the user is allowed to send animations, games, stickers and use inline bots
1829
+ - Field: can_add_web_page_previews
1830
+ Type: Boolean
1831
+ Description: Optional. True, if the user is allowed to add web page previews to their messages
1832
+ - Field: can_change_info
1833
+ Type: Boolean
1834
+ Description: Optional. True, if the user is allowed to change the chat title, photo and other settings. Ignored in public supergroups
1835
+ - Field: can_invite_users
1836
+ Type: Boolean
1837
+ Description: Optional. True, if the user is allowed to invite new users to the chat
1838
+ - Field: can_pin_messages
1839
+ Type: Boolean
1840
+ Description: Optional. True, if the user is allowed to pin messages. Ignored in public supergroups
1841
+ - Field: can_manage_topics
1842
+ Type: Boolean
1843
+ Description: Optional. True, if the user is allowed to create forum topics. If omitted defaults to the value of can_pin_messages
1844
+ - name: ChatLocation
1845
+ children: []
1846
+ desc:
1847
+ - name: p
1848
+ content: Represents a location to which a chat is connected.
1849
+ table:
1850
+ - Field: location
1851
+ Type: Location
1852
+ Description: The location to which the supergroup is connected. Can't be a live location.
1853
+ - Field: address
1854
+ Type: String
1855
+ Description: Location address; 1-64 characters, as defined by the chat owner
1856
+ - name: ForumTopic
1857
+ children: []
1858
+ desc:
1859
+ - name: p
1860
+ content: This object represents a forum topic.
1861
+ table:
1862
+ - Field: message_thread_id
1863
+ Type: Integer
1864
+ Description: Unique identifier of the forum topic
1865
+ - Field: name
1866
+ Type: String
1867
+ Description: Name of the topic
1868
+ - Field: icon_color
1869
+ Type: Integer
1870
+ Description: Color of the topic icon in RGB format
1871
+ - Field: icon_custom_emoji_id
1872
+ Type: String
1873
+ Description: Optional. Unique identifier of the custom emoji shown as the topic icon
1874
+ - name: BotCommand
1449
1875
  children: []
1450
1876
  desc:
1451
1877
  - name: p
@@ -1453,15 +1879,198 @@ children:
1453
1879
  table:
1454
1880
  - Field: command
1455
1881
  Type: String
1456
- Description: Text of the command, 1-32 characters. Can contain only lowercase English letters, digits and underscores.
1882
+ Description: Text of the command; 1-32 characters. Can contain only lowercase English letters, digits and underscores.
1883
+ - Field: description
1884
+ Type: String
1885
+ Description: Description of the command; 1-256 characters.
1886
+ - name: BotCommandScope
1887
+ children: []
1888
+ desc:
1889
+ - name: p
1890
+ content: 'This object represents the scope to which bot commands are applied. Currently, the following 7 scopes are supported:'
1891
+ - name: ul
1892
+ content:
1893
+ - BotCommandScopeDefault
1894
+ - BotCommandScopeAllPrivateChats
1895
+ - BotCommandScopeAllGroupChats
1896
+ - BotCommandScopeAllChatAdministrators
1897
+ - BotCommandScopeChat
1898
+ - BotCommandScopeChatAdministrators
1899
+ - BotCommandScopeChatMember
1900
+ - name: Determining list of commands
1901
+ children: []
1902
+ desc:
1903
+ - name: p
1904
+ content: 'The following algorithm is used to determine the list of commands for a particular user viewing the bot menu. The first list of commands which is set is returned:'
1905
+ - name: p
1906
+ content: Commands in the chat with the bot
1907
+ - name: ul
1908
+ content:
1909
+ - botCommandScopeChat + language_code
1910
+ - botCommandScopeChat
1911
+ - botCommandScopeAllPrivateChats + language_code
1912
+ - botCommandScopeAllPrivateChats
1913
+ - botCommandScopeDefault + language_code
1914
+ - botCommandScopeDefault
1915
+ - name: p
1916
+ content: Commands in group and supergroup chats
1917
+ - name: ul
1918
+ content:
1919
+ - botCommandScopeChatMember + language_code
1920
+ - botCommandScopeChatMember
1921
+ - botCommandScopeChatAdministrators + language_code (administrators only)
1922
+ - botCommandScopeChatAdministrators (administrators only)
1923
+ - botCommandScopeChat + language_code
1924
+ - botCommandScopeChat
1925
+ - botCommandScopeAllChatAdministrators + language_code (administrators only)
1926
+ - botCommandScopeAllChatAdministrators (administrators only)
1927
+ - botCommandScopeAllGroupChats + language_code
1928
+ - botCommandScopeAllGroupChats
1929
+ - botCommandScopeDefault + language_code
1930
+ - botCommandScopeDefault
1931
+ - name: BotCommandScopeDefault
1932
+ children: []
1933
+ desc:
1934
+ - name: p
1935
+ content: Represents the default scope of bot commands. Default commands are used if no commands with a narrower scope are specified for the user.
1936
+ table:
1937
+ - Field: type
1938
+ Type: String
1939
+ Description: Scope type, must be default
1940
+ - name: BotCommandScopeAllPrivateChats
1941
+ children: []
1942
+ desc:
1943
+ - name: p
1944
+ content: Represents the scope of bot commands, covering all private chats.
1945
+ table:
1946
+ - Field: type
1947
+ Type: String
1948
+ Description: Scope type, must be all_private_chats
1949
+ - name: BotCommandScopeAllGroupChats
1950
+ children: []
1951
+ desc:
1952
+ - name: p
1953
+ content: Represents the scope of bot commands, covering all group and supergroup chats.
1954
+ table:
1955
+ - Field: type
1956
+ Type: String
1957
+ Description: Scope type, must be all_group_chats
1958
+ - name: BotCommandScopeAllChatAdministrators
1959
+ children: []
1960
+ desc:
1961
+ - name: p
1962
+ content: Represents the scope of bot commands, covering all group and supergroup chat administrators.
1963
+ table:
1964
+ - Field: type
1965
+ Type: String
1966
+ Description: Scope type, must be all_chat_administrators
1967
+ - name: BotCommandScopeChat
1968
+ children: []
1969
+ desc:
1970
+ - name: p
1971
+ content: Represents the scope of bot commands, covering a specific chat.
1972
+ table:
1973
+ - Field: type
1974
+ Type: String
1975
+ Description: Scope type, must be chat
1976
+ - Field: chat_id
1977
+ Type: Integer or String
1978
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
1979
+ - name: BotCommandScopeChatAdministrators
1980
+ children: []
1981
+ desc:
1982
+ - name: p
1983
+ content: Represents the scope of bot commands, covering all administrators of a specific group or supergroup chat.
1984
+ table:
1985
+ - Field: type
1986
+ Type: String
1987
+ Description: Scope type, must be chat_administrators
1988
+ - Field: chat_id
1989
+ Type: Integer or String
1990
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
1991
+ - name: BotCommandScopeChatMember
1992
+ children: []
1993
+ desc:
1994
+ - name: p
1995
+ content: Represents the scope of bot commands, covering a specific member of a group or supergroup chat.
1996
+ table:
1997
+ - Field: type
1998
+ Type: String
1999
+ Description: Scope type, must be chat_member
2000
+ - Field: chat_id
2001
+ Type: Integer or String
2002
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
2003
+ - Field: user_id
2004
+ Type: Integer
2005
+ Description: Unique identifier of the target user
2006
+ - name: BotDescription
2007
+ children: []
2008
+ desc:
2009
+ - name: p
2010
+ content: This object represents the bot's description.
2011
+ table:
1457
2012
  - Field: description
1458
2013
  Type: String
1459
- Description: Description of the command, 3-256 characters.
2014
+ Description: The bot's description
2015
+ - name: BotShortDescription
2016
+ children: []
2017
+ desc:
2018
+ - name: p
2019
+ content: This object represents the bot's short description.
2020
+ table:
2021
+ - Field: short_description
2022
+ Type: String
2023
+ Description: The bot's short description
2024
+ - name: MenuButton
2025
+ children: []
2026
+ desc:
2027
+ - name: p
2028
+ content: This object describes the bot's menu button in a private chat. It should be one of
2029
+ - name: ul
2030
+ content:
2031
+ - MenuButtonCommands
2032
+ - MenuButtonWebApp
2033
+ - MenuButtonDefault
2034
+ - name: p
2035
+ content: If a menu button other than MenuButtonDefault is set for a private chat, then it is applied in the chat. Otherwise the default menu button is applied. By default, the menu button opens the list of bot commands.
2036
+ - name: MenuButtonCommands
2037
+ children: []
2038
+ desc:
2039
+ - name: p
2040
+ content: Represents a menu button, which opens the bot's list of commands.
2041
+ table:
2042
+ - Field: type
2043
+ Type: String
2044
+ Description: Type of the button, must be commands
2045
+ - name: MenuButtonWebApp
2046
+ children: []
2047
+ desc:
2048
+ - name: p
2049
+ content: Represents a menu button, which launches a Web App.
2050
+ table:
2051
+ - Field: type
2052
+ Type: String
2053
+ Description: Type of the button, must be web_app
2054
+ - Field: text
2055
+ Type: String
2056
+ Description: Text on the button
2057
+ - Field: web_app
2058
+ Type: WebAppInfo
2059
+ Description: Description of the Web App that will be launched when the user presses the button. The Web App will be able to send an arbitrary message on behalf of the user using the method answerWebAppQuery.
2060
+ - name: MenuButtonDefault
2061
+ children: []
2062
+ desc:
2063
+ - name: p
2064
+ content: Describes that no specific value for the menu button was set.
2065
+ table:
2066
+ - Field: type
2067
+ Type: String
2068
+ Description: Type of the button, must be default
1460
2069
  - name: ResponseParameters
1461
2070
  children: []
1462
2071
  desc:
1463
2072
  - name: p
1464
- content: Contains information about why a request was unsuccessful.
2073
+ content: Describes why a request was unsuccessful.
1465
2074
  table:
1466
2075
  - Field: migrate_to_chat_id
1467
2076
  Type: Integer
@@ -1492,7 +2101,7 @@ children:
1492
2101
  Description: Type of the result, must be photo
1493
2102
  - Field: media
1494
2103
  Type: String
1495
- Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More info on Sending Files »
2104
+ Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More information on Sending Files »
1496
2105
  - Field: caption
1497
2106
  Type: String
1498
2107
  Description: Optional. Caption of the photo to be sent, 0-1024 characters after entities parsing
@@ -1502,6 +2111,9 @@ children:
1502
2111
  - Field: caption_entities
1503
2112
  Type: Array of MessageEntity
1504
2113
  Description: Optional. List of special entities that appear in the caption, which can be specified instead of parse_mode
2114
+ - Field: has_spoiler
2115
+ Type: Boolean
2116
+ Description: Optional. Pass True if the photo needs to be covered with a spoiler animation
1505
2117
  - name: InputMediaVideo
1506
2118
  children: []
1507
2119
  desc:
@@ -1513,10 +2125,10 @@ children:
1513
2125
  Description: Type of the result, must be video
1514
2126
  - Field: media
1515
2127
  Type: String
1516
- Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More info on Sending Files »
1517
- - Field: thumb
2128
+ Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More information on Sending Files »
2129
+ - Field: thumbnail
1518
2130
  Type: InputFile or String
1519
- Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2131
+ Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
1520
2132
  - Field: caption
1521
2133
  Type: String
1522
2134
  Description: Optional. Caption of the video to be sent, 0-1024 characters after entities parsing
@@ -1534,10 +2146,13 @@ children:
1534
2146
  Description: Optional. Video height
1535
2147
  - Field: duration
1536
2148
  Type: Integer
1537
- Description: Optional. Video duration
2149
+ Description: Optional. Video duration in seconds
1538
2150
  - Field: supports_streaming
1539
2151
  Type: Boolean
1540
- Description: Optional. Pass True, if the uploaded video is suitable for streaming
2152
+ Description: Optional. Pass True if the uploaded video is suitable for streaming
2153
+ - Field: has_spoiler
2154
+ Type: Boolean
2155
+ Description: Optional. Pass True if the video needs to be covered with a spoiler animation
1541
2156
  - name: InputMediaAnimation
1542
2157
  children: []
1543
2158
  desc:
@@ -1549,10 +2164,10 @@ children:
1549
2164
  Description: Type of the result, must be animation
1550
2165
  - Field: media
1551
2166
  Type: String
1552
- Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More info on Sending Files »
1553
- - Field: thumb
2167
+ Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More information on Sending Files »
2168
+ - Field: thumbnail
1554
2169
  Type: InputFile or String
1555
- Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2170
+ Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
1556
2171
  - Field: caption
1557
2172
  Type: String
1558
2173
  Description: Optional. Caption of the animation to be sent, 0-1024 characters after entities parsing
@@ -1570,7 +2185,10 @@ children:
1570
2185
  Description: Optional. Animation height
1571
2186
  - Field: duration
1572
2187
  Type: Integer
1573
- Description: Optional. Animation duration
2188
+ Description: Optional. Animation duration in seconds
2189
+ - Field: has_spoiler
2190
+ Type: Boolean
2191
+ Description: Optional. Pass True if the animation needs to be covered with a spoiler animation
1574
2192
  - name: InputMediaAudio
1575
2193
  children: []
1576
2194
  desc:
@@ -1582,10 +2200,10 @@ children:
1582
2200
  Description: Type of the result, must be audio
1583
2201
  - Field: media
1584
2202
  Type: String
1585
- Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More info on Sending Files »
1586
- - Field: thumb
2203
+ Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More information on Sending Files »
2204
+ - Field: thumbnail
1587
2205
  Type: InputFile or String
1588
- Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2206
+ Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
1589
2207
  - Field: caption
1590
2208
  Type: String
1591
2209
  Description: Optional. Caption of the audio to be sent, 0-1024 characters after entities parsing
@@ -1615,10 +2233,10 @@ children:
1615
2233
  Description: Type of the result, must be document
1616
2234
  - Field: media
1617
2235
  Type: String
1618
- Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More info on Sending Files »
1619
- - Field: thumb
2236
+ Description: File to send. Pass a file_id to send a file that exists on the Telegram servers (recommended), pass an HTTP URL for Telegram to get a file from the Internet, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. More information on Sending Files »
2237
+ - Field: thumbnail
1620
2238
  Type: InputFile or String
1621
- Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2239
+ Description: Optional. 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
1622
2240
  - Field: caption
1623
2241
  Type: String
1624
2242
  Description: Optional. Caption of the document to be sent, 0-1024 characters after entities parsing
@@ -1630,7 +2248,7 @@ children:
1630
2248
  Description: Optional. List of special entities that appear in the caption, which can be specified instead of parse_mode
1631
2249
  - Field: disable_content_type_detection
1632
2250
  Type: Boolean
1633
- Description: Optional. Disables automatic server-side content type detection for files uploaded using multipart/form-data. Always true, if the document is sent as part of an album.
2251
+ Description: Optional. Disables automatic server-side content type detection for files uploaded using multipart/form-data. Always True, if the document is sent as part of an album.
1634
2252
  - name: InputFile
1635
2253
  children: []
1636
2254
  desc:
@@ -1660,7 +2278,7 @@ children:
1660
2278
  - name: ul
1661
2279
  content:
1662
2280
  - When sending by URL the target file must have the correct MIME type (e.g., audio/mpeg for sendAudio, etc.).
1663
- - In sendDocument, sending by URL will currently only work for gif, pdf and zip files.
2281
+ - In sendDocument, sending by URL will currently only work for GIF, PDF and ZIP files.
1664
2282
  - To use sendVoice, the file must have the type audio/ogg and be no more than 1MB in size. 1-20MB voice notes will be sent as files.
1665
2283
  - Other configurations may work but we can't guarantee that they will.
1666
2284
  - name: Inline mode objects
@@ -1681,7 +2299,7 @@ children:
1681
2299
  children: []
1682
2300
  desc:
1683
2301
  - name: p
1684
- content: A simple method for testing your bot's auth token. Requires no parameters. Returns basic information about the bot in form of a User object.
2302
+ content: A simple method for testing your bot's authentication token. Requires no parameters. Returns basic information about the bot in form of a User object.
1685
2303
  - name: logOut
1686
2304
  children: []
1687
2305
  desc:
@@ -1702,6 +2320,10 @@ children:
1702
2320
  Type: Integer or String
1703
2321
  Required: 'Yes'
1704
2322
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2323
+ - Parameter: message_thread_id
2324
+ Type: Integer
2325
+ Required: Optional
2326
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
1705
2327
  - Parameter: text
1706
2328
  Type: String
1707
2329
  Required: 'Yes'
@@ -1713,7 +2335,7 @@ children:
1713
2335
  - Parameter: entities
1714
2336
  Type: Array of MessageEntity
1715
2337
  Required: Optional
1716
- Description: List of special entities that appear in message text, which can be specified instead of parse_mode
2338
+ Description: A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode
1717
2339
  - Parameter: disable_web_page_preview
1718
2340
  Type: Boolean
1719
2341
  Required: Optional
@@ -1722,6 +2344,10 @@ children:
1722
2344
  Type: Boolean
1723
2345
  Required: Optional
1724
2346
  Description: Sends the message silently. Users will receive a notification with no sound.
2347
+ - Parameter: protect_content
2348
+ Type: Boolean
2349
+ Required: Optional
2350
+ Description: Protects the contents of the sent message from forwarding and saving
1725
2351
  - Parameter: reply_to_message_id
1726
2352
  Type: Integer
1727
2353
  Required: Optional
@@ -1729,7 +2355,7 @@ children:
1729
2355
  - Parameter: allow_sending_without_reply
1730
2356
  Type: Boolean
1731
2357
  Required: Optional
1732
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2358
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
1733
2359
  - Parameter: reply_markup
1734
2360
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
1735
2361
  Required: Optional
@@ -1738,17 +2364,17 @@ children:
1738
2364
  children: []
1739
2365
  desc:
1740
2366
  - name: p
1741
- content: The Bot API supports basic formatting for messages. You can use bold, italic, underlined and strikethrough text, as well as inline links and pre-formatted code in your bots' messages. Telegram clients will render them accordingly. You can use either markdown-style or HTML-style formatting.
2367
+ content: The Bot API supports basic formatting for messages. You can use bold, italic, underlined, strikethrough, and spoiler text, as well as inline links and pre-formatted code in your bots' messages. Telegram clients will render them accordingly. You can specify text entities directly, or use markdown-style or HTML-style formatting.
1742
2368
  - name: p
1743
2369
  content: Note that Telegram clients will display an alert to the user before opening an inline link ('Open this link?' together with the full URL).
1744
2370
  - name: p
1745
- content: Message entities can be nested, providing following restrictions are met:- If two entities has common characters then one of them is fully contained inside another.- bold, italic, underline and strikethrough entities can contain and to be contained in any other entities, except pre and code.- All other entities can't contain each other.
2371
+ content: Message entities can be nested, providing following restrictions are met:- If two entities have common characters, then one of them is fully contained inside another.- bold, italic, underline, strikethrough, and spoiler entities can contain and can be part of any other entities, except pre and code.- All other entities can't contain each other.
1746
2372
  - name: p
1747
2373
  content: 'Links tg://user?id=<user_id> can be used to mention a user by their ID without using a username. Please note:'
1748
2374
  - name: ul
1749
2375
  content:
1750
- - These links will work only if they are used inside an inline link. For example, they will not work, when used in an inline keyboard button or in a message text.
1751
- - These mentions are only guaranteed to work if the user has contacted the bot in the past, has sent a callback query to the bot via inline button or is a member in the group where he was mentioned.
2376
+ - These links will work only if they are used inside an inline link or in an inline keyboard button. For example, they will not work, when used in a message text.
2377
+ - Unless the user is a member of the chat where they were mentioned, these mentions are only guaranteed to work if the user has contacted the bot in private in the past or has sent a callback query to the bot via an inline button and doesn't have Forwarded Messages privacy enabled for the bot.
1752
2378
  - name: h6
1753
2379
  content: MarkdownV2 style
1754
2380
  - name: p
@@ -1759,7 +2385,8 @@ children:
1759
2385
  _italic \*text_
1760
2386
  __underline__
1761
2387
  ~strikethrough~
1762
- *bold _italic bold ~italic bold strikethrough~ __underline italic bold___ bold*
2388
+ ||spoiler||
2389
+ *bold _italic bold ~italic bold strikethrough ||italic bold strikethrough spoiler||~ __underline italic bold___ bold*
1763
2390
  [inline URL](http://www.example.com/)
1764
2391
  [inline mention of a user](tg://user?id=123456789)
1765
2392
  `inline fixed-width code`
@@ -1773,7 +2400,7 @@ children:
1773
2400
  content: 'Please note:'
1774
2401
  - name: ul
1775
2402
  content:
1776
- - Any character with code between 1 and 126 inclusively can be escaped anywhere with a preceding '\' character, in which case it is treated as an ordinary character and not a part of the markup.
2403
+ - Any character with code between 1 and 126 inclusively can be escaped anywhere with a preceding '\' character, in which case it is treated as an ordinary character and not a part of the markup. This implies that '\' character usually must be escaped with a preceding '\' character.
1777
2404
  - Inside pre and code entities, all '`' and '\' characters must be escaped with a preceding '\' character.
1778
2405
  - Inside (...) part of inline link definition, all ')' and '\' must be escaped with a preceding '\' character.
1779
2406
  - In all other places characters '_', '*', '[', ']', '(', ')', '~', '`', '>', '#', '+', '-', '=', '|', '{', '}', '.', '!' must be escaped with the preceding character '\'.
@@ -1788,7 +2415,8 @@ children:
1788
2415
  <i>italic</i>, <em>italic</em>
1789
2416
  <u>underline</u>, <ins>underline</ins>
1790
2417
  <s>strikethrough</s>, <strike>strikethrough</strike>, <del>strikethrough</del>
1791
- <b>bold <i>italic bold <s>italic bold strikethrough</s> <u>underline italic bold</u></i> bold</b>
2418
+ <span class="tg-spoiler">spoiler</span>, <tg-spoiler>spoiler</tg-spoiler>
2419
+ <b>bold <i>italic bold <s>italic bold strikethrough <span class="tg-spoiler">italic bold strikethrough spoiler</span></s> <u>underline italic bold</u></i> bold</b>
1792
2420
  <a href="http://www.example.com/">inline URL</a>
1793
2421
  <a href="tg://user?id=123456789">inline mention of a user</a>
1794
2422
  <code>inline fixed-width code</code>
@@ -1839,6 +2467,10 @@ children:
1839
2467
  Type: Integer or String
1840
2468
  Required: 'Yes'
1841
2469
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2470
+ - Parameter: message_thread_id
2471
+ Type: Integer
2472
+ Required: Optional
2473
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
1842
2474
  - Parameter: from_chat_id
1843
2475
  Type: Integer or String
1844
2476
  Required: 'Yes'
@@ -1847,6 +2479,10 @@ children:
1847
2479
  Type: Boolean
1848
2480
  Required: Optional
1849
2481
  Description: Sends the message silently. Users will receive a notification with no sound.
2482
+ - Parameter: protect_content
2483
+ Type: Boolean
2484
+ Required: Optional
2485
+ Description: Protects the contents of the forwarded message from forwarding and saving
1850
2486
  - Parameter: message_id
1851
2487
  Type: Integer
1852
2488
  Required: 'Yes'
@@ -1855,12 +2491,16 @@ children:
1855
2491
  children: []
1856
2492
  desc:
1857
2493
  - name: p
1858
- content: Use this method to copy messages of any kind. Service messages and invoice messages can't be copied. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success.
2494
+ content: Use this method to copy messages of any kind. Service messages and invoice messages can't be copied. A quiz poll can be copied only if the value of the field correct_option_id is known to the bot. The method is analogous to the method forwardMessage, but the copied message doesn't have a link to the original message. Returns the MessageId of the sent message on success.
1859
2495
  table:
1860
2496
  - Parameter: chat_id
1861
2497
  Type: Integer or String
1862
2498
  Required: 'Yes'
1863
2499
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2500
+ - Parameter: message_thread_id
2501
+ Type: Integer
2502
+ Required: Optional
2503
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
1864
2504
  - Parameter: from_chat_id
1865
2505
  Type: Integer or String
1866
2506
  Required: 'Yes'
@@ -1880,11 +2520,15 @@ children:
1880
2520
  - Parameter: caption_entities
1881
2521
  Type: Array of MessageEntity
1882
2522
  Required: Optional
1883
- Description: List of special entities that appear in the new caption, which can be specified instead of parse_mode
2523
+ Description: A JSON-serialized list of special entities that appear in the new caption, which can be specified instead of parse_mode
1884
2524
  - Parameter: disable_notification
1885
2525
  Type: Boolean
1886
2526
  Required: Optional
1887
2527
  Description: Sends the message silently. Users will receive a notification with no sound.
2528
+ - Parameter: protect_content
2529
+ Type: Boolean
2530
+ Required: Optional
2531
+ Description: Protects the contents of the sent message from forwarding and saving
1888
2532
  - Parameter: reply_to_message_id
1889
2533
  Type: Integer
1890
2534
  Required: Optional
@@ -1892,7 +2536,7 @@ children:
1892
2536
  - Parameter: allow_sending_without_reply
1893
2537
  Type: Boolean
1894
2538
  Required: Optional
1895
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2539
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
1896
2540
  - Parameter: reply_markup
1897
2541
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
1898
2542
  Required: Optional
@@ -1907,10 +2551,14 @@ children:
1907
2551
  Type: Integer or String
1908
2552
  Required: 'Yes'
1909
2553
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2554
+ - Parameter: message_thread_id
2555
+ Type: Integer
2556
+ Required: Optional
2557
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
1910
2558
  - Parameter: photo
1911
2559
  Type: InputFile or String
1912
2560
  Required: 'Yes'
1913
- Description: 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. More info on Sending Files »
2561
+ Description: 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. More information on Sending Files »
1914
2562
  - Parameter: caption
1915
2563
  Type: String
1916
2564
  Required: Optional
@@ -1922,11 +2570,19 @@ children:
1922
2570
  - Parameter: caption_entities
1923
2571
  Type: Array of MessageEntity
1924
2572
  Required: Optional
1925
- Description: List of special entities that appear in the caption, which can be specified instead of parse_mode
2573
+ Description: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
2574
+ - Parameter: has_spoiler
2575
+ Type: Boolean
2576
+ Required: Optional
2577
+ Description: Pass True if the photo needs to be covered with a spoiler animation
1926
2578
  - Parameter: disable_notification
1927
2579
  Type: Boolean
1928
2580
  Required: Optional
1929
2581
  Description: Sends the message silently. Users will receive a notification with no sound.
2582
+ - Parameter: protect_content
2583
+ Type: Boolean
2584
+ Required: Optional
2585
+ Description: Protects the contents of the sent message from forwarding and saving
1930
2586
  - Parameter: reply_to_message_id
1931
2587
  Type: Integer
1932
2588
  Required: Optional
@@ -1934,7 +2590,7 @@ children:
1934
2590
  - Parameter: allow_sending_without_reply
1935
2591
  Type: Boolean
1936
2592
  Required: Optional
1937
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2593
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
1938
2594
  - Parameter: reply_markup
1939
2595
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
1940
2596
  Required: Optional
@@ -1951,10 +2607,14 @@ children:
1951
2607
  Type: Integer or String
1952
2608
  Required: 'Yes'
1953
2609
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2610
+ - Parameter: message_thread_id
2611
+ Type: Integer
2612
+ Required: Optional
2613
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
1954
2614
  - Parameter: audio
1955
2615
  Type: InputFile or String
1956
2616
  Required: 'Yes'
1957
- Description: 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. More info on Sending Files »
2617
+ Description: 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. More information on Sending Files »
1958
2618
  - Parameter: caption
1959
2619
  Type: String
1960
2620
  Required: Optional
@@ -1966,7 +2626,7 @@ children:
1966
2626
  - Parameter: caption_entities
1967
2627
  Type: Array of MessageEntity
1968
2628
  Required: Optional
1969
- Description: List of special entities that appear in the caption, which can be specified instead of parse_mode
2629
+ Description: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
1970
2630
  - Parameter: duration
1971
2631
  Type: Integer
1972
2632
  Required: Optional
@@ -1979,14 +2639,18 @@ children:
1979
2639
  Type: String
1980
2640
  Required: Optional
1981
2641
  Description: Track name
1982
- - Parameter: thumb
2642
+ - Parameter: thumbnail
1983
2643
  Type: InputFile or String
1984
2644
  Required: Optional
1985
- Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2645
+ Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
1986
2646
  - Parameter: disable_notification
1987
2647
  Type: Boolean
1988
2648
  Required: Optional
1989
2649
  Description: Sends the message silently. Users will receive a notification with no sound.
2650
+ - Parameter: protect_content
2651
+ Type: Boolean
2652
+ Required: Optional
2653
+ Description: Protects the contents of the sent message from forwarding and saving
1990
2654
  - Parameter: reply_to_message_id
1991
2655
  Type: Integer
1992
2656
  Required: Optional
@@ -1994,7 +2658,7 @@ children:
1994
2658
  - Parameter: allow_sending_without_reply
1995
2659
  Type: Boolean
1996
2660
  Required: Optional
1997
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2661
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
1998
2662
  - Parameter: reply_markup
1999
2663
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2000
2664
  Required: Optional
@@ -2009,14 +2673,18 @@ children:
2009
2673
  Type: Integer or String
2010
2674
  Required: 'Yes'
2011
2675
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2676
+ - Parameter: message_thread_id
2677
+ Type: Integer
2678
+ Required: Optional
2679
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2012
2680
  - Parameter: document
2013
2681
  Type: InputFile or String
2014
2682
  Required: 'Yes'
2015
- Description: 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. More info on Sending Files »
2016
- - Parameter: thumb
2683
+ Description: 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. More information on Sending Files »
2684
+ - Parameter: thumbnail
2017
2685
  Type: InputFile or String
2018
2686
  Required: Optional
2019
- Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2687
+ Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
2020
2688
  - Parameter: caption
2021
2689
  Type: String
2022
2690
  Required: Optional
@@ -2028,7 +2696,7 @@ children:
2028
2696
  - Parameter: caption_entities
2029
2697
  Type: Array of MessageEntity
2030
2698
  Required: Optional
2031
- Description: List of special entities that appear in the caption, which can be specified instead of parse_mode
2699
+ Description: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
2032
2700
  - Parameter: disable_content_type_detection
2033
2701
  Type: Boolean
2034
2702
  Required: Optional
@@ -2037,6 +2705,10 @@ children:
2037
2705
  Type: Boolean
2038
2706
  Required: Optional
2039
2707
  Description: Sends the message silently. Users will receive a notification with no sound.
2708
+ - Parameter: protect_content
2709
+ Type: Boolean
2710
+ Required: Optional
2711
+ Description: Protects the contents of the sent message from forwarding and saving
2040
2712
  - Parameter: reply_to_message_id
2041
2713
  Type: Integer
2042
2714
  Required: Optional
@@ -2044,7 +2716,7 @@ children:
2044
2716
  - Parameter: allow_sending_without_reply
2045
2717
  Type: Boolean
2046
2718
  Required: Optional
2047
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2719
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2048
2720
  - Parameter: reply_markup
2049
2721
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2050
2722
  Required: Optional
@@ -2053,16 +2725,20 @@ children:
2053
2725
  children: []
2054
2726
  desc:
2055
2727
  - name: p
2056
- content: Use this method to send video files, Telegram clients support mp4 videos (other formats may be sent as Document). On success, the sent Message is returned. Bots can currently send video files of up to 50 MB in size, this limit may be changed in the future.
2728
+ content: Use this method to send video files, Telegram clients support MPEG4 videos (other formats may be sent as Document). On success, the sent Message is returned. Bots can currently send video files of up to 50 MB in size, this limit may be changed in the future.
2057
2729
  table:
2058
2730
  - Parameter: chat_id
2059
2731
  Type: Integer or String
2060
2732
  Required: 'Yes'
2061
2733
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2734
+ - Parameter: message_thread_id
2735
+ Type: Integer
2736
+ Required: Optional
2737
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2062
2738
  - Parameter: video
2063
2739
  Type: InputFile or String
2064
2740
  Required: 'Yes'
2065
- Description: 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. More info on Sending Files »
2741
+ Description: 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. More information on Sending Files »
2066
2742
  - Parameter: duration
2067
2743
  Type: Integer
2068
2744
  Required: Optional
@@ -2075,10 +2751,10 @@ children:
2075
2751
  Type: Integer
2076
2752
  Required: Optional
2077
2753
  Description: Video height
2078
- - Parameter: thumb
2754
+ - Parameter: thumbnail
2079
2755
  Type: InputFile or String
2080
2756
  Required: Optional
2081
- Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2757
+ Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
2082
2758
  - Parameter: caption
2083
2759
  Type: String
2084
2760
  Required: Optional
@@ -2090,15 +2766,23 @@ children:
2090
2766
  - Parameter: caption_entities
2091
2767
  Type: Array of MessageEntity
2092
2768
  Required: Optional
2093
- Description: List of special entities that appear in the caption, which can be specified instead of parse_mode
2769
+ Description: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
2770
+ - Parameter: has_spoiler
2771
+ Type: Boolean
2772
+ Required: Optional
2773
+ Description: Pass True if the video needs to be covered with a spoiler animation
2094
2774
  - Parameter: supports_streaming
2095
2775
  Type: Boolean
2096
2776
  Required: Optional
2097
- Description: Pass True, if the uploaded video is suitable for streaming
2777
+ Description: Pass True if the uploaded video is suitable for streaming
2098
2778
  - Parameter: disable_notification
2099
2779
  Type: Boolean
2100
2780
  Required: Optional
2101
2781
  Description: Sends the message silently. Users will receive a notification with no sound.
2782
+ - Parameter: protect_content
2783
+ Type: Boolean
2784
+ Required: Optional
2785
+ Description: Protects the contents of the sent message from forwarding and saving
2102
2786
  - Parameter: reply_to_message_id
2103
2787
  Type: Integer
2104
2788
  Required: Optional
@@ -2106,7 +2790,7 @@ children:
2106
2790
  - Parameter: allow_sending_without_reply
2107
2791
  Type: Boolean
2108
2792
  Required: Optional
2109
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2793
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2110
2794
  - Parameter: reply_markup
2111
2795
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2112
2796
  Required: Optional
@@ -2121,10 +2805,14 @@ children:
2121
2805
  Type: Integer or String
2122
2806
  Required: 'Yes'
2123
2807
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2808
+ - Parameter: message_thread_id
2809
+ Type: Integer
2810
+ Required: Optional
2811
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2124
2812
  - Parameter: animation
2125
2813
  Type: InputFile or String
2126
2814
  Required: 'Yes'
2127
- Description: 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. More info on Sending Files »
2815
+ Description: 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. More information on Sending Files »
2128
2816
  - Parameter: duration
2129
2817
  Type: Integer
2130
2818
  Required: Optional
@@ -2137,10 +2825,10 @@ children:
2137
2825
  Type: Integer
2138
2826
  Required: Optional
2139
2827
  Description: Animation height
2140
- - Parameter: thumb
2828
+ - Parameter: thumbnail
2141
2829
  Type: InputFile or String
2142
2830
  Required: Optional
2143
- Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2831
+ Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
2144
2832
  - Parameter: caption
2145
2833
  Type: String
2146
2834
  Required: Optional
@@ -2152,11 +2840,19 @@ children:
2152
2840
  - Parameter: caption_entities
2153
2841
  Type: Array of MessageEntity
2154
2842
  Required: Optional
2155
- Description: List of special entities that appear in the caption, which can be specified instead of parse_mode
2843
+ Description: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
2844
+ - Parameter: has_spoiler
2845
+ Type: Boolean
2846
+ Required: Optional
2847
+ Description: Pass True if the animation needs to be covered with a spoiler animation
2156
2848
  - Parameter: disable_notification
2157
2849
  Type: Boolean
2158
2850
  Required: Optional
2159
2851
  Description: Sends the message silently. Users will receive a notification with no sound.
2852
+ - Parameter: protect_content
2853
+ Type: Boolean
2854
+ Required: Optional
2855
+ Description: Protects the contents of the sent message from forwarding and saving
2160
2856
  - Parameter: reply_to_message_id
2161
2857
  Type: Integer
2162
2858
  Required: Optional
@@ -2164,7 +2860,7 @@ children:
2164
2860
  - Parameter: allow_sending_without_reply
2165
2861
  Type: Boolean
2166
2862
  Required: Optional
2167
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2863
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2168
2864
  - Parameter: reply_markup
2169
2865
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2170
2866
  Required: Optional
@@ -2179,10 +2875,14 @@ children:
2179
2875
  Type: Integer or String
2180
2876
  Required: 'Yes'
2181
2877
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2878
+ - Parameter: message_thread_id
2879
+ Type: Integer
2880
+ Required: Optional
2881
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2182
2882
  - Parameter: voice
2183
2883
  Type: InputFile or String
2184
2884
  Required: 'Yes'
2185
- Description: 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. More info on Sending Files »
2885
+ Description: 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. More information on Sending Files »
2186
2886
  - Parameter: caption
2187
2887
  Type: String
2188
2888
  Required: Optional
@@ -2194,7 +2894,7 @@ children:
2194
2894
  - Parameter: caption_entities
2195
2895
  Type: Array of MessageEntity
2196
2896
  Required: Optional
2197
- Description: List of special entities that appear in the caption, which can be specified instead of parse_mode
2897
+ Description: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
2198
2898
  - Parameter: duration
2199
2899
  Type: Integer
2200
2900
  Required: Optional
@@ -2203,6 +2903,10 @@ children:
2203
2903
  Type: Boolean
2204
2904
  Required: Optional
2205
2905
  Description: Sends the message silently. Users will receive a notification with no sound.
2906
+ - Parameter: protect_content
2907
+ Type: Boolean
2908
+ Required: Optional
2909
+ Description: Protects the contents of the sent message from forwarding and saving
2206
2910
  - Parameter: reply_to_message_id
2207
2911
  Type: Integer
2208
2912
  Required: Optional
@@ -2210,7 +2914,7 @@ children:
2210
2914
  - Parameter: allow_sending_without_reply
2211
2915
  Type: Boolean
2212
2916
  Required: Optional
2213
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2917
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2214
2918
  - Parameter: reply_markup
2215
2919
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2216
2920
  Required: Optional
@@ -2219,16 +2923,20 @@ children:
2219
2923
  children: []
2220
2924
  desc:
2221
2925
  - name: p
2222
- content: As of v.4.0, Telegram clients support rounded square mp4 videos of up to 1 minute long. Use this method to send video messages. On success, the sent Message is returned.
2926
+ content: As of v.4.0, Telegram clients support rounded square MPEG4 videos of up to 1 minute long. Use this method to send video messages. On success, the sent Message is returned.
2223
2927
  table:
2224
2928
  - Parameter: chat_id
2225
2929
  Type: Integer or String
2226
2930
  Required: 'Yes'
2227
2931
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2932
+ - Parameter: message_thread_id
2933
+ Type: Integer
2934
+ Required: Optional
2935
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2228
2936
  - Parameter: video_note
2229
2937
  Type: InputFile or String
2230
2938
  Required: 'Yes'
2231
- Description: 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. More info on Sending Files ». Sending video notes by a URL is currently unsupported
2939
+ Description: 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. More information on Sending Files ». Sending video notes by a URL is currently unsupported
2232
2940
  - Parameter: duration
2233
2941
  Type: Integer
2234
2942
  Required: Optional
@@ -2237,14 +2945,18 @@ children:
2237
2945
  Type: Integer
2238
2946
  Required: Optional
2239
2947
  Description: Video width and height, i.e. diameter of the video message
2240
- - Parameter: thumb
2948
+ - Parameter: thumbnail
2241
2949
  Type: InputFile or String
2242
2950
  Required: Optional
2243
- Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More info on Sending Files »
2951
+ Description: 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://<file_attach_name>” if the thumbnail was uploaded using multipart/form-data under <file_attach_name>. More information on Sending Files »
2244
2952
  - Parameter: disable_notification
2245
2953
  Type: Boolean
2246
2954
  Required: Optional
2247
2955
  Description: Sends the message silently. Users will receive a notification with no sound.
2956
+ - Parameter: protect_content
2957
+ Type: Boolean
2958
+ Required: Optional
2959
+ Description: Protects the contents of the sent message from forwarding and saving
2248
2960
  - Parameter: reply_to_message_id
2249
2961
  Type: Integer
2250
2962
  Required: Optional
@@ -2252,7 +2964,7 @@ children:
2252
2964
  - Parameter: allow_sending_without_reply
2253
2965
  Type: Boolean
2254
2966
  Required: Optional
2255
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
2967
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2256
2968
  - Parameter: reply_markup
2257
2969
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2258
2970
  Required: Optional
@@ -2267,6 +2979,10 @@ children:
2267
2979
  Type: Integer or String
2268
2980
  Required: 'Yes'
2269
2981
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2982
+ - Parameter: message_thread_id
2983
+ Type: Integer
2984
+ Required: Optional
2985
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2270
2986
  - Parameter: media
2271
2987
  Type: Array of InputMediaAudio, InputMediaDocument, InputMediaPhoto and InputMediaVideo
2272
2988
  Required: 'Yes'
@@ -2275,6 +2991,10 @@ children:
2275
2991
  Type: Boolean
2276
2992
  Required: Optional
2277
2993
  Description: Sends messages silently. Users will receive a notification with no sound.
2994
+ - Parameter: protect_content
2995
+ Type: Boolean
2996
+ Required: Optional
2997
+ Description: Protects the contents of the sent messages from forwarding and saving
2278
2998
  - Parameter: reply_to_message_id
2279
2999
  Type: Integer
2280
3000
  Required: Optional
@@ -2282,7 +3002,7 @@ children:
2282
3002
  - Parameter: allow_sending_without_reply
2283
3003
  Type: Boolean
2284
3004
  Required: Optional
2285
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
3005
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2286
3006
  - name: sendLocation
2287
3007
  children: []
2288
3008
  desc:
@@ -2293,6 +3013,10 @@ children:
2293
3013
  Type: Integer or String
2294
3014
  Required: 'Yes'
2295
3015
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3016
+ - Parameter: message_thread_id
3017
+ Type: Integer
3018
+ Required: Optional
3019
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2296
3020
  - Parameter: latitude
2297
3021
  Type: Float number
2298
3022
  Required: 'Yes'
@@ -2321,6 +3045,10 @@ children:
2321
3045
  Type: Boolean
2322
3046
  Required: Optional
2323
3047
  Description: Sends the message silently. Users will receive a notification with no sound.
3048
+ - Parameter: protect_content
3049
+ Type: Boolean
3050
+ Required: Optional
3051
+ Description: Protects the contents of the sent message from forwarding and saving
2324
3052
  - Parameter: reply_to_message_id
2325
3053
  Type: Integer
2326
3054
  Required: Optional
@@ -2328,75 +3056,11 @@ children:
2328
3056
  - Parameter: allow_sending_without_reply
2329
3057
  Type: Boolean
2330
3058
  Required: Optional
2331
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
3059
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2332
3060
  - Parameter: reply_markup
2333
3061
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2334
3062
  Required: Optional
2335
3063
  Description: Additional interface options. A JSON-serialized object for an inline keyboard, custom reply keyboard, instructions to remove reply keyboard or to force a reply from the user.
2336
- - name: editMessageLiveLocation
2337
- children: []
2338
- desc:
2339
- - name: p
2340
- content: Use this method to edit live location messages. A location can be edited until its live_period expires or editing is explicitly disabled by a call to stopMessageLiveLocation. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned.
2341
- table:
2342
- - Parameter: chat_id
2343
- Type: Integer or String
2344
- Required: Optional
2345
- Description: Required if inline_message_id is not specified. Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2346
- - Parameter: message_id
2347
- Type: Integer
2348
- Required: Optional
2349
- Description: Required if inline_message_id is not specified. Identifier of the message to edit
2350
- - Parameter: inline_message_id
2351
- Type: String
2352
- Required: Optional
2353
- Description: Required if chat_id and message_id are not specified. Identifier of the inline message
2354
- - Parameter: latitude
2355
- Type: Float number
2356
- Required: 'Yes'
2357
- Description: Latitude of new location
2358
- - Parameter: longitude
2359
- Type: Float number
2360
- Required: 'Yes'
2361
- Description: Longitude of new location
2362
- - Parameter: horizontal_accuracy
2363
- Type: Float number
2364
- Required: Optional
2365
- Description: The radius of uncertainty for the location, measured in meters; 0-1500
2366
- - Parameter: heading
2367
- Type: Integer
2368
- Required: Optional
2369
- Description: Direction in which the user is moving, in degrees. Must be between 1 and 360 if specified.
2370
- - Parameter: proximity_alert_radius
2371
- Type: Integer
2372
- Required: Optional
2373
- Description: Maximum distance for proximity alerts about approaching another chat member, in meters. Must be between 1 and 100000 if specified.
2374
- - Parameter: reply_markup
2375
- Type: InlineKeyboardMarkup
2376
- Required: Optional
2377
- Description: A JSON-serialized object for a new inline keyboard.
2378
- - name: stopMessageLiveLocation
2379
- children: []
2380
- desc:
2381
- - name: p
2382
- content: Use this method to stop updating a live location message before live_period expires. On success, if the message was sent by the bot, the sent Message is returned, otherwise True is returned.
2383
- table:
2384
- - Parameter: chat_id
2385
- Type: Integer or String
2386
- Required: Optional
2387
- Description: Required if inline_message_id is not specified. Unique identifier for the target chat or username of the target channel (in the format @channelusername)
2388
- - Parameter: message_id
2389
- Type: Integer
2390
- Required: Optional
2391
- Description: Required if inline_message_id is not specified. Identifier of the message with live location to stop
2392
- - Parameter: inline_message_id
2393
- Type: String
2394
- Required: Optional
2395
- Description: Required if chat_id and message_id are not specified. Identifier of the inline message
2396
- - Parameter: reply_markup
2397
- Type: InlineKeyboardMarkup
2398
- Required: Optional
2399
- Description: A JSON-serialized object for a new inline keyboard.
2400
3064
  - name: sendVenue
2401
3065
  children: []
2402
3066
  desc:
@@ -2407,6 +3071,10 @@ children:
2407
3071
  Type: Integer or String
2408
3072
  Required: 'Yes'
2409
3073
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3074
+ - Parameter: message_thread_id
3075
+ Type: Integer
3076
+ Required: Optional
3077
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2410
3078
  - Parameter: latitude
2411
3079
  Type: Float number
2412
3080
  Required: 'Yes'
@@ -2443,6 +3111,10 @@ children:
2443
3111
  Type: Boolean
2444
3112
  Required: Optional
2445
3113
  Description: Sends the message silently. Users will receive a notification with no sound.
3114
+ - Parameter: protect_content
3115
+ Type: Boolean
3116
+ Required: Optional
3117
+ Description: Protects the contents of the sent message from forwarding and saving
2446
3118
  - Parameter: reply_to_message_id
2447
3119
  Type: Integer
2448
3120
  Required: Optional
@@ -2450,7 +3122,7 @@ children:
2450
3122
  - Parameter: allow_sending_without_reply
2451
3123
  Type: Boolean
2452
3124
  Required: Optional
2453
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
3125
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2454
3126
  - Parameter: reply_markup
2455
3127
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2456
3128
  Required: Optional
@@ -2465,6 +3137,10 @@ children:
2465
3137
  Type: Integer or String
2466
3138
  Required: 'Yes'
2467
3139
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3140
+ - Parameter: message_thread_id
3141
+ Type: Integer
3142
+ Required: Optional
3143
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2468
3144
  - Parameter: phone_number
2469
3145
  Type: String
2470
3146
  Required: 'Yes'
@@ -2485,6 +3161,10 @@ children:
2485
3161
  Type: Boolean
2486
3162
  Required: Optional
2487
3163
  Description: Sends the message silently. Users will receive a notification with no sound.
3164
+ - Parameter: protect_content
3165
+ Type: Boolean
3166
+ Required: Optional
3167
+ Description: Protects the contents of the sent message from forwarding and saving
2488
3168
  - Parameter: reply_to_message_id
2489
3169
  Type: Integer
2490
3170
  Required: Optional
@@ -2492,11 +3172,11 @@ children:
2492
3172
  - Parameter: allow_sending_without_reply
2493
3173
  Type: Boolean
2494
3174
  Required: Optional
2495
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
3175
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2496
3176
  - Parameter: reply_markup
2497
3177
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2498
3178
  Required: Optional
2499
- Description: Additional interface options. A JSON-serialized object for an inline keyboard, custom reply keyboard, instructions to remove keyboard or to force a reply from the user.
3179
+ Description: Additional interface options. A JSON-serialized object for an inline keyboard, custom reply keyboard, instructions to remove reply keyboard or to force a reply from the user.
2500
3180
  - name: sendPoll
2501
3181
  children: []
2502
3182
  desc:
@@ -2507,6 +3187,10 @@ children:
2507
3187
  Type: Integer or String
2508
3188
  Required: 'Yes'
2509
3189
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3190
+ - Parameter: message_thread_id
3191
+ Type: Integer
3192
+ Required: Optional
3193
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2510
3194
  - Parameter: question
2511
3195
  Type: String
2512
3196
  Required: 'Yes'
@@ -2542,7 +3226,7 @@ children:
2542
3226
  - Parameter: explanation_entities
2543
3227
  Type: Array of MessageEntity
2544
3228
  Required: Optional
2545
- Description: List of special entities that appear in the poll explanation, which can be specified instead of parse_mode
3229
+ Description: A JSON-serialized list of special entities that appear in the poll explanation, which can be specified instead of parse_mode
2546
3230
  - Parameter: open_period
2547
3231
  Type: Integer
2548
3232
  Required: Optional
@@ -2554,11 +3238,15 @@ children:
2554
3238
  - Parameter: is_closed
2555
3239
  Type: Boolean
2556
3240
  Required: Optional
2557
- Description: Pass True, if the poll needs to be immediately closed. This can be useful for poll preview.
3241
+ Description: Pass True if the poll needs to be immediately closed. This can be useful for poll preview.
2558
3242
  - Parameter: disable_notification
2559
3243
  Type: Boolean
2560
3244
  Required: Optional
2561
3245
  Description: Sends the message silently. Users will receive a notification with no sound.
3246
+ - Parameter: protect_content
3247
+ Type: Boolean
3248
+ Required: Optional
3249
+ Description: Protects the contents of the sent message from forwarding and saving
2562
3250
  - Parameter: reply_to_message_id
2563
3251
  Type: Integer
2564
3252
  Required: Optional
@@ -2566,7 +3254,7 @@ children:
2566
3254
  - Parameter: allow_sending_without_reply
2567
3255
  Type: Boolean
2568
3256
  Required: Optional
2569
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
3257
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2570
3258
  - Parameter: reply_markup
2571
3259
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2572
3260
  Required: Optional
@@ -2581,6 +3269,10 @@ children:
2581
3269
  Type: Integer or String
2582
3270
  Required: 'Yes'
2583
3271
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3272
+ - Parameter: message_thread_id
3273
+ Type: Integer
3274
+ Required: Optional
3275
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
2584
3276
  - Parameter: emoji
2585
3277
  Type: String
2586
3278
  Required: Optional
@@ -2589,6 +3281,10 @@ children:
2589
3281
  Type: Boolean
2590
3282
  Required: Optional
2591
3283
  Description: Sends the message silently. Users will receive a notification with no sound.
3284
+ - Parameter: protect_content
3285
+ Type: Boolean
3286
+ Required: Optional
3287
+ Description: Protects the contents of the sent message from forwarding
2592
3288
  - Parameter: reply_to_message_id
2593
3289
  Type: Integer
2594
3290
  Required: Optional
@@ -2596,7 +3292,7 @@ children:
2596
3292
  - Parameter: allow_sending_without_reply
2597
3293
  Type: Boolean
2598
3294
  Required: Optional
2599
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
3295
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
2600
3296
  - Parameter: reply_markup
2601
3297
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
2602
3298
  Required: Optional
@@ -2615,10 +3311,14 @@ children:
2615
3311
  Type: Integer or String
2616
3312
  Required: 'Yes'
2617
3313
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3314
+ - Parameter: message_thread_id
3315
+ Type: Integer
3316
+ Required: Optional
3317
+ Description: Unique identifier for the target message thread; supergroups only
2618
3318
  - Parameter: action
2619
3319
  Type: String
2620
3320
  Required: 'Yes'
2621
- Description: 'Type of action to broadcast. Choose one, depending on what the user is about to receive: typing for text messages, upload_photo for photos, record_video or upload_video for videos, record_voice or upload_voice for voice notes, upload_document for general files, find_location for location data, record_video_note or upload_video_note for video notes.'
3321
+ Description: 'Type of action to broadcast. Choose one, depending on what the user is about to receive: typing for text messages, upload_photo for photos, record_video or upload_video for videos, record_voice or upload_voice for voice notes, upload_document for general files, choose_sticker for stickers, find_location for location data, record_video_note or upload_video_note for video notes.'
2622
3322
  - name: getUserProfilePhotos
2623
3323
  children: []
2624
3324
  desc:
@@ -2641,19 +3341,19 @@ children:
2641
3341
  children: []
2642
3342
  desc:
2643
3343
  - name: p
2644
- content: Use this method to get basic info about a file and prepare it for downloading. For the moment, bots can download files of up to 20MB in size. On success, a File object is returned. The file can then be downloaded via the link https://api.telegram.org/file/bot<token>/<file_path>, where <file_path> is taken from the response. It is guaranteed that the link will be valid for at least 1 hour. When the link expires, a new one can be requested by calling getFile again.
3344
+ content: Use this method to get basic information about a file and prepare it for downloading. For the moment, bots can download files of up to 20MB in size. On success, a File object is returned. The file can then be downloaded via the link https://api.telegram.org/file/bot<token>/<file_path>, where <file_path> is taken from the response. It is guaranteed that the link will be valid for at least 1 hour. When the link expires, a new one can be requested by calling getFile again.
2645
3345
  - name: p
2646
3346
  content: 'Note: This function may not preserve the original file name and MIME type. You should save the file''s MIME type and name (if available) when the File object is received.'
2647
3347
  table:
2648
3348
  - Parameter: file_id
2649
3349
  Type: String
2650
3350
  Required: 'Yes'
2651
- Description: File identifier to get info about
2652
- - name: kickChatMember
3351
+ Description: File identifier to get information about
3352
+ - name: banChatMember
2653
3353
  children: []
2654
3354
  desc:
2655
3355
  - name: p
2656
- content: Use this method to kick a user from a group, a supergroup or a channel. In the case of supergroups and channels, the user will not be able to return to the chat on their own using invite links, etc., unless unbanned first. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns True on success.
3356
+ content: Use this method to ban a user in a group, a supergroup or a channel. In the case of supergroups and channels, the user will not be able to return to the chat on their own using invite links, etc., unless unbanned first. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns True on success.
2657
3357
  table:
2658
3358
  - Parameter: chat_id
2659
3359
  Type: Integer or String
@@ -2675,12 +3375,12 @@ children:
2675
3375
  children: []
2676
3376
  desc:
2677
3377
  - name: p
2678
- content: Use this method to unban a previously kicked user in a supergroup or channel. The user will not return to the group or channel automatically, but will be able to join via link, etc. The bot must be an administrator for this to work. By default, this method guarantees that after the call the user is not a member of the chat, but will be able to join it. So if the user is a member of the chat they will also be removed from the chat. If you don't want this, use the parameter only_if_banned. Returns True on success.
3378
+ content: Use this method to unban a previously banned user in a supergroup or channel. The user will not return to the group or channel automatically, but will be able to join via link, etc. The bot must be an administrator for this to work. By default, this method guarantees that after the call the user is not a member of the chat, but will be able to join it. So if the user is a member of the chat they will also be removed from the chat. If you don't want this, use the parameter only_if_banned. Returns True on success.
2679
3379
  table:
2680
3380
  - Parameter: chat_id
2681
3381
  Type: Integer or String
2682
3382
  Required: 'Yes'
2683
- Description: Unique identifier for the target group or username of the target supergroup or channel (in the format @username)
3383
+ Description: Unique identifier for the target group or username of the target supergroup or channel (in the format @channelusername)
2684
3384
  - Parameter: user_id
2685
3385
  Type: Integer
2686
3386
  Required: 'Yes'
@@ -2693,7 +3393,7 @@ children:
2693
3393
  children: []
2694
3394
  desc:
2695
3395
  - name: p
2696
- content: Use this method to restrict a user in a supergroup. The bot must be an administrator in the supergroup for this to work and must have the appropriate admin rights. Pass True for all permissions to lift restrictions from a user. Returns True on success.
3396
+ content: Use this method to restrict a user in a supergroup. The bot must be an administrator in the supergroup for this to work and must have the appropriate administrator rights. Pass True for all permissions to lift restrictions from a user. Returns True on success.
2697
3397
  table:
2698
3398
  - Parameter: chat_id
2699
3399
  Type: Integer or String
@@ -2707,6 +3407,10 @@ children:
2707
3407
  Type: ChatPermissions
2708
3408
  Required: 'Yes'
2709
3409
  Description: A JSON-serialized object for new user permissions
3410
+ - Parameter: use_independent_chat_permissions
3411
+ Type: Boolean
3412
+ Required: Optional
3413
+ Description: Pass True if chat permissions are set independently. Otherwise, the can_send_other_messages and can_add_web_page_previews permissions will imply the can_send_messages, can_send_audios, can_send_documents, can_send_photos, can_send_videos, can_send_video_notes, and can_send_voice_notes permissions; the can_send_polls permission will imply the can_send_messages permission.
2710
3414
  - Parameter: until_date
2711
3415
  Type: Integer
2712
3416
  Required: Optional
@@ -2715,7 +3419,7 @@ children:
2715
3419
  children: []
2716
3420
  desc:
2717
3421
  - name: p
2718
- content: Use this method to promote or demote a user in a supergroup or a channel. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Pass False for all boolean parameters to demote a user. Returns True on success.
3422
+ content: Use this method to promote or demote a user in a supergroup or a channel. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Pass False for all boolean parameters to demote a user. Returns True on success.
2719
3423
  table:
2720
3424
  - Parameter: chat_id
2721
3425
  Type: Integer or String
@@ -2728,47 +3432,51 @@ children:
2728
3432
  - Parameter: is_anonymous
2729
3433
  Type: Boolean
2730
3434
  Required: Optional
2731
- Description: Pass True, if the administrator's presence in the chat is hidden
3435
+ Description: Pass True if the administrator's presence in the chat is hidden
2732
3436
  - Parameter: can_manage_chat
2733
3437
  Type: Boolean
2734
3438
  Required: Optional
2735
- Description: Pass True, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
3439
+ Description: Pass True if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
2736
3440
  - Parameter: can_post_messages
2737
3441
  Type: Boolean
2738
3442
  Required: Optional
2739
- Description: Pass True, if the administrator can create channel posts, channels only
3443
+ Description: Pass True if the administrator can create channel posts, channels only
2740
3444
  - Parameter: can_edit_messages
2741
3445
  Type: Boolean
2742
3446
  Required: Optional
2743
- Description: Pass True, if the administrator can edit messages of other users and can pin messages, channels only
3447
+ Description: Pass True if the administrator can edit messages of other users and can pin messages, channels only
2744
3448
  - Parameter: can_delete_messages
2745
3449
  Type: Boolean
2746
3450
  Required: Optional
2747
- Description: Pass True, if the administrator can delete messages of other users
2748
- - Parameter: can_manage_voice_chats
3451
+ Description: Pass True if the administrator can delete messages of other users
3452
+ - Parameter: can_manage_video_chats
2749
3453
  Type: Boolean
2750
3454
  Required: Optional
2751
- Description: Pass True, if the administrator can manage voice chats
3455
+ Description: Pass True if the administrator can manage video chats
2752
3456
  - Parameter: can_restrict_members
2753
3457
  Type: Boolean
2754
3458
  Required: Optional
2755
- Description: Pass True, if the administrator can restrict, ban or unban chat members
3459
+ Description: Pass True if the administrator can restrict, ban or unban chat members
2756
3460
  - Parameter: can_promote_members
2757
3461
  Type: Boolean
2758
3462
  Required: Optional
2759
- Description: Pass True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that he has promoted, directly or indirectly (promoted by administrators that were appointed by him)
3463
+ Description: Pass True if the administrator can add new administrators with a subset of their own privileges or demote administrators that they have promoted, directly or indirectly (promoted by administrators that were appointed by him)
2760
3464
  - Parameter: can_change_info
2761
3465
  Type: Boolean
2762
3466
  Required: Optional
2763
- Description: Pass True, if the administrator can change chat title, photo and other settings
3467
+ Description: Pass True if the administrator can change chat title, photo and other settings
2764
3468
  - Parameter: can_invite_users
2765
3469
  Type: Boolean
2766
3470
  Required: Optional
2767
- Description: Pass True, if the administrator can invite new users to the chat
3471
+ Description: Pass True if the administrator can invite new users to the chat
2768
3472
  - Parameter: can_pin_messages
2769
3473
  Type: Boolean
2770
3474
  Required: Optional
2771
- Description: Pass True, if the administrator can pin messages, supergroups only
3475
+ Description: Pass True if the administrator can pin messages, supergroups only
3476
+ - Parameter: can_manage_topics
3477
+ Type: Boolean
3478
+ Required: Optional
3479
+ Description: Pass True if the user is allowed to create, rename, close, and reopen forum topics, supergroups only
2772
3480
  - name: setChatAdministratorCustomTitle
2773
3481
  children: []
2774
3482
  desc:
@@ -2787,11 +3495,39 @@ children:
2787
3495
  Type: String
2788
3496
  Required: 'Yes'
2789
3497
  Description: New custom title for the administrator; 0-16 characters, emoji are not allowed
3498
+ - name: banChatSenderChat
3499
+ children: []
3500
+ desc:
3501
+ - name: p
3502
+ content: Use this method to ban a channel chat in a supergroup or a channel. Until the chat is unbanned, the owner of the banned chat won't be able to send messages on behalf of any of their channels. The bot must be an administrator in the supergroup or channel for this to work and must have the appropriate administrator rights. Returns True on success.
3503
+ table:
3504
+ - Parameter: chat_id
3505
+ Type: Integer or String
3506
+ Required: 'Yes'
3507
+ Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3508
+ - Parameter: sender_chat_id
3509
+ Type: Integer
3510
+ Required: 'Yes'
3511
+ Description: Unique identifier of the target sender chat
3512
+ - name: unbanChatSenderChat
3513
+ children: []
3514
+ desc:
3515
+ - name: p
3516
+ content: Use this method to unban a previously banned channel chat in a supergroup or channel. The bot must be an administrator for this to work and must have the appropriate administrator rights. Returns True on success.
3517
+ table:
3518
+ - Parameter: chat_id
3519
+ Type: Integer or String
3520
+ Required: 'Yes'
3521
+ Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3522
+ - Parameter: sender_chat_id
3523
+ Type: Integer
3524
+ Required: 'Yes'
3525
+ Description: Unique identifier of the target sender chat
2790
3526
  - name: setChatPermissions
2791
3527
  children: []
2792
3528
  desc:
2793
3529
  - name: p
2794
- content: Use this method to set default chat permissions for all members. The bot must be an administrator in the group or a supergroup for this to work and must have the can_restrict_members admin rights. Returns True on success.
3530
+ content: Use this method to set default chat permissions for all members. The bot must be an administrator in the group or a supergroup for this to work and must have the can_restrict_members administrator rights. Returns True on success.
2795
3531
  table:
2796
3532
  - Parameter: chat_id
2797
3533
  Type: Integer or String
@@ -2800,12 +3536,16 @@ children:
2800
3536
  - Parameter: permissions
2801
3537
  Type: ChatPermissions
2802
3538
  Required: 'Yes'
2803
- Description: New default chat permissions
3539
+ Description: A JSON-serialized object for new default chat permissions
3540
+ - Parameter: use_independent_chat_permissions
3541
+ Type: Boolean
3542
+ Required: Optional
3543
+ Description: Pass True if chat permissions are set independently. Otherwise, the can_send_other_messages and can_add_web_page_previews permissions will imply the can_send_messages, can_send_audios, can_send_documents, can_send_photos, can_send_videos, can_send_video_notes, and can_send_voice_notes permissions; the can_send_polls permission will imply the can_send_messages permission.
2804
3544
  - name: exportChatInviteLink
2805
3545
  children: []
2806
3546
  desc:
2807
3547
  - name: p
2808
- content: Use this method to generate a new primary invite link for a chat; any previously generated primary link is revoked. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns the new invite link as String on success.
3548
+ content: Use this method to generate a new primary invite link for a chat; any previously generated primary link is revoked. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns the new invite link as String on success.
2809
3549
  - name: blockquote
2810
3550
  content: 'Note: Each administrator in a chat generates their own invite links. Bots can''t use invite links generated by other administrators. If you want your bot to work with invite links, it will need to generate its own link using exportChatInviteLink or by calling the getChat method. If your bot needs to generate a new primary invite link replacing its previous one, use exportChatInviteLink again.'
2811
3551
  table:
@@ -2817,12 +3557,16 @@ children:
2817
3557
  children: []
2818
3558
  desc:
2819
3559
  - name: p
2820
- content: Use this method to create an additional invite link for a chat. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. The link can be revoked using the method revokeChatInviteLink. Returns the new invite link as ChatInviteLink object.
3560
+ content: Use this method to create an additional invite link for a chat. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. The link can be revoked using the method revokeChatInviteLink. Returns the new invite link as ChatInviteLink object.
2821
3561
  table:
2822
3562
  - Parameter: chat_id
2823
3563
  Type: Integer or String
2824
3564
  Required: 'Yes'
2825
3565
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3566
+ - Parameter: name
3567
+ Type: String
3568
+ Required: Optional
3569
+ Description: Invite link name; 0-32 characters
2826
3570
  - Parameter: expire_date
2827
3571
  Type: Integer
2828
3572
  Required: Optional
@@ -2830,12 +3574,16 @@ children:
2830
3574
  - Parameter: member_limit
2831
3575
  Type: Integer
2832
3576
  Required: Optional
2833
- Description: Maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
3577
+ Description: The maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
3578
+ - Parameter: creates_join_request
3579
+ Type: Boolean
3580
+ Required: Optional
3581
+ Description: True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can't be specified
2834
3582
  - name: editChatInviteLink
2835
3583
  children: []
2836
3584
  desc:
2837
3585
  - name: p
2838
- content: Use this method to edit a non-primary invite link created by the bot. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns the edited invite link as a ChatInviteLink object.
3586
+ content: Use this method to edit a non-primary invite link created by the bot. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns the edited invite link as a ChatInviteLink object.
2839
3587
  table:
2840
3588
  - Parameter: chat_id
2841
3589
  Type: Integer or String
@@ -2845,6 +3593,10 @@ children:
2845
3593
  Type: String
2846
3594
  Required: 'Yes'
2847
3595
  Description: The invite link to edit
3596
+ - Parameter: name
3597
+ Type: String
3598
+ Required: Optional
3599
+ Description: Invite link name; 0-32 characters
2848
3600
  - Parameter: expire_date
2849
3601
  Type: Integer
2850
3602
  Required: Optional
@@ -2852,12 +3604,16 @@ children:
2852
3604
  - Parameter: member_limit
2853
3605
  Type: Integer
2854
3606
  Required: Optional
2855
- Description: Maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
3607
+ Description: The maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999
3608
+ - Parameter: creates_join_request
3609
+ Type: Boolean
3610
+ Required: Optional
3611
+ Description: True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can't be specified
2856
3612
  - name: revokeChatInviteLink
2857
3613
  children: []
2858
3614
  desc:
2859
3615
  - name: p
2860
- content: Use this method to revoke an invite link created by the bot. If the primary link is revoked, a new link is automatically generated. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns the revoked invite link as ChatInviteLink object.
3616
+ content: Use this method to revoke an invite link created by the bot. If the primary link is revoked, a new link is automatically generated. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns the revoked invite link as ChatInviteLink object.
2861
3617
  table:
2862
3618
  - Parameter: chat_id
2863
3619
  Type: Integer or String
@@ -2867,11 +3623,39 @@ children:
2867
3623
  Type: String
2868
3624
  Required: 'Yes'
2869
3625
  Description: The invite link to revoke
3626
+ - name: approveChatJoinRequest
3627
+ children: []
3628
+ desc:
3629
+ - name: p
3630
+ content: Use this method to approve a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right. Returns True on success.
3631
+ table:
3632
+ - Parameter: chat_id
3633
+ Type: Integer or String
3634
+ Required: 'Yes'
3635
+ Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3636
+ - Parameter: user_id
3637
+ Type: Integer
3638
+ Required: 'Yes'
3639
+ Description: Unique identifier of the target user
3640
+ - name: declineChatJoinRequest
3641
+ children: []
3642
+ desc:
3643
+ - name: p
3644
+ content: Use this method to decline a chat join request. The bot must be an administrator in the chat for this to work and must have the can_invite_users administrator right. Returns True on success.
3645
+ table:
3646
+ - Parameter: chat_id
3647
+ Type: Integer or String
3648
+ Required: 'Yes'
3649
+ Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
3650
+ - Parameter: user_id
3651
+ Type: Integer
3652
+ Required: 'Yes'
3653
+ Description: Unique identifier of the target user
2870
3654
  - name: setChatPhoto
2871
3655
  children: []
2872
3656
  desc:
2873
3657
  - name: p
2874
- content: Use this method to set a new profile photo for the chat. Photos can't be changed for private chats. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns True on success.
3658
+ content: Use this method to set a new profile photo for the chat. Photos can't be changed for private chats. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns True on success.
2875
3659
  table:
2876
3660
  - Parameter: chat_id
2877
3661
  Type: Integer or String
@@ -2885,7 +3669,7 @@ children:
2885
3669
  children: []
2886
3670
  desc:
2887
3671
  - name: p
2888
- content: Use this method to delete a chat photo. Photos can't be changed for private chats. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns True on success.
3672
+ content: Use this method to delete a chat photo. Photos can't be changed for private chats. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns True on success.
2889
3673
  table:
2890
3674
  - Parameter: chat_id
2891
3675
  Type: Integer or String
@@ -2895,7 +3679,7 @@ children:
2895
3679
  children: []
2896
3680
  desc:
2897
3681
  - name: p
2898
- content: Use this method to change the title of a chat. Titles can't be changed for private chats. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns True on success.
3682
+ content: Use this method to change the title of a chat. Titles can't be changed for private chats. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns True on success.
2899
3683
  table:
2900
3684
  - Parameter: chat_id
2901
3685
  Type: Integer or String
@@ -2904,12 +3688,12 @@ children:
2904
3688
  - Parameter: title
2905
3689
  Type: String
2906
3690
  Required: 'Yes'
2907
- Description: New chat title, 1-255 characters
3691
+ Description: New chat title, 1-128 characters
2908
3692
  - name: setChatDescription
2909
3693
  children: []
2910
3694
  desc:
2911
3695
  - name: p
2912
- content: Use this method to change the description of a group, a supergroup or a channel. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Returns True on success.
3696
+ content: Use this method to change the description of a group, a supergroup or a channel. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Returns True on success.
2913
3697
  table:
2914
3698
  - Parameter: chat_id
2915
3699
  Type: Integer or String
@@ -2923,7 +3707,7 @@ children:
2923
3707
  children: []
2924
3708
  desc:
2925
3709
  - name: p
2926
- content: Use this method to add a message to the list of pinned messages in a chat. If the chat is not a private chat, the bot must be an administrator in the chat for this to work and must have the 'can_pin_messages' admin right in a supergroup or 'can_edit_messages' admin right in a channel. Returns True on success.
3710
+ content: Use this method to add a message to the list of pinned messages in a chat. If the chat is not a private chat, the bot must be an administrator in the chat for this to work and must have the 'can_pin_messages' administrator right in a supergroup or 'can_edit_messages' administrator right in a channel. Returns True on success.
2927
3711
  table:
2928
3712
  - Parameter: chat_id
2929
3713
  Type: Integer or String
@@ -2936,12 +3720,12 @@ children:
2936
3720
  - Parameter: disable_notification
2937
3721
  Type: Boolean
2938
3722
  Required: Optional
2939
- Description: Pass True, if it is not necessary to send a notification to all chat members about the new pinned message. Notifications are always disabled in channels and private chats.
3723
+ Description: Pass True if it is not necessary to send a notification to all chat members about the new pinned message. Notifications are always disabled in channels and private chats.
2940
3724
  - name: unpinChatMessage
2941
3725
  children: []
2942
3726
  desc:
2943
3727
  - name: p
2944
- content: Use this method to remove a message from the list of pinned messages in a chat. If the chat is not a private chat, the bot must be an administrator in the chat for this to work and must have the 'can_pin_messages' admin right in a supergroup or 'can_edit_messages' admin right in a channel. Returns True on success.
3728
+ content: Use this method to remove a message from the list of pinned messages in a chat. If the chat is not a private chat, the bot must be an administrator in the chat for this to work and must have the 'can_pin_messages' administrator right in a supergroup or 'can_edit_messages' administrator right in a channel. Returns True on success.
2945
3729
  table:
2946
3730
  - Parameter: chat_id
2947
3731
  Type: Integer or String
@@ -2955,7 +3739,7 @@ children:
2955
3739
  children: []
2956
3740
  desc:
2957
3741
  - name: p
2958
- content: Use this method to clear the list of pinned messages in a chat. If the chat is not a private chat, the bot must be an administrator in the chat for this to work and must have the 'can_pin_messages' admin right in a supergroup or 'can_edit_messages' admin right in a channel. Returns True on success.
3742
+ content: Use this method to clear the list of pinned messages in a chat. If the chat is not a private chat, the bot must be an administrator in the chat for this to work and must have the 'can_pin_messages' administrator right in a supergroup or 'can_edit_messages' administrator right in a channel. Returns True on success.
2959
3743
  table:
2960
3744
  - Parameter: chat_id
2961
3745
  Type: Integer or String
@@ -2985,13 +3769,13 @@ children:
2985
3769
  children: []
2986
3770
  desc:
2987
3771
  - name: p
2988
- content: Use this method to get a list of administrators in a chat. On success, returns an Array of ChatMember objects that contains information about all chat administrators except other bots. If the chat is a group or a supergroup and no administrators were appointed, only the creator will be returned.
3772
+ content: Use this method to get a list of administrators in a chat, which aren't bots. Returns an Array of ChatMember objects.
2989
3773
  table:
2990
3774
  - Parameter: chat_id
2991
3775
  Type: Integer or String
2992
3776
  Required: 'Yes'
2993
3777
  Description: Unique identifier for the target chat or username of the target supergroup or channel (in the format @channelusername)
2994
- - name: getChatMembersCount
3778
+ - name: getChatMemberCount
2995
3779
  children: []
2996
3780
  desc:
2997
3781
  - name: p
@@ -3005,7 +3789,7 @@ children:
3005
3789
  children: []
3006
3790
  desc:
3007
3791
  - name: p
3008
- content: Use this method to get information about a member of a chat. Returns a ChatMember object on success.
3792
+ content: Use this method to get information about a member of a chat. The method is only guaranteed to work for other users if the bot is an administrator in the chat. Returns a ChatMember object on success.
3009
3793
  table:
3010
3794
  - Parameter: chat_id
3011
3795
  Type: Integer or String
@@ -3019,7 +3803,7 @@ children:
3019
3803
  children: []
3020
3804
  desc:
3021
3805
  - name: p
3022
- content: Use this method to set a new group sticker set for a supergroup. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Use the field can_set_sticker_set optionally returned in getChat requests to check if the bot can use this method. Returns True on success.
3806
+ content: Use this method to set a new group sticker set for a supergroup. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Use the field can_set_sticker_set optionally returned in getChat requests to check if the bot can use this method. Returns True on success.
3023
3807
  table:
3024
3808
  - Parameter: chat_id
3025
3809
  Type: Integer or String
@@ -3033,7 +3817,166 @@ children:
3033
3817
  children: []
3034
3818
  desc:
3035
3819
  - name: p
3036
- content: Use this method to delete a group sticker set from a supergroup. The bot must be an administrator in the chat for this to work and must have the appropriate admin rights. Use the field can_set_sticker_set optionally returned in getChat requests to check if the bot can use this method. Returns True on success.
3820
+ content: Use this method to delete a group sticker set from a supergroup. The bot must be an administrator in the chat for this to work and must have the appropriate administrator rights. Use the field can_set_sticker_set optionally returned in getChat requests to check if the bot can use this method. Returns True on success.
3821
+ table:
3822
+ - Parameter: chat_id
3823
+ Type: Integer or String
3824
+ Required: 'Yes'
3825
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3826
+ - name: getForumTopicIconStickers
3827
+ children: []
3828
+ desc:
3829
+ - name: p
3830
+ content: Use this method to get custom emoji stickers, which can be used as a forum topic icon by any user. Requires no parameters. Returns an Array of Sticker objects.
3831
+ - name: createForumTopic
3832
+ children: []
3833
+ desc:
3834
+ - name: p
3835
+ content: Use this method to create a topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights. Returns information about the created topic as a ForumTopic object.
3836
+ table:
3837
+ - Parameter: chat_id
3838
+ Type: Integer or String
3839
+ Required: 'Yes'
3840
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3841
+ - Parameter: name
3842
+ Type: String
3843
+ Required: 'Yes'
3844
+ Description: Topic name, 1-128 characters
3845
+ - Parameter: icon_color
3846
+ Type: Integer
3847
+ Required: Optional
3848
+ Description: Color of the topic icon in RGB format. Currently, must be one of 7322096 (0x6FB9F0), 16766590 (0xFFD67E), 13338331 (0xCB86DB), 9367192 (0x8EEE98), 16749490 (0xFF93B2), or 16478047 (0xFB6F5F)
3849
+ - Parameter: icon_custom_emoji_id
3850
+ Type: String
3851
+ Required: Optional
3852
+ Description: Unique identifier of the custom emoji shown as the topic icon. Use getForumTopicIconStickers to get all allowed custom emoji identifiers.
3853
+ - name: editForumTopic
3854
+ children: []
3855
+ desc:
3856
+ - name: p
3857
+ content: Use this method to edit name and icon of a topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have can_manage_topics administrator rights, unless it is the creator of the topic. Returns True on success.
3858
+ table:
3859
+ - Parameter: chat_id
3860
+ Type: Integer or String
3861
+ Required: 'Yes'
3862
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3863
+ - Parameter: message_thread_id
3864
+ Type: Integer
3865
+ Required: 'Yes'
3866
+ Description: Unique identifier for the target message thread of the forum topic
3867
+ - Parameter: name
3868
+ Type: String
3869
+ Required: Optional
3870
+ Description: New topic name, 0-128 characters. If not specified or empty, the current name of the topic will be kept
3871
+ - Parameter: icon_custom_emoji_id
3872
+ Type: String
3873
+ Required: Optional
3874
+ Description: New unique identifier of the custom emoji shown as the topic icon. Use getForumTopicIconStickers to get all allowed custom emoji identifiers. Pass an empty string to remove the icon. If not specified, the current icon will be kept
3875
+ - name: closeForumTopic
3876
+ children: []
3877
+ desc:
3878
+ - name: p
3879
+ content: Use this method to close an open topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights, unless it is the creator of the topic. Returns True on success.
3880
+ table:
3881
+ - Parameter: chat_id
3882
+ Type: Integer or String
3883
+ Required: 'Yes'
3884
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3885
+ - Parameter: message_thread_id
3886
+ Type: Integer
3887
+ Required: 'Yes'
3888
+ Description: Unique identifier for the target message thread of the forum topic
3889
+ - name: reopenForumTopic
3890
+ children: []
3891
+ desc:
3892
+ - name: p
3893
+ content: Use this method to reopen a closed topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights, unless it is the creator of the topic. Returns True on success.
3894
+ table:
3895
+ - Parameter: chat_id
3896
+ Type: Integer or String
3897
+ Required: 'Yes'
3898
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3899
+ - Parameter: message_thread_id
3900
+ Type: Integer
3901
+ Required: 'Yes'
3902
+ Description: Unique identifier for the target message thread of the forum topic
3903
+ - name: deleteForumTopic
3904
+ children: []
3905
+ desc:
3906
+ - name: p
3907
+ content: Use this method to delete a forum topic along with all its messages in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_delete_messages administrator rights. Returns True on success.
3908
+ table:
3909
+ - Parameter: chat_id
3910
+ Type: Integer or String
3911
+ Required: 'Yes'
3912
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3913
+ - Parameter: message_thread_id
3914
+ Type: Integer
3915
+ Required: 'Yes'
3916
+ Description: Unique identifier for the target message thread of the forum topic
3917
+ - name: unpinAllForumTopicMessages
3918
+ children: []
3919
+ desc:
3920
+ - name: p
3921
+ content: Use this method to clear the list of pinned messages in a forum topic. The bot must be an administrator in the chat for this to work and must have the can_pin_messages administrator right in the supergroup. Returns True on success.
3922
+ table:
3923
+ - Parameter: chat_id
3924
+ Type: Integer or String
3925
+ Required: 'Yes'
3926
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3927
+ - Parameter: message_thread_id
3928
+ Type: Integer
3929
+ Required: 'Yes'
3930
+ Description: Unique identifier for the target message thread of the forum topic
3931
+ - name: editGeneralForumTopic
3932
+ children: []
3933
+ desc:
3934
+ - name: p
3935
+ content: Use this method to edit the name of the 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have can_manage_topics administrator rights. Returns True on success.
3936
+ table:
3937
+ - Parameter: chat_id
3938
+ Type: Integer or String
3939
+ Required: 'Yes'
3940
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3941
+ - Parameter: name
3942
+ Type: String
3943
+ Required: 'Yes'
3944
+ Description: New topic name, 1-128 characters
3945
+ - name: closeGeneralForumTopic
3946
+ children: []
3947
+ desc:
3948
+ - name: p
3949
+ content: Use this method to close an open 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights. Returns True on success.
3950
+ table:
3951
+ - Parameter: chat_id
3952
+ Type: Integer or String
3953
+ Required: 'Yes'
3954
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3955
+ - name: reopenGeneralForumTopic
3956
+ children: []
3957
+ desc:
3958
+ - name: p
3959
+ content: Use this method to reopen a closed 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights. The topic will be automatically unhidden if it was hidden. Returns True on success.
3960
+ table:
3961
+ - Parameter: chat_id
3962
+ Type: Integer or String
3963
+ Required: 'Yes'
3964
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3965
+ - name: hideGeneralForumTopic
3966
+ children: []
3967
+ desc:
3968
+ - name: p
3969
+ content: Use this method to hide the 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights. The topic will be automatically closed if it was open. Returns True on success.
3970
+ table:
3971
+ - Parameter: chat_id
3972
+ Type: Integer or String
3973
+ Required: 'Yes'
3974
+ Description: Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)
3975
+ - name: unhideGeneralForumTopic
3976
+ children: []
3977
+ desc:
3978
+ - name: p
3979
+ content: Use this method to unhide the 'General' topic in a forum supergroup chat. The bot must be an administrator in the chat for this to work and must have the can_manage_topics administrator rights. Returns True on success.
3037
3980
  table:
3038
3981
  - Parameter: chat_id
3039
3982
  Type: Integer or String
@@ -3045,7 +3988,7 @@ children:
3045
3988
  - name: p
3046
3989
  content: Use this method to send answers to callback queries sent from inline keyboards. The answer will be displayed to the user as a notification at the top of the chat screen or as an alert. On success, True is returned.
3047
3990
  - name: blockquote
3048
- content: Alternatively, the user can be redirected to the specified Game URL. For this option to work, you must first create a game for your bot via @Botfather and accept the terms. Otherwise, you may use links like t.me/your_bot?start=XXXX that open your bot with a parameter.
3991
+ content: Alternatively, the user can be redirected to the specified Game URL. For this option to work, you must first create a game for your bot via @BotFather and accept the terms. Otherwise, you may use links like t.me/your_bot?start=XXXX that open your bot with a parameter.
3049
3992
  table:
3050
3993
  - Parameter: callback_query_id
3051
3994
  Type: String
@@ -3058,11 +4001,11 @@ children:
3058
4001
  - Parameter: show_alert
3059
4002
  Type: Boolean
3060
4003
  Required: Optional
3061
- Description: If true, an alert will be shown by the client instead of a notification at the top of the chat screen. Defaults to false.
4004
+ Description: If True, an alert will be shown by the client instead of a notification at the top of the chat screen. Defaults to false.
3062
4005
  - Parameter: url
3063
4006
  Type: String
3064
4007
  Required: Optional
3065
- Description: URL that will be opened by the user's client. If you have created a Game and accepted the conditions via @Botfather, specify the URL that opens your game note that this will only work if the query comes from a callback_game button.Otherwise, you may use links like t.me/your_bot?start=XXXX that open your bot with a parameter.
4008
+ Description: URL that will be opened by the user's client. If you have created a Game and accepted the conditions via @BotFather, specify the URL that opens your game - note that this will only work if the query comes from a callback_game button.Otherwise, you may use links like t.me/your_bot?start=XXXX that open your bot with a parameter.
3066
4009
  - Parameter: cache_time
3067
4010
  Type: Integer
3068
4011
  Required: Optional
@@ -3071,17 +4014,144 @@ children:
3071
4014
  children: []
3072
4015
  desc:
3073
4016
  - name: p
3074
- content: Use this method to change the list of the bot's commands. Returns True on success.
4017
+ content: Use this method to change the list of the bot's commands. See this manual for more details about bot commands. Returns True on success.
3075
4018
  table:
3076
4019
  - Parameter: commands
3077
4020
  Type: Array of BotCommand
3078
4021
  Required: 'Yes'
3079
4022
  Description: A JSON-serialized list of bot commands to be set as the list of the bot's commands. At most 100 commands can be specified.
4023
+ - Parameter: scope
4024
+ Type: BotCommandScope
4025
+ Required: Optional
4026
+ Description: A JSON-serialized object, describing scope of users for which the commands are relevant. Defaults to BotCommandScopeDefault.
4027
+ - Parameter: language_code
4028
+ Type: String
4029
+ Required: Optional
4030
+ Description: A two-letter ISO 639-1 language code. If empty, commands will be applied to all users from the given scope, for whose language there are no dedicated commands
4031
+ - name: deleteMyCommands
4032
+ children: []
4033
+ desc:
4034
+ - name: p
4035
+ content: Use this method to delete the list of the bot's commands for the given scope and user language. After deletion, higher level commands will be shown to affected users. Returns True on success.
4036
+ table:
4037
+ - Parameter: scope
4038
+ Type: BotCommandScope
4039
+ Required: Optional
4040
+ Description: A JSON-serialized object, describing scope of users for which the commands are relevant. Defaults to BotCommandScopeDefault.
4041
+ - Parameter: language_code
4042
+ Type: String
4043
+ Required: Optional
4044
+ Description: A two-letter ISO 639-1 language code. If empty, commands will be applied to all users from the given scope, for whose language there are no dedicated commands
3080
4045
  - name: getMyCommands
3081
4046
  children: []
3082
4047
  desc:
3083
4048
  - name: p
3084
- content: Use this method to get the current list of the bot's commands. Requires no parameters. Returns Array of BotCommand on success.
4049
+ content: Use this method to get the current list of the bot's commands for the given scope and user language. Returns an Array of BotCommand objects. If commands aren't set, an empty list is returned.
4050
+ table:
4051
+ - Parameter: scope
4052
+ Type: BotCommandScope
4053
+ Required: Optional
4054
+ Description: A JSON-serialized object, describing scope of users. Defaults to BotCommandScopeDefault.
4055
+ - Parameter: language_code
4056
+ Type: String
4057
+ Required: Optional
4058
+ Description: A two-letter ISO 639-1 language code or an empty string
4059
+ - name: setMyDescription
4060
+ children: []
4061
+ desc:
4062
+ - name: p
4063
+ content: Use this method to change the bot's description, which is shown in the chat with the bot if the chat is empty. Returns True on success.
4064
+ table:
4065
+ - Parameter: description
4066
+ Type: String
4067
+ Required: Optional
4068
+ Description: New bot description; 0-512 characters. Pass an empty string to remove the dedicated description for the given language.
4069
+ - Parameter: language_code
4070
+ Type: String
4071
+ Required: Optional
4072
+ Description: A two-letter ISO 639-1 language code. If empty, the description will be applied to all users for whose language there is no dedicated description.
4073
+ - name: getMyDescription
4074
+ children: []
4075
+ desc:
4076
+ - name: p
4077
+ content: Use this method to get the current bot description for the given user language. Returns BotDescription on success.
4078
+ table:
4079
+ - Parameter: language_code
4080
+ Type: String
4081
+ Required: Optional
4082
+ Description: A two-letter ISO 639-1 language code or an empty string
4083
+ - name: setMyShortDescription
4084
+ children: []
4085
+ desc:
4086
+ - name: p
4087
+ content: Use this method to change the bot's short description, which is shown on the bot's profile page and is sent together with the link when users share the bot. Returns True on success.
4088
+ table:
4089
+ - Parameter: short_description
4090
+ Type: String
4091
+ Required: Optional
4092
+ Description: New short description for the bot; 0-120 characters. Pass an empty string to remove the dedicated short description for the given language.
4093
+ - Parameter: language_code
4094
+ Type: String
4095
+ Required: Optional
4096
+ Description: A two-letter ISO 639-1 language code. If empty, the short description will be applied to all users for whose language there is no dedicated short description.
4097
+ - name: getMyShortDescription
4098
+ children: []
4099
+ desc:
4100
+ - name: p
4101
+ content: Use this method to get the current bot short description for the given user language. Returns BotShortDescription on success.
4102
+ table:
4103
+ - Parameter: language_code
4104
+ Type: String
4105
+ Required: Optional
4106
+ Description: A two-letter ISO 639-1 language code or an empty string
4107
+ - name: setChatMenuButton
4108
+ children: []
4109
+ desc:
4110
+ - name: p
4111
+ content: Use this method to change the bot's menu button in a private chat, or the default menu button. Returns True on success.
4112
+ table:
4113
+ - Parameter: chat_id
4114
+ Type: Integer
4115
+ Required: Optional
4116
+ Description: Unique identifier for the target private chat. If not specified, default bot's menu button will be changed
4117
+ - Parameter: menu_button
4118
+ Type: MenuButton
4119
+ Required: Optional
4120
+ Description: A JSON-serialized object for the bot's new menu button. Defaults to MenuButtonDefault
4121
+ - name: getChatMenuButton
4122
+ children: []
4123
+ desc:
4124
+ - name: p
4125
+ content: Use this method to get the current value of the bot's menu button in a private chat, or the default menu button. Returns MenuButton on success.
4126
+ table:
4127
+ - Parameter: chat_id
4128
+ Type: Integer
4129
+ Required: Optional
4130
+ Description: Unique identifier for the target private chat. If not specified, default bot's menu button will be returned
4131
+ - name: setMyDefaultAdministratorRights
4132
+ children: []
4133
+ desc:
4134
+ - name: p
4135
+ content: Use this method to change the default administrator rights requested by the bot when it's added as an administrator to groups or channels. These rights will be suggested to users, but they are free to modify the list before adding the bot. Returns True on success.
4136
+ table:
4137
+ - Parameter: rights
4138
+ Type: ChatAdministratorRights
4139
+ Required: Optional
4140
+ Description: A JSON-serialized object describing new default administrator rights. If not specified, the default administrator rights will be cleared.
4141
+ - Parameter: for_channels
4142
+ Type: Boolean
4143
+ Required: Optional
4144
+ Description: Pass True to change the default administrator rights of the bot in channels. Otherwise, the default administrator rights of the bot for groups and supergroups will be changed.
4145
+ - name: getMyDefaultAdministratorRights
4146
+ children: []
4147
+ desc:
4148
+ - name: p
4149
+ content: Use this method to get the current default administrator rights of the bot. Returns ChatAdministratorRights on success.
4150
+ table:
4151
+ - Parameter: for_channels
4152
+ Type: Boolean
4153
+ Required: Optional
4154
+ Description: Pass True to get default administrator rights of the bot in channels. Otherwise, default administrator rights of the bot for groups and supergroups will be returned.
3085
4155
  - name: Inline mode methods
3086
4156
  children: []
3087
4157
  desc:
@@ -3121,20 +4191,80 @@ children:
3121
4191
  - Parameter: entities
3122
4192
  Type: Array of MessageEntity
3123
4193
  Required: Optional
3124
- Description: List of special entities that appear in message text, which can be specified instead of parse_mode
4194
+ Description: A JSON-serialized list of special entities that appear in message text, which can be specified instead of parse_mode
3125
4195
  - Parameter: disable_web_page_preview
3126
4196
  Type: Boolean
3127
4197
  Required: Optional
3128
- Description: Disables link previews for links in this message
4198
+ Description: Disables link previews for links in this message
4199
+ - Parameter: reply_markup
4200
+ Type: InlineKeyboardMarkup
4201
+ Required: Optional
4202
+ Description: A JSON-serialized object for an inline keyboard.
4203
+ - name: editMessageCaption
4204
+ children: []
4205
+ desc:
4206
+ - name: p
4207
+ content: Use this method to edit captions of messages. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned.
4208
+ table:
4209
+ - Parameter: chat_id
4210
+ Type: Integer or String
4211
+ Required: Optional
4212
+ Description: Required if inline_message_id is not specified. Unique identifier for the target chat or username of the target channel (in the format @channelusername)
4213
+ - Parameter: message_id
4214
+ Type: Integer
4215
+ Required: Optional
4216
+ Description: Required if inline_message_id is not specified. Identifier of the message to edit
4217
+ - Parameter: inline_message_id
4218
+ Type: String
4219
+ Required: Optional
4220
+ Description: Required if chat_id and message_id are not specified. Identifier of the inline message
4221
+ - Parameter: caption
4222
+ Type: String
4223
+ Required: Optional
4224
+ Description: New caption of the message, 0-1024 characters after entities parsing
4225
+ - Parameter: parse_mode
4226
+ Type: String
4227
+ Required: Optional
4228
+ Description: Mode for parsing entities in the message caption. See formatting options for more details.
4229
+ - Parameter: caption_entities
4230
+ Type: Array of MessageEntity
4231
+ Required: Optional
4232
+ Description: A JSON-serialized list of special entities that appear in the caption, which can be specified instead of parse_mode
4233
+ - Parameter: reply_markup
4234
+ Type: InlineKeyboardMarkup
4235
+ Required: Optional
4236
+ Description: A JSON-serialized object for an inline keyboard.
4237
+ - name: editMessageMedia
4238
+ children: []
4239
+ desc:
4240
+ - name: p
4241
+ content: Use this method to edit animation, audio, document, photo, or video messages. If a message is part of a message album, then it can be edited only to an audio for audio albums, only to a document for document albums and to a photo or a video otherwise. When an inline message is edited, a new file can't be uploaded; use a previously uploaded file via its file_id or specify a URL. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned.
4242
+ table:
4243
+ - Parameter: chat_id
4244
+ Type: Integer or String
4245
+ Required: Optional
4246
+ Description: Required if inline_message_id is not specified. Unique identifier for the target chat or username of the target channel (in the format @channelusername)
4247
+ - Parameter: message_id
4248
+ Type: Integer
4249
+ Required: Optional
4250
+ Description: Required if inline_message_id is not specified. Identifier of the message to edit
4251
+ - Parameter: inline_message_id
4252
+ Type: String
4253
+ Required: Optional
4254
+ Description: Required if chat_id and message_id are not specified. Identifier of the inline message
4255
+ - Parameter: media
4256
+ Type: InputMedia
4257
+ Required: 'Yes'
4258
+ Description: A JSON-serialized object for a new media content of the message
3129
4259
  - Parameter: reply_markup
3130
4260
  Type: InlineKeyboardMarkup
3131
4261
  Required: Optional
3132
- Description: A JSON-serialized object for an inline keyboard.
3133
- - name: editMessageCaption
4262
+ Description: A JSON-serialized object for a new inline keyboard.
4263
+ - name: editMessageLiveLocation
3134
4264
  children: []
3135
4265
  desc:
3136
4266
  - name: p
3137
- content: Use this method to edit captions of messages. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned.
4267
+ content: Use this method to edit live location messages. A location can be edited until its live_period expires or editing is explicitly disabled by a call to stopMessageLiveLocation. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned.
3138
4268
  table:
3139
4269
  - Parameter: chat_id
3140
4270
  Type: Integer or String
@@ -3148,27 +4278,35 @@ children:
3148
4278
  Type: String
3149
4279
  Required: Optional
3150
4280
  Description: Required if chat_id and message_id are not specified. Identifier of the inline message
3151
- - Parameter: caption
3152
- Type: String
4281
+ - Parameter: latitude
4282
+ Type: Float number
4283
+ Required: 'Yes'
4284
+ Description: Latitude of new location
4285
+ - Parameter: longitude
4286
+ Type: Float number
4287
+ Required: 'Yes'
4288
+ Description: Longitude of new location
4289
+ - Parameter: horizontal_accuracy
4290
+ Type: Float number
3153
4291
  Required: Optional
3154
- Description: New caption of the message, 0-1024 characters after entities parsing
3155
- - Parameter: parse_mode
3156
- Type: String
4292
+ Description: The radius of uncertainty for the location, measured in meters; 0-1500
4293
+ - Parameter: heading
4294
+ Type: Integer
3157
4295
  Required: Optional
3158
- Description: Mode for parsing entities in the message caption. See formatting options for more details.
3159
- - Parameter: caption_entities
3160
- Type: Array of MessageEntity
4296
+ Description: Direction in which the user is moving, in degrees. Must be between 1 and 360 if specified.
4297
+ - Parameter: proximity_alert_radius
4298
+ Type: Integer
3161
4299
  Required: Optional
3162
- Description: List of special entities that appear in the caption, which can be specified instead of parse_mode
4300
+ Description: The maximum distance for proximity alerts about approaching another chat member, in meters. Must be between 1 and 100000 if specified.
3163
4301
  - Parameter: reply_markup
3164
4302
  Type: InlineKeyboardMarkup
3165
4303
  Required: Optional
3166
- Description: A JSON-serialized object for an inline keyboard.
3167
- - name: editMessageMedia
4304
+ Description: A JSON-serialized object for a new inline keyboard.
4305
+ - name: stopMessageLiveLocation
3168
4306
  children: []
3169
4307
  desc:
3170
4308
  - name: p
3171
- content: Use this method to edit animation, audio, document, photo, or video messages. If a message is part of a message album, then it can be edited only to an audio for audio albums, only to a document for document albums and to a photo or a video otherwise. When an inline message is edited, a new file can't be uploaded. Use a previously uploaded file via its file_id or specify a URL. On success, if the edited message was sent by the bot, the edited Message is returned, otherwise True is returned.
4309
+ content: Use this method to stop updating a live location message before live_period expires. On success, if the message is not an inline message, the edited Message is returned, otherwise True is returned.
3172
4310
  table:
3173
4311
  - Parameter: chat_id
3174
4312
  Type: Integer or String
@@ -3177,15 +4315,11 @@ children:
3177
4315
  - Parameter: message_id
3178
4316
  Type: Integer
3179
4317
  Required: Optional
3180
- Description: Required if inline_message_id is not specified. Identifier of the message to edit
4318
+ Description: Required if inline_message_id is not specified. Identifier of the message with live location to stop
3181
4319
  - Parameter: inline_message_id
3182
4320
  Type: String
3183
4321
  Required: Optional
3184
4322
  Description: Required if chat_id and message_id are not specified. Identifier of the inline message
3185
- - Parameter: media
3186
- Type: InputMedia
3187
- Required: 'Yes'
3188
- Description: A JSON-serialized object for a new media content of the message
3189
4323
  - Parameter: reply_markup
3190
4324
  Type: InlineKeyboardMarkup
3191
4325
  Required: Optional
@@ -3216,7 +4350,7 @@ children:
3216
4350
  children: []
3217
4351
  desc:
3218
4352
  - name: p
3219
- content: Use this method to stop a poll which was sent by the bot. On success, the stopped Poll with the final results is returned.
4353
+ content: Use this method to stop a poll which was sent by the bot. On success, the stopped Poll is returned.
3220
4354
  table:
3221
4355
  - Parameter: chat_id
3222
4356
  Type: Integer or String
@@ -3234,7 +4368,7 @@ children:
3234
4368
  children: []
3235
4369
  desc:
3236
4370
  - name: p
3237
- content: Use this method to delete a message, including service messages, with the following limitations:- A message can only be deleted if it was sent less than 48 hours ago.- A dice message in a private chat can only be deleted if it was sent more than 24 hours ago.- Bots can delete outgoing messages in private chats, groups, and supergroups.- Bots can delete incoming messages in private chats.- Bots granted can_post_messages permissions can delete outgoing messages in channels.- If the bot is an administrator of a group, it can delete any message there.- If the bot has can_delete_messages permission in a supergroup or a channel, it can delete any message there.Returns True on success.
4371
+ content: Use this method to delete a message, including service messages, with the following limitations:- A message can only be deleted if it was sent less than 48 hours ago.- Service messages about a supergroup, channel, or forum topic creation can't be deleted.- A dice message in a private chat can only be deleted if it was sent more than 24 hours ago.- Bots can delete outgoing messages in private chats, groups, and supergroups.- Bots can delete incoming messages in private chats.- Bots granted can_post_messages permissions can delete outgoing messages in channels.- If the bot is an administrator of a group, it can delete any message there.- If the bot has can_delete_messages permission in a supergroup or a channel, it can delete any message there.Returns True on success.
3238
4372
  table:
3239
4373
  - Parameter: chat_id
3240
4374
  Type: Integer or String
@@ -3263,6 +4397,9 @@ children:
3263
4397
  - Field: file_unique_id
3264
4398
  Type: String
3265
4399
  Description: Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.
4400
+ - Field: type
4401
+ Type: String
4402
+ Description: Type of the sticker, currently one of “regular”, “mask”, “custom_emoji”. The type of the sticker is independent from its format, which is determined by the fields is_animated and is_video.
3266
4403
  - Field: width
3267
4404
  Type: Integer
3268
4405
  Description: Sticker width
@@ -3272,7 +4409,10 @@ children:
3272
4409
  - Field: is_animated
3273
4410
  Type: Boolean
3274
4411
  Description: True, if the sticker is animated
3275
- - Field: thumb
4412
+ - Field: is_video
4413
+ Type: Boolean
4414
+ Description: True, if the sticker is a video sticker
4415
+ - Field: thumbnail
3276
4416
  Type: PhotoSize
3277
4417
  Description: Optional. Sticker thumbnail in the .WEBP or .JPG format
3278
4418
  - Field: emoji
@@ -3281,12 +4421,21 @@ children:
3281
4421
  - Field: set_name
3282
4422
  Type: String
3283
4423
  Description: Optional. Name of the sticker set to which the sticker belongs
4424
+ - Field: premium_animation
4425
+ Type: File
4426
+ Description: Optional. For premium regular stickers, premium animation for the sticker
3284
4427
  - Field: mask_position
3285
4428
  Type: MaskPosition
3286
4429
  Description: Optional. For mask stickers, the position where the mask should be placed
4430
+ - Field: custom_emoji_id
4431
+ Type: String
4432
+ Description: Optional. For custom emoji stickers, unique identifier of the custom emoji
4433
+ - Field: needs_repainting
4434
+ Type: 'True'
4435
+ Description: Optional. True, if the sticker must be repainted to a text color in messages, the color of the Telegram Premium badge in emoji status, white color on chat photos, or another appropriate color in other places
3287
4436
  - Field: file_size
3288
4437
  Type: Integer
3289
- Description: Optional. File size
4438
+ Description: Optional. File size in bytes
3290
4439
  - name: StickerSet
3291
4440
  children: []
3292
4441
  desc:
@@ -3299,18 +4448,21 @@ children:
3299
4448
  - Field: title
3300
4449
  Type: String
3301
4450
  Description: Sticker set title
4451
+ - Field: sticker_type
4452
+ Type: String
4453
+ Description: Type of stickers in the set, currently one of “regular”, “mask”, “custom_emoji”
3302
4454
  - Field: is_animated
3303
4455
  Type: Boolean
3304
4456
  Description: True, if the sticker set contains animated stickers
3305
- - Field: contains_masks
4457
+ - Field: is_video
3306
4458
  Type: Boolean
3307
- Description: True, if the sticker set contains masks
4459
+ Description: True, if the sticker set contains video stickers
3308
4460
  - Field: stickers
3309
4461
  Type: Array of Sticker
3310
4462
  Description: List of all set stickers
3311
- - Field: thumb
4463
+ - Field: thumbnail
3312
4464
  Type: PhotoSize
3313
- Description: Optional. Sticker set thumbnail in the .WEBP or .TGS format
4465
+ Description: Optional. Sticker set thumbnail in the .WEBP, .TGS, or .WEBM format
3314
4466
  - name: MaskPosition
3315
4467
  children: []
3316
4468
  desc:
@@ -3329,24 +4481,54 @@ children:
3329
4481
  - Field: scale
3330
4482
  Type: Float number
3331
4483
  Description: Mask scaling coefficient. For example, 2.0 means double size.
4484
+ - name: InputSticker
4485
+ children: []
4486
+ desc:
4487
+ - name: p
4488
+ content: This object describes a sticker to be added to a sticker set.
4489
+ table:
4490
+ - Field: sticker
4491
+ Type: InputFile or String
4492
+ Description: The added sticker. Pass a file_id as a String to send a file that already exists on the Telegram servers, pass an HTTP URL as a String for Telegram to get a file from the Internet, upload a new one using multipart/form-data, or pass “attach://<file_attach_name>” to upload a new one using multipart/form-data under <file_attach_name> name. Animated and video stickers can't be uploaded via HTTP URL. More information on Sending Files »
4493
+ - Field: emoji_list
4494
+ Type: Array of String
4495
+ Description: List of 1-20 emoji associated with the sticker
4496
+ - Field: mask_position
4497
+ Type: MaskPosition
4498
+ Description: Optional. Position where the mask should be placed on faces. For “mask” stickers only.
4499
+ - Field: keywords
4500
+ Type: Array of String
4501
+ Description: Optional. List of 0-20 search keywords for the sticker with total length of up to 64 characters. For “regular” and “custom_emoji” stickers only.
3332
4502
  - name: sendSticker
3333
4503
  children: []
3334
4504
  desc:
3335
4505
  - name: p
3336
- content: Use this method to send static .WEBP or animated .TGS stickers. On success, the sent Message is returned.
4506
+ content: Use this method to send static .WEBP, animated .TGS, or video .WEBM stickers. On success, the sent Message is returned.
3337
4507
  table:
3338
4508
  - Parameter: chat_id
3339
4509
  Type: Integer or String
3340
4510
  Required: 'Yes'
3341
4511
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
4512
+ - Parameter: message_thread_id
4513
+ Type: Integer
4514
+ Required: Optional
4515
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
3342
4516
  - Parameter: sticker
3343
4517
  Type: InputFile or String
3344
4518
  Required: 'Yes'
3345
- Description: 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 file from the Internet, or upload a new one using multipart/form-data. More info on Sending Files »
4519
+ Description: 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. 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.
4520
+ - Parameter: emoji
4521
+ Type: String
4522
+ Required: Optional
4523
+ Description: Emoji associated with the sticker; only for just uploaded stickers
3346
4524
  - Parameter: disable_notification
3347
4525
  Type: Boolean
3348
4526
  Required: Optional
3349
4527
  Description: Sends the message silently. Users will receive a notification with no sound.
4528
+ - Parameter: protect_content
4529
+ Type: Boolean
4530
+ Required: Optional
4531
+ Description: Protects the contents of the sent message from forwarding and saving
3350
4532
  - Parameter: reply_to_message_id
3351
4533
  Type: Integer
3352
4534
  Required: Optional
@@ -3354,7 +4536,7 @@ children:
3354
4536
  - Parameter: allow_sending_without_reply
3355
4537
  Type: Boolean
3356
4538
  Required: Optional
3357
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
4539
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
3358
4540
  - Parameter: reply_markup
3359
4541
  Type: InlineKeyboardMarkup or ReplyKeyboardMarkup or ReplyKeyboardRemove or ForceReply
3360
4542
  Required: Optional
@@ -3369,25 +4551,39 @@ children:
3369
4551
  Type: String
3370
4552
  Required: 'Yes'
3371
4553
  Description: Name of the sticker set
4554
+ - name: getCustomEmojiStickers
4555
+ children: []
4556
+ desc:
4557
+ - name: p
4558
+ content: Use this method to get information about custom emoji stickers by their identifiers. Returns an Array of Sticker objects.
4559
+ table:
4560
+ - Parameter: custom_emoji_ids
4561
+ Type: Array of String
4562
+ Required: 'Yes'
4563
+ Description: List of custom emoji identifiers. At most 200 custom emoji identifiers can be specified.
3372
4564
  - name: uploadStickerFile
3373
4565
  children: []
3374
4566
  desc:
3375
4567
  - name: p
3376
- content: Use this method to upload a .PNG file with a sticker for later use in createNewStickerSet and addStickerToSet methods (can be used multiple times). Returns the uploaded File on success.
4568
+ content: Use this method to upload a file with a sticker for later use in the createNewStickerSet and addStickerToSet methods (the file can be used multiple times). Returns the uploaded File on success.
3377
4569
  table:
3378
4570
  - Parameter: user_id
3379
4571
  Type: Integer
3380
4572
  Required: 'Yes'
3381
4573
  Description: User identifier of sticker file owner
3382
- - Parameter: png_sticker
4574
+ - Parameter: sticker
3383
4575
  Type: InputFile
3384
4576
  Required: 'Yes'
3385
- Description: PNG image with the sticker, must be up to 512 kilobytes in size, dimensions must not exceed 512px, and either width or height must be exactly 512px. More info on Sending Files »
4577
+ Description: A file with the sticker in .WEBP, .PNG, .TGS, or .WEBM format. See https://core.telegram.org/stickers for technical requirements. More information on Sending Files »
4578
+ - Parameter: sticker_format
4579
+ Type: String
4580
+ Required: 'Yes'
4581
+ Description: Format of the sticker, must be one of “static”, “animated”, “video”
3386
4582
  - name: createNewStickerSet
3387
4583
  children: []
3388
4584
  desc:
3389
4585
  - name: p
3390
- content: Use this method to create a new sticker set owned by a user. The bot will be able to edit the sticker set thus created. You must use exactly one of the fields png_sticker or tgs_sticker. Returns True on success.
4586
+ content: Use this method to create a new sticker set owned by a user. The bot will be able to edit the sticker set thus created. Returns True on success.
3391
4587
  table:
3392
4588
  - Parameter: user_id
3393
4589
  Type: Integer
@@ -3396,36 +4592,32 @@ children:
3396
4592
  - Parameter: name
3397
4593
  Type: String
3398
4594
  Required: 'Yes'
3399
- Description: Short name of sticker set, to be used in 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 _by_<bot username>”. <bot_username> is case insensitive. 1-64 characters.
4595
+ Description: Short name of sticker set, to be used in 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 "_by_<bot_username>". <bot_username> is case insensitive. 1-64 characters.
3400
4596
  - Parameter: title
3401
4597
  Type: String
3402
4598
  Required: 'Yes'
3403
4599
  Description: Sticker set title, 1-64 characters
3404
- - Parameter: png_sticker
3405
- Type: InputFile or String
3406
- Required: Optional
3407
- Description: PNG image with the sticker, must be up to 512 kilobytes in size, dimensions must not exceed 512px, and either width or height must be exactly 512px. Pass a file_id as a String to send a file that already exists on the Telegram servers, 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. More info on Sending Files »
3408
- - Parameter: tgs_sticker
3409
- Type: InputFile
3410
- Required: Optional
3411
- Description: TGS animation with the sticker, uploaded using multipart/form-data. See https://core.telegram.org/animated_stickers#technical-requirements for technical requirements
3412
- - Parameter: emojis
4600
+ - Parameter: stickers
4601
+ Type: Array of InputSticker
4602
+ Required: 'Yes'
4603
+ Description: A JSON-serialized list of 1-50 initial stickers to be added to the sticker set
4604
+ - Parameter: sticker_format
3413
4605
  Type: String
3414
4606
  Required: 'Yes'
3415
- Description: One or more emoji corresponding to the sticker
3416
- - Parameter: contains_masks
3417
- Type: Boolean
4607
+ Description: Format of stickers in the set, must be one of “static”, “animated”, “video”
4608
+ - Parameter: sticker_type
4609
+ Type: String
3418
4610
  Required: Optional
3419
- Description: Pass True, if a set of mask stickers should be created
3420
- - Parameter: mask_position
3421
- Type: MaskPosition
4611
+ Description: Type of stickers in the set, pass “regular”, “mask”, or “custom_emoji”. By default, a regular sticker set is created.
4612
+ - Parameter: needs_repainting
4613
+ Type: Boolean
3422
4614
  Required: Optional
3423
- Description: A JSON-serialized object for position where the mask should be placed on faces
4615
+ Description: Pass 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
3424
4616
  - name: addStickerToSet
3425
4617
  children: []
3426
4618
  desc:
3427
4619
  - name: p
3428
- content: Use this method to add a new sticker to a set created by the bot. You must use exactly one of the fields png_sticker or tgs_sticker. Animated stickers can be added to animated sticker sets and only to them. Animated sticker sets can have up to 50 stickers. Static sticker sets can have up to 120 stickers. Returns True on success.
4620
+ content: 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 True on success.
3429
4621
  table:
3430
4622
  - Parameter: user_id
3431
4623
  Type: Integer
@@ -3435,22 +4627,10 @@ children:
3435
4627
  Type: String
3436
4628
  Required: 'Yes'
3437
4629
  Description: Sticker set name
3438
- - Parameter: png_sticker
3439
- Type: InputFile or String
3440
- Required: Optional
3441
- Description: PNG image with the sticker, must be up to 512 kilobytes in size, dimensions must not exceed 512px, and either width or height must be exactly 512px. Pass a file_id as a String to send a file that already exists on the Telegram servers, 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. More info on Sending Files »
3442
- - Parameter: tgs_sticker
3443
- Type: InputFile
3444
- Required: Optional
3445
- Description: TGS animation with the sticker, uploaded using multipart/form-data. See https://core.telegram.org/animated_stickers#technical-requirements for technical requirements
3446
- - Parameter: emojis
3447
- Type: String
4630
+ - Parameter: sticker
4631
+ Type: InputSticker
3448
4632
  Required: 'Yes'
3449
- Description: One or more emoji corresponding to the sticker
3450
- - Parameter: mask_position
3451
- Type: MaskPosition
3452
- Required: Optional
3453
- Description: A JSON-serialized object for position where the mask should be placed on faces
4633
+ Description: A JSON-serialized object with information about the added sticker. If exactly the same sticker had already been added to the set, then the set isn't changed.
3454
4634
  - name: setStickerPositionInSet
3455
4635
  children: []
3456
4636
  desc:
@@ -3475,11 +4655,67 @@ children:
3475
4655
  Type: String
3476
4656
  Required: 'Yes'
3477
4657
  Description: File identifier of the sticker
3478
- - name: setStickerSetThumb
4658
+ - name: setStickerEmojiList
4659
+ children: []
4660
+ desc:
4661
+ - name: p
4662
+ content: Use this method to change the list of emoji assigned to a regular or custom emoji sticker. The sticker must belong to a sticker set created by the bot. Returns True on success.
4663
+ table:
4664
+ - Parameter: sticker
4665
+ Type: String
4666
+ Required: 'Yes'
4667
+ Description: File identifier of the sticker
4668
+ - Parameter: emoji_list
4669
+ Type: Array of String
4670
+ Required: 'Yes'
4671
+ Description: A JSON-serialized list of 1-20 emoji associated with the sticker
4672
+ - name: setStickerKeywords
4673
+ children: []
4674
+ desc:
4675
+ - name: p
4676
+ content: Use this method to change search keywords assigned to a regular or custom emoji sticker. The sticker must belong to a sticker set created by the bot. Returns True on success.
4677
+ table:
4678
+ - Parameter: sticker
4679
+ Type: String
4680
+ Required: 'Yes'
4681
+ Description: File identifier of the sticker
4682
+ - Parameter: keywords
4683
+ Type: Array of String
4684
+ Required: Optional
4685
+ Description: A JSON-serialized list of 0-20 search keywords for the sticker with total length of up to 64 characters
4686
+ - name: setStickerMaskPosition
4687
+ children: []
4688
+ desc:
4689
+ - name: p
4690
+ content: Use this method to change the mask position of a mask sticker. The sticker must belong to a sticker set that was created by the bot. Returns True on success.
4691
+ table:
4692
+ - Parameter: sticker
4693
+ Type: String
4694
+ Required: 'Yes'
4695
+ Description: File identifier of the sticker
4696
+ - Parameter: mask_position
4697
+ Type: MaskPosition
4698
+ Required: Optional
4699
+ Description: A JSON-serialized object with the position where the mask should be placed on faces. Omit the parameter to remove the mask position.
4700
+ - name: setStickerSetTitle
4701
+ children: []
4702
+ desc:
4703
+ - name: p
4704
+ content: Use this method to set the title of a created sticker set. Returns True on success.
4705
+ table:
4706
+ - Parameter: name
4707
+ Type: String
4708
+ Required: 'Yes'
4709
+ Description: Sticker set name
4710
+ - Parameter: title
4711
+ Type: String
4712
+ Required: 'Yes'
4713
+ Description: Sticker set title, 1-64 characters
4714
+ - name: setStickerSetThumbnail
3479
4715
  children: []
3480
4716
  desc:
3481
4717
  - name: p
3482
- content: Use this method to set the thumbnail of a sticker set. Animated thumbnails can be set for animated sticker sets only. Returns True on success.
4718
+ content: Use this method to set the thumbnail of a regular or mask sticker set. The format of the thumbnail file must match the format of the stickers in the set. Returns True on success.
3483
4719
  table:
3484
4720
  - Parameter: name
3485
4721
  Type: String
@@ -3489,10 +4725,34 @@ children:
3489
4725
  Type: Integer
3490
4726
  Required: 'Yes'
3491
4727
  Description: User identifier of the sticker set owner
3492
- - Parameter: thumb
4728
+ - Parameter: thumbnail
3493
4729
  Type: InputFile or String
3494
4730
  Required: Optional
3495
- Description: A PNG image with the thumbnail, must be up to 128 kilobytes in size and have width and height exactly 100px, or a TGS animation with the thumbnail up to 32 kilobytes in size; see https://core.telegram.org/animated_stickers#technical-requirements for animated sticker technical requirements. Pass a file_id as a String to send a file that already exists on the Telegram servers, 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. More info on Sending Files ». Animated sticker set thumbnail can't be uploaded via HTTP URL.
4731
+ Description: A .WEBP or .PNG image with the thumbnail, must be up to 128 kilobytes in size and have a width and height of exactly 100px, or a .TGS animation with a thumbnail up to 32 kilobytes in size (see https://core.telegram.org/stickers#animated-sticker-requirements for animated sticker technical requirements), or a WEBM video with the thumbnail up to 32 kilobytes in size; see https://core.telegram.org/stickers#video-sticker-requirements for video sticker technical requirements. Pass a file_id as a String to send a file that already exists on the Telegram servers, 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. More information on Sending Files ». Animated and video sticker set thumbnails can't be uploaded via HTTP URL. If omitted, then the thumbnail is dropped and the first sticker is used as the thumbnail.
4732
+ - name: setCustomEmojiStickerSetThumbnail
4733
+ children: []
4734
+ desc:
4735
+ - name: p
4736
+ content: Use this method to set the thumbnail of a custom emoji sticker set. Returns True on success.
4737
+ table:
4738
+ - Parameter: name
4739
+ Type: String
4740
+ Required: 'Yes'
4741
+ Description: Sticker set name
4742
+ - Parameter: custom_emoji_id
4743
+ Type: String
4744
+ Required: Optional
4745
+ Description: Custom emoji identifier of a sticker from the sticker set; pass an empty string to drop the thumbnail and use the first sticker as the thumbnail.
4746
+ - name: deleteStickerSet
4747
+ children: []
4748
+ desc:
4749
+ - name: p
4750
+ content: Use this method to delete a sticker set that was created by the bot. Returns True on success.
4751
+ table:
4752
+ - Parameter: name
4753
+ Type: String
4754
+ Required: 'Yes'
4755
+ Description: Sticker set name
3496
4756
  desc:
3497
4757
  - name: p
3498
4758
  content: The following methods and objects allow your bot to handle stickers and sticker sets.
@@ -3518,7 +4778,7 @@ children:
3518
4778
  Description: Offset of the results to be returned, can be controlled by the bot
3519
4779
  - Field: chat_type
3520
4780
  Type: String
3521
- Description: Optional. Type of the chat, from which the inline query was sent. Can be either “sender” for a private chat with the inline query sender, “private”, “group”, “supergroup”, or “channel”. The chat type should be always known for requests sent from official clients and most third-party clients, unless the request was sent from a secret chat
4781
+ Description: Optional. Type of the chat from which the inline query was sent. Can be either “sender” for a private chat with the inline query sender, “private”, “group”, “supergroup”, or “channel”. The chat type should be always known for requests sent from official clients and most third-party clients, unless the request was sent from a secret chat
3522
4782
  - Field: location
3523
4783
  Type: Location
3524
4784
  Description: Optional. Sender location, only for bots that request user location
@@ -3543,7 +4803,7 @@ children:
3543
4803
  - Parameter: is_personal
3544
4804
  Type: Boolean
3545
4805
  Required: Optional
3546
- Description: Pass True, if results may be cached on the server side only for the user that sent the query. By default, results may be returned to any user who sends the same query
4806
+ Description: Pass True if results may be cached on the server side only for the user that sent the query. By default, results may be returned to any user who sends the same query
3547
4807
  - Parameter: next_offset
3548
4808
  Type: String
3549
4809
  Required: Optional
@@ -3555,7 +4815,7 @@ children:
3555
4815
  - Parameter: switch_pm_parameter
3556
4816
  Type: String
3557
4817
  Required: Optional
3558
- Description: 'Deep-linking parameter for the /start message sent to the bot when user presses the switch button. 1-64 characters, only A-Z, a-z, 0-9, _ and - are allowed.Example: An inline bot that sends YouTube videos can ask the user to connect the bot to their YouTube account to adapt search results accordingly. To do this, it displays a ''Connect your YouTube account'' button above the results, or even before showing any. The user presses the button, switches to a private chat with the bot and, in doing so, passes a start parameter that instructs the bot to return an oauth link. Once done, the bot can offer a switch_inline button so that the user can easily return to the chat where they wanted to use the bot''s inline capabilities.'
4818
+ Description: 'Deep-linking parameter for the /start message sent to the bot when user presses the switch button. 1-64 characters, only A-Z, a-z, 0-9, _ and - are allowed.Example: An inline bot that sends YouTube videos can ask the user to connect the bot to their YouTube account to adapt search results accordingly. To do this, it displays a ''Connect your YouTube account'' button above the results, or even before showing any. The user presses the button, switches to a private chat with the bot and, in doing so, passes a start parameter that instructs the bot to return an OAuth link. Once done, the bot can offer a switch_inline button so that the user can easily return to the chat where they wanted to use the bot''s inline capabilities.'
3559
4819
  - name: InlineQueryResult
3560
4820
  children: []
3561
4821
  desc:
@@ -3611,17 +4871,17 @@ children:
3611
4871
  Description: Optional. URL of the result
3612
4872
  - Field: hide_url
3613
4873
  Type: Boolean
3614
- Description: Optional. Pass True, if you don't want the URL to be shown in the message
4874
+ Description: Optional. Pass True if you don't want the URL to be shown in the message
3615
4875
  - Field: description
3616
4876
  Type: String
3617
4877
  Description: Optional. Short description of the result
3618
- - Field: thumb_url
4878
+ - Field: thumbnail_url
3619
4879
  Type: String
3620
4880
  Description: Optional. Url of the thumbnail for the result
3621
- - Field: thumb_width
4881
+ - Field: thumbnail_width
3622
4882
  Type: Integer
3623
4883
  Description: Optional. Thumbnail width
3624
- - Field: thumb_height
4884
+ - Field: thumbnail_height
3625
4885
  Type: Integer
3626
4886
  Description: Optional. Thumbnail height
3627
4887
  - name: InlineQueryResultPhoto
@@ -3638,8 +4898,8 @@ children:
3638
4898
  Description: Unique identifier for this result, 1-64 bytes
3639
4899
  - Field: photo_url
3640
4900
  Type: String
3641
- Description: A valid URL of the photo. Photo must be in jpeg format. Photo size must not exceed 5MB
3642
- - Field: thumb_url
4901
+ Description: A valid URL of the photo. Photo must be in JPEG format. Photo size must not exceed 5MB
4902
+ - Field: thumbnail_url
3643
4903
  Type: String
3644
4904
  Description: URL of the thumbnail for the photo
3645
4905
  - Field: photo_width
@@ -3692,11 +4952,11 @@ children:
3692
4952
  Description: Optional. Height of the GIF
3693
4953
  - Field: gif_duration
3694
4954
  Type: Integer
3695
- Description: Optional. Duration of the GIF
3696
- - Field: thumb_url
4955
+ Description: Optional. Duration of the GIF in seconds
4956
+ - Field: thumbnail_url
3697
4957
  Type: String
3698
4958
  Description: URL of the static (JPEG or GIF) or animated (MPEG4) thumbnail for the result
3699
- - Field: thumb_mime_type
4959
+ - Field: thumbnail_mime_type
3700
4960
  Type: String
3701
4961
  Description: Optional. MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to “image/jpeg”
3702
4962
  - Field: title
@@ -3731,7 +4991,7 @@ children:
3731
4991
  Description: Unique identifier for this result, 1-64 bytes
3732
4992
  - Field: mpeg4_url
3733
4993
  Type: String
3734
- Description: A valid URL for the MP4 file. File size must not exceed 1MB
4994
+ Description: A valid URL for the MPEG4 file. File size must not exceed 1MB
3735
4995
  - Field: mpeg4_width
3736
4996
  Type: Integer
3737
4997
  Description: Optional. Video width
@@ -3740,11 +5000,11 @@ children:
3740
5000
  Description: Optional. Video height
3741
5001
  - Field: mpeg4_duration
3742
5002
  Type: Integer
3743
- Description: Optional. Video duration
3744
- - Field: thumb_url
5003
+ Description: Optional. Video duration in seconds
5004
+ - Field: thumbnail_url
3745
5005
  Type: String
3746
5006
  Description: URL of the static (JPEG or GIF) or animated (MPEG4) thumbnail for the result
3747
- - Field: thumb_mime_type
5007
+ - Field: thumbnail_mime_type
3748
5008
  Type: String
3749
5009
  Description: Optional. MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to “image/jpeg”
3750
5010
  - Field: title
@@ -3784,10 +5044,10 @@ children:
3784
5044
  Description: A valid URL for the embedded video player or video file
3785
5045
  - Field: mime_type
3786
5046
  Type: String
3787
- Description: Mime type of the content of video url, “text/html” or “video/mp4”
3788
- - Field: thumb_url
5047
+ Description: MIME type of the content of the video URL, “text/html” or “video/mp4”
5048
+ - Field: thumbnail_url
3789
5049
  Type: String
3790
- Description: URL of the thumbnail (jpeg only) for the video
5050
+ Description: URL of the thumbnail (JPEG only) for the video
3791
5051
  - Field: title
3792
5052
  Type: String
3793
5053
  Description: Title for the result
@@ -3928,7 +5188,7 @@ children:
3928
5188
  Description: A valid URL for the file
3929
5189
  - Field: mime_type
3930
5190
  Type: String
3931
- Description: Mime type of the content of the file, either “application/pdf” or “application/zip”
5191
+ Description: MIME type of the content of the file, either “application/pdf” or “application/zip”
3932
5192
  - Field: description
3933
5193
  Type: String
3934
5194
  Description: Optional. Short description of the result
@@ -3938,13 +5198,13 @@ children:
3938
5198
  - Field: input_message_content
3939
5199
  Type: InputMessageContent
3940
5200
  Description: Optional. Content of the message to be sent instead of the file
3941
- - Field: thumb_url
5201
+ - Field: thumbnail_url
3942
5202
  Type: String
3943
- Description: Optional. URL of the thumbnail (jpeg only) for the file
3944
- - Field: thumb_width
5203
+ Description: Optional. URL of the thumbnail (JPEG only) for the file
5204
+ - Field: thumbnail_width
3945
5205
  Type: Integer
3946
5206
  Description: Optional. Thumbnail width
3947
- - Field: thumb_height
5207
+ - Field: thumbnail_height
3948
5208
  Type: Integer
3949
5209
  Description: Optional. Thumbnail height
3950
5210
  - name: InlineQueryResultLocation
@@ -3988,13 +5248,13 @@ children:
3988
5248
  - Field: input_message_content
3989
5249
  Type: InputMessageContent
3990
5250
  Description: Optional. Content of the message to be sent instead of the location
3991
- - Field: thumb_url
5251
+ - Field: thumbnail_url
3992
5252
  Type: String
3993
5253
  Description: Optional. Url of the thumbnail for the result
3994
- - Field: thumb_width
5254
+ - Field: thumbnail_width
3995
5255
  Type: Integer
3996
5256
  Description: Optional. Thumbnail width
3997
- - Field: thumb_height
5257
+ - Field: thumbnail_height
3998
5258
  Type: Integer
3999
5259
  Description: Optional. Thumbnail height
4000
5260
  - name: InlineQueryResultVenue
@@ -4041,13 +5301,13 @@ children:
4041
5301
  - Field: input_message_content
4042
5302
  Type: InputMessageContent
4043
5303
  Description: Optional. Content of the message to be sent instead of the venue
4044
- - Field: thumb_url
5304
+ - Field: thumbnail_url
4045
5305
  Type: String
4046
5306
  Description: Optional. Url of the thumbnail for the result
4047
- - Field: thumb_width
5307
+ - Field: thumbnail_width
4048
5308
  Type: Integer
4049
5309
  Description: Optional. Thumbnail width
4050
- - Field: thumb_height
5310
+ - Field: thumbnail_height
4051
5311
  Type: Integer
4052
5312
  Description: Optional. Thumbnail height
4053
5313
  - name: InlineQueryResultContact
@@ -4082,13 +5342,13 @@ children:
4082
5342
  - Field: input_message_content
4083
5343
  Type: InputMessageContent
4084
5344
  Description: Optional. Content of the message to be sent instead of the contact
4085
- - Field: thumb_url
5345
+ - Field: thumbnail_url
4086
5346
  Type: String
4087
5347
  Description: Optional. Url of the thumbnail for the result
4088
- - Field: thumb_width
5348
+ - Field: thumbnail_width
4089
5349
  Type: Integer
4090
5350
  Description: Optional. Thumbnail width
4091
- - Field: thumb_height
5351
+ - Field: thumbnail_height
4092
5352
  Type: Integer
4093
5353
  Description: Optional. Thumbnail height
4094
5354
  - name: InlineQueryResultGame
@@ -4194,7 +5454,7 @@ children:
4194
5454
  Description: Unique identifier for this result, 1-64 bytes
4195
5455
  - Field: mpeg4_file_id
4196
5456
  Type: String
4197
- Description: A valid file identifier for the MP4 file
5457
+ Description: A valid file identifier for the MPEG4 file
4198
5458
  - Field: title
4199
5459
  Type: String
4200
5460
  Description: Optional. Title for the result
@@ -4496,7 +5756,7 @@ children:
4496
5756
  Description: Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use for your internal processes.
4497
5757
  - Field: provider_token
4498
5758
  Type: String
4499
- Description: Payment provider token, obtained via Botfather
5759
+ Description: Payment provider token, obtained via @BotFather
4500
5760
  - Field: currency
4501
5761
  Type: String
4502
5762
  Description: Three-letter ISO 4217 currency code, see more on currencies
@@ -4514,10 +5774,10 @@ children:
4514
5774
  Description: Optional. A JSON-serialized object for data about the invoice, which will be shared with the payment provider. A detailed description of the required fields should be provided by the payment provider.
4515
5775
  - Field: photo_url
4516
5776
  Type: String
4517
- Description: Optional. URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service. People like it better when they see what they are paying for.
5777
+ Description: Optional. URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service.
4518
5778
  - Field: photo_size
4519
5779
  Type: Integer
4520
- Description: Optional. Photo size
5780
+ Description: Optional. Photo size in bytes
4521
5781
  - Field: photo_width
4522
5782
  Type: Integer
4523
5783
  Description: Optional. Photo width
@@ -4526,32 +5786,32 @@ children:
4526
5786
  Description: Optional. Photo height
4527
5787
  - Field: need_name
4528
5788
  Type: Boolean
4529
- Description: Optional. Pass True, if you require the user's full name to complete the order
5789
+ Description: Optional. Pass True if you require the user's full name to complete the order
4530
5790
  - Field: need_phone_number
4531
5791
  Type: Boolean
4532
- Description: Optional. Pass True, if you require the user's phone number to complete the order
5792
+ Description: Optional. Pass True if you require the user's phone number to complete the order
4533
5793
  - Field: need_email
4534
5794
  Type: Boolean
4535
- Description: Optional. Pass True, if you require the user's email address to complete the order
5795
+ Description: Optional. Pass True if you require the user's email address to complete the order
4536
5796
  - Field: need_shipping_address
4537
5797
  Type: Boolean
4538
- Description: Optional. Pass True, if you require the user's shipping address to complete the order
5798
+ Description: Optional. Pass True if you require the user's shipping address to complete the order
4539
5799
  - Field: send_phone_number_to_provider
4540
5800
  Type: Boolean
4541
- Description: Optional. Pass True, if user's phone number should be sent to provider
5801
+ Description: Optional. Pass True if the user's phone number should be sent to provider
4542
5802
  - Field: send_email_to_provider
4543
5803
  Type: Boolean
4544
- Description: Optional. Pass True, if user's email address should be sent to provider
5804
+ Description: Optional. Pass True if the user's email address should be sent to provider
4545
5805
  - Field: is_flexible
4546
5806
  Type: Boolean
4547
- Description: Optional. Pass True, if the final price depends on the shipping method
5807
+ Description: Optional. Pass True if the final price depends on the shipping method
4548
5808
  - name: ChosenInlineResult
4549
5809
  children: []
4550
5810
  desc:
4551
5811
  - name: p
4552
5812
  content: Represents a result of an inline query that was chosen by the user and sent to their chat partner.
4553
5813
  - name: p
4554
- content: 'Note: It is necessary to enable inline feedback via @Botfather in order to receive these objects in updates.'
5814
+ content: 'Note: It is necessary to enable inline feedback via @BotFather in order to receive these objects in updates.'
4555
5815
  table:
4556
5816
  - Field: result_id
4557
5817
  Type: String
@@ -4568,6 +5828,29 @@ children:
4568
5828
  - Field: query
4569
5829
  Type: String
4570
5830
  Description: The query that was used to obtain the result
5831
+ - name: answerWebAppQuery
5832
+ children: []
5833
+ desc:
5834
+ - name: p
5835
+ content: Use this method to set the result of an interaction with a Web App and send a corresponding message on behalf of the user to the chat from which the query originated. On success, a SentWebAppMessage object is returned.
5836
+ table:
5837
+ - Parameter: web_app_query_id
5838
+ Type: String
5839
+ Required: 'Yes'
5840
+ Description: Unique identifier for the query to be answered
5841
+ - Parameter: result
5842
+ Type: InlineQueryResult
5843
+ Required: 'Yes'
5844
+ Description: A JSON-serialized object describing the message to be sent
5845
+ - name: SentWebAppMessage
5846
+ children: []
5847
+ desc:
5848
+ - name: p
5849
+ content: Describes an inline message sent by a Web App on behalf of a user.
5850
+ table:
5851
+ - Field: inline_message_id
5852
+ Type: String
5853
+ Description: Optional. Identifier of the sent inline message. Available only if there is an inline keyboard attached to the message.
4571
5854
  desc:
4572
5855
  - name: p
4573
5856
  content: The following methods and objects allow your bot to work in inline mode.Please see our Introduction to Inline bots for more details.
@@ -4585,6 +5868,10 @@ children:
4585
5868
  Type: Integer or String
4586
5869
  Required: 'Yes'
4587
5870
  Description: Unique identifier for the target chat or username of the target channel (in the format @channelusername)
5871
+ - Parameter: message_thread_id
5872
+ Type: Integer
5873
+ Required: Optional
5874
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
4588
5875
  - Parameter: title
4589
5876
  Type: String
4590
5877
  Required: 'Yes'
@@ -4600,7 +5887,7 @@ children:
4600
5887
  - Parameter: provider_token
4601
5888
  Type: String
4602
5889
  Required: 'Yes'
4603
- Description: Payments provider token, obtained via Botfather
5890
+ Description: Payment provider token, obtained via @BotFather
4604
5891
  - Parameter: currency
4605
5892
  Type: String
4606
5893
  Required: 'Yes'
@@ -4624,7 +5911,7 @@ children:
4624
5911
  - Parameter: provider_data
4625
5912
  Type: String
4626
5913
  Required: Optional
4627
- Description: A JSON-serialized data about the invoice, which will be shared with the payment provider. A detailed description of required fields should be provided by the payment provider.
5914
+ Description: JSON-serialized data about the invoice, which will be shared with the payment provider. A detailed description of required fields should be provided by the payment provider.
4628
5915
  - Parameter: photo_url
4629
5916
  Type: String
4630
5917
  Required: Optional
@@ -4632,7 +5919,7 @@ children:
4632
5919
  - Parameter: photo_size
4633
5920
  Type: Integer
4634
5921
  Required: Optional
4635
- Description: Photo size
5922
+ Description: Photo size in bytes
4636
5923
  - Parameter: photo_width
4637
5924
  Type: Integer
4638
5925
  Required: Optional
@@ -4644,35 +5931,39 @@ children:
4644
5931
  - Parameter: need_name
4645
5932
  Type: Boolean
4646
5933
  Required: Optional
4647
- Description: Pass True, if you require the user's full name to complete the order
5934
+ Description: Pass True if you require the user's full name to complete the order
4648
5935
  - Parameter: need_phone_number
4649
5936
  Type: Boolean
4650
5937
  Required: Optional
4651
- Description: Pass True, if you require the user's phone number to complete the order
5938
+ Description: Pass True if you require the user's phone number to complete the order
4652
5939
  - Parameter: need_email
4653
5940
  Type: Boolean
4654
5941
  Required: Optional
4655
- Description: Pass True, if you require the user's email address to complete the order
5942
+ Description: Pass True if you require the user's email address to complete the order
4656
5943
  - Parameter: need_shipping_address
4657
5944
  Type: Boolean
4658
5945
  Required: Optional
4659
- Description: Pass True, if you require the user's shipping address to complete the order
5946
+ Description: Pass True if you require the user's shipping address to complete the order
4660
5947
  - Parameter: send_phone_number_to_provider
4661
5948
  Type: Boolean
4662
5949
  Required: Optional
4663
- Description: Pass True, if user's phone number should be sent to provider
5950
+ Description: Pass True if the user's phone number should be sent to provider
4664
5951
  - Parameter: send_email_to_provider
4665
5952
  Type: Boolean
4666
5953
  Required: Optional
4667
- Description: Pass True, if user's email address should be sent to provider
5954
+ Description: Pass True if the user's email address should be sent to provider
4668
5955
  - Parameter: is_flexible
4669
5956
  Type: Boolean
4670
5957
  Required: Optional
4671
- Description: Pass True, if the final price depends on the shipping method
5958
+ Description: Pass True if the final price depends on the shipping method
4672
5959
  - Parameter: disable_notification
4673
5960
  Type: Boolean
4674
5961
  Required: Optional
4675
5962
  Description: Sends the message silently. Users will receive a notification with no sound.
5963
+ - Parameter: protect_content
5964
+ Type: Boolean
5965
+ Required: Optional
5966
+ Description: Protects the contents of the sent message from forwarding and saving
4676
5967
  - Parameter: reply_to_message_id
4677
5968
  Type: Integer
4678
5969
  Required: Optional
@@ -4680,11 +5971,97 @@ children:
4680
5971
  - Parameter: allow_sending_without_reply
4681
5972
  Type: Boolean
4682
5973
  Required: Optional
4683
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
5974
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
4684
5975
  - Parameter: reply_markup
4685
5976
  Type: InlineKeyboardMarkup
4686
5977
  Required: Optional
4687
5978
  Description: A JSON-serialized object for an inline keyboard. If empty, one 'Pay total price' button will be shown. If not empty, the first button must be a Pay button.
5979
+ - name: createInvoiceLink
5980
+ children: []
5981
+ desc:
5982
+ - name: p
5983
+ content: Use this method to create a link for an invoice. Returns the created invoice link as String on success.
5984
+ table:
5985
+ - Parameter: title
5986
+ Type: String
5987
+ Required: 'Yes'
5988
+ Description: Product name, 1-32 characters
5989
+ - Parameter: description
5990
+ Type: String
5991
+ Required: 'Yes'
5992
+ Description: Product description, 1-255 characters
5993
+ - Parameter: payload
5994
+ Type: String
5995
+ Required: 'Yes'
5996
+ Description: Bot-defined invoice payload, 1-128 bytes. This will not be displayed to the user, use for your internal processes.
5997
+ - Parameter: provider_token
5998
+ Type: String
5999
+ Required: 'Yes'
6000
+ Description: Payment provider token, obtained via BotFather
6001
+ - Parameter: currency
6002
+ Type: String
6003
+ Required: 'Yes'
6004
+ Description: Three-letter ISO 4217 currency code, see more on currencies
6005
+ - Parameter: prices
6006
+ Type: Array of LabeledPrice
6007
+ Required: 'Yes'
6008
+ Description: Price breakdown, a JSON-serialized list of components (e.g. product price, tax, discount, delivery cost, delivery tax, bonus, etc.)
6009
+ - Parameter: max_tip_amount
6010
+ Type: Integer
6011
+ Required: Optional
6012
+ Description: The maximum accepted amount for tips in the smallest units of the currency (integer, not float/double). For example, for a maximum tip of US$ 1.45 pass max_tip_amount = 145. See the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies). Defaults to 0
6013
+ - Parameter: suggested_tip_amounts
6014
+ Type: Array of Integer
6015
+ Required: Optional
6016
+ Description: A JSON-serialized array of suggested amounts of tips in the smallest units of the currency (integer, not float/double). At most 4 suggested tip amounts can be specified. The suggested tip amounts must be positive, passed in a strictly increased order and must not exceed max_tip_amount.
6017
+ - Parameter: provider_data
6018
+ Type: String
6019
+ Required: Optional
6020
+ Description: JSON-serialized data about the invoice, which will be shared with the payment provider. A detailed description of required fields should be provided by the payment provider.
6021
+ - Parameter: photo_url
6022
+ Type: String
6023
+ Required: Optional
6024
+ Description: URL of the product photo for the invoice. Can be a photo of the goods or a marketing image for a service.
6025
+ - Parameter: photo_size
6026
+ Type: Integer
6027
+ Required: Optional
6028
+ Description: Photo size in bytes
6029
+ - Parameter: photo_width
6030
+ Type: Integer
6031
+ Required: Optional
6032
+ Description: Photo width
6033
+ - Parameter: photo_height
6034
+ Type: Integer
6035
+ Required: Optional
6036
+ Description: Photo height
6037
+ - Parameter: need_name
6038
+ Type: Boolean
6039
+ Required: Optional
6040
+ Description: Pass True if you require the user's full name to complete the order
6041
+ - Parameter: need_phone_number
6042
+ Type: Boolean
6043
+ Required: Optional
6044
+ Description: Pass True if you require the user's phone number to complete the order
6045
+ - Parameter: need_email
6046
+ Type: Boolean
6047
+ Required: Optional
6048
+ Description: Pass True if you require the user's email address to complete the order
6049
+ - Parameter: need_shipping_address
6050
+ Type: Boolean
6051
+ Required: Optional
6052
+ Description: Pass True if you require the user's shipping address to complete the order
6053
+ - Parameter: send_phone_number_to_provider
6054
+ Type: Boolean
6055
+ Required: Optional
6056
+ Description: Pass True if the user's phone number should be sent to the provider
6057
+ - Parameter: send_email_to_provider
6058
+ Type: Boolean
6059
+ Required: Optional
6060
+ Description: Pass True if the user's email address should be sent to the provider
6061
+ - Parameter: is_flexible
6062
+ Type: Boolean
6063
+ Required: Optional
6064
+ Description: Pass True if the final price depends on the shipping method
4688
6065
  - name: answerShippingQuery
4689
6066
  children: []
4690
6067
  desc:
@@ -4698,7 +6075,7 @@ children:
4698
6075
  - Parameter: ok
4699
6076
  Type: Boolean
4700
6077
  Required: 'Yes'
4701
- Description: Specify True if delivery to the specified address is possible and False if there are any problems (for example, if delivery to the specified address is not possible)
6078
+ Description: Pass True if delivery to the specified address is possible and False if there are any problems (for example, if delivery to the specified address is not possible)
4702
6079
  - Parameter: shipping_options
4703
6080
  Type: Array of ShippingOption
4704
6081
  Required: Optional
@@ -4766,7 +6143,7 @@ children:
4766
6143
  table:
4767
6144
  - Field: country_code
4768
6145
  Type: String
4769
- Description: ISO 3166-1 alpha-2 country code
6146
+ Description: Two-letter ISO 3166-1 alpha-2 country code
4770
6147
  - Field: state
4771
6148
  Type: String
4772
6149
  Description: State, if applicable
@@ -4835,7 +6212,7 @@ children:
4835
6212
  Description: Optional. Identifier of the shipping option chosen by the user
4836
6213
  - Field: order_info
4837
6214
  Type: OrderInfo
4838
- Description: Optional. Order info provided by the user
6215
+ Description: Optional. Order information provided by the user
4839
6216
  - Field: telegram_payment_charge_id
4840
6217
  Type: String
4841
6218
  Description: Telegram payment identifier
@@ -4886,7 +6263,7 @@ children:
4886
6263
  Description: Optional. Identifier of the shipping option chosen by the user
4887
6264
  - Field: order_info
4888
6265
  Type: OrderInfo
4889
- Description: Optional. Order info provided by the user
6266
+ Description: Optional. Order information provided by the user
4890
6267
  desc:
4891
6268
  - name: p
4892
6269
  content: Your bot can accept payments from Telegram users. Please see the introduction to payments for more details on the process and how to set up payments for your bot. Please note that users will need Telegram v.4.0 or higher to use payments (released on May 18, 2017).
@@ -4896,7 +6273,7 @@ children:
4896
6273
  children: []
4897
6274
  desc:
4898
6275
  - name: p
4899
- content: Contains information about Telegram Passport data shared with the bot by the user.
6276
+ content: Describes Telegram Passport data shared with the bot by the user.
4900
6277
  table:
4901
6278
  - Field: data
4902
6279
  Type: Array of EncryptedPassportElement
@@ -4918,7 +6295,7 @@ children:
4918
6295
  Description: Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.
4919
6296
  - Field: file_size
4920
6297
  Type: Integer
4921
- Description: File size
6298
+ Description: File size in bytes
4922
6299
  - Field: file_date
4923
6300
  Type: Integer
4924
6301
  Description: Unix time when the file was uploaded
@@ -4926,7 +6303,7 @@ children:
4926
6303
  children: []
4927
6304
  desc:
4928
6305
  - name: p
4929
- content: Contains information about documents or other Telegram Passport elements shared with the bot by the user.
6306
+ content: Describes documents or other Telegram Passport elements shared with the bot by the user.
4930
6307
  table:
4931
6308
  - Field: type
4932
6309
  Type: String
@@ -4962,7 +6339,7 @@ children:
4962
6339
  children: []
4963
6340
  desc:
4964
6341
  - name: p
4965
- content: Contains data required for decrypting and authenticating EncryptedPassportElement. See the Telegram Passport Documentation for a complete description of the data decryption and authentication processes.
6342
+ content: Describes data required for decrypting and authenticating EncryptedPassportElement. See the Telegram Passport Documentation for a complete description of the data decryption and authentication processes.
4966
6343
  table:
4967
6344
  - Field: data
4968
6345
  Type: String
@@ -5185,14 +6562,22 @@ children:
5185
6562
  Type: Integer
5186
6563
  Required: 'Yes'
5187
6564
  Description: Unique identifier for the target chat
6565
+ - Parameter: message_thread_id
6566
+ Type: Integer
6567
+ Required: Optional
6568
+ Description: Unique identifier for the target message thread (topic) of the forum; for forum supergroups only
5188
6569
  - Parameter: game_short_name
5189
6570
  Type: String
5190
6571
  Required: 'Yes'
5191
- Description: Short name of the game, serves as the unique identifier for the game. Set up your games via Botfather.
6572
+ Description: Short name of the game, serves as the unique identifier for the game. Set up your games via @BotFather.
5192
6573
  - Parameter: disable_notification
5193
6574
  Type: Boolean
5194
6575
  Required: Optional
5195
6576
  Description: Sends the message silently. Users will receive a notification with no sound.
6577
+ - Parameter: protect_content
6578
+ Type: Boolean
6579
+ Required: Optional
6580
+ Description: Protects the contents of the sent message from forwarding and saving
5196
6581
  - Parameter: reply_to_message_id
5197
6582
  Type: Integer
5198
6583
  Required: Optional
@@ -5200,7 +6585,7 @@ children:
5200
6585
  - Parameter: allow_sending_without_reply
5201
6586
  Type: Boolean
5202
6587
  Required: Optional
5203
- Description: Pass True, if the message should be sent even if the specified replied-to message is not found
6588
+ Description: Pass True if the message should be sent even if the specified replied-to message is not found
5204
6589
  - Parameter: reply_markup
5205
6590
  Type: InlineKeyboardMarkup
5206
6591
  Required: Optional
@@ -5238,7 +6623,7 @@ children:
5238
6623
  children: []
5239
6624
  desc:
5240
6625
  - name: p
5241
- content: Use this method to set the score of the specified user in a game. On success, if the message was sent by the bot, returns the edited Message, otherwise returns True. Returns an error, if the new score is not greater than the user's current score in the chat and force is False.
6626
+ content: Use this method to set the score of the specified user in a game message. On success, if the message is not an inline message, the Message is returned, otherwise True is returned. Returns an error, if the new score is not greater than the user's current score in the chat and force is False.
5242
6627
  table:
5243
6628
  - Parameter: user_id
5244
6629
  Type: Integer
@@ -5251,11 +6636,11 @@ children:
5251
6636
  - Parameter: force
5252
6637
  Type: Boolean
5253
6638
  Required: Optional
5254
- Description: Pass True, if the high score is allowed to decrease. This can be useful when fixing mistakes or banning cheaters
6639
+ Description: Pass True if the high score is allowed to decrease. This can be useful when fixing mistakes or banning cheaters
5255
6640
  - Parameter: disable_edit_message
5256
6641
  Type: Boolean
5257
6642
  Required: Optional
5258
- Description: Pass True, if the game message should not be automatically edited to include the current scoreboard
6643
+ Description: Pass True if the game message should not be automatically edited to include the current scoreboard
5259
6644
  - Parameter: chat_id
5260
6645
  Type: Integer
5261
6646
  Required: Optional
@@ -5272,9 +6657,9 @@ children:
5272
6657
  children: []
5273
6658
  desc:
5274
6659
  - name: p
5275
- content: Use this method to get data for high score tables. Will return the score of the specified user and several of their neighbors in a game. On success, returns an Array of GameHighScore objects.
6660
+ content: Use this method to get data for high score tables. Will return the score of the specified user and several of their neighbors in a game. Returns an Array of GameHighScore objects.
5276
6661
  - name: blockquote
5277
- content: This method will currently return scores for the target user, plus two of their closest neighbors on each side. Will also return the top three users if the user and his neighbors are not among them. Please note that this behavior is subject to change.
6662
+ content: This method will currently return scores for the target user, plus two of their closest neighbors on each side. Will also return the top three users if the user and their neighbors are not among them. Please note that this behavior is subject to change.
5278
6663
  table:
5279
6664
  - Parameter: user_id
5280
6665
  Type: Integer