diff --git a/data/web/corefork.telegram.org/api/antispam.html b/data/web/corefork.telegram.org/api/antispam.html index 3ceb8875dc..b474c33216 100644 --- a/data/web/corefork.telegram.org/api/antispam.html +++ b/data/web/corefork.telegram.org/api/antispam.html @@ -46,7 +46,7 @@
Admins of supergroups with a certain number of members can choose to unleash the full proactive power of Telegram's own antispam algorithms – turning on the new Aggressive mode for the automated spam filters.
Schema:
-channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
+channelFull#723027bd flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions stories:flags2.4?PeerStories = ChatFull;
channelAdminLogEventActionToggleAntiSpam#64f36dfc new_value:Bool = ChannelAdminLogEventAction;
channelAdminLogEventActionDeleteMessage#42e047bb message:Message = ChannelAdminLogEventAction;
diff --git a/data/web/corefork.telegram.org/api/bots/attach.html b/data/web/corefork.telegram.org/api/bots/attach.html
index c62839b6cb..aaf08962da 100644
--- a/data/web/corefork.telegram.org/api/bots/attach.html
+++ b/data/web/corefork.telegram.org/api/bots/attach.html
@@ -46,11 +46,11 @@
Bots can install attachment menu entries, offering conveniently accessible, versatile web apps.
Schema:
-user#8f97c628 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> = User;
+user#abb5f120 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true close_friend:flags2.2?true stories_hidden:flags2.3?true stories_unavailable:flags2.4?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> stories_max_id:flags2.5?int = User;
attachMenuBotsBot#93bf667f bot:AttachMenuBot users:Vector<User> = AttachMenuBotsBot;
-attachMenuBot#c8aa2cd2 flags:# inactive:flags.0?true has_settings:flags.1?true request_write_access:flags.2?true bot_id:long short_name:string peer_types:Vector<AttachMenuPeerType> icons:Vector<AttachMenuBotIcon> = AttachMenuBot;
+attachMenuBot#d90d8dfe flags:# inactive:flags.0?true has_settings:flags.1?true request_write_access:flags.2?true show_in_attach_menu:flags.3?true show_in_side_menu:flags.4?true side_menu_disclaimer_needed:flags.5?true bot_id:long short_name:string peer_types:flags.3?Vector<AttachMenuPeerType> icons:Vector<AttachMenuBotIcon> = AttachMenuBot;
attachMenuPeerTypeSameBotPM#7d6be90e = AttachMenuPeerType;
attachMenuPeerTypeBotPM#c32bfa1a = AttachMenuPeerType;
diff --git a/data/web/corefork.telegram.org/api/bots/buttons.html b/data/web/corefork.telegram.org/api/bots/buttons.html
index d06e364a74..7a4897606d 100644
--- a/data/web/corefork.telegram.org/api/bots/buttons.html
+++ b/data/web/corefork.telegram.org/api/bots/buttons.html
@@ -72,7 +72,7 @@ This article describes the full button flow, using the MTProto API.
---functions---
-messages.sendMessage#1cc20387 flags:# no_webpage:flags.1?true silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMessage#280d096f flags:# no_webpage:flags.1?true silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
Bots can attach a ReplyMarkup constructor to outgoing messages, to attach an inline keyboard or a custom reply keyboard:
- replyKeyboardMarkup - Sends a custom reply keyboard.
User clients receiving such a constructor should display a special keyboard with custom reply options.
diff --git a/data/web/corefork.telegram.org/api/bots/commands.html b/data/web/corefork.telegram.org/api/bots/commands.html
index 1bad50e588..a032902aea 100644
--- a/data/web/corefork.telegram.org/api/bots/commands.html
+++ b/data/web/corefork.telegram.org/api/bots/commands.html
@@ -51,10 +51,10 @@
botInfo#8f300b57 flags:# user_id:flags.0?long description:flags.1?string description_photo:flags.4?Photo description_document:flags.5?Document commands:flags.2?Vector<BotCommand> menu_button:flags.3?BotMenuButton = BotInfo;
-channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
-userFull#93eadb53 flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true translations_disabled:flags.23?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> wallpaper:flags.24?WallPaper = UserFull;
+channelFull#723027bd flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions stories:flags2.4?PeerStories = ChatFull;
+userFull#b9b12c6c flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true translations_disabled:flags.23?true stories_pinned_available:flags.26?true blocked_my_stories_from:flags.27?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> wallpaper:flags.24?WallPaper stories:flags.25?PeerStories = UserFull;
-user#8f97c628 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> = User;
+user#abb5f120 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true close_friend:flags2.2?true stories_hidden:flags2.3?true stories_unavailable:flags2.4?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> stories_max_id:flags2.5?int = User;
The botInfo constructors contained in the userFull, chatFull, channelFull contain a list of commands, and for groups, the ID and a description of each bot.
In graphical clients, when users begin a message with a /
, a list of commands supported by all bots present in the current chat should be shown; the same should be done for one-to-one chats with the bot itself.
If the command list of a bot changes, the bot_info_version
contained in the user constructor received in updates will change; this indicates that the client should refetch full bot information using users.getFullUser.
Bots can directly send a game using messages.sendMedia, providing:
inputGameShortName.short_name
Interactive HTML5 Mini Apps on Telegram can completely replace any website.
They support seamless authorization, integrated payments via multiple payment providers (with Google Pay and Apple Pay out of the box), delivering tailored push notifications to users, and much more.
-This article offers a client-side overview of the implementation of bot mini apps using the MTProto API: see here for an overview of the mini-app side JS API ».
-Both simple and normal Mini Apps can send web events starting with web_app_
; see the web event documentation for the full list of events that can be sent by the Mini App to the client ».
Mini Apps can also receive events, by exposing a window.Telegram.WebView.receiveEvent("event_name", params)
method.
Here's the full list of events that can be received by a Mini App from the client, by calling the receiveEvent
method.
main_button_pressed
This article offers a client-side overview of the implementation of bot mini apps using the MTProto API: see here for an overview of the mini-app side JS API ».
+Both simple and normal Mini Apps can send web events starting with web_app_
; see the web event documentation for the full list of events that can be sent by the Mini App to the client ».
Mini Apps can also receive events, by exposing a window.Telegram.WebView.receiveEvent("event_name", params)
method.
Here's the full list of events that can be received by a Mini App from the client, by calling the receiveEvent
method.
main_button_pressed
Params: null
Sent by the client when the user presses the main button located at the bottom of the webview, handle this event only if the main button was previously configured by a web_app_setup_main_button
event ».
settings_button_pressed
Sent by the client when the user presses the main button located at the bottom of the webview, handle this event only if the main button was previously configured by a web_app_setup_main_button
event ».
settings_button_pressed
Params: null
Sent by the client when the user presses the settings button, if it was previously enabled in @BotFather, as specified by the has_settings
flag of attachMenuBot ».
back_button_pressed
Sent by the client when the user presses the settings button, if it was previously enabled in @BotFather, as specified by the has_settings
flag of attachMenuBot ».
back_button_pressed
Params: null
Sent by the client when the user presses the (OS or UI) back button, if it was previously enabled by a web_app_setup_back_button
event ».
invoice_closed
Sent by the client when the user presses the (OS or UI) back button, if it was previously enabled by a web_app_setup_back_button
event ».
invoice_closed
Params: JSON object with the following fields:
slug
- Invoice identifier (string)status
- One of the following values (string):cancelled
– The user closed the invoice popup without paying, before the call to payments.sendPaymentForm.failed
– The user tried to pay, but the payment failed: the call to payments.sendPaymentForm returned an RPC error and the popup was closed.pending
– The payment is still processing: the bot will receive a further service message about a successful payment. payments.sendPaymentForm was successfully invoked returning payments.paymentVerificationNeeded, the user completed all additional verification forms returned by the method and the invoice popup was closed, but the client hasn't received a messageActionPaymentSent service message yet.failed
event if the user fails additional validation (ie 3-D Secure) returned by payments.paymentVerificationNeeded: the state will remaing pending
. paid
– The invoice was paid successfully: the client completed the payment flow », the invoice popup was closed and a messageActionPaymentSent service message was received by the client.pending
– The payment is still processing: the bot will receive a further service message about a successful payment. payments.sendPaymentForm was successfully invoked returning payments.paymentVerificationNeeded, the user completed all additional verification forms returned by the method and the invoice popup was closed, but the client hasn't received a messageActionPaymentSent service message yet.failed
event if the user fails additional validation (ie 3-D Secure) returned by payments.paymentVerificationNeeded: the state will remaing pending
. paid
– The invoice was paid successfully: the client completed the payment flow », the invoice popup was closed and a messageActionPaymentSent service message was received by the client.Sent by the client to report the payment status of an invoice obtained from a web_app_open_invoice
event ».
viewport_changed
Sent by the client to report the payment status of an invoice obtained from a web_app_open_invoice
event ».
viewport_changed
Params: a JSON object with the following fields:
height
- The current height of the visible area of the Mini App (excluding the bottom main button, if visible) (integer)is_expanded
- Whether the Mini App is expanded to its maximum height after the user swiped up or after the Mini App emitted a web_app_expand event (boolean)Emitted when the viewport is changed.
-theme_changed
theme_changed
Params: a JSON object with the following fields:
theme_params
: A theme parameters object » (object)theme_params
: A theme parameters object » (object)Emitted when requested by the Mini App using a web_app_request_theme
event », or when the app theme changes.
popup_closed
Emitted when requested by the Mini App using a web_app_request_theme
event », or when the app theme changes.
popup_closed
Params: a JSON object with an optional button_id
string field.
Emitted when the user presses a button or cancels a popup brought up by a previous web_app_open_popup
event ».
Emitted when the user presses a button or cancels a popup brought up by a previous web_app_open_popup
event ».
Schema:
-replyKeyboardMarkup#85dd99d1 flags:# resize:flags.0?true single_use:flags.1?true selective:flags.2?true persistent:flags.4?true rows:Vector<KeyboardButtonRow> placeholder:flags.3?string = ReplyMarkup;
+replyKeyboardMarkup#85dd99d1 flags:# resize:flags.0?true single_use:flags.1?true selective:flags.2?true persistent:flags.4?true rows:Vector<KeyboardButtonRow> placeholder:flags.3?string = ReplyMarkup;
-keyboardButtonSimpleWebView#a0c0505c text:string url:string = KeyboardButton;
+keyboardButtonSimpleWebView#a0c0505c text:string url:string = KeyboardButton;
-messageActionWebViewDataSentMe#47dd8079 text:string data:string = MessageAction;
-messageActionWebViewDataSent#b4c38cb5 text:string = MessageAction;
+messageActionWebViewDataSentMe#47dd8079 text:string data:string = MessageAction;
+messageActionWebViewDataSent#b4c38cb5 text:string = MessageAction;
-simpleWebViewResultUrl#882f76bb url:string = SimpleWebViewResult;
+simpleWebViewResultUrl#882f76bb url:string = SimpleWebViewResult;
---functions---
-messages.requestSimpleWebView#299bec8e flags:# from_switch_webview:flags.1?true bot:InputUser url:string theme_params:flags.0?DataJSON platform:string = SimpleWebViewResult;
+messages.requestSimpleWebView#1a46500a flags:# from_switch_webview:flags.1?true from_side_menu:flags.2?true bot:InputUser url:flags.3?string start_param:flags.4?string theme_params:flags.0?DataJSON platform:string = SimpleWebViewResult;
-messages.sendWebViewData#dc0242c8 bot:InputUser random_id:long button_text:string data:string = Updates;
-Simple Mini Apps can only send data back to the bot through the MTProto API via a web_app_data_send
JS event ».
+messages.sendWebViewData#dc0242c8 bot:InputUser random_id:long button_text:string data:string = Updates;
+Simple Mini Apps can only send data back to the bot through the MTProto API via a web_app_data_send
JS event ».
Simple Mini Apps can be opened from a keyboardButtonSimpleWebView button contained in a reply keyboard identified by a replyKeyboardMarkup constructor, or by clicking on the inlineBotWebView button on top of the inline result list, contained in messages.botResults.switch_webview
, returned by messages.getInlineBotResults.
To open them, users should call messages.requestSimpleWebView passing the original url
, and then open a webview using the url
contained in the returned simpleWebViewResultUrl.
If and only if the Mini App was opened from a keyboardButtonSimpleWebView reply keyboard button, upon receiving a web_app_data_send
JS event » from the Mini App, clients should invoke messages.sendWebViewData, passing the following arguments:
If and only if the Mini App was opened from a keyboardButtonSimpleWebView reply keyboard button, upon receiving a web_app_data_send
JS event » from the Mini App, clients should invoke messages.sendWebViewData, passing the following arguments:
bot
- Bot IDrandom_id
- Unique random ID to avoid resending the same event multiple timesAlways ignore all web_app_data_send
events received from inlineBotWebView Mini Apps, as only keyboardButtonSimpleWebView Mini Apps can send this event.
Make sure to ignore all web_app_data_send
events sent after the first one, messages.sendWebViewData must be called only once. The webview must be closed after invoking the messages.sendWebViewData method.
This will generate a messageActionWebViewDataSent update for the user, and a messageActionWebViewDataSentMe update for the bot, containing the event data.
-Schema:
-keyboardButtonWebView#13767230 text:string url:string = KeyboardButton;
-botMenuButton#c7b57ce6 text:string url:string = BotMenuButton;
+keyboardButtonWebView#13767230 text:string url:string = KeyboardButton;
+botMenuButton#c7b57ce6 text:string url:string = BotMenuButton;
-webViewResultUrl#c14557c query_id:long url:string = WebViewResult;
+webViewResultUrl#c14557c query_id:long url:string = WebViewResult;
-inputBotInlineResult#88bf9319 flags:# id:string type:string title:flags.1?string description:flags.2?string url:flags.3?string thumb:flags.4?InputWebDocument content:flags.5?InputWebDocument send_message:InputBotInlineMessage = InputBotInlineResult;
-inputBotInlineResultPhoto#a8d864a7 id:string type:string photo:InputPhoto send_message:InputBotInlineMessage = InputBotInlineResult;
-inputBotInlineResultDocument#fff8fdc4 flags:# id:string type:string title:flags.1?string description:flags.2?string document:InputDocument send_message:InputBotInlineMessage = InputBotInlineResult;
-inputBotInlineResultGame#4fa417f2 id:string short_name:string send_message:InputBotInlineMessage = InputBotInlineResult;
+inputBotInlineResult#88bf9319 flags:# id:string type:string title:flags.1?string description:flags.2?string url:flags.3?string thumb:flags.4?InputWebDocument content:flags.5?InputWebDocument send_message:InputBotInlineMessage = InputBotInlineResult;
+inputBotInlineResultPhoto#a8d864a7 id:string type:string photo:InputPhoto send_message:InputBotInlineMessage = InputBotInlineResult;
+inputBotInlineResultDocument#fff8fdc4 flags:# id:string type:string title:flags.1?string description:flags.2?string document:InputDocument send_message:InputBotInlineMessage = InputBotInlineResult;
+inputBotInlineResultGame#4fa417f2 id:string short_name:string send_message:InputBotInlineMessage = InputBotInlineResult;
-updateWebViewResultSent#1592b79d query_id:long = Update;
-webViewMessageSent#c94511c flags:# msg_id:flags.0?InputBotInlineMessageID = WebViewMessageSent;
+updateWebViewResultSent#1592b79d query_id:long = Update;
+webViewMessageSent#c94511c flags:# msg_id:flags.0?InputBotInlineMessageID = WebViewMessageSent;
---functions---
-messages.requestWebView#178b480b flags:# from_bot_menu:flags.4?true silent:flags.5?true peer:InputPeer bot:InputUser url:flags.1?string start_param:flags.3?string theme_params:flags.2?DataJSON platform:string reply_to_msg_id:flags.0?int top_msg_id:flags.9?int send_as:flags.13?InputPeer = WebViewResult;
+messages.requestWebView#269dc2c1 flags:# from_bot_menu:flags.4?true silent:flags.5?true peer:InputPeer bot:InputUser url:flags.1?string start_param:flags.3?string theme_params:flags.2?DataJSON platform:string reply_to:flags.0?InputReplyTo send_as:flags.13?InputPeer = WebViewResult;
-messages.prolongWebView#7ff34309 flags:# silent:flags.5?true peer:InputPeer bot:InputUser query_id:long reply_to_msg_id:flags.0?int top_msg_id:flags.9?int send_as:flags.13?InputPeer = Bool;
+messages.prolongWebView#b0d81a83 flags:# silent:flags.5?true peer:InputPeer bot:InputUser query_id:long reply_to:flags.0?InputReplyTo send_as:flags.13?InputPeer = Bool;
-messages.sendWebViewResultMessage#a4314f5 bot_query_id:string result:InputBotInlineResult = WebViewMessageSent;
-Normal Mini Apps work similarly to inline bots »: they send messages on behalf of the user to the chat from which the query originated.
+messages.sendWebViewResultMessage#a4314f5 bot_query_id:string result:InputBotInlineResult = WebViewMessageSent;
+Normal Mini Apps work similarly to inline bots »: they send messages on behalf of the user to the chat from which the query originated.
Normal Mini Apps can be opened from:
url
must be passed to messages.requestWebView.url
.from_bot_menu
flag should be set.start_parameter
should be provided to messages.requestWebView.start_param
, if present.from_bot_menu
flag should be set.start_parameter
should be provided to messages.requestWebView.start_param
, if present.To open them, clients should call messages.requestWebView, and then open a webview using the url
contained in the returned webViewResultUrl.
After loading the webview, until it is closed by a web_app_close event, the user client must invoke messages.prolongWebView every 60 seconds: if the method call returns QUERY_ID_INVALID
, the webview must be closed.
The opened URL's fragment parameters already contain basic information about the user and a query_id
parameter, that is exposed by the bot Mini Apps JS library: this query_id
can then be used by the bot to invoke messages.sendWebViewResultMessage, passing an InputBotInlineResult constructor that will automatically send a message with optionally attached media, and even inline buttons on behalf of the user.
The opened URL's fragment parameters already contain basic information about the user and a query_id
parameter, that is exposed by the bot Mini Apps JS library: this query_id
can then be used by the bot to invoke messages.sendWebViewResultMessage, passing an InputBotInlineResult constructor that will automatically send a message with optionally attached media, and even inline buttons on behalf of the user.
Schema:
-inputBotAppID#a920bd7a id:long access_hash:long = InputBotApp;
-inputBotAppShortName#908c0407 bot_id:InputUser short_name:string = InputBotApp;
+inputBotAppID#a920bd7a id:long access_hash:long = InputBotApp;
+inputBotAppShortName#908c0407 bot_id:InputUser short_name:string = InputBotApp;
-botAppNotModified#5da674b7 = BotApp;
-botApp#95fcd1d6 flags:# id:long access_hash:long short_name:string title:string description:string photo:Photo document:flags.0?Document hash:long = BotApp;
+botAppNotModified#5da674b7 = BotApp;
+botApp#95fcd1d6 flags:# id:long access_hash:long short_name:string title:string description:string photo:Photo document:flags.0?Document hash:long = BotApp;
-messages.botApp#eb50adf5 flags:# inactive:flags.0?true request_write_access:flags.1?true app:BotApp = messages.BotApp;
+messages.botApp#eb50adf5 flags:# inactive:flags.0?true request_write_access:flags.1?true has_settings:flags.2?true app:BotApp = messages.BotApp;
-appWebViewResultUrl#3c1b4f0d url:string = AppWebViewResult;
+appWebViewResultUrl#3c1b4f0d url:string = AppWebViewResult;
---functions---
-messages.getBotApp#34fdc5c3 app:InputBotApp hash:long = messages.BotApp;
+messages.getBotApp#34fdc5c3 app:InputBotApp hash:long = messages.BotApp;
-messages.requestAppWebView#8c5a3b3c flags:# write_allowed:flags.0?true peer:InputPeer app:InputBotApp start_param:flags.1?string theme_params:flags.2?DataJSON platform:string = AppWebViewResult;
-Another way to open Mini Apps is by using named bot Mini App links ».
-These links are different from bot attachment menu deep links », because they don't require the user to install an attachment menu, and a single bot can offer multiple Mini Apps, distinguished by their short_name
.
-These links should be handled as follows:
Check if bot_username
parameter of the link is indeed a bot username, if so then
- Invoke messages.getBotApp, passing an inputBotAppShortName with the short_name
contained in the appname
query string parameter.
If the client has already encountered an app with this short name from the same bot before, pass the hash
of the cached botApp constructor to messages.getBotApp.
If a messages.botApp constructor is returned and its request_write_access
flag is set, show a prompt to the user, indicating that the bot is asking permission to send messages to the user.
If the user agrees, set the write_allowed
flag when invoking messages.requestAppWebView in the next step.
- If a messages.botApp constructor is returned, open the Mini App by invoking messages.requestAppWebView, generating an inputBotAppID constructor from id
and access_hash
of the returned botApp, or from previously cached information if we already met the bot app and botAppNotModified was returned.
If the client has clicked on the link in a Telegram chat, pass the chat's peer information into peer
; otherwise pass the bot's peer information, instead.
- If the messages.botApp.inactive
flag is set, ask confirmation from the user before opening the Mini App; the request_write_access
checkbox should be shown in this prompt, if needed.
Confirmation should always be asked, even if the inactive
flag is not set, when opening the link from places where the full link is not visible (i.e. messageEntityTextUrl text links, inline buttons etc.).
If the startapp
query string parameter is present, pass it to start_param
when invoking messages.requestAppWebView.
- If the messages.botApp.request_write_access
flag is set, the bot is asking permission to send messages to the user: if the user agrees, set the write_allowed
flag when invoking messages.requestAppWebView.
+messages.requestAppWebView#8c5a3b3c flags:# write_allowed:flags.0?true peer:InputPeer app:InputBotApp start_param:flags.1?string theme_params:flags.2?DataJSON platform:string = AppWebViewResult;
+Another way to open Mini Apps is by using named bot Mini App links ».
+These links are different from bot attachment menu deep links », because they don't require the user to install an attachment menu, and a single bot can offer multiple Mini Apps, distinguished by their short_name
.
These links should be handled as follows:
+bot_username
parameter of the link is indeed a bot username, if so thenshort_name
contained in the appname
query string parameter.
+If the client has already encountered an app with this short name from the same bot before, pass the hash
of the cached botApp constructor to messages.getBotApp.request_write_access
flag is set, show a prompt to the user, indicating that the bot is asking permission to send messages to the user.write_allowed
flag when invoking messages.requestAppWebView in the next step.id
and access_hash
of the returned botApp, or from previously cached information if we already met the bot app and botAppNotModified was returned. peer
; otherwise pass the bot's peer information, instead.inactive
flag is set, ask confirmation from the user before opening the Mini App; the request_write_access
checkbox should be shown in this prompt, if needed.inactive
flag is not set, when opening the link from places where the full link is not visible (i.e. messageEntityTextUrl text links, inline buttons etc.). startapp
query string parameter is present, pass it to start_param
when invoking messages.requestAppWebView.request_write_access
flag is set, the bot is asking permission to send messages to the user: if the user agrees, set the write_allowed
flag when invoking messages.requestAppWebView.Finally, open the webview using the url
contained in the returned appWebViewResultUrl.
Since there is no linked inline query, web_app_data_send
events must be ignored.
The bot can, however, write to the user directly if it already has a chat with the user or if it requested permission via request_write_access
and the user granted it with write_allowed
.
Since there is no linked inline query, web_app_data_send
events must be ignored.
+The bot can, however, write to the user directly if it already has a chat with the user or if it requested permission via request_write_access
and the user granted it with write_allowed
.
Bot Mini Apps can be themed according to the following theme parameters, passed as a JSON object to the theme_params
parameter of the messages.requestSimpleWebView and messages.requestWebView methods.
This JSON object has the following keys, containing color theme information (hex string, RGB, no alpha) to pass to the Mini App:
link_color
- Link colorbutton_color
- Button colorbutton_text_color
- Button text colorboolFalse#bc799737 = Bool;
boolTrue#997275b5 = Bool;
-channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
+channelFull#723027bd flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions stories:flags2.4?PeerStories = ChatFull;
messages.chats#64ff9fd5 chats:Vector<Chat> = messages.Chats;
@@ -78,7 +78,7 @@ Before linking a supergroup to a channel, access to the supergroup's old message
channels.togglePreHistoryHidden#eabbb94c channel:InputChannel enabled:Bool = Updates;
channel#83259464 flags:# creator:flags.0?true left:flags.2?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true signatures:flags.11?true min:flags.12?true scam:flags.19?true has_link:flags.20?true has_geo:flags.21?true slowmode_enabled:flags.22?true call_active:flags.23?true call_not_empty:flags.24?true fake:flags.25?true gigagroup:flags.26?true noforwards:flags.27?true join_to_send:flags.28?true join_request:flags.29?true forum:flags.30?true flags2:# id:long access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int restriction_reason:flags.9?Vector<RestrictionReason> admin_rights:flags.14?ChatAdminRights banned_rights:flags.15?ChatBannedRights default_banned_rights:flags.18?ChatBannedRights participants_count:flags.17?int usernames:flags2.0?Vector<Username> = Chat;
+channel#94f592db flags:# creator:flags.0?true left:flags.2?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true signatures:flags.11?true min:flags.12?true scam:flags.19?true has_link:flags.20?true has_geo:flags.21?true slowmode_enabled:flags.22?true call_active:flags.23?true call_not_empty:flags.24?true fake:flags.25?true gigagroup:flags.26?true noforwards:flags.27?true join_to_send:flags.28?true join_request:flags.29?true forum:flags.30?true flags2:# stories_hidden:flags2.1?true stories_hidden_min:flags2.2?true stories_unavailable:flags2.3?true id:long access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int restriction_reason:flags.9?Vector<RestrictionReason> admin_rights:flags.14?ChatAdminRights banned_rights:flags.15?ChatBannedRights default_banned_rights:flags.18?ChatBannedRights participants_count:flags.17?int usernames:flags2.0?Vector<Username> stories_max_id:flags2.4?int = Chat;
---functions---
diff --git a/data/web/corefork.telegram.org/api/emoji-status.html b/data/web/corefork.telegram.org/api/emoji-status.html
index fec8b255c0..6e4b587292 100644
--- a/data/web/corefork.telegram.org/api/emoji-status.html
+++ b/data/web/corefork.telegram.org/api/emoji-status.html
@@ -50,7 +50,7 @@
emojiStatus#929b619d document_id:long = EmojiStatus;
emojiStatusUntil#fa30a8c7 document_id:long until:int = EmojiStatus;
-user#8f97c628 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> = User;
+user#abb5f120 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true close_friend:flags2.2?true stories_hidden:flags2.3?true stories_unavailable:flags2.4?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> stories_max_id:flags2.5?int = User;
updateUserEmojiStatus#28373599 user_id:long emoji_status:EmojiStatus = Update;
diff --git a/data/web/corefork.telegram.org/api/files.html b/data/web/corefork.telegram.org/api/files.html
index fd6f705cdb..b839ab1b75 100644
--- a/data/web/corefork.telegram.org/api/files.html
+++ b/data/web/corefork.telegram.org/api/files.html
@@ -65,7 +65,7 @@
---functions---
-messages.sendMedia#7547c966 flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMedia#72ccc23d flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
messages.uploadMedia#519bc2b1 peer:InputPeer media:InputMedia = MessageMedia;
messages.sendEncryptedFile#5559481d flags:# silent:flags.0?true peer:InputEncryptedChat random_id:long data:bytes file:InputEncryptedFile = messages.SentEncryptedMessage;
@@ -119,7 +119,7 @@ After the entire file is successfully saved, the final method may be called and
---functions---
-messages.sendMultiMedia#b6f11a1c flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int multi_media:Vector<InputSingleMedia> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMultiMedia#456e8987 flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo multi_media:Vector<InputSingleMedia> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
Telegram allows grouping photos into albums and generic files (audio, docuemnts) into media groups.
To do this, messages.sendMultiMedia is used, wrapping each InputMedia constructor (uploaded or pre-existing, maximum 10 per media group) into an inputSingleMedia constructor, optionally providing a custom per-file caption in message
.
For photo albums, clients should display an album caption only if exactly one photo in the group has a caption, otherwise no album caption should be displayed, and only when viewing in detail a specific photo of the group the caption should be shown. messages.getChatInviteImporters can be used to fetch info about users that joined using a specific invite link. Some basic stats about the number of invite links generated by a given admin can be fetched using messages.getAdminsWithInvites. To send a live geolocation, use messages.sendMedia with an inputMediaGeoLive Mentions are implemented as message entities, passed to the messages.sendMessage method:
diff --git a/data/web/corefork.telegram.org/api/fragment.html b/data/web/corefork.telegram.org/api/fragment.html
index 22abdc40b2..2467f5a9ab 100644
--- a/data/web/corefork.telegram.org/api/fragment.html
+++ b/data/web/corefork.telegram.org/api/fragment.html
@@ -50,9 +50,9 @@
updateUserName#a7848924 user_id:long first_name:string last_name:string usernames:Vector<Username> = Update;
-user#8f97c628 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> = User;
+user#abb5f120 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true close_friend:flags2.2?true stories_hidden:flags2.3?true stories_unavailable:flags2.4?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> stories_max_id:flags2.5?int = User;
-channel#83259464 flags:# creator:flags.0?true left:flags.2?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true signatures:flags.11?true min:flags.12?true scam:flags.19?true has_link:flags.20?true has_geo:flags.21?true slowmode_enabled:flags.22?true call_active:flags.23?true call_not_empty:flags.24?true fake:flags.25?true gigagroup:flags.26?true noforwards:flags.27?true join_to_send:flags.28?true join_request:flags.29?true forum:flags.30?true flags2:# id:long access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int restriction_reason:flags.9?Vector<RestrictionReason> admin_rights:flags.14?ChatAdminRights banned_rights:flags.15?ChatBannedRights default_banned_rights:flags.18?ChatBannedRights participants_count:flags.17?int usernames:flags2.0?Vector<Username> = Chat;
+channel#94f592db flags:# creator:flags.0?true left:flags.2?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true signatures:flags.11?true min:flags.12?true scam:flags.19?true has_link:flags.20?true has_geo:flags.21?true slowmode_enabled:flags.22?true call_active:flags.23?true call_not_empty:flags.24?true fake:flags.25?true gigagroup:flags.26?true noforwards:flags.27?true join_to_send:flags.28?true join_request:flags.29?true forum:flags.30?true flags2:# stories_hidden:flags2.1?true stories_hidden_min:flags2.2?true stories_unavailable:flags2.3?true id:long access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int restriction_reason:flags.9?Vector<RestrictionReason> admin_rights:flags.14?ChatAdminRights banned_rights:flags.15?ChatBannedRights default_banned_rights:flags.18?ChatBannedRights participants_count:flags.17?int usernames:flags2.0?Vector<Username> stories_max_id:flags2.4?int = Chat;
---functions---
diff --git a/data/web/corefork.telegram.org/api/invites.html b/data/web/corefork.telegram.org/api/invites.html
index 1c289d8b99..503cde108e 100644
--- a/data/web/corefork.telegram.org/api/invites.html
+++ b/data/web/corefork.telegram.org/api/invites.html
@@ -78,7 +78,7 @@ You can use channels.checkUsername
messages.chatAdminsWithInvites#b69b72d7 admins:Vector<ChatAdminWithInvites> users:Vector<User> = messages.ChatAdminsWithInvites;
chatInviteAlready#5a686d7c chat:Chat = ChatInvite;
-chatInvite#300c44c1 flags:# channel:flags.0?true broadcast:flags.1?true public:flags.2?true megagroup:flags.3?true request_needed:flags.6?true title:string about:flags.5?string photo:Photo participants_count:int participants:flags.4?Vector<User> = ChatInvite;
+chatInvite#300c44c1 flags:# channel:flags.0?true broadcast:flags.1?true public:flags.2?true megagroup:flags.3?true request_needed:flags.6?true verified:flags.7?true scam:flags.8?true fake:flags.9?true title:string about:flags.5?string photo:Photo participants_count:int participants:flags.4?Vector<User> = ChatInvite;
chatInvitePeek#61695cb0 chat:Chat expires:int = ChatInvite;
---functions---
@@ -111,9 +111,9 @@ Use messages.deleteExportedC
Join requests
-channel#83259464 flags:# creator:flags.0?true left:flags.2?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true signatures:flags.11?true min:flags.12?true scam:flags.19?true has_link:flags.20?true has_geo:flags.21?true slowmode_enabled:flags.22?true call_active:flags.23?true call_not_empty:flags.24?true fake:flags.25?true gigagroup:flags.26?true noforwards:flags.27?true join_to_send:flags.28?true join_request:flags.29?true forum:flags.30?true flags2:# id:long access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int restriction_reason:flags.9?Vector<RestrictionReason> admin_rights:flags.14?ChatAdminRights banned_rights:flags.15?ChatBannedRights default_banned_rights:flags.18?ChatBannedRights participants_count:flags.17?int usernames:flags2.0?Vector<Username> = Chat;
+
channel#94f592db flags:# creator:flags.0?true left:flags.2?true broadcast:flags.5?true verified:flags.7?true megagroup:flags.8?true restricted:flags.9?true signatures:flags.11?true min:flags.12?true scam:flags.19?true has_link:flags.20?true has_geo:flags.21?true slowmode_enabled:flags.22?true call_active:flags.23?true call_not_empty:flags.24?true fake:flags.25?true gigagroup:flags.26?true noforwards:flags.27?true join_to_send:flags.28?true join_request:flags.29?true forum:flags.30?true flags2:# stories_hidden:flags2.1?true stories_hidden_min:flags2.2?true stories_unavailable:flags2.3?true id:long access_hash:flags.13?long title:string username:flags.6?string photo:ChatPhoto date:int restriction_reason:flags.9?Vector<RestrictionReason> admin_rights:flags.14?ChatAdminRights banned_rights:flags.15?ChatBannedRights default_banned_rights:flags.18?ChatBannedRights participants_count:flags.17?int usernames:flags2.0?Vector<Username> stories_max_id:flags2.4?int = Chat;
-chatInvite#300c44c1 flags:# channel:flags.0?true broadcast:flags.1?true public:flags.2?true megagroup:flags.3?true request_needed:flags.6?true title:string about:flags.5?string photo:Photo participants_count:int participants:flags.4?Vector<User> = ChatInvite;
+chatInvite#300c44c1 flags:# channel:flags.0?true broadcast:flags.1?true public:flags.2?true megagroup:flags.3?true request_needed:flags.6?true verified:flags.7?true scam:flags.8?true fake:flags.9?true title:string about:flags.5?string photo:Photo participants_count:int participants:flags.4?Vector<User> = ChatInvite;
updatePendingJoinRequests#7063c3db peer:Peer requests_pending:int recent_requesters:Vector<long> = Update;
updateBotChatInviteRequester#11dfa986 peer:Peer date:int user_id:long about:string invite:ExportedChatInvite qts:int = Update;
diff --git a/data/web/corefork.telegram.org/api/live-location.html b/data/web/corefork.telegram.org/api/live-location.html
index 640f23b909..40c58296ba 100644
--- a/data/web/corefork.telegram.org/api/live-location.html
+++ b/data/web/corefork.telegram.org/api/live-location.html
@@ -54,7 +54,7 @@
---functions---
-messages.sendMedia#7547c966 flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMedia#72ccc23d flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
messages.editMessage#48f71778 flags:# no_webpage:flags.1?true peer:InputPeer id:int message:flags.11?string media:flags.14?InputMedia reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.15?int = Updates;
media
. provider
parameter of the inputMediaInvoice constructor is where you put the token value that you've obtained earlier via Botfather. It is possible for one merchant bot to use several different tokens for different users or different goods and services.
test
order.
The recurring
flag will be set for recurring payments, and recurring_terms_url
will link to the terms of service of the recurring payment: the user must read and accept them before continuing.
invoice#3e85a91b flags:# test:flags.0?true name_requested:flags.1?true phone_requested:flags.2?true email_requested:flags.3?true shipping_address_requested:flags.4?true flexible:flags.5?true phone_to_provider:flags.6?true email_to_provider:flags.7?true recurring:flags.9?true currency:string prices:Vector<LabeledPrice> max_tip_amount:flags.8?long suggested_tip_amounts:flags.8?Vector<long> recurring_terms_url:flags.9?string = Invoice;
+invoice#5db95a15 flags:# test:flags.0?true name_requested:flags.1?true phone_requested:flags.2?true email_requested:flags.3?true shipping_address_requested:flags.4?true flexible:flags.5?true phone_to_provider:flags.6?true email_to_provider:flags.7?true recurring:flags.9?true currency:string prices:Vector<LabeledPrice> max_tip_amount:flags.8?long suggested_tip_amounts:flags.8?Vector<long> terms_url:flags.10?string = Invoice;
postAddress#1e8caaeb street_line1:string street_line2:string city:string state:string country_iso2:string post_code:string = PostAddress;
diff --git a/data/web/corefork.telegram.org/api/poll.html b/data/web/corefork.telegram.org/api/poll.html
index 588ef2a697..bb6058ab80 100644
--- a/data/web/corefork.telegram.org/api/poll.html
+++ b/data/web/corefork.telegram.org/api/poll.html
@@ -54,7 +54,7 @@
---functions---
-messages.sendMedia#7547c966 flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMedia#72ccc23d flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
To send a poll in a chat, call messages.sendMedia, providing an inputMediaPoll:
pollAnswerVoters#3b6ddad2 flags:# chosen:flags.0?true correct:flags.1?true option:bytes voters:int = PollAnswerVoters;
-pollResults#dcb82ea3 flags:# min:flags.0?true results:flags.1?Vector<PollAnswerVoters> total_voters:flags.2?int recent_voters:flags.3?Vector<long> solution:flags.4?string solution_entities:flags.4?Vector<MessageEntity> = PollResults;
+pollResults#7adf2420 flags:# min:flags.0?true results:flags.1?Vector<PollAnswerVoters> total_voters:flags.2?int recent_voters:flags.3?Vector<Peer> solution:flags.4?string solution_entities:flags.4?Vector<MessageEntity> = PollResults;
poll#86e18161 id:long flags:# closed:flags.0?true public_voters:flags.1?true multiple_choice:flags.2?true quiz:flags.3?true question:string answers:Vector<PollAnswer> close_period:flags.4?int close_date:flags.5?int = Poll;
@@ -101,7 +101,7 @@ These last two parameters are exactly the same, except that one uses absolute, t
Getting poll votes
pollAnswerVoters#3b6ddad2 flags:# chosen:flags.0?true correct:flags.1?true option:bytes voters:int = PollAnswerVoters;
-pollResults#dcb82ea3 flags:# min:flags.0?true results:flags.1?Vector<PollAnswerVoters> total_voters:flags.2?int recent_voters:flags.3?Vector<long> solution:flags.4?string solution_entities:flags.4?Vector<MessageEntity> = PollResults;
+pollResults#7adf2420 flags:# min:flags.0?true results:flags.1?Vector<PollAnswerVoters> total_voters:flags.2?int recent_voters:flags.3?Vector<Peer> solution:flags.4?string solution_entities:flags.4?Vector<MessageEntity> = PollResults;
updateMessagePoll#aca1657b flags:# poll_id:long poll:flags.0?Poll results:PollResults = Update;
@@ -115,9 +115,9 @@ These last two parameters are exactly the same, except that one uses absolute, t
messageUserVoteInputOption#3ca5b0ec user_id:long date:int = MessageUserVote;
messageUserVoteMultiple#8a65e557 user_id:long options:Vector<bytes> date:int = MessageUserVote;
-messages.votesList#823f649 flags:# count:int votes:Vector<MessageUserVote> users:Vector<User> next_offset:flags.0?string = messages.VotesList;
+messages.votesList#4899484e flags:# count:int votes:Vector<MessagePeerVote> chats:Vector<Chat> users:Vector<User> next_offset:flags.0?string = messages.VotesList;
-updateMessagePollVote#106395c9 poll_id:long user_id:long options:Vector<bytes> qts:int = Update;
+updateMessagePollVote#24f40e77 poll_id:long peer:Peer options:Vector<bytes> qts:int = Update;
---functions---
diff --git a/data/web/corefork.telegram.org/api/premium.html b/data/web/corefork.telegram.org/api/premium.html
index 295f125878..96ff99fb5c 100644
--- a/data/web/corefork.telegram.org/api/premium.html
+++ b/data/web/corefork.telegram.org/api/premium.html
@@ -51,7 +51,7 @@
Telegram Premium users
inputUserSelf#f7c1b13f = InputUser;
-user#8f97c628 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> = User;
+user#abb5f120 flags:# self:flags.10?true contact:flags.11?true mutual_contact:flags.12?true deleted:flags.13?true bot:flags.14?true bot_chat_history:flags.15?true bot_nochats:flags.16?true verified:flags.17?true restricted:flags.18?true min:flags.20?true bot_inline_geo:flags.21?true support:flags.23?true scam:flags.24?true apply_min_photo:flags.25?true fake:flags.26?true bot_attach_menu:flags.27?true premium:flags.28?true attach_menu_enabled:flags.29?true flags2:# bot_can_edit:flags2.1?true close_friend:flags2.2?true stories_hidden:flags2.3?true stories_unavailable:flags2.4?true id:long access_hash:flags.0?long first_name:flags.1?string last_name:flags.2?string username:flags.3?string phone:flags.4?string photo:flags.5?UserProfilePhoto status:flags.6?UserStatus bot_info_version:flags.14?int restriction_reason:flags.18?Vector<RestrictionReason> bot_inline_placeholder:flags.19?string lang_code:flags.22?string emoji_status:flags.30?EmojiStatus usernames:flags2.0?Vector<Username> stories_max_id:flags2.5?int = User;
help.premiumPromo#5334759c status_text:string status_entities:Vector<MessageEntity> video_sections:Vector<string> videos:Vector<Document> period_options:Vector<PremiumSubscriptionOption> users:Vector<User> = help.PremiumPromo;
@@ -135,7 +135,7 @@ Then, when the user clicks on the subscribe button in the sent invoice, follow t
There is also a store-based subscription flow based on payments.assignAppStoreTransaction/payments.assignPlayMarketTransaction, but it's currently not available to third-party apps (unlike the flow described above, which can be used by all clients).
userFull#93eadb53 flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true translations_disabled:flags.23?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> wallpaper:flags.24?WallPaper = UserFull;
+userFull#b9b12c6c flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true translations_disabled:flags.23?true stories_pinned_available:flags.26?true blocked_my_stories_from:flags.27?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> wallpaper:flags.24?WallPaper stories:flags.25?PeerStories = UserFull;
premiumGiftOption#74c34319 flags:# months:int currency:string amount:long bot_url:string store_product:flags.0?string = PremiumGiftOption;
diff --git a/data/web/corefork.telegram.org/api/qr-login.html b/data/web/corefork.telegram.org/api/qr-login.html
index 44a3c8a26f..a10cf83bd7 100644
--- a/data/web/corefork.telegram.org/api/qr-login.html
+++ b/data/web/corefork.telegram.org/api/qr-login.html
@@ -52,7 +52,7 @@
updateLoginToken#564fe691 = Update;
-authorization#ad01d61d flags:# current:flags.0?true official_app:flags.1?true password_pending:flags.2?true encrypted_requests_disabled:flags.3?true call_requests_disabled:flags.4?true hash:long device_model:string platform:string system_version:string api_id:int app_name:string app_version:string date_created:int date_active:int ip:string country:string region:string = Authorization;
+authorization#ad01d61d flags:# current:flags.0?true official_app:flags.1?true password_pending:flags.2?true encrypted_requests_disabled:flags.3?true call_requests_disabled:flags.4?true unconfirmed:flags.5?true hash:long device_model:string platform:string system_version:string api_id:int app_name:string app_version:string date_created:int date_active:int ip:string country:string region:string = Authorization;
---functions---
diff --git a/data/web/corefork.telegram.org/api/ringtones.html b/data/web/corefork.telegram.org/api/ringtones.html
index 797e3f8d50..8583b42943 100644
--- a/data/web/corefork.telegram.org/api/ringtones.html
+++ b/data/web/corefork.telegram.org/api/ringtones.html
@@ -107,7 +107,7 @@ The client will receive an updateSav
inputNotifyChats#4a95e84e = InputNotifyPeer;
inputNotifyBroadcasts#b1db7c7e = InputNotifyPeer;
-inputPeerNotifySettings#df1f002b flags:# show_previews:flags.0?Bool silent:flags.1?Bool mute_until:flags.2?int sound:flags.3?NotificationSound = InputPeerNotifySettings;
+inputPeerNotifySettings#cacb6ae2 flags:# show_previews:flags.0?Bool silent:flags.1?Bool mute_until:flags.2?int sound:flags.3?NotificationSound stories_muted:flags.6?Bool stories_hide_sender:flags.7?Bool stories_sound:flags.8?NotificationSound = InputPeerNotifySettings;
---functions---
diff --git a/data/web/corefork.telegram.org/api/scheduled-messages.html b/data/web/corefork.telegram.org/api/scheduled-messages.html
index e103fdacc6..22ae004c34 100644
--- a/data/web/corefork.telegram.org/api/scheduled-messages.html
+++ b/data/web/corefork.telegram.org/api/scheduled-messages.html
@@ -50,9 +50,9 @@
---functions---
-messages.sendMessage#1cc20387 flags:# no_webpage:flags.1?true silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMessage#280d096f flags:# no_webpage:flags.1?true silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
-messages.sendMedia#7547c966 flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMedia#72ccc23d flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
To schedule a message, simply provide a future unixtime in the schedule_date
flag of messages.sendMessage or messages.sendMedia.
The specified message or media will be added to a server-side schedule queue for the current chat, and will be automatically sent at the specified time.
The method call generates the following updates:
Related TL schema:
-sponsoredMessage#fc25b828 flags:# recommended:flags.5?true show_peer_photo:flags.6?true random_id:bytes from_id:flags.3?Peer chat_invite:flags.4?ChatInvite chat_invite_hash:flags.4?string channel_post:flags.2?int start_param:flags.0?string message:string entities:flags.1?Vector<MessageEntity> sponsor_info:flags.7?string additional_info:flags.8?string = SponsoredMessage;
+sponsoredMessage#daafff6b flags:# recommended:flags.5?true show_peer_photo:flags.6?true random_id:bytes from_id:flags.3?Peer chat_invite:flags.4?ChatInvite chat_invite_hash:flags.4?string channel_post:flags.2?int start_param:flags.0?string webpage:flags.9?SponsoredWebPage message:string entities:flags.1?Vector<MessageEntity> sponsor_info:flags.7?string additional_info:flags.8?string = SponsoredMessage;
messages.sponsoredMessages#c9ee1d87 flags:# posts_between:flags.0?int messages:Vector<SponsoredMessage> chats:Vector<Chat> users:Vector<User> = messages.SponsoredMessages;
---functions---
diff --git a/data/web/corefork.telegram.org/api/stats.html b/data/web/corefork.telegram.org/api/stats.html
index 79b80c3b1d..b590e471af 100644
--- a/data/web/corefork.telegram.org/api/stats.html
+++ b/data/web/corefork.telegram.org/api/stats.html
@@ -62,7 +62,7 @@
stats.broadcastStats#bdf78394 period:StatsDateRangeDays followers:StatsAbsValueAndPrev views_per_post:StatsAbsValueAndPrev shares_per_post:StatsAbsValueAndPrev enabled_notifications:StatsPercentValue growth_graph:StatsGraph followers_graph:StatsGraph mute_graph:StatsGraph top_hours_graph:StatsGraph interactions_graph:StatsGraph iv_interactions_graph:StatsGraph views_by_source_graph:StatsGraph new_followers_by_source_graph:StatsGraph languages_graph:StatsGraph recent_message_interactions:Vector<MessageInteractionCounters> = stats.BroadcastStats;
messages.chatFull#e5d7d19c full_chat:ChatFull chats:Vector<Chat> users:Vector<User> = messages.ChatFull;
-channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
+channelFull#723027bd flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions stories:flags2.4?PeerStories = ChatFull;
---functions---
@@ -97,7 +97,7 @@ Note that in this case, current
refers to the period
i
stats.megagroupStats#ef7ff916 period:StatsDateRangeDays members:StatsAbsValueAndPrev messages:StatsAbsValueAndPrev viewers:StatsAbsValueAndPrev posters:StatsAbsValueAndPrev growth_graph:StatsGraph members_graph:StatsGraph new_members_by_source_graph:StatsGraph languages_graph:StatsGraph messages_graph:StatsGraph actions_graph:StatsGraph top_hours_graph:StatsGraph weekdays_graph:StatsGraph top_posters:Vector<StatsGroupTopPoster> top_admins:Vector<StatsGroupTopAdmin> top_inviters:Vector<StatsGroupTopInviter> users:Vector<User> = stats.MegagroupStats;
messages.chatFull#e5d7d19c full_chat:ChatFull chats:Vector<Chat> users:Vector<User> = messages.ChatFull;
-channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
+channelFull#723027bd flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions stories:flags2.4?PeerStories = ChatFull;
---functions---
@@ -111,7 +111,7 @@ The returned stats.broadcastStatsstats.messageStats#8999f295 views_graph:StatsGraph = stats.MessageStats;
messages.chatFull#e5d7d19c full_chat:ChatFull chats:Vector<Chat> users:Vector<User> = messages.ChatFull;
-channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
+channelFull#723027bd flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions stories:flags2.4?PeerStories = ChatFull;
---functions---
diff --git a/data/web/corefork.telegram.org/api/stickers.html b/data/web/corefork.telegram.org/api/stickers.html
index 6c9a07615a..e5b0169b87 100644
--- a/data/web/corefork.telegram.org/api/stickers.html
+++ b/data/web/corefork.telegram.org/api/stickers.html
@@ -334,9 +334,9 @@ This update should trigger a call to masks and custom emojis from a specific stickerset in the stickerset selection bar (not through suggested or recent stickersets UI views).
Note that for custom emojis, the flag should only be set when manually choosing custom emojis from a single custom emoji stickerset (not multiple custom emoji stickersets).
Setting this flag will trigger an updateMoveStickerSetToTop update (instead of the usual updateStickerSetsOrder/updateStickerSets updates), indicating that the installed stickerset list was reordered and the specified stickerset was moved to the top.
@@ -388,7 +388,7 @@ The stickers_emoji_cache_time ap
---functions---
-messages.sendMedia#7547c966 flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to_msg_id:flags.0?int top_msg_id:flags.9?int media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
+messages.sendMedia#72ccc23d flags:# silent:flags.5?true background:flags.6?true clear_draft:flags.7?true noforwards:flags.14?true update_stickersets_order:flags.15?true peer:InputPeer reply_to:flags.0?InputReplyTo media:InputMedia message:string random_id:long reply_markup:flags.2?ReplyMarkup entities:flags.3?Vector<MessageEntity> schedule_date:flags.10?int send_as:flags.13?InputPeer = Updates;
messages.getAttachedStickers#cc5b67cc media:InputStickeredMedia = Vector<StickerSetCovered>;
Stickers of all kinds can be attached to photos and videos.
diff --git a/data/web/corefork.telegram.org/api/translation.html b/data/web/corefork.telegram.org/api/translation.html
index d6f18cd638..cd09e15b01 100644
--- a/data/web/corefork.telegram.org/api/translation.html
+++ b/data/web/corefork.telegram.org/api/translation.html
@@ -56,11 +56,11 @@
messages.translateText can be used to translate a list of chat messages (by populating the peer
and id
flags), or a generic list of messages (by populating the text
flag, for example when translating instant view articles).
The method will return a vector of textWithEntities constructors, containing the translated text, and, only for Telegram Premium users, the corresponding styled text entities (i.e. correctly repositioned bold, italic, link entities for the translated message, corresponding to the same entities in the original message).
Real-time translation
-userFull#93eadb53 flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true translations_disabled:flags.23?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> wallpaper:flags.24?WallPaper = UserFull;
+userFull#b9b12c6c flags:# blocked:flags.0?true phone_calls_available:flags.4?true phone_calls_private:flags.5?true can_pin_message:flags.7?true has_scheduled:flags.12?true video_calls_available:flags.13?true voice_messages_forbidden:flags.20?true translations_disabled:flags.23?true stories_pinned_available:flags.26?true blocked_my_stories_from:flags.27?true id:long about:flags.1?string settings:PeerSettings personal_photo:flags.21?Photo profile_photo:flags.2?Photo fallback_photo:flags.22?Photo notify_settings:PeerNotifySettings bot_info:flags.3?BotInfo pinned_msg_id:flags.6?int common_chats_count:int folder_id:flags.11?int ttl_period:flags.14?int theme_emoticon:flags.15?string private_forward_name:flags.16?string bot_group_admin_rights:flags.17?ChatAdminRights bot_broadcast_admin_rights:flags.18?ChatAdminRights premium_gifts:flags.19?Vector<PremiumGiftOption> wallpaper:flags.24?WallPaper stories:flags.25?PeerStories = UserFull;
chatFull#c9d31138 flags:# can_set_username:flags.7?true has_scheduled:flags.8?true translations_disabled:flags.19?true id:long about:string participants:ChatParticipants chat_photo:flags.2?Photo notify_settings:PeerNotifySettings exported_invite:flags.13?ExportedChatInvite bot_info:flags.3?Vector<BotInfo> pinned_msg_id:flags.6?int folder_id:flags.11?int call:flags.12?InputGroupCall ttl_period:flags.14?int groupcall_default_join_as:flags.15?Peer theme_emoticon:flags.16?string requests_pending:flags.17?int recent_requesters:flags.17?Vector<long> available_reactions:flags.18?ChatReactions = ChatFull;
-channelFull#f2355507 flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions = ChatFull;
+channelFull#723027bd flags:# can_view_participants:flags.3?true can_set_username:flags.6?true can_set_stickers:flags.7?true hidden_prehistory:flags.10?true can_set_location:flags.16?true has_scheduled:flags.19?true can_view_stats:flags.20?true blocked:flags.22?true flags2:# can_delete_channel:flags2.0?true antispam:flags2.1?true participants_hidden:flags2.2?true translations_disabled:flags2.3?true stories_pinned_available:flags2.5?true id:long about:string participants_count:flags.0?int admins_count:flags.1?int kicked_count:flags.2?int banned_count:flags.2?int online_count:flags.13?int read_inbox_max_id:int read_outbox_max_id:int unread_count:int chat_photo:Photo notify_settings:PeerNotifySettings exported_invite:flags.23?ExportedChatInvite bot_info:Vector<BotInfo> migrated_from_chat_id:flags.4?long migrated_from_max_id:flags.4?int pinned_msg_id:flags.5?int stickerset:flags.8?StickerSet available_min_id:flags.9?int folder_id:flags.11?int linked_chat_id:flags.14?long location:flags.15?ChannelLocation slowmode_seconds:flags.17?int slowmode_next_send_date:flags.18?int stats_dc:flags.12?int pts:int call:flags.21?InputGroupCall ttl_period:flags.24?int pending_suggestions:flags.25?Vector<string> groupcall_default_join_as:flags.26?Peer theme_emoticon:flags.27?string requests_pending:flags.28?int recent_requesters:flags.28?Vector<long> default_send_as:flags.29?Peer available_reactions:flags.30?ChatReactions stories:flags2.4?PeerStories = ChatFull;
---functions---
diff --git a/data/web/corefork.telegram.org/bots.html b/data/web/corefork.telegram.org/bots.html
index 35568d5d0d..6df016ac8a 100644
--- a/data/web/corefork.telegram.org/bots.html
+++ b/data/web/corefork.telegram.org/bots.html
@@ -48,10 +48,10 @@
- Detailed Guide to Bot Features
- Full API Reference for Developers
-- Basic Tutorial: From @BotFather to 'Hello World'
+- Basic Tutorial: From @BotFather to 'Hello World'
The Telegram Bot Platform hosts more than 10 million bots and is free for both users and developers.
-What Can You Do with Bots?
+What Can You Do with Bots?
- Replace Entire Websites
- Receive Payments
@@ -61,103 +61,96 @@
- Build Social Networks
- Anything Else!
-Replace Entire Websites
+Replace Entire Websites
Telegram bots can host Mini Apps built with JavaScript. This allows for infinitely flexible interfaces that can power everything from online stores to arcade games. Unlike websites, bots support seamless authorization and notifications through Telegram out of the box.
+
-
-Try @DurgerKingBot – or check out the dedicated guide to Web Apps to build your own.
+Try @DurgerKingBot – or check out the dedicated guide to Web Apps to build your own.
-Receive Payments
+Receive Payments
Bots can receive payments from more than 200 countries through more than 20 integrated payment providers (which include support for Apple Pay and Google Pay). These payments are securely processed by the providers and Telegram takes no commission.
+
-
Try @ShopBot – or check out the Bot Payments Manual to build your own.
-Create Custom Tools
+Create Custom Tools
Increase your productivity by creating bots for specific tasks – like converting files, managing chats or fetching today’s forecast. Users can chat directly with bots, or add them to groups and channels to introduce extra features.
+
-
Try @QuizBot to combine several quiz-style polls into a proper quiz.
-Integrate with Other Services
-Many popular platforms already have official Telegram bots, which allow users to comfortably access content in one app – or perform quick searches using inline mode.
+Integrate with Other Services
+Many popular platforms already have official Telegram bots, which allow users to comfortably access content in one app – or perform quick searches using inline mode.
-
Try @GMailBot, @GitHubBot, @Bing, @YouTube, @wiki and more.
-Host Games
+Host Games
Using HTML5, developers can create immersive single or multi-player games that allow users to team up or compete for the highest score.
+
-
-Try @Gamee and @GameBot – or check out the HTML5 Games Manual to build your own.
+Try @Gamee and @GameBot – or check out the HTML5 Games Manual to build your own.
-Build Social Networks
+Build Social Networks
Bots can serve as an intermediary to connect users based on shared interests, location, and more. Coordinate meetups, show local services, or help people sell second-hand items.
+
-
-Anything Else
+Anything Else
The possibilities for bots are endless – from simple scripts to complex mini apps. Whether you’re a beginner or professional programmer, you can create personalized tools with the help of the Bot Platform.
-How Do Bots Work?
+How Do Bots Work?
For a detailed explanation of Bot Features, see this guide
Telegram bots are special accounts that do not need a phone number to set up. Bots are connected to their owner’s server, which processes inputs and requests from users.
Telegram’s intermediary server handles all encryption and communication with the Telegram API. Developers communicate with this server via an easy HTTPS-interface with a simplified version of the Telegram API – known as the Bot API.
-How Are Bots Different from Users?
+How Are Bots Different from Users?
Bots are able to process inputs and requests in ways that user accounts can’t, but there are several differences between a bot and a normal user.
- Bots don’t have ‘last seen’ or online statuses – instead they show a ‘bot’ label in the chat.
- Bots have limited cloud storage – older messages may be removed by the server shortly after they have been processed.
-- Bots can't start conversations with users. A user must either add them to a group or send them a message first. People can search for your bot’s username or start a chat via its unique t.me/bot_username link.
+- Bots can't start conversations with users. A user must either add them to a group or send them a message first. People can search for your bot’s username or start a chat via its unique t.me/bot_username link.
- By default, bots added to groups only see relevant messages in the chat (see Privacy Mode).
- Bots never eat, sleep or complain (unless expressly programmed otherwise).
-Bot Links
+Bot Links
Bot usernames normally require a ‘bot’ suffix, but some bots don’t have them – such as @stickers, @gif, @wiki or @bing.
-Anyone can assign collectible usernames to bots, including those without the 'bot' suffix.
-How Do I Create a Bot?
+Anyone can assign collectible usernames to bots, including those without the 'bot' suffix.
+How Do I Create a Bot?
Creating Telegram bots is super-easy, but you will need at least some skills in computer programming.
Creating a bot is streamlined by Telegram’s Bot API, which gives the tools and framework required to integrate your code. To get started, message @BotFather on Telegram to register your bot and receive its authentication token.
Your bot token is its unique identifier – store it in a secure place, and only share it with people who need direct access to the bot. Everyone who has your token will have full control over your bot.
-What Next?
+What Next?
We recommend that you check out our guide to Bot Features to see what you can teach your bot to do:
-
-The Bot API is an HTTP-based interface created for developers keen on building bots for Telegram.
+
To learn how to create and set up a bot, please consult our Introduction to Bots »The Bot API is an HTTP-based interface created for developers keen on building bots for Telegram. +To learn how to create and set up a bot, please consult our Introduction to Bots »
You will find all changes to our Bot API on this page.
--Subscribe to @BotNews to be the first to know about the latest updates and join the discussion in @BotTalk
Bot API 6.9
Bot API 6.8
Bot API 6.7
Bot API 6.6
Bot API 6.5
Bot API 6.4
Bot API 6.3
Bot API 6.2
Custom Emoji Support
Bot API 6.1
Media in Descriptions
Web App Improvements
Join Requests & Payments
Telegram Premium Support (more info)
@@ -221,15 +222,15 @@ To learn how to create…">Bot API 6.0
-WARNING!
+
After the next update, only HTTPS links will be allowed in login_url inline keyboard buttons.WARNING! +After the next update, only HTTPS links will be allowed in login_url inline keyboard buttons.
Bot API 5.7
Bot API 5.6
Bot API 5.5
Note: After this update it will become impossible to forward messages from some chats. Use the fields has_protected_content in the classes Message and Chat to check this.
Note: After this update users are able to send messages on behalf of channels they own. Bots are expected to use the field sender_chat in the class Message to correctly support such messages.
Note: As previously announced, user identifiers can now have up to 52 significant bits and require a 64-bit integer or double-precision float type to be stored safely.
-Bot API 5.4
creates_join_request
to the methods createChatInviteLink and editChatInviteLink for managing chat invite links that create join requests (read more about this on our blog).-WARNING!
+
User identifiers will become bigger than2^31 - 1
before the end of this year 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.WARNING! +User identifiers will become bigger than
2^31 - 1
before the end of this year 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.
Bot API 5.3
Personalized Commands
scope
and language_code
to the method setMyCommands to allow bots specify different commands for different chats and users.scope
and language_code
to the method getMyCommands.Custom Placeholders
-WARNING!
+
After one of the upcoming Bot API updates, user identifiers will become bigger than2^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.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.
Bot API 5.2
-WARNING!
+
After the next Bot API update (Bot API 5.3) there will be a one-time change of the value of the fieldfile_unique_id
in objects of the type PhotoSize and of the fieldssmall_file_unique_id
andbig_file_unique_id
in objects of the type ChatPhoto.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 fieldssmall_file_unique_id
andbig_file_unique_id
in objects of the type ChatPhoto.
-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.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.
-WARNING!
+
After one of the upcoming Bot API updates, user identifiers will become bigger than2^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.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.
Bot API 5.1
Added two new update types
-WARNING!
+
After one of the upcoming Bot API updates, some user identifiers will become bigger than2^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.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.
Introducing Bot API 5.0
Run Your Own Bot API Server
Working with Groups
Live Locations
Bot API 4.9
Bot API 4.8
Bot API 4.7
Bot API 4.6
Bot API 4.5
<u>/<ins>
(for underlined text) and <s>/<strike>/<del>
(for strikethrough text) in parse mode HTML.__
(for underlined text) and ~
(for strikethrough text). Parse mode Markdown remains unchanged for backward compatibility.Bot API 4.4
149.154.160.0/20
and 91.108.4.0/22
. Most users won't need to do anything to continue receiving webhooks. If you control inbound access with a firewall, you may need to update your configuration. You can always find the list of actual IP addresses of servers used to send webhooks there: https://core.telegram.org/bots/webhooks.149.154.160.0/20
and 91.108.4.0/22
. Most users won't need to do anything to continue receiving webhooks. If you control inbound access with a firewall, you may need to update your configuration. You can always find the list of actual IP addresses of servers used to send webhooks there: https://core.telegram.org/bots/webhooks.Bot API 4.3
Also in this update:
reply_markup
to the Message object, containing the inline keyboard attached to the message.149.154.160.0/20
and 91.108.4.0/22
. Most users won't need to do anything to continue receiving webhooks. If you control inbound access with a firewall, you may need to update your configuration. You can always find the list of actual IP addresses of servers used to send webhooks there: https://core.telegram.org/bots/webhooks.149.154.160.0/20
and 91.108.4.0/22
. Most users won't need to do anything to continue receiving webhooks. If you control inbound access with a firewall, you may need to update your configuration. You can always find the list of actual IP addresses of servers used to send webhooks there: https://core.telegram.org/bots/webhooks.Bot API 4.2
149.154.160.0/20
and 91.108.4.0/22
. Most users won't need to do anything to continue receiving webhooks. If you control inbound access with a firewall, you may need to update your configuration. You can always find the list of actual IP addresses of servers used to send webhooks there: https://core.telegram.org/bots/webhooks.149.154.160.0/20
and 91.108.4.0/22
. Most users won't need to do anything to continue receiving webhooks. If you control inbound access with a firewall, you may need to update your configuration. You can always find the list of actual IP addresses of servers used to send webhooks there: https://core.telegram.org/bots/webhooks.Bot API 4.1
Bot API 4.0.
Retry-After
response header to configure the delay after which the Bot API will retry the request after an unsuccessful response from a webhook.410 Gone
for all requests for more than 23 hours successively, it can be automatically removed.Bot API 3.6.
Bot API 3.5.
Bot API 3.4.
Bot API 3.3.
Bot API 3.2. Teach your bot to handle stickers and sticker sets.
Bot API 3.1. Build your own robotic police force for supergoups with these new methods for admin bots:
Introducing Bot API 3.0.
NEW Payment Platform
-See Introduction to Bot Payments for a brief overview. If you're not a developer, you may like this user-friendly blog post better.
+See Introduction to Bot Payments for a brief overview. If you're not a developer, you may like this user-friendly blog post better.
NEW Multilingual Bots
More power to admin bots
@@ -637,30 +644,45 @@ To learn how to create…">Introducing Bot API 2.3.1, a nifty little update that will give you more control over how your bot gets its updates.
Bot API 2.3
Your bot can now get updates about posts in channels. Added new fields channel_post and edited_channel_post to Update.
+Modified bot privacy mode for the sake of consistency.
You can now update high scores to a lower value by using the new force parameter in setGameScore. Handy for punishing cheaters or fixing errors in your game's High Score table.
+Your bot can now get updates about posts in channels. Added new fields channel_post and edited_channel_post to Update.
+You can now update high scores to a lower value by using the new force parameter in setGameScore. Handy for punishing cheaters or fixing errors in your game's High Score table.
+Starting today, messages with high scores will be updated with new high scores by default. Use disable_edit_message in setGameScore if you don't want this.
+The edit_message parameter from setGameScore is no longer in use. For backward compatibility, it will be taken into account for a while, unless disable_edit_message is passed explicitly.
+Added the new field forward_from_message_id to Message.
+Added the new parameter cache_time to answerCallbackQuery. Will eventually work in Telegram apps — somewhere after version 3.14, maybe 3.15.
+Renamed hide_keyboard to remove_keyboard in ReplyKeyboardRemove for clarity. hide_keyboard will still work for a while for backward compatibility.
Bot API 2.2. Introducing a new Gaming Platform! See this introduction for a brief overview.
If you're not a developer, you may like this user-friendly blog post better.
Bot API 2.2. Introducing a new Gaming Platform! See this introduction for a brief overview. +If you're not a developer, you may like this user-friendly blog post better.
Other changes
New method getWebhookInfo to check current webhook status.
+Making life easier for webhook users. Added a detailed Guide to All Things Webhook that describes every pothole you can run into on the webhook road.
Added the option to specify an HTTP URL for a file in all methods where InputFile or file_id can be used (except voice messages). Telegram will get the file from the specified URL and send it to the user. Files must be smaller than 5 MB for photos and smaller than 20 MB for all other types of content.
+New method getWebhookInfo to check current webhook status.
+Added the option to specify an HTTP URL for a file in all methods where InputFile or file_id can be used (except voice messages). Telegram will get the file from the specified URL and send it to the user. Files must be smaller than 5 MB for photos and smaller than 20 MB for all other types of content.
+Use the new url parameter in answerCallbackQuery to create buttons that open your bot with user-specific parameters.
+Added new field switch_inline_query_current_chat in InlineKeyboardButton.
+Added caption fields to sendAudio, sendVoice, InlineQueryResultAudio, InlineQueryResultVoice, InlineQueryResultCachedAudio, and InlineQueryResultCachedVoice.
Introducing Bot API 2.0. Check out this page for a review of this major update.
setinlinefeedback
command for Botfather, new type ChosenInlineResult, new field chosen_inline_result to the Update object./setinline
to @BotFather.@channelusername
) in the place of chat_id in all methods (and instead of from_chat_id in forwardMessage). For this to work, the bot must be an administrator in the channel (and that's exactly what Telegram clients don't support yet — adding bots as administrators coming soon).@channelusername
) in the place of chat_id in all methods (and instead of from_chat_id in forwardMessage). For this to work, the bot must be an administrator in the channel (and that's exactly what Telegram clients don't support yet — adding bots as administrators coming soon).The bot platform is officially launched.
--
--The Bot API is an HTTP-based interface created for developers keen on building bots for Telegram.
+
To learn how to create and set up a bot, please consult our Introduction to Bots and Bot FAQ.The Bot API is an HTTP-based interface created for developers keen on building bots for Telegram. +To learn how to create and set up a bot, please consult our Introduction to Bots and Bot FAQ.
-Subscribe to @BotNews to be the first to know about the latest updates and join the discussion in @BotTalk
Bot API 6.9
Bot API 6.8
Bot API 6.7
Each bot is given a unique authentication token when it is created. The token looks something like 123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11
, but we'll use simply <token> in this document instead. You can learn about obtaining tokens and generating new ones in this document.
Each bot is given a unique authentication token when it is created. The token looks something like 123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11
, but we'll use simply <token> in this document instead. You can learn about obtaining tokens and generating new ones in this document.
All queries to the Telegram Bot API must be served over HTTPS and need to be presented in this form: https://api.telegram.org/bot<token>/METHOD_NAME
. Like this for example:
https://api.telegram.org/bot123456:ABC-DEF1234ghIkl-zyx57W2v1u123ew11/getMe
We support GET and POST HTTP methods. We support four ways of passing parameters in Bot API requests:
@@ -99,17 +100,17 @@ To learn how to create…">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.
+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.
If you're using webhooks, you can perform a request to the Bot API while sending an answer to the webhook. Use either application/json or application/x-www-form-urlencoded or multipart/form-data response content type for passing parameters. Specify the method to be invoked in the method parameter of the request. It's not possible to know that such a request was successful or get its result.
+If you're using webhooks, you can perform a request to the Bot API while sending an answer to the webhook. Use either application/json or application/x-www-form-urlencoded or multipart/form-data response content type for passing parameters. Specify the method to be invoked in the method parameter of the request. It's not possible to know that such a request was successful or get its result.
-Please see our FAQ for examples.
The Bot API server source code is available at telegram-bot-api. You can run it locally and send the requests to your own server instead of https://api.telegram.org
. If you switch to a local Bot API server, your bot will be able to:
The majority of bots will be OK with the default configuration, running on our servers. But if you feel that you need one of these features, you're welcome to switch to your own at any time.
-The majority of bots will be OK with the default configuration, running on our servers. But if you feel that you need one of these features, you're welcome to switch to your own at any time.
+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.
Regardless of which option you choose, you will receive JSON-serialized Update objects as a result.
-This object represents an incoming update.
At most one of the optional parameters can be present in any given update.
This object represents an incoming update. +At most one of the optional parameters can be present in any given update.
update_id | Integer | -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. | +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. |
message | @@ -200,12 +202,12 @@ To learn how to create…">|||
my_chat_member | ChatMemberUpdated | -Optional. The bot's chat member status was updated in a chat. For private chats, this update is received only when the bot is blocked or unblocked by the user. | +Optional. The bot's chat member status was updated in a chat. For private chats, this update is received only when the bot is blocked or unblocked by the user. |
chat_member | ChatMemberUpdated | -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. | +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. |
chat_join_request | @@ -214,7 +216,7 @@ To learn how to create…">
Use this method to receive incoming updates using long polling (wiki). Returns an Array of Update objects.
allowed_updates | Array of String | Optional | -A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used. Please note that this parameter doesn't affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time. |
+A JSON-serialized list of the update types you want your bot to receive. For example, specify ["message", "edited_channel_post", "callback_query"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used. Please note that this parameter doesn't affect updates created before the call to the getUpdates, so unwanted updates may be received for a short period of time. |
--Notes
+
1. 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.Notes +1. 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.
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.
-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.
+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.
max_connections | Integer | Optional | -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. | +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. | |
allowed_updates | Array of String | Optional | -A JSON-serialized list of the update types you want your bot to receive. For example, specify [“message”, “edited_channel_post”, “callback_query”] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used. Please note that this parameter doesn't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time. |
+A JSON-serialized list of the update types you want your bot to receive. For example, specify ["message", "edited_channel_post", "callback_query"] to only receive updates of these types. See Update for a complete list of available update types. Specify an empty list to receive all update types except chat_member (default). If not specified, the previous setting will be used. Please note that this parameter doesn't affect updates created before the call to the setWebhook, so unwanted updates may be received for a short period of time. |
|
drop_pending_updates | @@ -308,15 +312,20 @@ To learn how to create…">secret_token | String | Optional | -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. |
+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. |
--Notes
-
1. 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.If you're having any trouble setting up webhooks, please check out this amazing guide to webhooks.
+Notes +1. 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.
++If you're having any trouble setting up webhooks, please check out this amazing guide to webhooks.
+
Use this method to remove webhook integration if you decide to switch back to getUpdates. Returns True on success.
Use this method to get current webhook status. Requires no parameters. On success, returns a WebhookInfo object. If the bot is using getUpdates, will return an object with the url field empty.
-Describes the current status of a webhook.
All types used in the Bot API responses are represented as JSON-objects.
It is safe to use 32-bit signed integers for storing all Integer fields unless otherwise noted.
-Optional fields may be not returned when irrelevant.
This object represents a Telegram user or bot.
first_name | String | -User's or bot's first name | +User's or bot's first name |
last_name | String | -Optional. User's or bot's last name | +Optional. User's or bot's last name |
username | String | -Optional. User's or bot's username | +Optional. User's or bot's username |
language_code | String | -Optional. IETF language tag of the user's language | +Optional. IETF language tag of the user's language |
is_premium | @@ -470,7 +479,7 @@ To learn how to create…">
This object represents a chat.
type | String | -Type of chat, can be either “private”, “group”, “supergroup” or “channel” | +Type of chat, can be either "private", "group", "supergroup" or "channel" |
title | @@ -604,7 +613,7 @@ To learn how to create…">|||
has_protected_content | True | -Optional. True, if messages from the chat can't be forwarded to other chats. Returned only in getChat. | +Optional. True, if messages from the chat can't be forwarded to other chats. Returned only in getChat. |
sticker_set_name | @@ -628,7 +637,7 @@ To learn how to create…">
This object represents a message.
forward_sender_name | String | -Optional. Sender's name for messages forwarded from users who disallow adding a link to their account in forwarded messages | +Optional. Sender's name for messages forwarded from users who disallow adding a link to their account in forwarded messages |
forward_date | @@ -727,7 +736,7 @@ To learn how to create…">|||
has_protected_content | True | -Optional. True, if the message can't be forwarded | +Optional. True, if the message can't be forwarded |
media_group_id | @@ -872,12 +881,12 @@ To learn how to create…">|||
supergroup_chat_created | True | -Optional. Service message: the supergroup has been created. This field can't be received in a message coming through updates, because bot can't be a member of a supergroup when it is created. It can only be found in reply_to_message if someone replies to a very first message in a directly created supergroup. | +Optional. Service message: the supergroup has been created. This field can't be received in a message coming through updates, because bot can't be a member of a supergroup when it is created. It can only be found in reply_to_message if someone replies to a very first message in a directly created supergroup. |
channel_chat_created | True | -Optional. Service message: the channel has been created. This field can't be received in a message coming through updates, because bot can't be a member of a channel when it is created. It can only be found in reply_to_message if someone replies to a very first message in a channel. | +Optional. Service message: the channel has been created. This field can't be received in a message coming through updates, because bot can't be a member of a channel when it is created. It can only be found in reply_to_message if someone replies to a very first message in a channel. |
message_auto_delete_timer_changed | @@ -937,7 +946,7 @@ To learn how to create…">|||
proximity_alert_triggered | ProximityAlertTriggered | -Optional. Service message. A user in the chat triggered another user's proximity alert while sharing Live Location. | +Optional. Service message. A user in the chat triggered another user's proximity alert while sharing Live Location. |
forum_topic_created | @@ -962,12 +971,12 @@ To learn how to create…">|||
general_forum_topic_hidden | GeneralForumTopicHidden | -Optional. Service message: the 'General' forum topic hidden | +Optional. Service message: the 'General' forum topic hidden |
general_forum_topic_unhidden | GeneralForumTopicUnhidden | -Optional. Service message: the 'General' forum topic unhidden | +Optional. Service message: the 'General' forum topic unhidden |
video_chat_scheduled | @@ -1001,7 +1010,7 @@ To learn how to create…">
This object represents a unique message identifier.
This object represents one special entity in a text message. For example, hashtags, usernames, URLs, etc.
type | String | -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) |
+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) |
offset | @@ -1048,26 +1057,26 @@ To learn how to create…">|||
url | String | -Optional. For “text_link” only, URL that will be opened after user taps on the text | +Optional. For "text_link" only, URL that will be opened after user taps on the text |
user | User | -Optional. For “text_mention” only, the mentioned user | +Optional. For "text_mention" only, the mentioned user |
language | String | -Optional. For “pre” only, the programming language of the entity text | +Optional. For "pre" only, the programming language of the entity text |
custom_emoji_id | String | -Optional. For “custom_emoji” only, unique identifier of the custom emoji. Use getCustomEmojiStickers to get full information about the sticker | +Optional. For "custom_emoji" only, unique identifier of the custom emoji. Use getCustomEmojiStickers to get full information about the sticker |
This object represents one size of a photo or a file / sticker thumbnail.
file_unique_id | String | -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. | +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. |
width | @@ -1105,7 +1114,7 @@ To learn how to create…">
This object represents an animation file (GIF or H.264/MPEG-4 AVC video without sound).
file_unique_id | String | -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. | +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. |
width | @@ -1163,7 +1172,7 @@ To learn how to create…">
This object represents an audio file to be treated as music by the Telegram clients.
file_unique_id | String | -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. | +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. |
duration | @@ -1221,7 +1230,7 @@ To learn how to create…">
This object represents a general file (as opposed to photos, voice messages and audio files).
file_unique_id | String | -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. | +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. |
thumbnail | @@ -1264,9 +1273,9 @@ To learn how to create…">
This object represents a message about a forwarded story in the chat. Currently holds no information.
-This object represents a video file.
file_unique_id | String | -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. | +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. |
width | @@ -1324,7 +1333,7 @@ To learn how to create…">
This object represents a video message (available in Telegram apps as of v.4.0).
file_unique_id | String | -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. | +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. |
length | @@ -1367,7 +1376,7 @@ To learn how to create…">
This object represents a voice note.
file_unique_id | String | -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. | +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. |
duration | @@ -1405,7 +1414,7 @@ To learn how to create…">
This object represents a phone contact.
phone_number | String | -Contact's phone number | +Contact's phone number |
first_name | String | -Contact's first name | +Contact's first name |
last_name | String | -Optional. Contact's last name | +Optional. Contact's last name |
user_id | Integer | -Optional. Contact's user identifier in Telegram. 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. | +Optional. Contact's user identifier in Telegram. 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. |
vcard | @@ -1443,7 +1452,7 @@ To learn how to create…">
This object represents an animated emoji that displays a random value.
value | Integer | -Value of the dice, 1-6 for “”, “” and “” base emoji, 1-5 for “” and “” base emoji, 1-64 for “” base emoji | +Value of the dice, 1-6 for "", "" and "" base emoji, 1-5 for "" and "" base emoji, 1-64 for "" base emoji |
This object contains information about one answer option in a poll.
This object represents an answer of a user in a non-anonymous poll.
user | User | -Optional. The user that changed the answer to the poll, if the voter isn't anonymous | +Optional. The user that changed the answer to the poll, if the voter isn't anonymous |
option_ids | @@ -1522,7 +1531,7 @@ To learn how to create…">
This object contains information about a poll.
type | String | -Poll type, currently can be “regular” or “quiz” | +Poll type, currently can be "regular" or "quiz" |
allows_multiple_answers | @@ -1600,7 +1609,7 @@ To learn how to create…">
This object represents a point on the map.
This object represents a venue.
location | Location | -Venue location. Can't be a live location | +Venue location. Can't be a live location |
title | @@ -1677,7 +1686,7 @@ To learn how to create…">|||
foursquare_type | String | -Optional. Foursquare type of the venue. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.) | +Optional. Foursquare type of the venue. (For example, "arts_entertainment/default", "arts_entertainment/aquarium" or "food/icecream".) |
google_place_id | @@ -1691,7 +1700,7 @@ To learn how to create…">
Describes data sent from a Web App to the bot.
This object represents the content of a service message, sent whenever a user in the chat triggers a proximity alert set by another user.
This object represents a service message about a change in auto-delete timer settings.
This object represents a service message about a new forum topic created in the chat.
This object represents a service message about a forum topic closed in the chat. Currently holds no information.
-This object represents a service message about an edited forum topic.
This object represents a service message about a forum topic reopened in the chat. Currently holds no information.
-This object represents a service message about General forum topic hidden in the chat. Currently holds no information.
-This object represents a service message about General forum topic unhidden in the chat. Currently holds no information.
-This object contains information about the user whose identifier was shared with the bot using a KeyboardButtonRequestUser button.
This object contains information about the chat whose identifier was shared with the bot using a KeyboardButtonRequestChat button.
This object represents a service message about a user allowing a bot to write messages after adding it to the attachment menu, launching a Web App from a link, or accepting an explicit request from a Web App sent by the method requestWriteAccess.
This object represents a service message about a video chat scheduled in the chat.
This object represents a service message about a video chat started in the chat. Currently holds no information.
-This object represents a service message about a video chat ended in the chat.
This object represents a service message about new members invited to a video chat.
This object represent a user's profile pictures.
+This object represent a user's profile pictures.
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.
The maximum file size to download is 20 MB
@@ -1994,7 +2003,7 @@ To learn how to create…">file_unique_id String -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. +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. - file_size @@ -2008,7 +2017,7 @@ To learn how to create…">WebAppInfo
+WebAppInfo
Describes a Web App.
@@ -2026,7 +2035,7 @@ To learn how to create…">
-ReplyKeyboardMarkup
+ReplyKeyboardMarkup
This object represents a custom keyboard with reply options (see Introduction to bots for details and examples).
@@ -2050,12 +2059,12 @@ To learn how to create…">
-resize_keyboard Boolean -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. +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. one_time_keyboard Boolean -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. +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. input_field_placeholder @@ -2065,11 +2074,11 @@ To learn how to create…">selective Boolean -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.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.KeyboardButton
+KeyboardButton
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.
@@ -2088,22 +2097,22 @@ To learn how to create…">
-request_user KeyboardButtonRequestUser -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. +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. request_chat KeyboardButtonRequestChat -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. +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. request_contact Boolean -Optional. If True, the user's phone number will be sent as a contact when the button is pressed. Available in private chats only. +Optional. If True, the user's phone number will be sent as a contact when the button is pressed. Available in private chats only. request_location Boolean -Optional. If True, the user's current location will be sent when the button is pressed. Available in private chats only. +Optional. If True, the user's current location will be sent when the button is pressed. Available in private chats only. request_poll @@ -2113,12 +2122,15 @@ To learn how to create…">web_app WebAppInfo -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. +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. 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.KeyboardButtonRequestUser
+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.
+KeyboardButtonRequestUser
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 »
@@ -2146,7 +2158,7 @@ To learn how to create…">
-KeyboardButtonRequestChat
+KeyboardButtonRequestChat
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 »
@@ -2199,7 +2211,7 @@ To learn how to create…">
-KeyboardButtonPollType
+KeyboardButtonPollType
This object represents type of a poll, which is allowed to be created and sent when the corresponding button is pressed.
@@ -2217,7 +2229,7 @@ To learn how to create…">
-ReplyKeyboardRemove
+ReplyKeyboardRemove
Upon receiving a message with this object, Telegram clients will remove the current custom keyboard and display the default letter-keyboard. By default, custom keyboards are displayed until a new keyboard is sent by a bot. An exception is made for one-time keyboards that are hidden immediately after the user presses a button (see ReplyKeyboardMarkup).
@@ -2236,11 +2248,11 @@ To learn how to create…">
-selective Boolean -Optional. Use this parameter if you want to remove the keyboard for 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 votes in a poll, bot returns confirmation message in reply to the vote and removes the keyboard for that user, while still showing the keyboard with poll options to users who haven't voted yet.Optional. Use this parameter if you want to remove the keyboard for 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 votes in a poll, bot returns confirmation message in reply to the vote and removes the keyboard for that user, while still showing the keyboard with poll options to users who haven't voted yet.InlineKeyboardMarkup
+InlineKeyboardMarkup
This object represents an inline keyboard that appears right next to the message it belongs to.
@@ -2259,7 +2271,7 @@ To learn how to create…">
Note: This will only work in Telegram versions released after 9 April, 2016. Older clients will display unsupported message.
-InlineKeyboardButton
+InlineKeyboardButton
This object represents one button of an inline keyboard. You must use exactly one of the optional fields.
@@ -2298,17 +2310,17 @@ To learn how to create…">
-switch_inline_query String -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. +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. switch_inline_query_current_chat String -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.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.switch_inline_query_chosen_chat SwitchInlineQueryChosenChat -Optional. If set, pressing the button will prompt the user to select one of their chats of the specified type, open that chat and insert the bot's username and the specified inline query in the input field +Optional. If set, pressing the button will prompt the user to select one of their chats of the specified type, open that chat and insert the bot's username and the specified inline query in the input field callback_game @@ -2322,12 +2334,11 @@ To learn how to create…">LoginUrl
+LoginUrl
This object represents a parameter of the inline keyboard button used to automatically authorize a user. Serves as a great replacement for the Telegram Login Widget when the user is coming from Telegram. All the user needs to do is tap/click a button and confirm that they want to log in:
-Telegram apps support these buttons as of version 5.7.
Sample bot: @discussbot
@@ -2354,7 +2365,7 @@ To learn how to create…">bot_username String -Optional. Username of a bot, which will be used for user authorization. See Setting up a bot for more details. If not specified, the current bot's username will be assumed. The url's domain must be the same as the domain linked with the bot. See Linking your domain to the bot for more details. +Optional. Username of a bot, which will be used for user authorization. See Setting up a bot for more details. If not specified, the current bot's username will be assumed. The url's domain must be the same as the domain linked with the bot. See Linking your domain to the bot for more details. - request_write_access @@ -2363,7 +2374,7 @@ To learn how to create…">SwitchInlineQueryChosenChat
+SwitchInlineQueryChosenChat
This object represents an inline button that switches the current user to inline mode in a chosen chat, with an optional default inline query.
@@ -2377,7 +2388,7 @@ To learn how to create…">
-query String -Optional. The default inline query to be inserted in the input field. If left empty, only the bot's username will be inserted +Optional. The default inline query to be inserted in the input field. If left empty, only the bot's username will be inserted allow_user_chats @@ -2401,7 +2412,7 @@ To learn how to create…">CallbackQuery
+CallbackQuery
This object represents an incoming callback query from a callback button in an inline keyboard. If the button that originated the query was attached to a message sent by the bot, the field message will be present. If the button was attached to a message sent via the bot (in inline mode), the field inline_message_id will be present. Exactly one of the fields data or game_short_name will be present.
@@ -2452,8 +2463,8 @@ To learn how to create…">
--NOTE: After the user presses a callback button, Telegram clients will display a progress bar until you call answerCallbackQuery. It is, therefore, necessary to react by calling answerCallbackQuery even if no notification to the user is needed (e.g., without specifying any of the optional parameters).
ForceReply
-Upon receiving a message with this object, Telegram clients will display a reply interface to the user (act as if the user has selected the bot's message and tapped 'Reply'). This can be extremely useful if you want to create user-friendly step-by-step interfaces without having to sacrifice privacy mode.
+ForceReply
+Upon receiving a message with this object, Telegram clients will display a reply interface to the user (act as if the user has selected the bot's message and tapped 'Reply'). This can be extremely useful if you want to create user-friendly step-by-step interfaces without having to sacrifice privacy mode.
@@ -2484,11 +2495,11 @@ To learn how to create…">
@@ -2466,7 +2477,7 @@ To learn how to create…"> force_reply True -Shows reply interface to the user, as if they manually selected the bot's message and tapped 'Reply' +Shows reply interface to the user, as if they manually selected the bot's message and tapped 'Reply' input_field_placeholder @@ -2476,7 +2487,7 @@ To learn how to create…">selective Boolean -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. +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. Example: A poll bot for groups runs in privacy mode (only receives commands, replies to its messages and mentions). There could be two ways to create a new poll:
-
- 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.
-- 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'.
+- 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'.
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.
+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.
-ChatPhoto
+ChatPhoto
This object represents a chat photo.
@@ -2507,7 +2518,7 @@ To learn how to create…">
-small_file_unique_id String -Unique file identifier of small (160x160) chat photo, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file. +Unique file identifier of small (160x160) chat photo, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file. big_file_id @@ -2517,11 +2528,11 @@ To learn how to create…">big_file_unique_id String -Unique file identifier of big (640x640) chat photo, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file. +Unique file identifier of big (640x640) chat photo, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file. ChatInviteLink
+ChatInviteLink
Represents an invite link for a chat.
@@ -2535,7 +2546,7 @@ To learn how to create…">
-invite_link String -The invite link. If the link was created by another chat administrator, then the second part of the link will be replaced with “…”. +The invite link. If the link was created by another chat administrator, then the second part of the link will be replaced with "...". creator @@ -2579,7 +2590,7 @@ To learn how to create…">ChatAdministratorRights
+ChatAdministratorRights
Represents the rights of an administrator in a chat.
@@ -2593,7 +2604,7 @@ To learn how to create…">
-is_anonymous Boolean -True, if the user's presence in the chat is hidden +True, if the user's presence in the chat is hidden can_manage_chat @@ -2667,7 +2678,7 @@ To learn how to create…">ChatMember
+ChatMember
This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported:
-
- ChatMemberOwner
@@ -2677,7 +2688,7 @@ To learn how to create…">- ChatMemberLeft
- ChatMemberBanned
ChatMemberOwner
+ChatMemberOwner
Represents a chat member that owns the chat and has all administrator privileges.
@@ -2691,7 +2702,7 @@ To learn how to create…">
-status String -The member's status in the chat, always “creator” +The member's status in the chat, always "creator" user @@ -2701,7 +2712,7 @@ To learn how to create…">is_anonymous Boolean -True, if the user's presence in the chat is hidden +True, if the user's presence in the chat is hidden custom_title @@ -2710,7 +2721,7 @@ To learn how to create…">ChatMemberAdministrator
+ChatMemberAdministrator
Represents a chat member that has some additional privileges.
@@ -2724,7 +2735,7 @@ To learn how to create…">
-status String -The member's status in the chat, always “administrator” +The member's status in the chat, always "administrator" user @@ -2739,7 +2750,7 @@ To learn how to create…">is_anonymous Boolean -True, if the user's presence in the chat is hidden +True, if the user's presence in the chat is hidden can_manage_chat @@ -2818,7 +2829,7 @@ To learn how to create…">ChatMemberMember
+ChatMemberMember
Represents a chat member that has no additional privileges or restrictions.
@@ -2832,7 +2843,7 @@ To learn how to create…">
-status String -The member's status in the chat, always “member” +The member's status in the chat, always "member" user @@ -2841,7 +2852,7 @@ To learn how to create…">ChatMemberRestricted
+ChatMemberRestricted
Represents a chat member that is under certain restrictions in the chat. Supergroups only.
@@ -2855,7 +2866,7 @@ To learn how to create…">
-status String -The member's status in the chat, always “restricted” +The member's status in the chat, always "restricted" user @@ -2944,8 +2955,8 @@ To learn how to create…">ChatMemberLeft
-Represents a chat member that isn't currently a member of the chat, but may join it themselves.
+ChatMemberLeft
+Represents a chat member that isn't currently a member of the chat, but may join it themselves.
-
@@ -2958,7 +2969,7 @@ To learn how to create…"> status String -The member's status in the chat, always “left” +The member's status in the chat, always "left" user @@ -2967,8 +2978,8 @@ To learn how to create…">ChatMemberBanned
-Represents a chat member that was banned in the chat and can't return to the chat or view chat messages.
+ChatMemberBanned
+Represents a chat member that was banned in the chat and can't return to the chat or view chat messages.
-
@@ -2981,7 +2992,7 @@ To learn how to create…"> status String -The member's status in the chat, always “kicked” +The member's status in the chat, always "kicked" user @@ -2995,7 +3006,7 @@ To learn how to create…">ChatMemberUpdated
+ChatMemberUpdated
This object represents changes in the status of a chat member.
@@ -3043,7 +3054,7 @@ To learn how to create…">
-ChatJoinRequest
+ChatJoinRequest
Represents a join request sent to a chat.
@@ -3086,7 +3097,7 @@ To learn how to create…">
-ChatPermissions
+ChatPermissions
Describes actions that a non-administrator user is allowed to take in a chat.
@@ -3169,7 +3180,7 @@ To learn how to create…">
-ChatLocation
+ChatLocation
Represents a location to which a chat is connected.
@@ -3183,7 +3194,7 @@ To learn how to create…">
-location Location -The location to which the supergroup is connected. Can't be a live location. +The location to which the supergroup is connected. Can't be a live location. address @@ -3192,7 +3203,7 @@ To learn how to create…">ForumTopic
+ForumTopic
This object represents a forum topic.
@@ -3225,7 +3236,7 @@ To learn how to create…">
-BotCommand
+BotCommand
This object represents a bot command.
@@ -3248,7 +3259,7 @@ To learn how to create…">
-BotCommandScope
+BotCommandScope
This object represents the scope to which bot commands are applied. Currently, the following 7 scopes are supported:
-
- BotCommandScopeDefault
@@ -3259,7 +3270,7 @@ To learn how to create…">- BotCommandScopeChatAdministrators
- BotCommandScopeChatMember
Determining list of commands
+Determining list of commands
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:
Commands in the chat with the bot
@@ -3285,7 +3296,7 @@ To learn how to create…">
-- botCommandScopeDefault + language_code
- botCommandScopeDefault
BotCommandScopeDefault
+BotCommandScopeDefault
Represents the default scope of bot commands. Default commands are used if no commands with a narrower scope are specified for the user.
@@ -3303,7 +3314,7 @@ To learn how to create…">
-BotCommandScopeAllPrivateChats
+BotCommandScopeAllPrivateChats
Represents the scope of bot commands, covering all private chats.
@@ -3321,7 +3332,7 @@ To learn how to create…">
-BotCommandScopeAllGroupChats
+BotCommandScopeAllGroupChats
Represents the scope of bot commands, covering all group and supergroup chats.
@@ -3339,7 +3350,7 @@ To learn how to create…">
-BotCommandScopeAllChatAdministrators
+BotCommandScopeAllChatAdministrators
Represents the scope of bot commands, covering all group and supergroup chat administrators.
@@ -3357,7 +3368,7 @@ To learn how to create…">
-BotCommandScopeChat
+BotCommandScopeChat
Represents the scope of bot commands, covering a specific chat.
@@ -3380,7 +3391,7 @@ To learn how to create…">
-BotCommandScopeChatAdministrators
+BotCommandScopeChatAdministrators
Represents the scope of bot commands, covering all administrators of a specific group or supergroup chat.
@@ -3403,7 +3414,7 @@ To learn how to create…">
-BotCommandScopeChatMember
+BotCommandScopeChatMember
Represents the scope of bot commands, covering a specific member of a group or supergroup chat.
@@ -3431,8 +3442,8 @@ To learn how to create…">
-BotName
-This object represents the bot's name.
+BotName
+This object represents the bot's name.
-
@@ -3445,12 +3456,12 @@ To learn how to create…"> name String -The bot's name +The bot's name BotDescription
-This object represents the bot's description.
+BotDescription
+This object represents the bot's description.
-
@@ -3463,12 +3474,12 @@ To learn how to create…"> description String -The bot's description +The bot's description BotShortDescription
-This object represents the bot's short description.
+BotShortDescription
+This object represents the bot's short description.
-
@@ -3481,20 +3492,20 @@ To learn how to create…"> short_description String -The bot's short description +The bot's short description MenuButton
-This object describes the bot's menu button in a private chat. It should be one of
+MenuButton
+This object describes the bot's menu button in a private chat. It should be one of
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.
-MenuButtonCommands
-Represents a menu button, which opens the bot's list of commands.
+MenuButtonCommands
+Represents a menu button, which opens the bot's list of commands.
-
@@ -3511,7 +3522,7 @@ To learn how to create…"> MenuButtonWebApp
+MenuButtonWebApp
Represents a menu button, which launches a Web App.
@@ -3539,7 +3550,7 @@ To learn how to create…">
-MenuButtonDefault
+MenuButtonDefault
Describes that no specific value for the menu button was set.
@@ -3557,7 +3568,7 @@ To learn how to create…">
-ResponseParameters
+ResponseParameters
Describes why a request was unsuccessful.
@@ -3580,7 +3591,7 @@ To learn how to create…">
-InputMedia
+InputMedia
This object represents the content of a media message to be sent. It should be one of
-
- InputMediaAnimation
@@ -3589,7 +3600,7 @@ To learn how to create…">- InputMediaPhoto
- InputMediaVideo
InputMediaPhoto
+InputMediaPhoto
Represents a photo to be sent.
@@ -3608,7 +3619,7 @@ To learn how to create…">
-media String -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 » +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 » caption @@ -3632,7 +3643,7 @@ To learn how to create…">InputMediaVideo
+InputMediaVideo
Represents a video to be sent.
@@ -3651,12 +3662,12 @@ To learn how to create…">
-media String -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 » +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 » thumbnail InputFile or String -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 » +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 » caption @@ -3700,7 +3711,7 @@ To learn how to create…">InputMediaAnimation
+InputMediaAnimation
Represents an animation file (GIF or H.264/MPEG-4 AVC video without sound) to be sent.
@@ -3719,12 +3730,12 @@ To learn how to create…">
-media String -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 » +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 » thumbnail InputFile or String -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 » +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 » caption @@ -3763,7 +3774,7 @@ To learn how to create…">InputMediaAudio
+InputMediaAudio
Represents an audio file to be treated as music to be sent.
@@ -3782,12 +3793,12 @@ To learn how to create…">
-media String -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 » +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 » thumbnail InputFile or String -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 » +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 » caption @@ -3821,7 +3832,7 @@ To learn how to create…">InputMediaDocument
+InputMediaDocument
Represents a general file to be sent.
@@ -3840,12 +3851,12 @@ To learn how to create…">
-media String -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 » +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 » thumbnail InputFile or String -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 » +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 » caption @@ -3869,21 +3880,21 @@ To learn how to create…">InputFile
+InputFile
This object represents the contents of a file to be uploaded. Must be posted using multipart/form-data in the usual way that files are uploaded via the browser.
-Sending files
+Sending files
There are three ways to send files (photos, stickers, audio, media, etc.):
-
- If the file is already stored somewhere on the Telegram servers, you don't need to reupload it: each file object has a file_id field, simply pass this file_id as a parameter instead of uploading. There are no limits for files sent this way.
+- If the file is already stored somewhere on the Telegram servers, you don't need to reupload it: each file object has a file_id field, simply pass this file_id as a parameter instead of uploading. There are no limits for files sent this way.
- Provide Telegram with an HTTP URL for the file to be sent. Telegram will download and send the file. 5 MB max size for photos and 20 MB max for other types of content.
- Post the file using multipart/form-data in the usual way that files are uploaded via the browser. 10 MB max size for photos, 50 MB for other files.
Sending by file_id
-
- It is not possible to change the file type when resending by file_id. I.e. a video can't be sent as a photo, a photo can't be sent as a document, etc.
+- It is not possible to change the file type when resending by file_id. I.e. a video can't be sent as a photo, a photo can't be sent as a document, etc.
- It is not possible to resend thumbnails.
- Resending a photo by file_id will send all of its sizes.
-- file_id is unique for each individual bot and can't be transferred from one bot to another.
+- file_id is unique for each individual bot and can't be transferred from one bot to another.
- file_id uniquely identifies a file, but a file can have different valid file_ids even for the same bot.
Sending by URL
@@ -3891,21 +3902,22 @@ To learn how to create…">When sending by URL the target file must have the correct MIME type (e.g., audio/mpeg for sendAudio, etc.). In sendDocument, sending by URL will currently only work for GIF, PDF and ZIP files. 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. -Other configurations may work but we can't guarantee that they will. +Other configurations may work but we can't guarantee that they will. -Inline mode objects
+Inline mode objects
Objects and methods used in the inline mode are described in the Inline mode section.
-Available methods
+Available methods
--All methods in the Bot API are case-insensitive. We support GET and POST HTTP methods. Use either URL query string or application/json or application/x-www-form-urlencoded or multipart/form-data for passing parameters in Bot API requests.
+
On successful call, a JSON-object containing the result will be returned.All methods in the Bot API are case-insensitive. We support GET and POST HTTP methods. Use either URL query string or application/json or application/x-www-form-urlencoded or multipart/form-data for passing parameters in Bot API requests. +On successful call, a JSON-object containing the result will be returned.
getMe
-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.
-logOut
+getMe
+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.
+logOut
Use this method to log out from the cloud Bot API server before launching the bot locally. You must log out the bot before running it locally, otherwise there is no guarantee that the bot will receive updates. After a successful call, you can immediately log in on a local server, but will not be able to log in back to the cloud Bot API server for 10 minutes. Returns True on success. Requires no parameters.
-close
-Use this method to close the bot instance before moving it from one local server to another. You need to delete the webhook before calling this method to ensure that the bot isn't launched again after server restart. The method will return error 429 in the first 10 minutes after the bot is launched. Returns True on success. Requires no parameters.
-sendMessage
+close
+Use this method to close the bot instance before moving it from one local server to another. You need to delete the webhook before calling this method to ensure that the bot isn't launched again after server restart. The method will return error 429 in the first 10 minutes after the bot is launched. Returns True on success. Requires no parameters.
+sendMessage
Use this method to send text messages. On success, the sent Message is returned.
@@ -3985,16 +3997,21 @@ To learn how to create…">
-Formatting options
-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.
-Note that Telegram clients will display an alert to the user before opening an inline link ('Open this link?' together with the full URL).
-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.Formatting options
+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.
+Note that Telegram clients will display an alert to the user before opening an inline link ('Open this link?' together with the full URL).
+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.
+Links
tg://user?id=<user_id>
can be used to mention a user by their ID without using a username. Please note:-
- 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.
-- 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.
+- 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.
MarkdownV2 style
+MarkdownV2 style
To use this mode, pass MarkdownV2 in the parse_mode field. Use the following syntax in your message:
*bold \*text* _italic \*text_ @@ -4014,28 +4031,28 @@ pre-formatted fixed-width code block written in the Python programming language ```
Please note:
-
-- 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.
-- Inside
-pre
andcode
entities, all '`' and '\' characters must be escaped with a preceding '\' character.- Inside the
-(...)
part of the inline link and custom emoji definition, all ')' and '\' must be escaped with a preceding '\' character.- In all other places characters '_', '*', '[', ']', '(', ')', '~', '`', '>', '#', '+', '-', '=', '|', '{', '}', '.', '!' must be escaped with the preceding character '\'.
+- 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.
+- Inside
+pre
andcode
entities, all '`' and '\' characters must be escaped with a preceding '\' character.- Inside the
+(...)
part of the inline link and custom emoji definition, all ')' and '\' must be escaped with a preceding '\' character.- In all other places characters '_', '*', '[', ']', '(', ')', '~', '`', '>', '#', '+', '-', '=', '|', '{', '}', '.', '!' must be escaped with the preceding character '\'.
- In case of ambiguity between
italic
andunderline
entities__
is always greadily treated from left to right as beginning or end ofunderline
entity, so instead of___italic underline___
use___italic underline_\r__
, where\r
is a character with code 13, which will be ignored.- A valid emoji must be provided as an alternative value for the custom emoji. The emoji will be shown instead of the custom emoji in places where a custom emoji cannot be displayed (e.g., system notifications) or if the message is forwarded by a non-premium user. It is recommended to use the emoji from the emoji field of the custom emoji sticker.
- Custom emoji entities can only be used by bots that purchased additional usernames on Fragment.
HTML style
+HTML style
To use this mode, pass HTML in the parse_mode field. The following tags are currently supported:
+<pre><code class="language-python">pre-formatted fixed-width code block written in the Python programming language</code></pre><b>bold</b>, <strong>bold</strong> <i>italic</i>, <em>italic</em> <u>underline</u>, <ins>underline</ins> <s>strikethrough</s>, <strike>strikethrough</strike>, <del>strikethrough</del> -<span class="tg-spoiler">spoiler</span>, <tg-spoiler>spoiler</tg-spoiler> -<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> -<a href="http://www.example.com/">inline URL</a> -<a href="tg://user?id=123456789">inline mention of a user</a> -<tg-emoji emoji-id="5368324170671202286"></tg-emoji> +<span class="tg-spoiler">spoiler</span>, <tg-spoiler>spoiler</tg-spoiler> +<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> +<a href="http://www.example.com/">inline URL</a> +<a href="tg://user?id=123456789">inline mention of a user</a> +<tg-emoji emoji-id="5368324170671202286"></tg-emoji> <code>inline fixed-width code</code> <pre>pre-formatted fixed-width code block</pre> -<pre><code class="language-python">pre-formatted fixed-width code block written in the Python programming language</code></pre>
Please note:
-
- Only the tags mentioned above are currently supported.
@@ -4043,11 +4060,11 @@ pre-formatted fixed-width code block written in the Python programming language- All numerical HTML entities are supported.
- The API currently supports only the following named HTML entities:
<
,>
,&
and"
.- Use nested
-pre
andcode
tags, to define programming language forpre
entity.- Programming language can't be specified for standalone
+code
tags.- Programming language can't be specified for standalone
code
tags.- A valid emoji must be used as the content of the
tg-emoji
tag. The emoji will be shown instead of the custom emoji in places where a custom emoji cannot be displayed (e.g., system notifications) or if the message is forwarded by a non-premium user. It is recommended to use the emoji from the emoji field of the custom emoji sticker.- Custom emoji entities can only be used by bots that purchased additional usernames on Fragment.
Markdown style
+Markdown style
This is a legacy mode, retained for backward compatibility. To use this mode, pass Markdown in the parse_mode field. Use the following syntax in your message:
*bold text* _italic text_ @@ -4064,11 +4081,11 @@ pre-formatted fixed-width code block written in the Python programming language
-
- Entities must not be nested, use parse mode MarkdownV2 instead.
- There is no way to specify underline and strikethrough entities, use parse mode MarkdownV2 instead.
-- To escape characters '_', '*', '`', '[' outside of an entity, prepend the characters '\' before them.
+- To escape characters '_', '*', '`', '[' outside of an entity, prepend the characters '\' before them.
- Escaping inside entities is not allowed, so entity must be closed first and reopened again: use
_snake_\__case_
for italicsnake_case
and*2*\**2=4*
for bold2*2=4
.forwardMessage
-Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned.
+forwardMessage
+Use this method to forward messages of any kind. Service messages can't be forwarded. On success, the sent Message is returned.
-
@@ -4117,8 +4134,8 @@ pre-formatted fixed-width code block written in the Python programming language copyMessage
-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.
+copyMessage
+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.
-
@@ -4203,7 +4220,7 @@ pre-formatted fixed-width code block written in the Python programming language sendPhoto
+sendPhoto
Use this method to send photos. On success, the sent Message is returned.
@@ -4231,7 +4248,7 @@ pre-formatted fixed-width code block written in the Python programming language
-photo InputFile or String Yes -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 » +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 » caption @@ -4289,7 +4306,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendAudio
+sendAudio
Use this method to send audio files, if you want Telegram clients to display them in the music player. Your audio must be in the .MP3 or .M4A format. On success, the sent Message is returned. Bots can currently send audio files of up to 50 MB in size, this limit may be changed in the future.
For sending voice messages, use the sendVoice method instead.
@@ -4360,7 +4377,7 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail InputFile or String 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 » +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 » disable_notification @@ -4394,7 +4411,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendDocument
+sendDocument
Use this method to send general files. On success, the sent Message is returned. Bots can currently send files of any type of up to 50 MB in size, this limit may be changed in the future.
@@ -4428,7 +4445,7 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail InputFile or String 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 » +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 » caption @@ -4486,7 +4503,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendVideo
+sendVideo
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.
@@ -4538,7 +4555,7 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail InputFile or String 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 » +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 » caption @@ -4602,7 +4619,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendAnimation
+sendAnimation
Use this method to send animation files (GIF or H.264/MPEG-4 AVC video without sound). On success, the sent Message is returned. Bots can currently send animation files of up to 50 MB in size, this limit may be changed in the future.
@@ -4654,7 +4671,7 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail InputFile or String 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 » +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 » caption @@ -4712,7 +4729,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendVoice
+sendVoice
Use this method to send audio files, if you want Telegram clients to display the file as a playable voice message. For this to work, your audio must be in an .OGG file encoded with OPUS (other formats may be sent as Audio or Document). On success, the sent Message is returned. Bots can currently send voice messages of up to 50 MB in size, this limit may be changed in the future.
@@ -4798,7 +4815,7 @@ pre-formatted fixed-width code block written in the Python programming language
-sendVideoNote
+sendVideoNote
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.
@@ -4844,7 +4861,7 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail InputFile or String 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 » +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 » disable_notification @@ -4878,7 +4895,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendMediaGroup
+sendMediaGroup
Use this method to send a group of photos, videos, documents or audios as an album. Documents and audio files can be only grouped in an album with messages of the same type. On success, an array of Messages that were sent is returned.
@@ -4934,7 +4951,7 @@ pre-formatted fixed-width code block written in the Python programming language
-sendLocation
+sendLocation
Use this method to send point on the map. On success, the sent Message is returned.
@@ -5026,7 +5043,7 @@ pre-formatted fixed-width code block written in the Python programming language
-sendVenue
+sendVenue
Use this method to send information about a venue. On success, the sent Message is returned.
@@ -5084,7 +5101,7 @@ pre-formatted fixed-width code block written in the Python programming language
-foursquare_type String Optional -Foursquare type of the venue, if known. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.) +Foursquare type of the venue, if known. (For example, "arts_entertainment/default", "arts_entertainment/aquarium" or "food/icecream".) google_place_id @@ -5130,7 +5147,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendContact
+sendContact
Use this method to send phone contacts. On success, the sent Message is returned.
@@ -5158,19 +5175,19 @@ pre-formatted fixed-width code block written in the Python programming language
-phone_number String Yes -Contact's phone number +Contact's phone number first_name String Yes -Contact's first name +Contact's first name last_name String Optional -Contact's last name +Contact's last name vcard @@ -5210,7 +5227,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendPoll
+sendPoll
Use this method to send a native poll. On success, the sent Message is returned.
@@ -5256,7 +5273,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String Optional -Poll type, “quiz” or “regular”, defaults to “regular” +Poll type, "quiz" or "regular", defaults to "regular" allows_multiple_answers @@ -5292,13 +5309,13 @@ pre-formatted fixed-width code block written in the Python programming languageopen_period Integer Optional -Amount of time in seconds the poll will be active after creation, 5-600. Can't be used together with close_date. +Amount of time in seconds the poll will be active after creation, 5-600. Can't be used together with close_date. close_date Integer Optional -Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future. Can't be used together with open_period. +Point in time (Unix timestamp) when the poll will be automatically closed. Must be at least 5 and no more than 600 seconds in the future. Can't be used together with open_period. is_closed @@ -5338,7 +5355,7 @@ pre-formatted fixed-width code block written in the Python programming languagesendDice
+sendDice
Use this method to send an animated emoji that will display a random value. On success, the sent Message is returned.
@@ -5366,7 +5383,7 @@ pre-formatted fixed-width code block written in the Python programming language
-emoji String Optional -Emoji on which the dice throw animation is based. Currently, must be one of “”, “”, “”, “”, “”, or “”. Dice can have values 1-6 for “”, “” and “”, values 1-5 for “” and “”, and values 1-64 for “”. Defaults to “” +Emoji on which the dice throw animation is based. Currently, must be one of "", "", "", "", "", or "". Dice can have values 1-6 for "", "" and "", values 1-5 for "" and "", and values 1-64 for "". Defaults to "" disable_notification @@ -5400,10 +5417,10 @@ pre-formatted fixed-width code block written in the Python programming languagesendChatAction
-Use this method when you need to tell the user that something is happening on the bot's side. The status is set for 5 seconds or less (when a message arrives from your bot, Telegram clients clear its typing status). Returns True on success.
+sendChatAction
+Use this method when you need to tell the user that something is happening on the bot's side. The status is set for 5 seconds or less (when a message arrives from your bot, Telegram clients clear its typing status). Returns True on success.
-Example: The ImageBot needs some time to process a request and upload the image. Instead of sending a text message along the lines of “Retrieving image, please wait…”, the bot may use sendChatAction with action = upload_photo. The user will see a “sending photo” status for the bot.
+Example: The ImageBot needs some time to process a request and upload the image. Instead of sending a text message along the lines of "Retrieving image, please wait...", the bot may use sendChatAction with action = upload_photo. The user will see a "sending photo" status for the bot.
We only recommend using this method when a response from the bot will take a noticeable amount of time to arrive.
@@ -5436,7 +5453,7 @@ pre-formatted fixed-width code block written in the Python programming language
-getUserProfilePhotos
+getUserProfilePhotos
Use this method to get a list of profile pictures for a user. Returns a UserProfilePhotos object.
@@ -5468,7 +5485,7 @@ pre-formatted fixed-width code block written in the Python programming language
-getFile
+getFile
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.@@ -5488,8 +5505,8 @@ pre-formatted fixed-width code block written in the Python programming language
-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.
-banChatMember
+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.
+banChatMember
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.
@@ -5527,8 +5544,8 @@ pre-formatted fixed-width code block written in the Python programming language
-unbanChatMember
-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.
+unbanChatMember
+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.
-
@@ -5559,7 +5576,7 @@ pre-formatted fixed-width code block written in the Python programming language restrictChatMember
+restrictChatMember
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.
@@ -5603,7 +5620,7 @@ pre-formatted fixed-width code block written in the Python programming language
-promoteChatMember
+promoteChatMember
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.
@@ -5631,7 +5648,7 @@ pre-formatted fixed-width code block written in the Python programming language
-is_anonymous Boolean Optional -Pass True if the administrator's presence in the chat is hidden +Pass True if the administrator's presence in the chat is hidden can_manage_chat @@ -5719,7 +5736,7 @@ pre-formatted fixed-width code block written in the Python programming languagesetChatAdministratorCustomTitle
+setChatAdministratorCustomTitle
Use this method to set a custom title for an administrator in a supergroup promoted by the bot. Returns True on success.
@@ -5751,8 +5768,8 @@ pre-formatted fixed-width code block written in the Python programming language
-banChatSenderChat
-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.
+banChatSenderChat
+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.
-
@@ -5777,7 +5794,7 @@ pre-formatted fixed-width code block written in the Python programming language unbanChatSenderChat
+unbanChatSenderChat
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.
@@ -5803,7 +5820,7 @@ pre-formatted fixed-width code block written in the Python programming language
-setChatPermissions
+setChatPermissions
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.
@@ -5835,7 +5852,7 @@ pre-formatted fixed-width code block written in the Python programming language
-exportChatInviteLink
+exportChatInviteLink
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.
@@ -5856,9 +5873,9 @@ pre-formatted fixed-width code block written in the Python programming language
--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.
+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.
createChatInviteLink
+createChatInviteLink
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.
@@ -5898,11 +5915,11 @@ pre-formatted fixed-width code block written in the Python programming language
-creates_join_request Boolean Optional -True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can't be specified +True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can't be specified editChatInviteLink
+editChatInviteLink
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.
@@ -5948,11 +5965,11 @@ pre-formatted fixed-width code block written in the Python programming language
-creates_join_request Boolean Optional -True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can't be specified +True, if users joining the chat via the link need to be approved by chat administrators. If True, member_limit can't be specified revokeChatInviteLink
+revokeChatInviteLink
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.
@@ -5978,7 +5995,7 @@ pre-formatted fixed-width code block written in the Python programming language
-approveChatJoinRequest
+approveChatJoinRequest
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.
@@ -6004,7 +6021,7 @@ pre-formatted fixed-width code block written in the Python programming language
-declineChatJoinRequest
+declineChatJoinRequest
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.
@@ -6030,8 +6047,8 @@ pre-formatted fixed-width code block written in the Python programming language
-setChatPhoto
-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.
+setChatPhoto
+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.
-
@@ -6056,8 +6073,8 @@ pre-formatted fixed-width code block written in the Python programming language deleteChatPhoto
-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.
+deleteChatPhoto
+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.
-
@@ -6076,8 +6093,8 @@ pre-formatted fixed-width code block written in the Python programming language setChatTitle
-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.
+setChatTitle
+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.
-
@@ -6102,7 +6119,7 @@ pre-formatted fixed-width code block written in the Python programming language setChatDescription
+setChatDescription
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.
@@ -6128,8 +6145,8 @@ pre-formatted fixed-width code block written in the Python programming language
-pinChatMessage
-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.
+pinChatMessage
+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.
-
@@ -6160,8 +6177,8 @@ pre-formatted fixed-width code block written in the Python programming language unpinChatMessage
-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.
+unpinChatMessage
+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.
-
@@ -6186,8 +6203,8 @@ pre-formatted fixed-width code block written in the Python programming language unpinAllChatMessages
-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.
+unpinAllChatMessages
+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.
-
@@ -6206,7 +6223,7 @@ pre-formatted fixed-width code block written in the Python programming language leaveChat
+leaveChat
Use this method for your bot to leave a group, supergroup or channel. Returns True on success.
@@ -6226,7 +6243,7 @@ pre-formatted fixed-width code block written in the Python programming language
-getChat
+getChat
Use this method to get up to date information about the chat (current name of the user for one-on-one conversations, current username of a user, group or channel, etc.). Returns a Chat object on success.
@@ -6246,8 +6263,8 @@ pre-formatted fixed-width code block written in the Python programming language
-getChatAdministrators
-Use this method to get a list of administrators in a chat, which aren't bots. Returns an Array of ChatMember objects.
+getChatAdministrators
+Use this method to get a list of administrators in a chat, which aren't bots. Returns an Array of ChatMember objects.
-
@@ -6266,7 +6283,7 @@ pre-formatted fixed-width code block written in the Python programming language getChatMemberCount
+getChatMemberCount
Use this method to get the number of members in a chat. Returns Int on success.
@@ -6286,7 +6303,7 @@ pre-formatted fixed-width code block written in the Python programming language
-getChatMember
+getChatMember
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.
@@ -6312,7 +6329,7 @@ pre-formatted fixed-width code block written in the Python programming language
-setChatStickerSet
+setChatStickerSet
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.
@@ -6338,7 +6355,7 @@ pre-formatted fixed-width code block written in the Python programming language
-deleteChatStickerSet
+deleteChatStickerSet
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.
@@ -6358,9 +6375,9 @@ pre-formatted fixed-width code block written in the Python programming language
-getForumTopicIconStickers
+getForumTopicIconStickers
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.
-createForumTopic
+createForumTopic
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.
@@ -6398,7 +6415,7 @@ pre-formatted fixed-width code block written in the Python programming language
-editForumTopic
+editForumTopic
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.
@@ -6436,7 +6453,7 @@ pre-formatted fixed-width code block written in the Python programming language
-closeForumTopic
+closeForumTopic
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.
@@ -6462,7 +6479,7 @@ pre-formatted fixed-width code block written in the Python programming language
-reopenForumTopic
+reopenForumTopic
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.
@@ -6488,7 +6505,7 @@ pre-formatted fixed-width code block written in the Python programming language
-deleteForumTopic
+deleteForumTopic
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.
@@ -6514,7 +6531,7 @@ pre-formatted fixed-width code block written in the Python programming language
-unpinAllForumTopicMessages
+unpinAllForumTopicMessages
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.
@@ -6540,8 +6557,8 @@ pre-formatted fixed-width code block written in the Python programming language
-editGeneralForumTopic
-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.
+editGeneralForumTopic
+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.
-
@@ -6566,8 +6583,8 @@ pre-formatted fixed-width code block written in the Python programming language closeGeneralForumTopic
-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.
+closeGeneralForumTopic
+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.
-
@@ -6586,8 +6603,8 @@ pre-formatted fixed-width code block written in the Python programming language reopenGeneralForumTopic
-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.
+reopenGeneralForumTopic
+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.
-
@@ -6606,8 +6623,8 @@ pre-formatted fixed-width code block written in the Python programming language hideGeneralForumTopic
-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.
+hideGeneralForumTopic
+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.
-
@@ -6626,8 +6643,8 @@ pre-formatted fixed-width code block written in the Python programming language unhideGeneralForumTopic
-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.
+unhideGeneralForumTopic
+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.
-
@@ -6646,7 +6663,7 @@ pre-formatted fixed-width code block written in the Python programming language unpinAllGeneralForumTopicMessages
+unpinAllGeneralForumTopicMessages
Use this method to clear the list of pinned messages in a General 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.
@@ -6666,7 +6683,7 @@ pre-formatted fixed-width code block written in the Python programming language
-answerCallbackQuery
+answerCallbackQuery
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.
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
@@ -6703,7 +6720,7 @@ pre-formatted fixed-width code block written in the Python programming languaget.me/your_bot?start=XXXX
that open your bot with a parameter.url String Optional -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 liket.me/your_bot?start=XXXX
that open your bot with a parameter.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 liket.me/your_bot?start=XXXX
that open your bot with a parameter.cache_time @@ -6713,8 +6730,8 @@ pre-formatted fixed-width code block written in the Python programming languagesetMyCommands
-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.
+setMyCommands
+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.
-
@@ -6729,7 +6746,7 @@ pre-formatted fixed-width code block written in the Python programming language commands Array of BotCommand Yes -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. +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. scope @@ -6745,8 +6762,8 @@ pre-formatted fixed-width code block written in the Python programming languagedeleteMyCommands
-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.
+deleteMyCommands
+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.
-
@@ -6771,8 +6788,8 @@ pre-formatted fixed-width code block written in the Python programming language getMyCommands
-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.
+getMyCommands
+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.
-
@@ -6797,8 +6814,8 @@ pre-formatted fixed-width code block written in the Python programming language setMyName
-Use this method to change the bot's name. Returns True on success.
+setMyName
+Use this method to change the bot's name. Returns True on success.
-
@@ -6823,7 +6840,7 @@ pre-formatted fixed-width code block written in the Python programming language getMyName
+getMyName
Use this method to get the current bot name for the given user language. Returns BotName on success.
@@ -6843,8 +6860,8 @@ pre-formatted fixed-width code block written in the Python programming language
-setMyDescription
-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.
+setMyDescription
+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.
-
@@ -6869,7 +6886,7 @@ pre-formatted fixed-width code block written in the Python programming language getMyDescription
+getMyDescription
Use this method to get the current bot description for the given user language. Returns BotDescription on success.
@@ -6889,8 +6906,8 @@ pre-formatted fixed-width code block written in the Python programming language
-setMyShortDescription
-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.
+setMyShortDescription
+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.
-
@@ -6915,7 +6932,7 @@ pre-formatted fixed-width code block written in the Python programming language getMyShortDescription
+getMyShortDescription
Use this method to get the current bot short description for the given user language. Returns BotShortDescription on success.
@@ -6935,8 +6952,8 @@ pre-formatted fixed-width code block written in the Python programming language
-setChatMenuButton
-Use this method to change the bot's menu button in a private chat, or the default menu button. Returns True on success.
+setChatMenuButton
+Use this method to change the bot's menu button in a private chat, or the default menu button. Returns True on success.
-
@@ -6951,18 +6968,18 @@ pre-formatted fixed-width code block written in the Python programming language chat_id Integer Optional -Unique identifier for the target private chat. If not specified, default bot's menu button will be changed +Unique identifier for the target private chat. If not specified, default bot's menu button will be changed menu_button MenuButton Optional -A JSON-serialized object for the bot's new menu button. Defaults to MenuButtonDefault +A JSON-serialized object for the bot's new menu button. Defaults to MenuButtonDefault getChatMenuButton
-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.
+getChatMenuButton
+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.
-
@@ -6977,12 +6994,12 @@ pre-formatted fixed-width code block written in the Python programming language chat_id Integer Optional -Unique identifier for the target private chat. If not specified, default bot's menu button will be returned +Unique identifier for the target private chat. If not specified, default bot's menu button will be returned setMyDefaultAdministratorRights
-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.
+setMyDefaultAdministratorRights
+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.
-
@@ -7007,7 +7024,7 @@ pre-formatted fixed-width code block written in the Python programming language getMyDefaultAdministratorRights
+getMyDefaultAdministratorRights
Use this method to get the current default administrator rights of the bot. Returns ChatAdministratorRights on success.
@@ -7027,12 +7044,12 @@ pre-formatted fixed-width code block written in the Python programming language
-Inline mode methods
+Inline mode methods
Methods and objects used in the inline mode are described in the Inline mode section.
-Updating messages
+Updating messages
The following methods allow you to change an existing message in the message history instead of sending a new one with a result of an action. This is most useful for messages with inline keyboards using callback queries, but can also help reduce clutter in conversations with regular chat bots.
Please note, that it is currently only possible to edit messages without reply_markup or with inline keyboards.
-editMessageText
+editMessageText
Use this method to edit text and game messages. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned.
@@ -7094,7 +7111,7 @@ pre-formatted fixed-width code block written in the Python programming language
-editMessageCaption
+editMessageCaption
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.
@@ -7150,8 +7167,8 @@ pre-formatted fixed-width code block written in the Python programming language
-editMessageMedia
-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.
+editMessageMedia
+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.
-
@@ -7194,7 +7211,7 @@ pre-formatted fixed-width code block written in the Python programming language editMessageLiveLocation
+editMessageLiveLocation
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.
@@ -7262,7 +7279,7 @@ pre-formatted fixed-width code block written in the Python programming language
-stopMessageLiveLocation
+stopMessageLiveLocation
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.
@@ -7300,7 +7317,7 @@ pre-formatted fixed-width code block written in the Python programming language
-editMessageReplyMarkup
+editMessageReplyMarkup
Use this method to edit only the reply markup of messages. On success, if the edited message is not an inline message, the edited Message is returned, otherwise True is returned.
@@ -7338,7 +7355,7 @@ pre-formatted fixed-width code block written in the Python programming language
-stopPoll
+stopPoll
Use this method to stop a poll which was sent by the bot. On success, the stopped Poll is returned.
@@ -7370,8 +7387,19 @@ pre-formatted fixed-width code block written in the Python programming language
-deleteMessage
-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.deleteMessage
+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.
+-
@@ -7396,9 +7424,9 @@ pre-formatted fixed-width code block written in the Python programming language Stickers
+Stickers
The following methods and objects allow your bot to handle stickers and sticker sets.
-Sticker
+Sticker
This object represents a sticker.
@@ -7417,12 +7445,12 @@ pre-formatted fixed-width code block written in the Python programming language
-file_unique_id String -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. +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. type String -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. +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. width @@ -7486,7 +7514,7 @@ pre-formatted fixed-width code block written in the Python programming languageStickerSet
+StickerSet
This object represents a sticker set.
@@ -7510,7 +7538,7 @@ pre-formatted fixed-width code block written in the Python programming language
-sticker_type String -Type of stickers in the set, currently one of “regular”, “mask”, “custom_emoji” +Type of stickers in the set, currently one of "regular", "mask", "custom_emoji" is_animated @@ -7534,7 +7562,7 @@ pre-formatted fixed-width code block written in the Python programming languageMaskPosition
+MaskPosition
This object describes the position on faces where a mask should be placed by default.
@@ -7548,7 +7576,7 @@ pre-formatted fixed-width code block written in the Python programming language
-point String -The part of the face relative to which the mask should be placed. One of “forehead”, “eyes”, “mouth”, or “chin”. +The part of the face relative to which the mask should be placed. One of "forehead", "eyes", "mouth", or "chin". x_shift @@ -7567,7 +7595,7 @@ pre-formatted fixed-width code block written in the Python programming languageInputSticker
+InputSticker
This object describes a sticker to be added to a sticker set.
@@ -7581,7 +7609,7 @@ pre-formatted fixed-width code block written in the Python programming language
-sticker InputFile or String -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 » +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 » emoji_list @@ -7591,16 +7619,16 @@ pre-formatted fixed-width code block written in the Python programming languagemask_position MaskPosition -Optional. Position where the mask should be placed on faces. For “mask” stickers only. +Optional. Position where the mask should be placed on faces. For "mask" stickers only. keywords Array of String -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. +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. sendSticker
+sendSticker
Use this method to send static .WEBP, animated .TGS, or video .WEBM stickers. On success, the sent Message is returned.
@@ -7628,7 +7656,7 @@ pre-formatted fixed-width code block written in the Python programming language
-sticker InputFile or String Yes -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. +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. emoji @@ -7668,7 +7696,7 @@ pre-formatted fixed-width code block written in the Python programming languagegetStickerSet
+getStickerSet
Use this method to get a sticker set. On success, a StickerSet object is returned.
@@ -7688,7 +7716,7 @@ pre-formatted fixed-width code block written in the Python programming language
-getCustomEmojiStickers
+getCustomEmojiStickers
Use this method to get information about custom emoji stickers by their identifiers. Returns an Array of Sticker objects.
@@ -7708,7 +7736,7 @@ pre-formatted fixed-width code block written in the Python programming language
-uploadStickerFile
+uploadStickerFile
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.
@@ -7730,17 +7758,17 @@ pre-formatted fixed-width code block written in the Python programming language
-sticker InputFile Yes -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 » +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 » sticker_format String Yes -Format of the sticker, must be one of “static”, “animated”, “video” +Format of the sticker, must be one of "static", "animated", "video" createNewStickerSet
+createNewStickerSet
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.
@@ -7762,7 +7790,7 @@ pre-formatted fixed-width code block written in the Python programming language
-name String Yes -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.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.title @@ -7780,13 +7808,13 @@ pre-formatted fixed-width code block written in the Python programming languagesticker_format String Yes -Format of stickers in the set, must be one of “static”, “animated”, “video” +Format of stickers in the set, must be one of "static", "animated", "video" sticker_type String Optional -Type of stickers in the set, pass “regular”, “mask”, or “custom_emoji”. By default, a regular sticker set is created. +Type of stickers in the set, pass "regular", "mask", or "custom_emoji". By default, a regular sticker set is created. needs_repainting @@ -7796,7 +7824,7 @@ pre-formatted fixed-width code block written in the Python programming languageaddStickerToSet
+addStickerToSet
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.
@@ -7824,11 +7852,11 @@ pre-formatted fixed-width code block written in the Python programming language
-sticker InputSticker Yes -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. +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. setStickerPositionInSet
+setStickerPositionInSet
Use this method to move a sticker in a set created by the bot to a specific position. Returns True on success.
@@ -7854,7 +7882,7 @@ pre-formatted fixed-width code block written in the Python programming language
-deleteStickerFromSet
+deleteStickerFromSet
Use this method to delete a sticker from a set created by the bot. Returns True on success.
@@ -7874,7 +7902,7 @@ pre-formatted fixed-width code block written in the Python programming language
-setStickerEmojiList
+setStickerEmojiList
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.
@@ -7900,7 +7928,7 @@ pre-formatted fixed-width code block written in the Python programming language
-setStickerKeywords
+setStickerKeywords
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.
@@ -7926,7 +7954,7 @@ pre-formatted fixed-width code block written in the Python programming language
-setStickerMaskPosition
+setStickerMaskPosition
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.
@@ -7952,7 +7980,7 @@ pre-formatted fixed-width code block written in the Python programming language
-setStickerSetTitle
+setStickerSetTitle
Use this method to set the title of a created sticker set. Returns True on success.
@@ -7978,7 +8006,7 @@ pre-formatted fixed-width code block written in the Python programming language
-setStickerSetThumbnail
+setStickerSetThumbnail
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.
@@ -8006,11 +8034,11 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail InputFile or String Optional -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. +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. setCustomEmojiStickerSetThumbnail
+setCustomEmojiStickerSetThumbnail
Use this method to set the thumbnail of a custom emoji sticker set. Returns True on success.
@@ -8036,7 +8064,7 @@ pre-formatted fixed-width code block written in the Python programming language
-deleteStickerSet
+deleteStickerSet
Use this method to delete a sticker set that was created by the bot. Returns True on success.
@@ -8056,10 +8084,11 @@ pre-formatted fixed-width code block written in the Python programming language
-Inline mode
-The following methods and objects allow your bot to work in inline mode.
-
Please see our Introduction to Inline bots for more details.To enable this option, send the
-/setinline
command to @BotFather and provide the placeholder text that the user will see in the input field after typing your bot's name.InlineQuery
+Inline mode
+The following methods and objects allow your bot to work in inline mode. +Please see our Introduction to Inline bots for more details.
+To enable this option, send the
+/setinline
command to @BotFather and provide the placeholder text that the user will see in the input field after typing your bot's name.InlineQuery
This object represents an incoming inline query. When the user sends an empty query, your bot could return some default or trending results.
@@ -8093,7 +8122,7 @@ pre-formatted fixed-width code block written in the Python programming language
-chat_type String -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 +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 location @@ -8102,8 +8131,9 @@ pre-formatted fixed-width code block written in the Python programming languageanswerInlineQuery
-Use this method to send answers to an inline query. On success, True is returned.
+
No more than 50 results per query are allowed.answerInlineQuery
+Use this method to send answers to an inline query. On success, True is returned. +No more than 50 results per query are allowed.
-
@@ -8142,7 +8172,7 @@ pre-formatted fixed-width code block written in the Python programming language next_offset String Optional -Pass the offset that a client should send in the next query with the same text to receive more results. Pass an empty string if there are no more results or if you don't support pagination. Offset length can't exceed 64 bytes. +Pass the offset that a client should send in the next query with the same text to receive more results. Pass an empty string if there are no more results or if you don't support pagination. Offset length can't exceed 64 bytes. button @@ -8152,7 +8182,7 @@ pre-formatted fixed-width code block written in the Python programming languageInlineQueryResultsButton
+InlineQueryResultsButton
This object represents a button to be shown above inline query results. You must use exactly one of the optional fields.
@@ -8176,11 +8206,11 @@ pre-formatted fixed-width code block written in the Python programming language
-start_parameter String -Optional. Deep-linking parameter for the /start message sent to the bot when a user presses the 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.Optional. Deep-linking parameter for the /start message sent to the bot when a user presses the 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.InlineQueryResult
+InlineQueryResult
This object represents one result of an inline query. Telegram clients currently support results of the following 20 types:
- InlineQueryResultCachedAudio
@@ -8205,7 +8235,7 @@ pre-formatted fixed-width code block written in the Python programming language- InlineQueryResultVoice
Note: All URLs passed in inline query results will be available to end users and therefore must be assumed to be public.
-InlineQueryResultArticle
+InlineQueryResultArticle
Represents a link to an article or web page.
@@ -8249,7 +8279,7 @@ pre-formatted fixed-width code block written in the Python programming language
-hide_url Boolean -Optional. Pass True if you don't want the URL to be shown in the message +Optional. Pass True if you don't want the URL to be shown in the message description @@ -8273,7 +8303,7 @@ pre-formatted fixed-width code block written in the Python programming languageInlineQueryResultPhoto
+InlineQueryResultPhoto
Represents a link to a photo. By default, this photo will be sent by the user with optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the photo.
@@ -8351,7 +8381,7 @@ pre-formatted fixed-width code block written in the Python programming language
-InlineQueryResultGif
+InlineQueryResultGif
Represents a link to an animated GIF file. By default, this animated GIF file will be sent by the user with optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the animation.
@@ -8400,7 +8430,7 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail_mime_type String -Optional. MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to “image/jpeg” +Optional. MIME type of the thumbnail, must be one of "image/jpeg", "image/gif", or "video/mp4". Defaults to "image/jpeg" title @@ -8434,7 +8464,7 @@ pre-formatted fixed-width code block written in the Python programming languageInlineQueryResultMpeg4Gif
+InlineQueryResultMpeg4Gif
Represents a link to a video animation (H.264/MPEG-4 AVC video without sound). By default, this animated MPEG-4 file will be sent by the user with optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the animation.
@@ -8483,7 +8513,7 @@ pre-formatted fixed-width code block written in the Python programming language
-thumbnail_mime_type String -Optional. MIME type of the thumbnail, must be one of “image/jpeg”, “image/gif”, or “video/mp4”. Defaults to “image/jpeg” +Optional. MIME type of the thumbnail, must be one of "image/jpeg", "image/gif", or "video/mp4". Defaults to "image/jpeg" title @@ -8517,7 +8547,7 @@ pre-formatted fixed-width code block written in the Python programming languageInlineQueryResultVideo
+InlineQueryResultVideo
Represents a link to a page containing an embedded video player or a video file. By default, this video file will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the video.
If an InlineQueryResultVideo message contains an embedded video (e.g., YouTube), you must replace its content using input_message_content.
@@ -8549,7 +8579,7 @@ pre-formatted fixed-width code block written in the Python programming languagemime_type String -MIME type of the content of the video URL, “text/html” or “video/mp4” +MIME type of the content of the video URL, "text/html" or "video/mp4" - thumbnail_url @@ -8608,7 +8638,7 @@ pre-formatted fixed-width code block written in the Python programming languageInlineQueryResultAudio
+InlineQueryResultAudio
Represents a link to an MP3 audio file. By default, this audio file will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the audio.
@@ -8677,7 +8707,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultVoice
+InlineQueryResultVoice
Represents a link to a voice recording in an .OGG container encoded with OPUS. By default, this voice recording will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the the voice message.
@@ -8741,7 +8771,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultDocument
+InlineQueryResultDocument
Represents a link to a file. By default, this file will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the file. Currently, only .PDF and .ZIP files can be sent using this method.
@@ -8790,7 +8820,7 @@ pre-formatted fixed-width code block written in the Python programming language
mime_type String -MIME type of the content of the file, either “application/pdf” or “application/zip” +MIME type of the content of the file, either "application/pdf" or "application/zip" description @@ -8825,7 +8855,7 @@ pre-formatted fixed-width code block written in the Python programming languageNote: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultLocation
+InlineQueryResultLocation
Represents a location on a map. By default, the location will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the location.
@@ -8909,7 +8939,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultVenue
+InlineQueryResultVenue
Represents a venue. By default, the venue will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the venue.
@@ -8958,7 +8988,7 @@ pre-formatted fixed-width code block written in the Python programming language
foursquare_type String -Optional. Foursquare type of the venue, if known. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.) +Optional. Foursquare type of the venue, if known. (For example, "arts_entertainment/default", "arts_entertainment/aquarium" or "food/icecream".) google_place_id @@ -8998,7 +9028,7 @@ pre-formatted fixed-width code block written in the Python programming languageNote: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultContact
+InlineQueryResultContact
Represents a contact with a phone number. By default, this contact will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the contact.
@@ -9022,17 +9052,17 @@ pre-formatted fixed-width code block written in the Python programming language
phone_number String -Contact's phone number +Contact's phone number first_name String -Contact's first name +Contact's first name last_name String -Optional. Contact's last name +Optional. Contact's last name vcard @@ -9067,7 +9097,7 @@ pre-formatted fixed-width code block written in the Python programming languageNote: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultGame
+InlineQueryResultGame
Represents a Game.
@@ -9101,7 +9131,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after October 1, 2016. Older clients will not display any inline results if a game result is among them.
-InlineQueryResultCachedPhoto
+InlineQueryResultCachedPhoto
Represents a link to a photo stored on the Telegram servers. By default, this photo will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the photo.
@@ -9164,7 +9194,7 @@ pre-formatted fixed-width code block written in the Python programming language
-InlineQueryResultCachedGif
+InlineQueryResultCachedGif
Represents a link to an animated GIF file stored on the Telegram servers. By default, this animated GIF file will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with specified content instead of the animation.
@@ -9222,7 +9252,7 @@ pre-formatted fixed-width code block written in the Python programming language
-InlineQueryResultCachedMpeg4Gif
+InlineQueryResultCachedMpeg4Gif
Represents a link to a video animation (H.264/MPEG-4 AVC video without sound) stored on the Telegram servers. By default, this animated MPEG-4 file will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the animation.
@@ -9280,7 +9310,7 @@ pre-formatted fixed-width code block written in the Python programming language
-InlineQueryResultCachedSticker
+InlineQueryResultCachedSticker
Represents a link to a sticker stored on the Telegram servers. By default, this sticker will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the sticker.
@@ -9319,7 +9349,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after 9 April, 2016 for static stickers and after 06 July, 2019 for animated stickers. Older clients will ignore them.
-InlineQueryResultCachedDocument
+InlineQueryResultCachedDocument
Represents a link to a file stored on the Telegram servers. By default, this file will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the file.
@@ -9383,7 +9413,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultCachedVideo
+InlineQueryResultCachedVideo
Represents a link to a video file stored on the Telegram servers. By default, this video file will be sent by the user with an optional caption. Alternatively, you can use input_message_content to send a message with the specified content instead of the video.
@@ -9446,7 +9476,7 @@ pre-formatted fixed-width code block written in the Python programming language
-InlineQueryResultCachedVoice
+InlineQueryResultCachedVoice
Represents a link to a voice message stored on the Telegram servers. By default, this voice message will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the voice message.
@@ -9505,7 +9535,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InlineQueryResultCachedAudio
+InlineQueryResultCachedAudio
Represents a link to an MP3 audio file stored on the Telegram servers. By default, this audio file will be sent by the user. Alternatively, you can use input_message_content to send a message with the specified content instead of the audio.
@@ -9559,7 +9589,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: This will only work in Telegram versions released after 9 April, 2016. Older clients will ignore them.
-InputMessageContent
+InputMessageContent
This object represents the content of a message to be sent as a result of an inline query. Telegram clients currently support the following 5 types:
-
- InputTextMessageContent
@@ -9568,7 +9598,7 @@ pre-formatted fixed-width code block written in the Python programming language- InputContactMessageContent
- InputInvoiceMessageContent
InputTextMessageContent
+InputTextMessageContent
Represents the content of a text message to be sent as the result of an inline query.
@@ -9601,7 +9631,7 @@ pre-formatted fixed-width code block written in the Python programming language
-InputLocationMessageContent
+InputLocationMessageContent
Represents the content of a location message to be sent as the result of an inline query.
@@ -9644,7 +9674,7 @@ pre-formatted fixed-width code block written in the Python programming language
-InputVenueMessageContent
+InputVenueMessageContent
Represents the content of a venue message to be sent as the result of an inline query.
@@ -9683,7 +9713,7 @@ pre-formatted fixed-width code block written in the Python programming language
-foursquare_type String -Optional. Foursquare type of the venue, if known. (For example, “arts_entertainment/default”, “arts_entertainment/aquarium” or “food/icecream”.) +Optional. Foursquare type of the venue, if known. (For example, "arts_entertainment/default", "arts_entertainment/aquarium" or "food/icecream".) google_place_id @@ -9697,7 +9727,7 @@ pre-formatted fixed-width code block written in the Python programming languageInputContactMessageContent
+InputContactMessageContent
Represents the content of a contact message to be sent as the result of an inline query.
@@ -9711,17 +9741,17 @@ pre-formatted fixed-width code block written in the Python programming language
-phone_number String -Contact's phone number +Contact's phone number first_name String -Contact's first name +Contact's first name last_name String -Optional. Contact's last name +Optional. Contact's last name vcard @@ -9730,7 +9760,7 @@ pre-formatted fixed-width code block written in the Python programming languageInputInvoiceMessageContent
+InputInvoiceMessageContent
Represents the content of an invoice message to be sent as the result of an inline query.
@@ -9809,32 +9839,32 @@ pre-formatted fixed-width code block written in the Python programming language
-need_name Boolean -Optional. Pass True if you require the user's full name to complete the order +Optional. Pass True if you require the user's full name to complete the order need_phone_number Boolean -Optional. Pass True if you require the user's phone number to complete the order +Optional. Pass True if you require the user's phone number to complete the order need_email Boolean -Optional. Pass True if you require the user's email address to complete the order +Optional. Pass True if you require the user's email address to complete the order need_shipping_address Boolean -Optional. Pass True if you require the user's shipping address to complete the order +Optional. Pass True if you require the user's shipping address to complete the order send_phone_number_to_provider Boolean -Optional. Pass True if the user's phone number should be sent to provider +Optional. Pass True if the user's phone number should be sent to provider send_email_to_provider Boolean -Optional. Pass True if the user's email address should be sent to provider +Optional. Pass True if the user's email address should be sent to provider is_flexible @@ -9843,7 +9873,7 @@ pre-formatted fixed-width code block written in the Python programming languageChosenInlineResult
+ChosenInlineResult
Represents a result of an inline query that was chosen by the user and sent to their chat partner.
@@ -9882,7 +9912,7 @@ pre-formatted fixed-width code block written in the Python programming language
Note: It is necessary to enable inline feedback via @BotFather in order to receive these objects in updates.
-answerWebAppQuery
+answerWebAppQuery
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.
@@ -9908,7 +9938,7 @@ pre-formatted fixed-width code block written in the Python programming language
-SentWebAppMessage
+SentWebAppMessage
Describes an inline message sent by a Web App on behalf of a user.
@@ -9926,9 +9956,9 @@ pre-formatted fixed-width code block written in the Python programming language
-Payments
+Payments
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).
-sendInvoice
+sendInvoice
Use this method to send invoices. On success, the sent Message is returned.
@@ -10040,37 +10070,37 @@ pre-formatted fixed-width code block written in the Python programming language
-need_name Boolean Optional -Pass True if you require the user's full name to complete the order +Pass True if you require the user's full name to complete the order need_phone_number Boolean Optional -Pass True if you require the user's phone number to complete the order +Pass True if you require the user's phone number to complete the order need_email Boolean Optional -Pass True if you require the user's email address to complete the order +Pass True if you require the user's email address to complete the order need_shipping_address Boolean Optional -Pass True if you require the user's shipping address to complete the order +Pass True if you require the user's shipping address to complete the order send_phone_number_to_provider Boolean Optional -Pass True if the user's phone number should be sent to provider +Pass True if the user's phone number should be sent to provider send_email_to_provider Boolean Optional -Pass True if the user's email address should be sent to provider +Pass True if the user's email address should be sent to provider is_flexible @@ -10106,11 +10136,11 @@ pre-formatted fixed-width code block written in the Python programming languagereply_markup InlineKeyboardMarkup Optional -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.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.createInvoiceLink
+createInvoiceLink
Use this method to create a link for an invoice. Returns the created invoice link as String on success.
@@ -10204,37 +10234,37 @@ pre-formatted fixed-width code block written in the Python programming language
-need_name Boolean Optional -Pass True if you require the user's full name to complete the order +Pass True if you require the user's full name to complete the order need_phone_number Boolean Optional -Pass True if you require the user's phone number to complete the order +Pass True if you require the user's phone number to complete the order need_email Boolean Optional -Pass True if you require the user's email address to complete the order +Pass True if you require the user's email address to complete the order need_shipping_address Boolean Optional -Pass True if you require the user's shipping address to complete the order +Pass True if you require the user's shipping address to complete the order send_phone_number_to_provider Boolean Optional -Pass True if the user's phone number should be sent to the provider +Pass True if the user's phone number should be sent to the provider send_email_to_provider Boolean Optional -Pass True if the user's email address should be sent to the provider +Pass True if the user's email address should be sent to the provider is_flexible @@ -10244,7 +10274,7 @@ pre-formatted fixed-width code block written in the Python programming languageanswerShippingQuery
+answerShippingQuery
If you sent an invoice requesting a shipping address and the parameter is_flexible was specified, the Bot API will send an Update with a shipping_query field to the bot. Use this method to reply to shipping queries. On success, True is returned.
@@ -10278,11 +10308,11 @@ pre-formatted fixed-width code block written in the Python programming language
-error_message String Optional -Required if ok is False. Error message in human readable form that explains why it is impossible to complete the order (e.g. "Sorry, delivery to your desired address is unavailable'). Telegram will display this message to the user. +Required if ok is False. Error message in human readable form that explains why it is impossible to complete the order (e.g. "Sorry, delivery to your desired address is unavailable'). Telegram will display this message to the user. answerPreCheckoutQuery
+answerPreCheckoutQuery
Once the user has confirmed their payment and shipping details, the Bot API sends the final confirmation in the form of an Update with the field pre_checkout_query. Use this method to respond to such pre-checkout queries. On success, True is returned. Note: The Bot API must receive an answer within 10 seconds after the pre-checkout query was sent.
@@ -10310,11 +10340,11 @@ pre-formatted fixed-width code block written in the Python programming language
-error_message String Optional -Required if ok is False. Error message in human readable form that explains the reason for failure to proceed with the checkout (e.g. "Sorry, somebody just bought the last of our amazing black T-shirts while you were busy filling out your payment details. Please choose a different color or garment!"). Telegram will display this message to the user. +Required if ok is False. Error message in human readable form that explains the reason for failure to proceed with the checkout (e.g. "Sorry, somebody just bought the last of our amazing black T-shirts while you were busy filling out your payment details. Please choose a different color or garment!"). Telegram will display this message to the user. LabeledPrice
+LabeledPrice
This object represents a portion of the price for goods or services.
@@ -10337,7 +10367,7 @@ pre-formatted fixed-width code block written in the Python programming language
-Invoice
+Invoice
This object contains basic information about an invoice.
@@ -10375,7 +10405,7 @@ pre-formatted fixed-width code block written in the Python programming language
-ShippingAddress
+ShippingAddress
This object represents a shipping address.
@@ -10418,7 +10448,7 @@ pre-formatted fixed-width code block written in the Python programming language
-OrderInfo
+OrderInfo
This object represents information about an order.
@@ -10437,7 +10467,7 @@ pre-formatted fixed-width code block written in the Python programming language
-phone_number String -Optional. User's phone number +Optional. User's phone number ShippingOption
+ShippingOption
This object represents one shipping option.
@@ -10479,7 +10509,7 @@ pre-formatted fixed-width code block written in the Python programming language
-SuccessfulPayment
+SuccessfulPayment
This object contains basic information about a successful payment.
@@ -10527,7 +10557,7 @@ pre-formatted fixed-width code block written in the Python programming language
-ShippingQuery
+ShippingQuery
This object contains information about an incoming shipping query.
@@ -10560,7 +10590,7 @@ pre-formatted fixed-width code block written in the Python programming language
-PreCheckoutQuery
+PreCheckoutQuery
This object contains information about an incoming pre-checkout query.
@@ -10608,9 +10638,9 @@ pre-formatted fixed-width code block written in the Python programming language
-Telegram Passport
+Telegram Passport
Telegram Passport is a unified authorization method for services that require personal identification. Users can upload their documents once, then instantly share their data with services that require real-world ID (finance, ICOs, etc.). Please see the manual for details.
-PassportData
+PassportData
Describes Telegram Passport data shared with the bot by the user.
@@ -10633,8 +10663,8 @@ pre-formatted fixed-width code block written in the Python programming language
-PassportFile
-This object represents a file uploaded to Telegram Passport. Currently all Telegram Passport files are in JPEG format when decrypted and don't exceed 10MB.
+PassportFile
+This object represents a file uploaded to Telegram Passport. Currently all Telegram Passport files are in JPEG format when decrypted and don't exceed 10MB.
-
@@ -10652,7 +10682,7 @@ pre-formatted fixed-width code block written in the Python programming language file_unique_id String -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. +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. file_size @@ -10666,7 +10696,7 @@ pre-formatted fixed-width code block written in the Python programming languageEncryptedPassportElement
+EncryptedPassportElement
Describes documents or other Telegram Passport elements shared with the bot by the user.
@@ -10680,47 +10710,47 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -Element type. One of “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport”, “address”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration”, “phone_number”, “email”. +Element type. One of "personal_details", "passport", "driver_license", "identity_card", "internal_passport", "address", "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration", "phone_number", "email". data String -Optional. Base64-encoded encrypted Telegram Passport element data provided by the user, available for “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport” and “address” types. Can be decrypted and verified using the accompanying EncryptedCredentials. +Optional. Base64-encoded encrypted Telegram Passport element data provided by the user, available for "personal_details", "passport", "driver_license", "identity_card", "internal_passport" and "address" types. Can be decrypted and verified using the accompanying EncryptedCredentials. phone_number String -Optional. User's verified phone number, available only for “phone_number” type +Optional. User's verified phone number, available only for "phone_number" type String -Optional. User's verified email address, available only for “email” type +Optional. User's verified email address, available only for "email" type files Array of PassportFile -Optional. Array of encrypted files with documents provided by the user, available for “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. +Optional. Array of encrypted files with documents provided by the user, available for "utility_bill", "bank_statement", "rental_agreement", "passport_registration" and "temporary_registration" types. Files can be decrypted and verified using the accompanying EncryptedCredentials. front_side PassportFile -Optional. Encrypted file with the front side of the document, provided by the user. Available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. +Optional. Encrypted file with the front side of the document, provided by the user. Available for "passport", "driver_license", "identity_card" and "internal_passport". The file can be decrypted and verified using the accompanying EncryptedCredentials. reverse_side PassportFile -Optional. Encrypted file with the reverse side of the document, provided by the user. Available for “driver_license” and “identity_card”. The file can be decrypted and verified using the accompanying EncryptedCredentials. +Optional. Encrypted file with the reverse side of the document, provided by the user. Available for "driver_license" and "identity_card". The file can be decrypted and verified using the accompanying EncryptedCredentials. selfie PassportFile -Optional. Encrypted file with the selfie of the user holding a document, provided by the user; available for “passport”, “driver_license”, “identity_card” and “internal_passport”. The file can be decrypted and verified using the accompanying EncryptedCredentials. +Optional. Encrypted file with the selfie of the user holding a document, provided by the user; available for "passport", "driver_license", "identity_card" and "internal_passport". The file can be decrypted and verified using the accompanying EncryptedCredentials. translation Array of PassportFile -Optional. Array of encrypted files with translated versions of documents provided by the user. Available if requested for “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration” and “temporary_registration” types. Files can be decrypted and verified using the accompanying EncryptedCredentials. +Optional. Array of encrypted files with translated versions of documents provided by the user. Available if requested for "passport", "driver_license", "identity_card", "internal_passport", "utility_bill", "bank_statement", "rental_agreement", "passport_registration" and "temporary_registration" types. Files can be decrypted and verified using the accompanying EncryptedCredentials. hash @@ -10729,7 +10759,7 @@ pre-formatted fixed-width code block written in the Python programming languageEncryptedCredentials
+EncryptedCredentials
Describes data required for decrypting and authenticating EncryptedPassportElement. See the Telegram Passport Documentation for a complete description of the data decryption and authentication processes.
@@ -10743,7 +10773,7 @@ pre-formatted fixed-width code block written in the Python programming language
-data String -Base64-encoded encrypted JSON-serialized data with unique user's payload, data hashes and secrets required for EncryptedPassportElement decryption and authentication +Base64-encoded encrypted JSON-serialized data with unique user's payload, data hashes and secrets required for EncryptedPassportElement decryption and authentication hash @@ -10753,13 +10783,13 @@ pre-formatted fixed-width code block written in the Python programming languagesecret String -Base64-encoded secret, encrypted with the bot's public RSA key, required for data decryption +Base64-encoded secret, encrypted with the bot's public RSA key, required for data decryption setPassportDataErrors
+setPassportDataErrors
Informs a user that some of the Telegram Passport elements they provided contains errors. The user will not be able to re-submit their Passport to you until the errors are fixed (the contents of the field for which you returned the error must change). Returns True on success.
-Use this if the data submitted by the user doesn't satisfy the standards your service requires for any reason. For example, if a birthday date seems invalid, a submitted document is blurry, a scan shows evidence of tampering, etc. Supply some details in the error message to make sure the user knows how to correct the issues.
+Use this if the data submitted by the user doesn't satisfy the standards your service requires for any reason. For example, if a birthday date seems invalid, a submitted document is blurry, a scan shows evidence of tampering, etc. Supply some details in the error message to make sure the user knows how to correct the issues.
-
@@ -10784,7 +10814,7 @@ pre-formatted fixed-width code block written in the Python programming language PassportElementError
+PassportElementError
This object represents an error in the Telegram Passport element which was submitted that should be resolved by the user. It should be one of:
-
- PassportElementErrorDataField
@@ -10797,8 +10827,8 @@ pre-formatted fixed-width code block written in the Python programming language- PassportElementErrorTranslationFiles
- PassportElementErrorUnspecified
PassportElementErrorDataField
-Represents an issue in one of the data fields that was provided by the user. The error is considered resolved when the field's value changes.
+PassportElementErrorDataField
+Represents an issue in one of the data fields that was provided by the user. The error is considered resolved when the field's value changes.
-
@@ -10816,7 +10846,7 @@ pre-formatted fixed-width code block written in the Python programming language type String -The section of the user's Telegram Passport which has the error, one of “personal_details”, “passport”, “driver_license”, “identity_card”, “internal_passport”, “address” +The section of the user's Telegram Passport which has the error, one of "personal_details", "passport", "driver_license", "identity_card", "internal_passport", "address" field_name @@ -10835,7 +10865,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorFrontSide
+PassportElementErrorFrontSide
Represents an issue with the front side of a document. The error is considered resolved when the file with the front side of the document changes.
@@ -10854,7 +10884,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -The section of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport” +The section of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport" file_hash @@ -10868,7 +10898,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorReverseSide
+PassportElementErrorReverseSide
Represents an issue with the reverse side of a document. The error is considered resolved when the file with reverse side of the document changes.
@@ -10887,7 +10917,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -The section of the user's Telegram Passport which has the issue, one of “driver_license”, “identity_card” +The section of the user's Telegram Passport which has the issue, one of "driver_license", "identity_card" file_hash @@ -10901,7 +10931,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorSelfie
+PassportElementErrorSelfie
Represents an issue with the selfie with a document. The error is considered resolved when the file with the selfie changes.
@@ -10920,7 +10950,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -The section of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport” +The section of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport" file_hash @@ -10934,7 +10964,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorFile
+PassportElementErrorFile
Represents an issue with a document scan. The error is considered resolved when the file with the document scan changes.
@@ -10953,7 +10983,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -The section of the user's Telegram Passport which has the issue, one of “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” +The section of the user's Telegram Passport which has the issue, one of "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" file_hash @@ -10967,7 +10997,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorFiles
+PassportElementErrorFiles
Represents an issue with a list of scans. The error is considered resolved when the list of files containing the scans changes.
@@ -10986,7 +11016,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -The section of the user's Telegram Passport which has the issue, one of “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” +The section of the user's Telegram Passport which has the issue, one of "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" file_hashes @@ -11000,7 +11030,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorTranslationFile
+PassportElementErrorTranslationFile
Represents an issue with one of the files that constitute the translation of a document. The error is considered resolved when the file changes.
@@ -11019,7 +11049,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -Type of element of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” +Type of element of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport", "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" file_hash @@ -11033,7 +11063,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorTranslationFiles
+PassportElementErrorTranslationFiles
Represents an issue with the translated version of a document. The error is considered resolved when a file with the document translation change.
@@ -11052,7 +11082,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -Type of element of the user's Telegram Passport which has the issue, one of “passport”, “driver_license”, “identity_card”, “internal_passport”, “utility_bill”, “bank_statement”, “rental_agreement”, “passport_registration”, “temporary_registration” +Type of element of the user's Telegram Passport which has the issue, one of "passport", "driver_license", "identity_card", "internal_passport", "utility_bill", "bank_statement", "rental_agreement", "passport_registration", "temporary_registration" file_hashes @@ -11066,7 +11096,7 @@ pre-formatted fixed-width code block written in the Python programming languagePassportElementErrorUnspecified
+PassportElementErrorUnspecified
Represents an issue in an unspecified place. The error is considered resolved when new data is added.
@@ -11085,7 +11115,7 @@ pre-formatted fixed-width code block written in the Python programming language
-type String -Type of element of the user's Telegram Passport which has the issue +Type of element of the user's Telegram Passport which has the issue element_hash @@ -11099,20 +11129,20 @@ pre-formatted fixed-width code block written in the Python programming languageGames
+Games
Your bot can offer users HTML5 games to play solo or to compete against each other in groups and one-on-one chats. Create games via @BotFather using the /newgame command. Please note that this kind of power requires responsibility: you will need to accept the terms for each game that your bots will be offering.
-
- Games are a new type of content on Telegram, represented by the Game and InlineQueryResultGame objects.
-- Once you've created a game via BotFather, you can send games to chats as regular messages using the sendGame method, or use inline mode with InlineQueryResultGame.
-- If you send the game message without any buttons, it will automatically have a 'Play GameName' button. When this button is pressed, your bot gets a CallbackQuery with the game_short_name of the requested game. You provide the correct URL for this particular user and the app opens the game in the in-app browser.
-- You can manually add multiple buttons to your game message. Please note that the first button in the first row must always launch the game, using the field callback_game in InlineKeyboardButton. You can add extra buttons according to taste: e.g., for a description of the rules, or to open the game's official community.
+- Once you've created a game via BotFather, you can send games to chats as regular messages using the sendGame method, or use inline mode with InlineQueryResultGame.
+- If you send the game message without any buttons, it will automatically have a 'Play GameName' button. When this button is pressed, your bot gets a CallbackQuery with the game_short_name of the requested game. You provide the correct URL for this particular user and the app opens the game in the in-app browser.
+- You can manually add multiple buttons to your game message. Please note that the first button in the first row must always launch the game, using the field callback_game in InlineKeyboardButton. You can add extra buttons according to taste: e.g., for a description of the rules, or to open the game's official community.
- To make your game more attractive, you can upload a GIF animation that demostrates the game to the users via BotFather (see Lumberjack for example).
- A game message will also display high scores for the current chat. Use setGameScore to post high scores to the chat with the game, add the edit_message parameter to automatically update the message with the current scoreboard.
- Use getGameHighScores to get data for in-game high score tables.
- You can also add an extra sharing button for users to share their best score to different chats.
- For examples of what can be done using this new stuff, check the @gamebot and @gamee bots.
sendGame
+sendGame
Use this method to send a game. On success, the sent Message is returned.
@@ -11170,11 +11200,11 @@ pre-formatted fixed-width code block written in the Python programming language
-reply_markup InlineKeyboardMarkup Optional -A JSON-serialized object for an inline keyboard. If empty, one 'Play game_title' button will be shown. If not empty, the first button must launch the game. +A JSON-serialized object for an inline keyboard. If empty, one 'Play game_title' button will be shown. If not empty, the first button must launch the game. Game
+Game
This object represents a game. Use BotFather to create and edit games, their short names will act as unique identifiers.
@@ -11217,10 +11247,10 @@ pre-formatted fixed-width code block written in the Python programming language
-CallbackGame
+CallbackGame
A placeholder, currently holds no information. Use BotFather to set up your game.
-setGameScore
-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.
+setGameScore
+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.
-
@@ -11275,7 +11305,7 @@ pre-formatted fixed-width code block written in the Python programming language getGameHighScores
+getGameHighScores
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.
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.
@@ -11316,7 +11346,7 @@ pre-formatted fixed-width code block written in the Python programming language -GameHighScore
+GameHighScore
This object represents one row of the high scores table for a game.
@@ -11345,8 +11375,8 @@ pre-formatted fixed-width code block written in the Python programming language
-And that's about all we've got for now.
-
If you've got any questions, please check out our Bot FAQ »
And that's about all we've got for now. +If you've got any questions, please check out our Bot FAQ »
diff --git a/data/web/corefork.telegram.org/constructor/appWebViewResultUrl.html b/data/web/corefork.telegram.org/constructor/appWebViewResultUrl.html index fc97a84b6d..c9112b8ebb 100644 --- a/data/web/corefork.telegram.org/constructor/appWebViewResultUrl.html +++ b/data/web/corefork.telegram.org/constructor/appWebViewResultUrl.html @@ -76,7 +76,7 @@Bots can offer users interactive HTML5 web apps to completely replace any website.
diff --git a/data/web/corefork.telegram.org/constructor/attachMenuBot.html b/data/web/corefork.telegram.org/constructor/attachMenuBot.html index b77bd0d207..95b7463ede 100644 --- a/data/web/corefork.telegram.org/constructor/attachMenuBot.html +++ b/data/web/corefork.telegram.org/constructor/attachMenuBot.html @@ -87,6 +87,21 @@Enable or disable web bot attachment menu »
-Bots can offer users interactive HTML5 web apps to completely replace any website.
Bots can install attachment menu entries, offering conveniently accessible, versatile web apps.
diff --git a/data/web/corefork.telegram.org/constructor/authorization.html b/data/web/corefork.telegram.org/constructor/authorization.html index 6880698548..a379d620d8 100644 --- a/data/web/corefork.telegram.org/constructor/authorization.html +++ b/data/web/corefork.telegram.org/constructor/authorization.html @@ -97,6 +97,11 @@Telegram clients must handle special tg:// and t.me deep links encountered in messages, link entities and in other apps by registering OS handlers.
Obtain information about a named bot web app
-Bots can offer users interactive HTML5 web apps to completely replace any website.
Bots can offer users interactive HTML5 web apps to completely replace any website.
Bots can choose the behavior of the menu button shown next to the text input field.
diff --git a/data/web/corefork.telegram.org/constructor/channelFull.html b/data/web/corefork.telegram.org/constructor/channelFull.html index 822566af0b..a372b0b2f3 100644 --- a/data/web/corefork.telegram.org/constructor/channelFull.html +++ b/data/web/corefork.telegram.org/constructor/channelFull.html @@ -137,6 +137,11 @@Bots can offer users interactive HTML5 web apps to completely replace any website.
Contains information about a named bot web app.
diff --git a/data/web/corefork.telegram.org/constructor/inputMediaStory.html b/data/web/corefork.telegram.org/constructor/inputMediaStory.html index 5804e70933..d7cf5dc935 100644 --- a/data/web/corefork.telegram.org/constructor/inputMediaStory.html +++ b/data/web/corefork.telegram.org/constructor/inputMediaStory.html @@ -2,12 +2,34 @@ -inputMediaStory#89fdd778 peer:InputPeer id:int = InputMedia;
+Name | +Type | +Description | +
---|---|---|
peer | +InputPeer | ++ |
id | +int | ++ |
inputPrivacyKeyAbout#3823cc40 = InputPrivacyKey;
+This constructor does not require any parameters.
+inputReplyToMessage#9c5386e4 flags:# reply_to_msg_id:int top_msg_id:flags.0?int = InputReplyTo;
+Name | +Type | +Description | +
---|---|---|
flags | +# | +Flags, see TL conditional fields | +
reply_to_msg_id | +int | ++ |
top_msg_id | +flags.0?int | ++ |
inputReplyToStory#15b0f283 user_id:InputUser story_id:int = InputReplyTo;
+Name | +Type | +Description | +
---|---|---|
user_id | +InputUser | ++ |
story_id | +int | ++ |
max_tip_amount
.Bots can offer users interactive HTML5 web apps to completely replace any website.
Open a bot web app, sending over user information after user confirmation.
diff --git a/data/web/corefork.telegram.org/constructor/mediaAreaGeoPoint.html b/data/web/corefork.telegram.org/constructor/mediaAreaGeoPoint.html index 5804e70933..6913ecd64f 100644 --- a/data/web/corefork.telegram.org/constructor/mediaAreaGeoPoint.html +++ b/data/web/corefork.telegram.org/constructor/mediaAreaGeoPoint.html @@ -2,12 +2,34 @@ -mediaAreaGeoPoint#df8b3b22 coordinates:MediaAreaCoordinates geo:GeoPoint = MediaArea;
+Name | +Type | +Description | +
---|---|---|
coordinates | +MediaAreaCoordinates | ++ |
geo | +GeoPoint | ++ |
mediaAreaSuggestedReaction#14455871 flags:# dark:flags.0?true flipped:flags.1?true coordinates:MediaAreaCoordinates reaction:Reaction = MediaArea;
+Name | +Type | +Description | +
---|---|---|
flags | +# | +Flags, see TL conditional fields | +
dark | +flags.0?true | ++ |
flipped | +flags.1?true | ++ |
coordinates | +MediaAreaCoordinates | ++ |
reaction | +Reaction | ++ |
mediaAreaVenue#be82db9c coordinates:MediaAreaCoordinates geo:GeoPoint title:string address:string provider:string venue_id:string venue_type:string = MediaArea;
+Name | +Type | +Description | +
---|---|---|
coordinates | +MediaAreaCoordinates | ++ |
geo | +GeoPoint | ++ |
title | +string | ++ |
address | +string | ++ |
provider | +string | ++ |
venue_id | +string | ++ |
venue_type | +string | ++ |
Button to open a bot web app using messages.requestSimpleWebView, without sending user information to the web app.
Can only be sent or received as part of a reply keyboard, use keyboardButtonWebView for inline keyboards.
-Bots can offer users interactive HTML5 web apps to completely replace any website.
messageMediaStory#68cb6283 flags:# via_mention:flags.1?true peer:Peer id:int story:flags.0?StoryItem = MessageMedia;
+Name | +Type | +Description | +
---|---|---|
flags | +# | +Flags, see TL conditional fields | +
via_mention | +flags.1?true | ++ |
peer | +Peer | ++ |
id | +int | ++ |
story | +flags.0?StoryItem | ++ |
messageReplyStoryHeader#9c98bfc1 user_id:long story_id:int = MessageReplyHeader;
+Name | +Type | +Description | +
---|---|---|
user_id | +long | ++ |
story_id | +int | ++ |
Bots can offer users interactive HTML5 web apps to completely replace any website.
peerStories#9a35e999 flags:# peer:Peer max_read_id:flags.0?int stories:Vector<StoryItem> = PeerStories;
+Name | +Type | +Description | +
---|---|---|
flags | +# | +Flags, see TL conditional fields | +
peer | +Peer | ++ |
max_read_id | +flags.0?int | ++ |
stories | +Vector<StoryItem> | ++ |
sponsoredWebPage#3db8ec63 flags:# url:string site_name:string photo:flags.0?Photo = SponsoredWebPage;
+Name | +Type | +Description | +
---|---|---|
flags | +# | +Flags, see TL conditional fields | +
url | +string | ++ |
site_name | +string | ++ |
photo | +flags.0?Photo | ++ |
stories.boostersList#f3dd3d1d flags:# count:int boosters:Vector<Booster> next_offset:flags.0?string users:Vector<User> = stories.BoostersList;
+Name | +Type | +Description | +
---|---|---|
flags | +# | +Flags, see TL conditional fields | +
count | +int | ++ |
boosters | +Vector<Booster> | ++ |
next_offset | +flags.0?string | ++ |
users | +Vector<User> | ++ |
stories.canApplyBoostOk#c3173587 = stories.CanApplyBoostResult;
+This constructor does not require any parameters.
+storyView#b0bdeac5 flags:# blocked:flags.0?true blocked_my_stories_from:flags.1?true user_id:long date:int reaction:flags.2?Reaction = StoryView;
+Name | +Type | +Description | +
---|---|---|
flags | +# | +Flags, see TL conditional fields | +
blocked | +flags.0?true | ++ |
blocked_my_stories_from | +flags.1?true | ++ |
user_id | +long | ++ |
date | +int | ++ |
reaction | +flags.2?Reaction | ++ |