<divid="dev_page_content"><h3><aclass="anchor"href="#accepting-the-terms-of-service"id="accepting-the-terms-of-service"name="accepting-the-terms-of-service"><iclass="anchor-icon"></i></a>Accepting the <ahref="https://telegram.org/tos">Terms of Service</a></h3>
<h3><aclass="anchor"href="#dealing-with-spam-and-tos-violations"id="dealing-with-spam-and-tos-violations"name="dealing-with-spam-and-tos-violations"><iclass="anchor-icon"></i></a>Dealing with spam and ToS violations</h3>
<h3><aclass="anchor"href="#login-via-qr-code"id="login-via-qr-code"name="login-via-qr-code"><iclass="anchor-icon"></i></a>Login via <ahref="/api/qr-login">QR code</a></h3>
<td>Generate a login token, for <ahref="/api/qr-login">login via QR code</a>. <br>The generated login token should be encoded using base64url, then shown as a <code>tg://login?token=base64encodedtoken</code><ahref="/api/links#qr-code-login-links">deep link »</a> in the QR code.<br><br>For more info, see <ahref="/api/qr-login">login via QR code</a>.</td>
<td>Accept QR code login token, logging in the app that generated it.<br><br>Returns info about the new session.<br><br>For more info, see <ahref="/api/qr-login">login via QR code</a>.</td>
<td>Login using a redirected login token, generated in case of DC mismatch during <ahref="/api/qr-login">QR code login</a>.<br><br>For more info, see <ahref="/api/qr-login">login via QR code</a>.</td>
<td>Invoke a request without subscribing the used connection for <ahref="/api/updates">updates</a> (this is enabled by default for <ahref="/api/files">file queries</a>).</td>
<td>Binds a temporary authorization key <code>temp_auth_key_id</code> to the permanent authorization key <code>perm_auth_key_id</code>. Each permanent key may only be bound to one temporary key at a time, binding a new temporary key overwrites the previous one.<br><br>For more information, see <ahref="/api/pfs">Perfect Forward Secrecy</a>.</td>
<td>Initiate a 2FA password reset: can only be used if the user is already logged-in, <ahref="/api/srp#password-reset">see here for more info »</a></td>
<td>Check if the <ahref="/api/srp">2FA recovery code</a> sent using <ahref="/method/auth.requestPasswordRecovery">auth.requestPasswordRecovery</a> is valid, before passing it to <ahref="/method/auth.recoverPassword">auth.recoverPassword</a>.</td>
<td>Reset the <ahref="/api/srp">2FA password</a> using the recovery code sent using <ahref="/method/auth.requestPasswordRecovery">auth.requestPasswordRecovery</a>.</td>
<td>Request recovery code of a <ahref="/api/srp">2FA password</a>, only for accounts with a <ahref="/api/srp#email-verification">recovery email configured</a>.</td>
<td>Resend the login code via another medium, the phone code type is determined by the return value of the previous auth.sendCode/auth.resendCode: see <ahref="/api/auth">login</a> for more info.</td>
<td>Terminates all user's authorized sessions except for the current one.<br><br>After calling this method it is necessary to reregister the current device using the method <ahref="/method/account.registerDevice">account.registerDevice</a></td>
<h3><aclass="anchor"href="#working-with-public-service-announcement-and-mtproxy-channels"id="working-with-public-service-announcement-and-mtproxy-channels"name="working-with-public-service-announcement-and-mtproxy-channels"><iclass="anchor-icon"></i></a>Working with Public Service Announcement and MTProxy channels</h3>
<h3><aclass="anchor"href="#working-with-tsf-internal-use-only"id="working-with-tsf-internal-use-only"name="working-with-tsf-internal-use-only"><iclass="anchor-icon"></i></a>Working with TSF (internal use only)</h3>
<h3><aclass="anchor"href="#working-with-telegram-premium"id="working-with-telegram-premium"name="working-with-telegram-premium"><iclass="anchor-icon"></i></a>Working with Telegram Premium</h3>
<td>Informs server about a purchase made through the Play Store: for official applications only.</td>
</tr>
</tbody>
</table>
<h3><aclass="anchor"href="#working-with-2fa-login"id="working-with-2fa-login"name="working-with-2fa-login"><iclass="anchor-icon"></i></a>Working with <ahref="/api/srp">2FA login</a></h3>
<h3><aclass="anchor"href="#working-with-seamless-telegram-login"id="working-with-seamless-telegram-login"name="working-with-seamless-telegram-login"><iclass="anchor-icon"></i></a>Working with <ahref="/api/url-authorization">Seamless Telegram Login</a></h3>
<h3><aclass="anchor"href="#working-with-voip-calls"id="working-with-voip-calls"name="working-with-voip-calls"><iclass="anchor-icon"></i></a>Working with <ahref="/api/end-to-end/voice-calls">VoIP calls</a></h3>
<td>Optional: notify the server that the user is currently busy in a call: this will automatically refuse all incoming phone calls until the current phone call is ended.</td>
<h3><aclass="anchor"href="#working-with-accent-colors-"id="working-with-accent-colors-"name="working-with-accent-colors-"><iclass="anchor-icon"></i></a>Working with <ahref="/api/colors">accent colors »</a></h3>
<td>Get a set of suggested <ahref="/api/custom-emoji">custom emoji stickers</a> that can be used in an <ahref="/api/colors">accent color pattern</a>.</td>
</tr>
</tbody>
</table>
<h3><aclass="anchor"href="#working-with-boosts-"id="working-with-boosts-"name="working-with-boosts-"><iclass="anchor-icon"></i></a>Working with <ahref="/api/boost">boosts »</a></h3>
<td>Returns the lists of boost that were applied to a channel by a specific user (admins only)</td>
</tr>
</tbody>
</table>
<h3><aclass="anchor"href="#working-with-channel-recommendations-"id="working-with-channel-recommendations-"name="working-with-channel-recommendations-"><iclass="anchor-icon"></i></a>Working with <ahref="/api/recommend">channel recommendations »</a></h3>
<td>Obtain a list of similarly themed public channels, selected based on similarities in their <strong>subscriber bases</strong>.</td>
</tr>
</tbody>
</table>
<h3><aclass="anchor"href="#working-with-channels-supergroups-geogroups"id="working-with-channels-supergroups-geogroups"name="working-with-channels-supergroups-geogroups"><iclass="anchor-icon"></i></a>Working with <ahref="/api/channel">channels/supergroups/geogroups</a></h3>
<td>Get <ahref="/api/channel">channels/supergroups/geogroups</a> we're admin in. Usually called when the user exceeds the <ahref="/constructor/config">limit</a> for owned public <ahref="/api/channel">channels/supergroups/geogroups</a>, and the user is given the choice to remove one of his channels/supergroups/geogroups.</td>
<td>Get full info about a <ahref="/api/channel#supergroups">supergroup</a>, <ahref="/api/channel#gigagroups">gigagroup</a> or <ahref="/api/channel#channels">channel</a></td>
<td>Get all groups that can be used as <ahref="/api/discussion">discussion groups</a>.<br><br>Returned <ahref="/api/channel#basic-groups">basic group chats</a> must be first upgraded to <ahref="/api/channel#supergroups">supergroups</a> before they can be set as a discussion group. <br>To set a returned supergroup as a discussion group, access to its old messages must be enabled using <ahref="/method/channels.togglePreHistoryHidden">channels.togglePreHistoryHidden</a>, first.</td>
<td>Invite users to a channel/supergroup<br><br>May also return 0-N updates of type <ahref="/constructor/updateGroupInvitePrivacyForbidden">updateGroupInvitePrivacyForbidden</a>: it indicates we couldn't add a user to a chat because of their privacy settings; if required, an <ahref="/api/invites">invite link</a> can be shared with the user, instead.</td>
<td>Hide or display the participants list in a <ahref="/api/channel">supergroup</a>.<br><br>The supergroup must have at least <code>hidden_members_group_size_min</code> participants in order to use this method, as specified by the <ahref="/api/config#client-configuration">client configuration parameters »</a>.</td>
<h3><aclass="anchor"href="#working-with-chat-invites-and-join-requests"id="working-with-chat-invites-and-join-requests"name="working-with-chat-invites-and-join-requests"><iclass="anchor-icon"></i></a>Working with <ahref="/api/invites">chat invites and join requests</a></h3>
<td>Set whether all users <ahref="/api/discussion#requiring-users-to-join-the-group">should join a discussion group in order to comment on a post »</a></td>
<h3><aclass="anchor"href="#working-with-chats-supergroups-channels"id="working-with-chats-supergroups-channels"name="working-with-chats-supergroups-channels"><iclass="anchor-icon"></i></a>Working with <ahref="/api/channel">chats/supergroups/channels</a></h3>
<td>Get which users read a specific message: only available for groups and supergroups with less than <ahref="/api/config#chat-read-mark-size-threshold"><code>chat_read_mark_size_threshold</code> members</a>, read receipts will be stored for <ahref="/api/config#chat-read-mark-expire-period"><code>chat_read_mark_expire_period</code> seconds after the message was sent</a>, see <ahref="/api/config#client-configuration">client configuration for more info »</a>.</td>
<td>Adds a user to a chat and sends a service message on it.<br><br>May also return 0-N updates of type <ahref="/constructor/updateGroupInvitePrivacyForbidden">updateGroupInvitePrivacyForbidden</a>: it indicates we couldn't add a user to a chat because of their privacy settings; if required, an <ahref="/api/invites">invite link</a> can be shared with the user, instead.</td>
<td>Creates a new chat.<br><br>May also return 0-N updates of type <ahref="/constructor/updateGroupInvitePrivacyForbidden">updateGroupInvitePrivacyForbidden</a>: it indicates we couldn't add a user to a chat because of their privacy settings; if required, an <ahref="/api/invites">invite link</a> can be shared with the user, instead.</td>
<td>Convert a <ahref="/api/channel">supergroup</a> to a <ahref="/api/channel">gigagroup</a>, when requested by <ahref="/api/config#channel-suggestions">channel suggestions</a>.</td>
<h3><aclass="anchor"href="#working-with-cloud-themes"id="working-with-cloud-themes"name="working-with-cloud-themes"><iclass="anchor-icon"></i></a>Working with <ahref="/api/themes">cloud themes</a></h3>
<h3><aclass="anchor"href="#working-with-custom-animated-emojis"id="working-with-custom-animated-emojis"name="working-with-custom-animated-emojis"><iclass="anchor-icon"></i></a>Working with <ahref="/api/custom-emoji">custom animated emojis</a></h3>
<td>Fetch <ahref="/api/custom-emoji">custom emoji stickers »</a>.<br><br>Returns a list of <ahref="/constructor/document">documents</a> with the animated custom emoji in TGS format, and a <ahref="/constructor/documentAttributeCustomEmoji">documentAttributeCustomEmoji</a> attribute with the original emoji and info about the emoji stickerset this custom emoji belongs to.</td>
<td>Represents a list of <ahref="/api/custom-emoji#emoji-categories">emoji categories</a>, to be used when selecting <ahref="/api/custom-emoji">custom emojis</a>.</td>
<td>Represents a list of <ahref="/api/custom-emoji#emoji-categories">emoji categories</a>, to be used when selecting custom emojis to set as <ahref="/api">custom emoji status</a>.</td>
<td>Represents a list of <ahref="/api/custom-emoji#emoji-categories">emoji categories</a>, to be used when selecting custom emojis to set as <ahref="/api/files#sticker-profile-pictures">profile picture</a>.</td>
<td>Get a set of suggested <ahref="/api/custom-emoji">custom emoji stickers</a> that can be <ahref="/api/files#sticker-profile-pictures">used as profile picture</a></td>
<td>Get a set of suggested <ahref="/api/custom-emoji">custom emoji stickers</a> that can be <ahref="/api/files#sticker-profile-pictures">used as group picture</a></td>
<h3><aclass="anchor"href="#working-with-deep-links"id="working-with-deep-links"name="working-with-deep-links"><iclass="anchor-icon"></i></a>Working with <ahref="/api/links">deep links</a></h3>
<td>Get recently used <code>t.me</code> links.<br><br>When installing official applications from "Download Telegram" buttons present in <ahref="https://t.me">t.me</a> pages, a referral parameter is passed to applications after installation. <br>If, after downloading the application, the user creates a new account (instead of logging into an existing one), the referral parameter should be imported using this method, which returns the <ahref="https://t.me">t.me</a> pages the user recently opened, before installing Telegram.</td>
<h3><aclass="anchor"href="#working-with-emoji-keywords"id="working-with-emoji-keywords"name="working-with-emoji-keywords"><iclass="anchor-icon"></i></a>Working with <ahref="/api/custom-emoji#emoji-keywords">emoji keywords</a></h3>
<td>Obtain a list of related languages that must be used when fetching <ahref="/api/custom-emoji#emoji-keywords">emoji keyword lists »</a>.<br><br>Usually the method will return the passed language codes (if localized) + <code>en</code> + some language codes for similar languages (if applicable).</td>
<td>Returns an HTTP URL which can be used to automatically log in into translation platform and suggest new <ahref="/api/custom-emoji#emoji-keywords">emoji keywords »</a>. The URL will be valid for 30 seconds after generation.</td>
<h3><aclass="anchor"href="#working-with-emoji-statuses"id="working-with-emoji-statuses"name="working-with-emoji-statuses"><iclass="anchor-icon"></i></a>Working with <ahref="/api/emoji-status">emoji statuses</a></h3>
<td>Returns fetch the full list of <ahref="/api/custom-emoji">custom emoji IDs »</a> that cannot be used in <ahref="/api/emoji-status">channel emoji statuses »</a>.</td>
<h3><aclass="anchor"href="#working-with-files"id="working-with-files"name="working-with-files"><iclass="anchor-icon"></i></a>Working with <ahref="/api/files">files</a></h3>
<td>Returns content of a web file, by proxying the request through telegram, see the <ahref="/api/files#downloading-webfiles">webfile docs for more info</a>.<br><br><strong>Note</strong>: the query must be sent to the DC specified in the <code>webfile_dc_id</code><ahref="/api/config#mtproto-configuration">MTProto configuration field</a>.</td>
<h3><aclass="anchor"href="#working-with-forums"id="working-with-forums"name="working-with-forums"><iclass="anchor-icon"></i></a>Working with <ahref="/api/forum">forums</a></h3>
<td>Users may also choose to display messages from all topics of a <ahref="/api/forum">forum</a> as if they were sent to a normal group, using a "View as messages" setting in the local client: this setting only affects the current account, and is synced to other logged in sessions using this method.<br><br>Invoking this method will update the value of the <code>view_forum_as_messages</code> flag of <ahref="/constructor/channelFull">channelFull</a> or <ahref="/constructor/dialog">dialog</a> and emit an <ahref="/constructor/updateChannelViewForumAsMessages">updateChannelViewForumAsMessages</a>.</td>
<h3><aclass="anchor"href="#working-with-fragmentcom-usernames"id="working-with-fragmentcom-usernames"name="working-with-fragmentcom-usernames"><iclass="anchor-icon"></i></a>Working with <ahref="/api/fragment">fragment.com usernames</a></h3>
<td>Activate or deactivate a purchased <ahref="https://fragment.com">fragment.com</a> username associated to a <ahref="/api/channel">supergroup or channel</a> we own.</td>
<h3><aclass="anchor"href="#working-with-gift-codes"id="working-with-gift-codes"name="working-with-gift-codes"><iclass="anchor-icon"></i></a>Working with <ahref="/api/links#premium-giftcode-links">gift codes</a></h3>
<td>Apply a <ahref="/api/giveaways">Telegram Premium giftcode »</a></td>
</tr>
</tbody>
</table>
<h3><aclass="anchor"href="#working-with-giveaways-amp-gifts"id="working-with-giveaways-amp-gifts"name="working-with-giveaways-amp-gifts"><iclass="anchor-icon"></i></a>Working with <ahref="/api/giveaways">giveaways & gifts</a></h3>
<h3><aclass="anchor"href="#working-with-instant-view-pages"id="working-with-instant-view-pages"name="working-with-instant-view-pages"><iclass="anchor-icon"></i></a>Working with <ahref="https://instantview.telegram.org">instant view pages</a></h3>
<h3><aclass="anchor"href="#working-with-message-reactions"id="working-with-message-reactions"name="working-with-message-reactions"><iclass="anchor-icon"></i></a>Working with <ahref="/api/reactions">message reactions</a></h3>
<td>Change default emoji reaction to use in the quick reaction menu: the value is synced across devices and can be fetched using <ahref="/method/help.getConfig">help.getConfig, <code>reactions_default</code> field</a>.</td>
<td>React to message.<br><br>Starting from layer 159, the reaction will be sent from the peer specified using <ahref="/method/messages.saveDefaultSendAs">messages.saveDefaultSendAs</a>.</td>
<h3><aclass="anchor"href="#working-with-message-translation"id="working-with-message-translation"name="working-with-message-translation"><iclass="anchor-icon"></i></a>Working with <ahref="/api/translation">message translation</a></h3>
<td>Translate a given text.<br><br><ahref="/api/entities">Styled text entities</a> will only be preserved for <ahref="/api/premium">Telegram Premium</a> users.</td>
<td>Open a <ahref="/bots/webapps">bot mini app</a>, sending over user information after user confirmation.<br><br>After calling this method, until the user closes the webview, <ahref="/method/messages.prolongWebView">messages.prolongWebView</a> must be called every 60 seconds.</td>
<td>Indicate to the server (from the user side) that the user is still using a web app.<br><br>If the method returns a <code>QUERY_ID_INVALID</code> error, the webview must be closed.</td>
<td>Terminate webview interaction started with <ahref="/method/messages.requestWebView">messages.requestWebView</a>, sending the specified message to the chat on behalf of the user.</td>
<td>Open a <ahref="/bots/webapps">bot mini app</a> from a <ahref="/api/links#direct-mini-app-links">direct Mini App deep link</a>, sending over user information after user confirmation.<br><br>After calling this method, until the user closes the webview, <ahref="/method/messages.prolongWebView">messages.prolongWebView</a> must be called every 60 seconds.</td>
<td>Send a custom request from a <ahref="/api/bots/webapps">mini bot app</a>, triggered by a <ahref="/api/web-events#web-app-invoke-custom-method">web_app_invoke_custom_method event »</a>.<br><br>The response should be sent using a <ahref="/api/bots/webapps#custom-method-invoked">custom_method_invoked</a> event, <ahref="/api/web-events#web-app-invoke-custom-method">see here »</a> for more info on the flow.</td>
</tr>
</tbody>
</table>
<h3><aclass="anchor"href="#working-with-saved-message-dialogs-"id="working-with-saved-message-dialogs-"name="working-with-saved-message-dialogs-"><iclass="anchor-icon"></i></a>Working with <ahref="/api/saved-messages">saved message dialogs »</a></h3>
<h3><aclass="anchor"href="#working-with-secret-chats"id="working-with-secret-chats"name="working-with-secret-chats"><iclass="anchor-icon"></i></a>Working with <ahref="/api/end-to-end">secret chats</a></h3>
<td>Confirms receipt of messages in a secret chat by client, cancels push notifications. <br>The method returns a list of <strong>random_id</strong>s of messages for which push notifications were cancelled.</td>
<h3><aclass="anchor"href="#working-with-statistics"id="working-with-statistics"name="working-with-statistics"><iclass="anchor-icon"></i></a>Working with <ahref="/api/stats">statistics</a></h3>
<td>Obtains a list of messages, indicating to which other public channels was a channel message forwarded. <br>Will return a list of <ahref="/constructor/message">messages</a> with <code>peer_id</code> equal to the public channel to which this message was forwarded.</td>
<h3><aclass="anchor"href="#working-with-stickers-"id="working-with-stickers-"name="working-with-stickers-"><iclass="anchor-icon"></i></a>Working with <ahref="/api/stickers">stickers »</a></h3>
<h3><aclass="anchor"href="#working-with-stories"id="working-with-stories"name="working-with-stories"><iclass="anchor-icon"></i></a>Working with <ahref="/api/stories">stories</a></h3>
<td>Fetch the List of active (or active and hidden) stories, see <ahref="/api/stories#watching-stories">here »</a> for more info on watching stories.</td>
<td>Mark all stories up to a certain ID as read, for a given peer; will emit an <ahref="/constructor/updateReadStories">updateReadStories</a> update to all logged-in sessions.</td>
<td>Get the <ahref="/api/reactions">reaction</a> and interaction list of a <ahref="/api/stories">story</a> posted to a channel, along with the sender of each reaction.<br><br>Can only be used by channel admins.</td>
<td>Activates <ahref="/api/stories#stealth-mode">stories stealth mode</a>, see <ahref="/api/stories#stealth-mode">here »</a> for more info.<br><br>Will return an <ahref="/constructor/updateStoriesStealthMode">updateStoriesStealthMode</a>.</td>
<td>Obtain the latest read story ID for all peers when first logging in, returned as a list of <ahref="/constructor/updateReadStories">updateReadStories</a> updates, see <ahref="/api/stories#watching-stories">here »</a> for more info.</td>
<td>Hide the active stories of a user, preventing them from being displayed on the action bar on the homescreen, see <ahref="/api/stories#hiding-stories-of-other-users">here »</a> for more info.</td>
<h3><aclass="anchor"href="#working-with-telegram-passport"id="working-with-telegram-passport"name="working-with-telegram-passport"><iclass="anchor-icon"></i></a>Working with <ahref="/passport">telegram passport</a></h3>
<td>Delete stored <ahref="/passport">Telegram Passport</a> documents, <ahref="/passport/encryption#encryption">for more info see the passport docs »</a></td>
<td>Get all saved <ahref="/passport">Telegram Passport</a> documents, <ahref="/passport/encryption#encryption">for more info see the passport docs »</a></td>
<td>Get saved <ahref="/passport">Telegram Passport</a> document, <ahref="/passport/encryption#encryption">for more info see the passport docs »</a></td>
<td>Securely save <ahref="/passport">Telegram Passport</a> document, <ahref="/passport/encryption#encryption">for more info see the passport docs »</a></td>
<td>Notify the user that the sent <ahref="/passport">passport</a> data contains some errors The user will not be able to re-submit their Passport data to you until the errors are fixed (the contents of the field for which you returned the error must change).<br><br>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.</td>
<h3><aclass="anchor"href="#working-with-temporary-profile-links"id="working-with-temporary-profile-links"name="working-with-temporary-profile-links"><iclass="anchor-icon"></i></a>Working with <ahref="/api/links#temporary-profile-links">temporary profile links</a></h3>
<h3><aclass="anchor"href="#working-with-updates"id="working-with-updates"name="working-with-updates"><iclass="anchor-icon"></i></a>Working with <ahref="/api/updates">updates</a></h3>
<h3><aclass="anchor"href="#working-with-voice-message-transcription"id="working-with-voice-message-transcription"name="working-with-voice-message-transcription"><iclass="anchor-icon"></i></a>Working with <ahref="/api/transcribe">voice message transcription</a></h3>
<h3><aclass="anchor"href="#working-with-wallpapers-"id="working-with-wallpapers-"name="working-with-wallpapers-"><iclass="anchor-icon"></i></a>Working with <ahref="/api/wallpapers">wallpapers »</a></h3>
<h3><aclass="anchor"href="#working-with-bot-admin-right-suggestions"id="working-with-bot-admin-right-suggestions"name="working-with-bot-admin-right-suggestions"><iclass="anchor-icon"></i></a>Working with bot admin right suggestions</h3>
<td>Set the default <ahref="/api/rights#suggested-bot-rights">suggested admin rights</a> for bots being added as admins to channels, see <ahref="/api/rights#suggested-bot-rights">here for more info on how to handle them »</a>.</td>
<td>Set the default <ahref="/api/rights#suggested-bot-rights">suggested admin rights</a> for bots being added as admins to groups, see <ahref="/api/rights#suggested-bot-rights">here for more info on how to handle them »</a>.</td>
<h3><aclass="anchor"href="#working-with-bot-inline-queries-and-callback-buttons"id="working-with-bot-inline-queries-and-callback-buttons"name="working-with-bot-inline-queries-and-callback-buttons"><iclass="anchor-icon"></i></a>Working with bot inline queries and callback buttons</h3>
<h3><aclass="anchor"href="#working-with-bots-internal-bot-api-use"id="working-with-bots-internal-bot-api-use"name="working-with-bots-internal-bot-api-use"><iclass="anchor-icon"></i></a>Working with bots (internal bot API use)</h3>
<h3><aclass="anchor"href="#working-with-contacts-and-top-peers"id="working-with-contacts-and-top-peers"name="working-with-contacts-and-top-peers"><iclass="anchor-icon"></i></a>Working with contacts and <ahref="/api/top-rating">top peers</a></h3>
<td>Add an existing telegram user as contact.<br><br>Use <ahref="/method/contacts.importContacts">contacts.importContacts</a> to add contacts by phone number, without knowing their Telegram ID.</td>
<td>Get the telegram IDs of all contacts. <br>Returns an array of Telegram user IDs for all contacts (0 if a contact does not have an associated Telegram account or have hidden their account using privacy settings).</td>
<td>Imports contacts: saves a full list on the server, adds already registered contacts to the contact list, returns added contacts and their info.<br><br>Use <ahref="/method/contacts.addContact">contacts.addContact</a> to add Telegram contacts without actually using their phone number.</td>
<h3><aclass="anchor"href="#working-with-credit-cards"id="working-with-credit-cards"name="working-with-credit-cards"><iclass="anchor-icon"></i></a>Working with credit cards</h3>
<h3><aclass="anchor"href="#working-with-dialogs"id="working-with-dialogs"name="working-with-dialogs"><iclass="anchor-icon"></i></a>Working with dialogs</h3>
<td>Should be called after the user hides the <ahref="/api/action-bar">report spam/add as contact bar</a> of a new chat, effectively prevents the user from executing the actions specified in the <ahref="/api/action-bar">action bar »</a>.</td>
<td>Sends a current user typing event (see <ahref="/type/SendMessageAction">SendMessageAction</a> for all event types) to a conversation partner or group.</td>
<h3><aclass="anchor"href="#working-with-drafts"id="working-with-drafts"name="working-with-drafts"><iclass="anchor-icon"></i></a>Working with drafts</h3>
<td>Return all message <ahref="/api/drafts">drafts</a>. <br>Returns all the latest <ahref="/constructor/updateDraftMessage">updateDraftMessage</a> updates related to all chats with drafts.</td>
<h3><aclass="anchor"href="#working-with-folders"id="working-with-folders"name="working-with-folders"><iclass="anchor-icon"></i></a>Working with folders</h3>
<td>Fetch new chats associated with an imported <ahref="/api/links#chat-folder-links">chat folder deep link »</a>. Must be invoked at most every <code>chatlist_update_period</code> seconds (as per the related <ahref="/api/config#chatlist-update-period">client configuration parameter »</a>).</td>
<td>Returns identifiers of pinned or always included chats from a chat folder imported using a <ahref="/api/links#chat-folder-links">chat folder deep link »</a>, which are suggested to be left when the chat folder is deleted.</td>
<h3><aclass="anchor"href="#working-with-group-calls-amp-live-streaming"id="working-with-group-calls-amp-live-streaming"name="working-with-group-calls-amp-live-streaming"><iclass="anchor-icon"></i></a>Working with group calls & live streaming</h3>
<td>Edit information about a given group call participant<br><br>Note: <ahref="/mtproto/TL-combinators#conditional-fields">flags</a>.N?<ahref="/type/Bool">Bool</a> parameters can have three possible values:<br><br>- If the <ahref="/mtproto/TL-combinators#conditional-fields">TL flag</a> is not set, the previous value will not be changed.<br>- If the <ahref="/mtproto/TL-combinators#conditional-fields">TL flag</a> is set and contains a <ahref="/constructor/boolTrue">boolTrue</a>, the previous value will be overwritten to <code>true</code>.<br>- If the <ahref="/mtproto/TL-combinators#conditional-fields">TL flag</a> is set and contains a <ahref="/constructor/boolFalse">boolFalse</a>, the previous value will be overwritten to <code>false</code>.</td>
<td>Start or stop recording a group call: the recorded audio and video streams will be automatically sent to <code>Saved messages</code> (the chat with ourselves).</td>
<td>Check whether the group call Server Forwarding Unit is currently receiving the streams with the specified WebRTC source IDs. <br>Returns an intersection of the source IDs specified in <code>sources</code>, and the source IDs currently being forwarded by the SFU.</td>
<td>Get info about RTMP streams in a group call or livestream. <br>This method should be invoked to the same group/channel-related DC used for <ahref="/api/files#downloading-files">downloading livestream chunks</a>. <br>As usual, the media DC is preferred, if available.</td>
<td>Get RTMP URL and stream key for RTMP livestreams. Can be used even before creating the actual RTMP livestream with <ahref="/method/phone.createGroupCall">phone.createGroupCall</a> (the <code>rtmp_stream</code> flag must be set).</td>
<h3><aclass="anchor"href="#working-with-imported-chats"id="working-with-imported-chats"name="working-with-imported-chats"><iclass="anchor-icon"></i></a>Working with imported chats</h3>
<td>Complete the <ahref="/api/import">history import process</a>, importing all messages into the chat. <br>To be called only after initializing the import with <ahref="/method/messages.initHistoryImport">messages.initHistoryImport</a> and uploading all files using <ahref="/method/messages.uploadImportedMedia">messages.uploadImportedMedia</a>.</td>
<td>Check whether chat history exported from another chat app can be <ahref="/api/import">imported into a specific Telegram chat, click here for more info »</a>.<br><br>If the check succeeds, and no RPC errors are returned, a <ahref="/type/messages.CheckedHistoryImportPeer">messages.CheckedHistoryImportPeer</a> constructor will be returned, with a confirmation text to be shown to the user, before actually initializing the import.</td>
<td>Obtains information about a chat export file, generated by a foreign chat app, <ahref="/api/import">click here for more info about imported chats »</a>.</td>
<td>Import chat history from a foreign chat app into a specific Telegram chat, <ahref="/api/import">click here for more info about imported chats »</a>.</td>
<h3><aclass="anchor"href="#working-with-localization-packs"id="working-with-localization-packs"name="working-with-localization-packs"><iclass="anchor-icon"></i></a>Working with localization packs</h3>
<h3><aclass="anchor"href="#working-with-media-autodownload-settings"id="working-with-media-autodownload-settings"name="working-with-media-autodownload-settings"><iclass="anchor-icon"></i></a>Working with media autodownload settings</h3>
<h3><aclass="anchor"href="#working-with-media-autosave-settings"id="working-with-media-autosave-settings"name="working-with-media-autosave-settings"><iclass="anchor-icon"></i></a>Working with media autosave settings</h3>
<h3><aclass="anchor"href="#working-with-message-threads"id="working-with-message-threads"name="working-with-message-threads"><iclass="anchor-icon"></i></a>Working with message <ahref="/api/threads">threads</a></h3>
<td>Get <ahref="/api/threads">discussion message</a> from the <ahref="/api/discussion">associated discussion group</a> of a channel to show it on top of the comment section, without actually joining the group</td>
<h3><aclass="anchor"href="#working-with-messages"id="working-with-messages"name="working-with-messages"><iclass="anchor-icon"></i></a>Working with messages</h3>
<td>Returns sparse positions of messages of the specified type in the chat to be used for shared media scroll implementation.<br><br>Returns the results in reverse chronological order (i.e., in order of decreasing message_id).</td>
<td>Returns information about the next messages of the specified type in the chat split by days.<br><br>Returns the results in reverse chronological order. <br>Can return partial results for the last returned day.</td>
<h3><aclass="anchor"href="#working-with-notification-settings"id="working-with-notification-settings"name="working-with-notification-settings"><iclass="anchor-icon"></i></a>Working with notification settings</h3>
<h3><aclass="anchor"href="#working-with-notification-sounds"id="working-with-notification-sounds"name="working-with-notification-sounds"><iclass="anchor-icon"></i></a>Working with notification sounds</h3>
<td>Save or remove saved notification sound.<br><br>If the notification sound is already in MP3 format, <ahref="/constructor/account.savedRingtone">account.savedRingtone</a> will be returned. <br>Otherwise, it will be automatically converted and a <ahref="/constructor/account.savedRingtoneConverted">account.savedRingtoneConverted</a> will be returned, containing a new <ahref="/constructor/document">document</a> object that should be used to refer to the ringtone from now on (ie when deleting it using the <code>unsave</code> parameter, or when downloading it).</td>
<td>Upload notification sound, use <ahref="/method/account.saveRingtone">account.saveRingtone</a> to convert it and add it to the list of saved notification sounds.</td>
</tr>
</tbody>
</table>
<h3><aclass="anchor"href="#working-with-other-users"id="working-with-other-users"name="working-with-other-users"><iclass="anchor-icon"></i></a>Working with other users</h3>
<h3><aclass="anchor"href="#working-with-payments"id="working-with-payments"name="working-with-payments"><iclass="anchor-icon"></i></a>Working with payments</h3>
<td>If you sent an invoice requesting a shipping address and the parameter is_flexible was specified, the bot will receive an <ahref="/constructor/updateBotShippingQuery">updateBotShippingQuery</a> update. Use this method to reply to shipping queries.</td>
<td>Once the user has confirmed their payment and shipping details, the bot receives an <ahref="/constructor/updateBotPrecheckoutQuery">updateBotPrecheckoutQuery</a> update. <br>Use this method to respond to such pre-checkout queries. <br><strong>Note</strong>: Telegram must receive an answer within 10 seconds after the pre-checkout query was sent.</td>
<td>Vote in a <ahref="/constructor/poll">poll</a><br><br>Starting from layer 159, the vote will be sent from the peer specified using <ahref="/method/messages.saveDefaultSendAs">messages.saveDefaultSendAs</a>.</td>
<h3><aclass="anchor"href="#working-with-scheduled-messages"id="working-with-scheduled-messages"name="working-with-scheduled-messages"><iclass="anchor-icon"></i></a>Working with scheduled messages</h3>
<h3><aclass="anchor"href="#working-with-sensitive-content-nsfw"id="working-with-sensitive-content-nsfw"name="working-with-sensitive-content-nsfw"><iclass="anchor-icon"></i></a>Working with sensitive content (NSFW)</h3>
<h3><aclass="anchor"href="#working-with-sponsored-messages"id="working-with-sponsored-messages"name="working-with-sponsored-messages"><iclass="anchor-icon"></i></a>Working with sponsored messages</h3>
<td>Informs the server that the user has either:<br><br>- Clicked on a link in the sponsored message<br>- Has opened a sponsored chat or a sponsored website via the associated button<br>- Has opened the sponsored chat via the sponsored message name, the sponsored message photo, or a mention in the sponsored message</td>
<h3><aclass="anchor"href="#working-with-the-attachment-menu--of-mini-bot-apps-"id="working-with-the-attachment-menu--of-mini-bot-apps-"name="working-with-the-attachment-menu--of-mini-bot-apps-"><iclass="anchor-icon"></i></a>Working with the <ahref="/bots/webapps#launching-mini-apps-from-the-attachment-menu">attachment menu »</a> of <ahref="/bots/webapps">mini bot apps »</a></h3>
<h3><aclass="anchor"href="#working-with-the-native-anti-spam-system"id="working-with-the-native-anti-spam-system"name="working-with-the-native-anti-spam-system"><iclass="anchor-icon"></i></a>Working with the <ahref="/api/antispam">native anti-spam system</a></h3>
<h3><aclass="anchor"href="#working-with-the-takeout-api-see-here--for-more-info"id="working-with-the-takeout-api-see-here--for-more-info"name="working-with-the-takeout-api-see-here--for-more-info"><iclass="anchor-icon"></i></a>Working with the <ahref="/api/takeout">takeout API, see here » for more info</a>.</h3>
<td>Get a list of <ahref="/api/channel">channels/supergroups</a> we left, requires a <ahref="/api/takeout">takeout session, see here » for more info</a>.</td>
<h3><aclass="anchor"href="#working-with-the-bot-menu-button-"id="working-with-the-bot-menu-button-"name="working-with-the-bot-menu-button-"><iclass="anchor-icon"></i></a>Working with the bot <ahref="/bots/webapps#launching-mini-apps-from-the-menu-button">menu button »</a></h3>
<td>Gets the menu button action for a given user or for all users, previously set using <ahref="/method/bots.setBotMenuButton">bots.setBotMenuButton</a>; users can see this information in the <ahref="/constructor/botInfo">botInfo</a> constructor.</td>
<h3><aclass="anchor"href="#working-with-the-users-account"id="working-with-the-users-account"name="working-with-the-users-account"><iclass="anchor-icon"></i></a>Working with the user's account</h3>
<td>Delete the user's account from the telegram servers.<br><br>Can also be used to delete the account of a user that provided the login code, but forgot the 2FA password and no recovery method is configured, see <ahref="/api/srp#password-recovery">here »</a> for more info on password recovery, and <ahref="/api/account-deletion">here »</a> for more info on account deletion.</td>
<h3><aclass="anchor"href="#working-with-user-profile-pictures"id="working-with-user-profile-pictures"name="working-with-user-profile-pictures"><iclass="anchor-icon"></i></a>Working with user profile pictures</h3>
<td>Updates current user profile photo.<br><br>The <code>file</code>, <code>video</code> and <code>video_emoji_markup</code> flags are mutually exclusive.</td>
<td>Upload a custom profile picture for a contact, or suggest a new profile picture to a contact.<br><br>The <code>file</code>, <code>video</code> and <code>video_emoji_markup</code> flags are mutually exclusive.</td>
<h3><aclass="anchor"href="#working-with-usernames"id="working-with-usernames"name="working-with-usernames"><iclass="anchor-icon"></i></a>Working with usernames</h3>