Accepts an OAuth authorization request. Returns an HTTP URL to open after
successful authorization. May return an empty link if just a toast about
successful login has to be shown
Returns HttpUrl
Activates stealth mode for stories, which hides all views of stories from
the current user in the last "story_stealth_mode_past_period" seconds and
for the next "story_stealth_mode_future_period" seconds; for Telegram
Premium users only
Returns Ok
Adds a new media preview to the beginning of the list of media previews of
a bot. Returns the added preview after addition is completed server-side.
The total number of previews must not exceed
getOption("bot_media_preview_count_max") for the given language
Returns BotMediaPreview
Adds a new member to a chat; requires can_invite_users member right.
Members can't be added to private or secret chats. Returns information
about members that weren't added
Returns FailedToAddMembers
Adds multiple new members to a chat; requires can_invite_users member
right. Currently, this method is available only in supergroups and
channels. This method can't be used to join a chat. Members can't be added
to a channel if it has more than 200 members. Returns information about
members that weren't added
Returns FailedToAddMembers
Adds a chat to a chat list. A chat can't be simultaneously in Main and
Archive chat lists, so it is automatically removed from another one if
needed
Returns Ok
Adds a custom server language pack to the list of installed language packs
in current localization target. Can be called before authorization
Returns Ok
Adds a new sticker to the list of favorite stickers. The new sticker is
added to the top of the list. If the sticker was already in the list, it
is removed from the list first. Only stickers belonging to a sticker set
or in WEBP or WEBM format can be added to this list. Emoji stickers can't
be added to favorite stickers
Returns Ok
Adds a file from a message to the list of file downloads. Download
progress and completion of the download will be notified through
updateFile updates. If message database is used, the list of file
downloads is persistent across application restarts. The downloading is
independent of download using downloadFile, i.e. it continues if
downloadFile is canceled or is used to download a part of the file
Returns File
Adds gifts to the beginning of a previously created collection. If the
collection is owned by a channel chat, then requires can_post_messages
administrator right in the channel chat. Returns the changed collection
Returns GiftCollection
Adds a local message to a chat. The message is persistent across
application restarts only if the message database is used. Returns the
added message
Returns Message
Adds a passkey allowed to be used for the login by the current user and
returns the added passkey. Call getPasskeyParameters to get parameters for
creating of the passkey
Returns Passkey
Sends a suggested post based on a previously sent message in a channel
direct messages chat. Can be also used to suggest price or time change for
an existing suggested post. Returns the sent message
Returns Message
Adds pending paid reaction in a live story group call. Can't be used in
live stories posted by the current user. Call
commitPendingLiveStoryReactions or removePendingLiveStoryReactions to
actually send all pending reactions when the undo timer is over or abort
the sending
Returns Ok
Adds a message to a quick reply shortcut via inline bot. If shortcut
doesn't exist and there are less than
getOption("quick_reply_shortcut_count_max") shortcuts, then a new shortcut
is created. The shortcut must not contain more than
getOption("quick_reply_shortcut_message_count_max") messages after adding
the new message. Returns the added message
Returns QuickReplyMessage
Adds a message to a quick reply shortcut. If shortcut doesn't exist and
there are less than getOption("quick_reply_shortcut_count_max") shortcuts,
then a new shortcut is created. The shortcut must not contain more than
getOption("quick_reply_shortcut_message_count_max") messages after adding
the new message. Returns the added message
Returns QuickReplyMessage
Adds 2-10 messages grouped together into an album to a quick reply
shortcut. Currently, only audio, document, photo and video messages can be
grouped into an album. Documents and audio files can be only grouped in an
album with messages of the same type. Returns sent messages
Returns QuickReplyMessages
Adds a chat to the list of recently found chats. The chat is added to the
beginning of the list. If the chat is already in the list, it will be
removed from the list first
Returns Ok
Manually adds a new sticker to the list of recently used stickers. The new
sticker is added to the top of the list. If the sticker was already in the
list, it is removed from the list first. Only stickers belonging to a
sticker set or in WEBP or WEBM format can be added to this list. Emoji
stickers can't be added to recent stickers
Returns Stickers
Manually adds a new animation to the list of saved animations. The new
animation is added to the beginning of the list. If the animation was
already in the list, it is removed first. Only non-secret video animations
with MIME type "video/mp4" can be added to the list
Returns Ok
Adds a new notification sound to the list of saved notification sounds.
The new notification sound is added to the top of the list. If it is
already in the list, its position isn't changed
Returns NotificationSound
Adds stories to the beginning of a previously created story album. If the
album is owned by a supergroup or a channel chat, then requires
can_edit_stories administrator right in the chat. Returns the changed
album
Returns StoryAlbum
Adds a custom text composition style to the list of used by the user
styles. May return an error with a message "TONES_SAVED_TOO_MANY" if the
maximum number of added custom styles
getOption("added_text_composition_style_count_max") has been reached
Returns Ok
Sets the result of interaction with a Web App and sends corresponding
message on behalf of the user to the chat from which the query originated;
for bots only
Returns InlineMessageId
An authentication code is delivered by an immediately canceled call to the
specified phone number. The phone number that calls is the code that must
be entered automatically
An authentication code is delivered by an immediately canceled call to the
specified phone number. The last digits of the phone number that calls are
the code that must be entered manually by the user
A digit-only authentication code is delivered via an SMS message to the
specified phone number; non-official applications may not receive this
type of code
An authentication code is a phrase from multiple words delivered via an
SMS message to the specified phone number; non-official applications may
not receive this type of code
An authentication code is a word delivered via an SMS message to the
specified phone number; non-official applications may not receive this
type of code
TDLib client is in its final state. All databases are closed and all
resources are released. No other updates will be received after this. All
queries will be responded to with error code 500. To continue working, one
must create a new instance of the TDLib client
TDLib is closing, all subsequent queries will be answered with the error
500. Note that closing TDLib can take a while. All resources will be freed
only after authorizationStateClosed has been received
TDLib needs the user's email address to authorize. Call
setAuthenticationEmailAddress to provide the email address, or directly
call checkAuthenticationEmailCode with Apple ID/Google ID token if allowed
The user has been authorized, but needs to enter a 2-step verification
password to start using the application. Call checkAuthenticationPassword
to provide the password, or requestAuthenticationPasswordRecovery to
recover the password, or deleteAccount to delete the account after a week
TDLib needs the user's phone number to authorize. Call
setAuthenticationPhoneNumber to provide the phone number, or use
requestQrCodeAuthentication, getAuthenticationPasskeyParameters,
checkAuthenticationWebToken, or checkAuthenticationBotToken for other
authentication options
The user must buy Telegram Premium as an in-store purchase to log in. Call
checkAuthenticationPremiumPurchase and then
setAuthenticationPremiumPurchaseTransaction
The user is unregistered and needs to accept terms of service and enter
their first name and last name to finish registration. Call registerUser
to accept the terms of service and provide the data
Bans a member in a chat; requires can_restrict_members administrator
right. Members can't be banned in private or secret chats. In supergroups
and channels, the user will not be able to return to the group on their
own using invite links, etc., unless unbanned first
Returns Ok
Bans users from a group call not bound to a chat; requires
groupCall.is_owned. Only the owner of the group call can invite the banned
users back
Returns Ok
Describes settings for greeting messages that are automatically sent by a
Telegram Business account as response to incoming messages in an inactive
private chat
Checks whether the specified bot can send messages to the user. Returns a
404 error if can't and the access can be granted by call to
allowBotToSendMessages
Returns Ok
Checks whether the current user can post a story on behalf of a chat;
requires can_post_stories administrator right for supergroup and channel
chats
Returns CanPostStoryResult
Changes imported contacts using the list of contacts saved on the device.
Imports newly added contacts and, if at least the file database is
enabled, deletes recently deleted contacts. Query result depends on the
result of the previous query, so only one query is possible at the same
time
Returns ImportedContacts
The chat is a private or secret chat, which can be reported using the
method reportChat, or the other user can be blocked using the method
setMessageSenderBlockList, or the other user can be added to the contact
list using the method addContact. If the chat is a private chat with a
user with an emoji status, then a notice about emoji status usage must be
shown
The chat can be reported as spam using the method reportChat with an empty
option_id and message_ids. If the chat is a private chat with a user with
an emoji status, then a notice about emoji status usage must be shown
The chat is a private or secret chat with a mutual contact and the user's
phone number can be shared with the other user using the method
sharePhoneNumber
A list of chats usually located at the top of the main chat list. Unmuted
chats are automatically moved from the Archive to the Main chat list when
a new message arrives
The user is a member of the chat and has some additional privileges. In
basic groups, administrators have all applicable rights. In supergroups
and channels, any subset of the rights can be chosen for an administrator
The user or the chat was banned (and hence is not a member of the chat).
Implies the user can't return to the chat, view messages, or be used as a
participant identifier to join a video chat of the chat
Checks the authentication token of a bot; to log in as a bot. Works only
when the current authorization state is authorizationStateWaitPhoneNumber.
Can be used instead of setAuthenticationPhoneNumber and
checkAuthenticationCode to log in
Returns Ok
Checks a passkey to log in to the corresponding account. Call
getAuthenticationPasskeyParameters to get parameters for the passkey.
Works only when the current authorization state is
authorizationStateWaitPhoneNumber or
authorizationStateWaitOtherDeviceConfirmation, or if there is no pending
authentication query and the current authorization state is
authorizationStateWaitPremiumPurchase, authorizationStateWaitEmailAddress,
authorizationStateWaitEmailCode, authorizationStateWaitCode,
authorizationStateWaitRegistration, or authorizationStateWaitPassword
Returns Ok
Checks whether a 2-step verification password recovery code sent to an
email address is valid. Works only when the current authorization state is
authorizationStateWaitPassword
Returns Ok
Checks whether an in-store purchase of Telegram Premium is possible before
authorization. Works only when the current authorization state is
authorizationStateWaitPremiumPurchase
Returns Ok
Checks a web token to log in to the corresponding account; for official
Telegram apps only. Works only when the current authorization state is
authorizationStateWaitPhoneNumber or
authorizationStateWaitOtherDeviceConfirmation
Returns Ok
Checks whether the maximum number of owned public chats has been reached.
Returns corresponding error if the limit was reached. The limit can be
increased with Telegram Premium
Returns Ok
Checks a match-code for an OAuth authorization request. If fails, then the
authorization request has failed. Otherwise, authorization confirmation
dialog must be shown and the link must be processed using
acceptOauthRequest or declineOauthRequest
Returns Ok
Informs TDLib that a message with an animated emoji was clicked by the
user. Returns a big animated sticker to be played or a 404 error if usual
animation needs to be played
Returns Sticker
Informs TDLib that the user opened the sponsored chat via the button, the
name, the chat photo, a mention in the sponsored message text, or the
media in the sponsored message
Returns Ok
Closes the TDLib instance. All databases will be flushed to disk and
properly closed. After the close completes, updateAuthorizationState with
authorizationStateClosed will be sent. Can be called before initialization
Returns Ok
Changes a rich message using an AI model. May return an error with a
message "AICOMPOSE_FLOOD_PREMIUM" if Telegram Premium is required to send
further requests
Returns RichMessage
Changes text using an AI model; must not be used in secret chats. May
return an error with a message "AICOMPOSE_FLOOD_PREMIUM" if Telegram
Premium is required to send further requests
Returns FormattedText
Creates a bot which will be managed by another bot. Returns the created
bot. May return an error with a message "BOT_CREATE_LIMIT_EXCEEDED" if the
user already owns the maximum allowed number of bots as per
getOption("owned_bot_count_max"). An internal link
"https://t.me/BotFather?start=deletebot" can be processed to handle the
error
Returns User
Creates a business chat link for the current account. Requires Telegram
Business subscription. There can be up to
getOption("business_chat_link_count_max") links created. Returns the
created link
Returns BusinessChatLink
Creates new chat folder. Returns information about the created chat
folder. There can be up to getOption("chat_folder_count_max") chat
folders, but the limit can be increased with Telegram Premium
Returns ChatFolderInfo
Creates a new invite link for a chat folder. A link can be created for a
chat folder if it has only pinned and included chats
Returns ChatFolderInviteLink
Creates a new invite link for a chat. Available for basic groups,
supergroups, and channels. Requires administrator privileges and
can_invite_users right in the chat
Returns ChatInviteLink
Creates a topic in a forum supergroup chat or a chat with a bot with
topics; requires can_manage_topics administrator or can_create_topics
member right in the supergroup
Returns ForumTopicInfo
Creates a collection from gifts on the current user's or a channel's
profile page; requires can_post_messages administrator right in the
channel chat. An owner can have up to
getOption("gift_collection_count_max") gift collections. The new
collection will be added to the end of the gift collection list of the
owner. Returns the created collection
Returns GiftCollection
Creates a new basic group and sends a corresponding
messageBasicGroupChatCreate. Returns information about the newly created
chat
Returns CreatedBasicGroupChat
Creates a new rich message using an AI model. May return an error with a
message "AICOMPOSE_FLOOD_PREMIUM" if Telegram Premium is required to send
further requests
Returns RichMessage
Creates a custom text composition style. May return an error with a
message "TONES_SAVED_TOO_MANY" if the maximum number of added custom
styles has been reached
Returns TextCompositionStyle
Creates a video chat (a group call bound to a chat); for basic groups,
supergroups and channels only; requires can_manage_video_chats
administrator right
Returns GroupCallId
Deletes the account of the current user, deleting all information
associated with the user from the server. The phone number of the account
can be used to create a new account. Can be called before authorization
when the current authorization state is authorizationStateWaitPassword
Returns Ok
Deletes all recent reactions added by the specified sender in a chat.
Supported only for basic groups and supergroups; requires
can_delete_messages administrator right
Returns Ok
Deletes all revoked chat invite links created by a given chat
administrator. Requires administrator privileges and can_invite_users
right in the chat for own links and owner privileges for other links
Returns Ok
Deletes a chat along with all messages in the corresponding chat for all
chat members. For group chats this will release the usernames and remove
all members. Use the field chat.can_be_deleted_for_all_users to find
whether the method can be applied to the chat
Returns Ok
Deletes all messages in the chat. Use chat.can_be_deleted_only_for_self
and chat.can_be_deleted_for_all_users fields to find whether and how the
method can be applied to the chat
Returns Ok
Deletes all messages between the specified dates in a chat. Supported only
for private chats and basic groups. Messages sent in the last 30 seconds
will not be deleted
Returns Ok
Deletes all messages sent by the specified message sender in a chat.
Supported only for supergroups; requires can_delete_messages administrator
right
Returns Ok
Deletes the default reply markup from a chat. Must be called after a
one-time keyboard or a replyMarkupForceReply reply markup has been used or
dismissed
Returns Ok
Deletes all messages between the specified dates in the topic in a channel
direct messages chat administered by the current user. Messages sent in
the last 30 seconds will not be deleted
Returns Ok
Deletes all messages from a topic in a forum supergroup chat or a chat
with a bot with topics; requires can_delete_messages administrator right
in the supergroup unless the user is creator of the topic, the topic has
no messages from other users and has at most 11 messages
Returns Ok
Deletes a gift collection. If the collection is owned by a channel chat,
then requires can_post_messages administrator right in the channel chat
Returns Ok
Deletes all messages sent by the specified message sender in a group call;
for live story calls only. Requires groupCall.can_delete_messages right
Returns Ok
Deletes all information about a language pack in the current localization
target. The language pack which is currently in use (including base
language pack) or is being synchronized can't be deleted. Can be called
before authorization
Returns Ok
Deletes revoked chat invite links. Requires administrator privileges and
can_invite_users right in the chat for own links and owner privileges for
other links
Returns Ok
Deletes a story album. If the album is owned by a supergroup or a channel
chat, then requires can_edit_stories administrator right in the chat
Returns Ok
Closes the TDLib instance, destroying all local data without a proper
logout. The current user session will remain in the list of all active
sessions. All local data will be destroyed. After the destruction
completes updateAuthorizationState with authorizationStateClosed will be
sent. Can be called before authorization
Returns Ok
Disconnects an affiliate program from the given affiliate and immediately
deactivates its referral link. Returns updated information about the
disconnected affiliate program
Returns ConnectedAffiliateProgram
Edits the media content of a message with a text, an animation, an audio,
a document, a photo or a video in a message sent on behalf of a business
account; for bots only
Returns BusinessMessage
Edits a non-primary invite link for a chat. Available in basic groups,
supergroups, and channels. If the link creates a subscription, then
expiration_date, member_limit and creates_join_request must not be used.
Requires administrator privileges and can_invite_users right in the chat
for own links and owner privileges for other links
Returns ChatInviteLink
Edits a subscription invite link for a channel chat. Requires
can_invite_users right in the chat for own links and owner privileges for
other links
Returns ChatInviteLink
Edits title and icon of a topic in a forum supergroup chat or a chat with
a bot with topics; for supergroup chats requires can_manage_topics
administrator right unless the user is creator of the topic
Returns Ok
Edits the media content of a message with a text, an animation, an audio,
a document, a photo or a video in an inline message sent via a bot; for
bots only
Returns Ok
Edits the message content of a live location. Messages can be edited for a
limited period of time specified in the live location. Returns the edited
message after the edit is completed on the server side
Returns Message
Edits the media content of a message, including message caption. If only
the caption needs to be edited, use editMessageCaption instead. The type
of message content in an album can't be changed with exception of
replacing a photo with a video or vice versa. Returns the edited message
after the edit is completed on the server side
Returns Message
Edits the time when a scheduled message will be sent. Scheduling state of
all messages in the same album or forwarded together with the message will
be also changed
Returns Ok
Asynchronously edits the text, media or caption of a quick reply message.
Use quickReplyMessage.can_be_edited to check whether a message can be
edited. Media message can be edited only to a media message. Checklist
messages can be edited only to a checklist message. The type of message
content in an album can't be changed with exception of replacing a photo
with a video or vice versa
Returns Ok
Email address can be reset after the given period. Call
resetAuthenticationEmailAddress to reset it and allow the user to
authorize with a code sent to the user's phone number
The category contains a list of similar emoji to search for in getStickers
and searchStickers for stickers, or getInlineQueryResults with the bot
getOption("animation_search_bot_username") for animations
Fixes a rich message using an AI model. May return an error with a message
"AICOMPOSE_FLOOD_PREMIUM" if Telegram Premium is required to send further
requests
Returns RichMessage
Fixes text using an AI model; must not be used in secret chats. May return
an error with a message "AICOMPOSE_FLOOD_PREMIUM" if Telegram Premium is
required to send further requests
Returns FixedText
Forwards previously sent messages. Returns the forwarded messages in the
same order as the message identifiers passed in message_ids. If a message
can't be forwarded, null will be returned instead of the message
Returns Messages
Returns all active sessions of the current user. Additionally,
getBusinessConnectedBot must be used to show the bot on top of active
sessions
Returns Sessions
Returns a list of sticker sets attached to a file, including regular,
mask, and emoji sticker sets. Currently, only animations, photos, and
videos can have attached sticker sets
Returns StickerSets
Returns the current authorization state. This is an offline method. For
informational purposes only. Use updateAuthorizationState instead to
maintain the current authorization state. Can be called before
initialization
Returns AuthorizationState
Returns the text shown in the chat with a bot if the chat is empty in the
given language. Can be called only if userTypeBot.can_be_edited == true
Returns Text
Returns the text shown on a bot's profile page and sent together with the
link when users share the bot in the given language. Can be called only if
userTypeBot.can_be_edited == true
Returns Text
Returns the list of media previews for the given language and the list of
languages for which the bot has dedicated previews
Returns BotMediaPreviewInfo
Returns information about the business bot that is connected to the
current user account. Returns a 404 error if there is no connected bot
Returns BusinessConnectedBotInfo
Sends a callback query to a bot and returns an answer. Returns an error
with code 502 if the bot fails to answer the query before the query
timeout expires
Returns CallbackQueryAnswer
Returns the list of all stories posted by the given chat; requires
can_edit_stories administrator right in the chat. The stories are returned
in reverse chronological order (i.e., in order of decreasing story_id).
For optimal performance, the number of returned stories is chosen by TDLib
Returns Stories
Returns a list of service actions taken by chat members and administrators
in the last 48 hours. Available only in supergroups and channels. Requires
administrator rights. Returns results in reverse chronological order
(i.e., in order of decreasing event_id)
Returns ChatEvents
Returns approximate number of chats in a being created chat folder. Main
and archive chat lists must be fully preloaded for this function to work
correctly
Returns Count
Returns identifiers of pinned or always included chats from a chat folder,
which are suggested to be left when the chat folder is deleted
Returns Chats
Returns new chats added to a shareable chat folder by its owner. The
method must be called at most once in
getOption("chat_folder_new_chats_update_period") for the given chat folder
Returns Chats
Returns messages in a chat. The messages are returned in reverse
chronological order (i.e., in order of decreasing message_id). For optimal
performance, the number of returned messages is chosen by TDLib. This is
an offline method if only_local is true
Returns Messages
Returns information about an invite link. Requires administrator
privileges and can_invite_users right in the chat to get own links and
owner privileges to get other links
Returns ChatInviteLink
Returns chat members joined a chat via an invite link. Requires
administrator privileges and can_invite_users right in the chat for own
links and owner privileges for other links
Returns ChatInviteLinkMembers
Returns invite links for a chat created by specified administrator.
Requires administrator privileges and can_invite_users right in the chat
to get own links and owner privileges to get other links
Returns ChatInviteLinks
Returns information about the next messages of the specified type in the
chat split by days. Returns the results in reverse chronological order.
Can return partial result for the last returned day. Behavior of this
method depends on the value of the option "utc_time_offset"
Returns MessageCalendar
Returns approximate 1-based position of a message among messages, which
can be found by the specified filter in the chat and topic. Cannot be used
in secret chats
Returns Count
Returns the user who will become the owner of the chat after 7 days if the
current user does not return to the supergroup or channel during that
period or immediately for basic groups; requires owner privileges in the
chat. Available only for basic groups, supergroups, and channel chats
Returns User
Returns the list of stories that posted by the given chat to its chat
page. If from_story_id == 0, then pinned stories are returned first. Then,
stories are returned in reverse chronological order (i.e., in order of
decreasing story_id). For optimal performance, the number of returned
stories is chosen by TDLib
Returns Stories
Returns detailed revenue statistics about a chat. Currently, this method
can be used only for channels if
supergroupFullInfo.can_get_revenue_statistics == true or bots if
userFullInfo.bot_info.can_get_revenue_statistics == true
Returns ChatRevenueStatistics
Returns the list of revenue transactions for a chat. Currently, this
method can be used only for channels if
supergroupFullInfo.can_get_revenue_statistics == true or bots if
userFullInfo.bot_info.can_get_revenue_statistics == true
Returns ChatRevenueTransactions
Returns a URL for chat revenue withdrawal; requires owner privileges in
the channel chat or the bot. Currently, this method can be used only if
getOption("can_withdraw_chat_revenue") for channels with
supergroupFullInfo.can_get_revenue_statistics == true or bots with
userFullInfo.bot_info.can_get_revenue_statistics == true
Returns HttpUrl
Returns an ordered list of chats from the beginning of a chat list. For
informational purposes only. Use loadChats and updates processing instead
to maintain chat lists in a consistent state
Returns Chats
Returns all scheduled messages in a chat. The messages are returned in
reverse chronological order (i.e., in order of decreasing message_id)
Returns Messages
Returns sparse positions of messages of the specified type in the chat to
be used for Shared Media scroll implementation. Returns the results in
reverse chronological order (i.e., in order of decreasing message_id).
Cannot be used in secret chats or with searchMessagesFilterFailedToSend
filter without an enabled message database
Returns MessagePositions
Returns detailed statistics about a chat. Currently, this method can be
used only for supergroups and channels. Can be used only if
supergroupFullInfo.can_get_statistics == true
Returns ChatStatistics
Returns supergroup and channel chats in which the current user has the
right to post stories. The chats must be rechecked with canPostStory
before actually trying to post a story there
Returns Chats
Returns interactions with a story posted in a chat. Can be used only if
story is posted on behalf of a chat and the user is an administrator in
the chat
Returns StoryInteractions
Returns an affiliate program that was connected to the given affiliate by
identifier of the bot that created the program
Returns ConnectedAffiliateProgram
Uses the current IP address to find the current country. Returns
two-letter ISO 3166-1 alpha-2 country code. Can be called before
authorization
Returns Text
Returns all updates needed to restore current TDLib state, i.e. all actual
updateAuthorizationState/updateUser/updateNewChat and others. This is
especially useful if TDLib is run in a separate process. Can be called
before initialization
Returns Updates
Returns the list of custom emoji stickers by their identifiers. Stickers
are returned in arbitrary order. Only found stickers are returned
Returns Stickers
Returns information about a tg:// deep link. Use
"tg://need_update_for_some_feature" or "tg:some_unsupported_feature" for
testing. Returns a 404 error for unknown links. Can be called before
authorization
Returns DeepLinkInfo
Returns messages in the topic in a channel direct messages chat
administered by the current user. The messages are returned in reverse
chronological order (i.e., in order of decreasing message_id)
Returns Messages
Returns the last message sent in the topic in a channel direct messages
chat administered by the current user no later than the specified date
Returns Message
Returns the list of emoji statuses, which can't be used as chat emoji
status, even if they are from a sticker set with
is_allowed_as_chat_emoji_status == true
Returns EmojiStatusCustomEmojis
Returns an HTTP URL which can be used to automatically log in to the
translation platform and suggest new emoji replacements. The URL will be
valid for 30 seconds after generation
Returns HttpUrl
Returns an HTTP URL which can be used to automatically authorize the
current user on a website after clicking an HTTP link. Use the method
getExternalLinkInfo to find whether a prior user confirmation is needed.
May return an empty link if just a toast about successful login has to be
shown
Returns HttpUrl
Returns information about an action to be done when the current user
clicks an external link. Don't use this method for links from secret chats
if link preview is disabled in secret chats, and use directly
getLinkWebBrowserType
Returns LoginUrlInfo
Returns messages in a topic in a forum supergroup chat or a chat with a
bot with topics. The messages are returned in reverse chronological order
(i.e., in order of decreasing message_id). For optimal performance, the
number of returned messages is chosen by TDLib
Returns Messages
Returns found forum topics in a forum supergroup chat or a chat with a bot
with topics. This is a temporary method for getting information about
topic list from the server
Returns ForumTopics
Returns a URL for TON Gram withdrawal from the current user's account. The
user must have at least 10 Grams to withdraw and can withdraw up to 100000
Grams in one transaction
Returns HttpUrl
Returns a list of recently inactive supergroups and channels. Can be used
when user reaches limit on the number of joined supergroups and channels
and receives the error "CHANNELS_TOO_MUCH". Also, the limit can be
increased with Telegram Premium
Returns Chats
Sends an inline query to a bot and returns its results. Returns an error
with code 502 if the bot fails to answer the query before the query
timeout expires
Returns InlineQueryResults
Returns information about the type of internal link. Returns a 404 error
if the link is not internal. Can be called before authorization
Returns InternalLinkType
Returns information about a language pack. Returned language pack
identifier may be different from a provided one. Can be called before
authorization
Returns LanguagePackInfo
Returns a string stored in the local database from the specified
localization target and language pack by its key. Returns a 404 error if
the string is not found. Can be called synchronously
Returns LanguagePackStringValue
Returns a link preview by the text of a message. Do not call this function
too often. Returns a 404 error if the text has no link preview
Returns LinkPreview
Returns information about the user or the chat that streams to a live
story; for live stories that aren't an RTMP stream only
Returns GroupCallParticipant
Returns information about the current localization target. This is an
offline method if only_local is true. Can be called before authorization
Returns LocalizationTargetInfo
Returns an HTTP URL which can be used to automatically authorize the user
on a website after clicking an inline button of type
inlineKeyboardButtonTypeLoginUrl. Use the method getLoginUrlInfo to find
whether a prior user confirmation is needed. If an error is returned, then
the button must be handled as an ordinary URL button
Returns HttpUrl
Returns information about a button of type
inlineKeyboardButtonTypeLoginUrl. The method needs to be called when the
user presses the button
Returns LoginUrlInfo
Returns the list of available TDLib internal log tags, for example,
"actor", "binlog", "connections", "notifications", "proxy". Can be
called synchronously
Returns LogTags
Replaces text entities with Markdown formatting in a human-friendly
format. Entities that can't be represented in Markdown unambiguously are
kept as is. Can be called synchronously
Returns FormattedText
Returns information about actual author of a message sent on behalf of a
channel. The method can be called if messageProperties.can_get_author ==
true
Returns User
Returns reactions, which can be added to a message. The list can change
after updateActiveEmojiReactions, updateChatAvailableReactions for the
chat, or updateMessageInteractionInfo for the message
Returns AvailableReactions
Returns an HTTPS link to a message in a chat. Available only if
messageProperties.can_get_link, or if
messageProperties.can_get_media_timestamp_links and a media timestamp link
is generated. This is an offline method
Returns MessageLink
Returns information about a public or private message link. Can be called
for any internal link of the type internalLinkTypeMessage
Returns MessageLinkInfo
Returns information about a message, if it is available without sending
network request. Returns a 404 error if message isn't available locally.
This is an offline method
Returns Message
Returns forwarded copies of a channel message to different public channels
and public reposts as a story. Can be used only if
messageProperties.can_get_statistics == true. For optimal performance, the
number of returned messages and stories is chosen by TDLib
Returns PublicForwards
Returns read date of a recent outgoing message in a private chat. The
method can be called if messageProperties.can_get_read_date == true
Returns MessageReadDate
Returns messages in a message thread of a message. Can be used only if
messageProperties.can_get_message_thread == true. Message thread of a
channel message is in the channel's linked supergroup. The messages are
returned in reverse chronological order (i.e., in order of decreasing
message_id). For optimal performance, the number of returned messages is
chosen by TDLib
Returns Messages
Returns viewers of a recent outgoing message in a basic group or a
supergroup chat. For video notes and voice notes only users, opened
content of the message, are returned. The method can be called if
messageProperties.can_get_viewers == true
Returns MessageViewers
Returns information about an OAuth deep link. Use
checkOauthRequestMatchCode, acceptOauthRequest or declineOauthRequest to
process the link
Returns OauthLinkInfo
Returns the value of an option by its name. (Check the list of available
options on https://core.telegram.org/tdlib/options.) Can be called before
authorization. Can be called synchronously for options "version" and
"commit_hash"
Returns OptionValue
Returns already available Telegram Passport elements suitable for
completing a Telegram Passport authorization form. Result can be received
only once for each authorization form
Returns PassportElementsWithErrors
Returns an invoice payment form. This method must be called when the user
presses inline button of the type inlineKeyboardButtonTypeBuy, or wants to
buy access to media in a messagePaidMedia message
Returns PaymentForm
Returns information about a phone number by its prefix synchronously.
getCountries must be called at least once after changing localization to
the specified language if properly localized country information is
expected. Can be called synchronously
Returns PhoneNumberInfo
Returns message senders voted for the specified option in a poll; use
poll.can_get_voters to check whether the method can be used. For optimal
performance, the number of returned users is chosen by TDLib
Returns PollVoters
Returns an IETF language tag of the language preferred in the country,
which must be used to fill native fields in Telegram Passport personal
details. Returns a 404 error if unknown
Returns Text
Returns available options for creating of Telegram Premium giveaway or
manual distribution of Telegram Premium among chat members
Returns PremiumGiveawayPaymentOptions
Returns a keyboard button prepared by the bot for the user. The button
will be of the type keyboardButtonTypeRequestUsers,
keyboardButtonTypeRequestChat, or keyboardButtonTypeRequestManagedBot
Returns KeyboardButton
Returns a globally unique push notification subscription identifier for
identification of an account, which has received a push notification. Can
be called synchronously
Returns PushReceiverId
Returns a 2-step verification recovery email address that was previously
set up. This method can be used to verify a password provided by the user
Returns RecoveryEmailAddress
Returns information about a file by its remote identifier. This is an
offline method. Can be used to register a URL as a file for further
uploading, or sending as a message. Even if the request succeeds, the file
can be used only if it is still accessible to the user. For example, if
the file is from a message, then the message must be not deleted and
accessible to the user. If the file database is disabled, then the
corresponding object with the file must be preloaded by the application
Returns File
Returns information about a non-bundled message that is replied by a given
message. Also, returns the pinned message for messagePinMessage, the game
message for messageGameScore, the invoice message for
messagePaymentSuccessful, the message with a previously set same
background for messageChatSetBackground, the giveaway message for
messageGiveawayCompleted, the checklist message for
messageChecklistTasksDone, messageChecklistTasksAdded, the message with
suggested post information for messageSuggestedPostApprovalFailed,
messageSuggestedPostApproved, messageSuggestedPostDeclined,
messageSuggestedPostPaid, messageSuggestedPostRefunded, the message with
the regular gift that was upgraded for messageUpgradedGift with origin of
the type upgradedGiftOriginUpgrade, the message with gift purchase offer
for messageUpgradedGiftPurchaseOfferRejected, the message with the request
to disable content protection for messageChatHasProtectedContentToggled,
the message with the poll for messagePollOptionAdded and
messagePollOptionDeleted, and the topic creation message for topic
messages without non-bundled replied message. Returns a 404 error if the
message doesn't exist
Returns Message
Returns messages in a Saved Messages topic. The messages are returned in
reverse chronological order (i.e., in order of decreasing message_id)
Returns Messages
Returns saved notification sound by its identifier. Returns a 404 error if
there is no saved notification sound with the specified identifier
Returns NotificationSound
Returns a URL for a Telegram Ad platform account that can be used to set
up advertisements for the chat paid in the owned Telegram Stars
Returns HttpUrl
Returns emoji corresponding to a sticker. The list is only for
informational purposes, because a sticker is always sent with a fixed
emoji from the corresponding Sticker object
Returns Emojis
Returns stickers from the installed sticker sets that correspond to any of
the given emoji or can be found by sticker-specific keywords. If the query
is non-empty, then favorite, recently used or trending stickers may also
be returned
Returns Stickers
Returns forwards of a story as a message to public chats and reposts by
public channels. Can be used only if the story is posted on behalf of the
current user or story.can_get_statistics == true. For optimal performance,
the number of returned messages and stories is chosen by TDLib
Returns PublicForwards
Returns a list of basic group and supergroup chats, which can be used as a
discussion group for a channel. Returned basic group chats must be first
upgraded to supergroups before they can be set as a discussion group. To
set a returned supergroup as a discussion group, access to its old
messages must be enabled using toggleSupergroupIsAllHistoryAvailable first
Returns Chats
Returns information about members or banned users in a supergroup or
channel. Can be used only if supergroupFullInfo.can_get_members == true;
additionally, administrator privileges may be required for some filters
Returns ChatMembers
Returns all entities (mentions, hashtags, cashtags, bot commands, bank
card numbers, URLs, and email addresses) found in the text. Can be called
synchronously
Returns TextEntities
Returns up to 8 emoji statuses, which must be shown right after the
default Premium Badge in the emoji status list for self status
Returns EmojiStatusCustomEmojis
Returns advertisements to be shown while a video from a message is
watched. Available only if messageProperties.can_get_video_advertisements
Returns VideoMessageAdvertisements
Returns an HTTPS URL of a Web App to open from the side menu, a
keyboardButtonTypeWebApp button, or an inlineQueryResultsButtonTypeWebApp
button
Returns WebAppUrl
Returns an instant view version of a web page if available. This is an
offline method if only_local is true. Returns a 404 error if the web page
has no instant view page
Returns WebPageInstantView
A button to buy something. This button must be in the first column and row
of the keyboard and can be attached only to a message with content of the
type messageInvoice
A button with a game that sends a callback query to a bot. This button
must be in the first column and row of the keyboard and can be attached
only to a message with content of the type messageGame
Applies if a user chooses some previously saved payment credentials. To
use their previously saved credentials, the user must have a valid
temporary password
A file generated by the application. The application must handle updates
updateFileGenerationStart and updateFileGenerationStop to generate the
file when asked by TDLib
A file defined by its remote identifier. The remote identifier is
guaranteed to be usable only if the corresponding file is still accessible
to the user and known to TDLib. For example, if the file is from a
message, then the message must be not deleted and accessible to the user.
If the file database is disabled, then the corresponding object with the
file must be preloaded by the application
A message with a poll. Polls can't be sent to secret chats and channel
direct messages chats. Polls can be sent to a private chat only if the
chat is a chat with a bot or the Saved Messages chat
The media is a photo. 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
One of the files containing the translation of the document contains an
error. The error is considered resolved when the file with the translation
changes
A rich message to send. Total length of all texts, including custom emoji
alternative text and formula source, must not exceed
getOption("rich_message_text_length_max"). The total number of all blocks,
list items and table rows must not exceed
getOption("rich_message_block_count_max"). The maximum allowed depth of
nested blocks and rich texts is getOption("rich_message_depth_max"). The
total number of media in all blocks must not exceed
getOption("rich_message_media_count_max"). The maximum allowed number of
table columns is getOption("rich_message_table_column_count_max")
The link is a link to an attachment menu bot to be opened in the specified
or a chosen chat. Process given target_chat to open the chat. Then, call
searchPublicChat with the given bot username, check that the user is a bot
and can be added to attachment menu. Then, use getAttachmentMenuBot to
receive information about the bot. If the bot isn't added to attachment
menu, then show a disclaimer about Mini Apps being third-party
applications, ask the user to accept their Terms of service and confirm
adding the bot to side and attachment menu. If the user accept the terms
and confirms adding, then use toggleBotIsAddedToAttachmentMenu to add the
bot. If the attachment menu bot can't be used in the opened chat, show an
error to the user. If the bot is added to attachment menu and can be used
in the chat, then use openWebApp with the given URL
The link is a link to a background. Call searchBackground with the given
background name to process the link. If background is found and the user
wants to apply it, then call setDefaultBackground
The link is a link to a Telegram bot, which is expected to be added to a
channel chat as an administrator. Call searchPublicChat with the given bot
username and check that the user is a bot, ask the current user to select
a channel chat to add the bot to as an administrator. Then, call
getChatMember to receive the current bot rights in the chat and if the bot
already is an administrator, check that the current user can edit its
administrator rights and combine received rights with the requested
administrator rights. Then, show confirmation box to the user, and call
setChatMemberStatus with the chosen chat and confirmed rights
The link is a link to a chat with a Telegram bot. Call searchPublicChat
with the given bot username, check that the user is a bot, show START
button in the chat with the bot, and then call sendBotStartMessage with
the given start parameter after the button is pressed
The link is a link to a Telegram bot, which is expected to be added to a
group chat. Call searchPublicChat with the given bot username, check that
the user is a bot and can be added to groups, ask the current user to
select a basic group or a supergroup chat to add the bot to, taking into
account that bots can be added to a public supergroup only by
administrators of the supergroup. If administrator rights are provided by
the link, call getChatMember to receive the current bot rights in the chat
and if the bot already is an administrator, check that the current user
can edit its administrator rights, combine received rights with the
requested administrator rights, show confirmation box to the user, and
call setChatMemberStatus with the chosen chat and confirmed administrator
rights. Before call to setChatMemberStatus it may be required to upgrade
the chosen basic group chat to a supergroup chat. Then, if start_parameter
isn't empty, call sendBotStartMessage with the given start parameter and
the chosen chat; otherwise, just send /start message with bot's username
added to the chat
The link is a link to a business chat. Use getBusinessChatLinkInfo with
the provided link name to get information about the link, then open
received private chat and replace chat draft with the provided text
The link is a link to boost a Telegram chat. Call getChatBoostLinkInfo
with the given URL to process the link. If the chat is found, then call
getChatBoostStatus and getAvailableChatBoostSlots to get the current boost
status and check whether the chat can be boosted. If the user wants to
boost the chat and the chat can be boosted, then call boostChat
The link is an invite link to a chat folder. Call
checkChatFolderInviteLink with the given invite link to process the link.
If the link is valid and the user wants to join the chat folder, then call
addChatFolderByInviteLink
The link is a chat invite link. Call checkChatInviteLink with the given
invite link to process the link. If the link is valid and the user wants
to join the chat, then call joinChatByInviteLink
The link is a link to a channel direct messages chat by username of the
channel. Call searchPublicChat with the given chat username to process the
link. If the chat is found and is channel, open the direct messages chat
of the channel
The link is a link to a game. Call searchPublicChat with the given bot
username, check that the user is a bot, ask the current user to select a
chat to send the game, and then call sendMessage with inputMessageGame
The link is a link to a gift collection. Call searchPublicChat with the
given username, then call getReceivedGifts with the received gift owner
identifier and the given collection identifier, then show the collection
if received
The link is a link to a group call that isn't bound to a chat. Use
getGroupCallParticipants to get the list of group call participants and
show them on the join group call screen. Call joinGroupCall with the given
invite_link to join the call
The link must be opened in an Instant View. Call getWebPageInstantView
with the given URL to process the link. If Instant View is found, then
show it, otherwise, open the fallback URL in an external browser
The link is a link to a language pack. Call getLanguagePackInfo with the
given language pack identifier to process the link. If the language pack
is found and the user wants to apply it, then call setOption for the
option "language_pack_id"
The link is a link to a live story. Call searchPublicChat with the given
chat username, then getChatActiveStories to get active stories in the
chat, then find a live story among active stories of the chat, and then
joinLiveStory to join the live story
The link is a link to the main Web App of a bot. Call searchPublicChat
with the given bot username, check that the user is a bot and has the main
Web App. If the bot can be added to attachment menu, then use
getAttachmentMenuBot to receive information about the bot, then if the bot
isn't added to side menu, show a disclaimer about Mini Apps being
third-party applications, ask the user to accept their Terms of service
and confirm adding the bot to side and attachment menu, then if the user
accepts the terms and confirms adding, use
toggleBotIsAddedToAttachmentMenu to add the bot. Then, use getMainWebApp
with the given start parameter and mode and open the returned URL as a Web
App
The link is a link to a Telegram message or a forum topic. Call
getMessageLinkInfo with the given URL to process the link, and then open
received forum topic or chat and show the message there
The link contains a message draft text. A share screen needs to be shown
to the user, then the chosen chat must be opened and the text is added to
the input field
The link is an OAuth link. Call getOauthLinkInfo with the given URL to
process the link if the link was received from outside of the application;
otherwise, ignore it. After getOauthLinkInfo, show the user confirmation
dialog and process it with checkOauthRequestMatchCode, acceptOauthRequest
or declineOauthRequest
The link contains a request of Telegram passport data. Call
getPassportAuthorizationForm with the given parameters to process the link
if the link was received from outside of the application; otherwise,
ignore it
The link can be used to confirm ownership of a phone number to prevent
account deletion. Call sendPhoneNumberCode with the given phone number and
with phoneNumberCodeTypeConfirmOwnership with the given hash to process
the link. If succeeded, call checkPhoneNumberCode to check entered by the
user code, or resendPhoneNumberCode to resend it
The link is a link to the Premium features screen of the application from
which the user can subscribe to Telegram Premium. Call getPremiumFeatures
with the given referrer to process the link
The link is a link with a Telegram Premium gift code. Call
checkPremiumGiftCode with the given code to process the link. If the code
is valid and the user wants to apply it, then call applyPremiumGiftCode
The link is a link to the screen for gifting Telegram Premium
subscriptions to friends via inputInvoiceTelegram with
telegramPaymentPurposePremiumGift payments or in-store purchases
The link is a link to a chat by its username. Call searchPublicChat with
the given chat username to process the link. If the chat is found, open
its profile information screen or the chat itself. If draft text isn't
empty and the chat is a private chat with a regular user, then put the
draft text in the input field
The link can be used to login the current user on another device, but it
must be scanned from QR-code using in-app camera. An alert similar to
"This code can be used to allow someone to log in to your Telegram
account. To confirm Telegram login, please go to Settings
The link is a link to a dialog for creating of a managed bot. Call
searchPublicChat with the given manager bot username. If the chat is
found, the chat is a chat with a bot and the bot has can_manage_bots ==
true, then show bot creation confirmation dialog with the given
suggested_bot_username and suggested_bot_name. If user agrees, call
createBot with via_link == true to create the bot
The link is a link to a sticker set. Call searchStickerSet with the given
sticker set name to process the link and show the sticker set. If the
sticker set is found and the user wants to add it, then call
changeStickerSet
The link is a link to a story. Call searchPublicChat with the given poster
username, then call getStory with the received chat identifier and the
given story identifier, then show the story if received
The link is a link to an album of stories. Call searchPublicChat with the
given username, then call getStoryAlbumStories with the received chat
identifier and the given story album identifier, then show the story album
if received
The link is a link to a text composition style. Call
searchTextCompositionStyle with the given style name to get information
about the style. If the style is found and the user wants to add it, then
call addTextCompositionStyle
The link is a link to a user by its phone number. Call
searchUserByPhoneNumber with the given phone number to process the link.
If the user is found, then call createPrivateChat and open user's profile
information screen or the chat itself. If draft text isn't empty, then put
the draft text in the input field
The link is a link to a user by a temporary token. Call searchUserByToken
with the given token to process the link. If the user is found, then call
createPrivateChat and open the chat
The link is a link to a video chat. Call searchPublicChat with the given
chat username, and then joinVideoChat with the given invite hash to
process the link
The link is a link to a Web App. Call searchPublicChat with the given bot
username, check that the user is a bot. If the bot is restricted for the
current user, then show an error message. Otherwise, call searchWebApp
with the received bot and the given web_app_short_name. Process received
foundWebApp by showing a confirmation dialog if needed. If the bot can be
added to attachment or side menu, but isn't added yet, then show a
disclaimer about Mini Apps being third-party applications instead of the
dialog and ask the user to accept their Terms of service. If the user
accept the terms and confirms adding, then use
toggleBotIsAddedToAttachmentMenu to add the bot. Then, call
getWebAppLinkUrl and open the returned URL as a Web App
Invites a user to an active group call; for group calls not bound to a
chat only. Sends a service message of the type messageGroupCall. The group
call can have at most getOption("group_call_participant_count_max")
participants
Returns InviteGroupCallParticipantResult
The user was invited and a service message of the type messageGroupCall
was sent which can be used in declineGroupCallInvitation to cancel the
invitation
Invites users to an active video chat. Sends a service message of the type
messageInviteVideoChatParticipants to the chat bound to the group call
Returns Ok
A button that requests a chat to be shared by the current user; available
only in private chats. Use the method shareChatWithBot to complete the
request
A button that requests creation of a managed bot by the current user;
available only in private chats. Use the method createBot to complete the
request
A button that requests users to be shared by the current user; available
only in private chats. Use the method shareUsersWithBot to complete the
request
Loads more active stories from a story list. The loaded stories will be
sent through updates. Active stories are sorted by the pair
(active_stories.order, active_stories.story_poster_chat_id) in descending
order. Returns a 404 error if all active stories have been loaded
Returns Ok
Loads more chats from a chat list. The loaded chats and their positions in
the chat list will be sent through updates. Chats are sorted by the pair
(chat.position.order, chat.id) in descending order. Returns a 404 error if
all chats have been loaded
Returns Ok
Loads more topics in a channel direct messages chat administered by the
current user. The loaded topics will be sent through
updateDirectMessagesChatTopic. Topics are sorted by their topic.order in
descending order. Returns a 404 error if all topics have been loaded
Returns Ok
Loads more participants of a group call; not supported in live stories.
The loaded participants will be received through updates. Use the field
groupCall.loaded_all_participants to check whether all participants have
already been loaded
Returns Ok
Loads quick reply messages that can be sent by a given quick reply
shortcut. The loaded messages will be sent through
updateQuickReplyShortcutMessages
Returns Ok
Loads quick reply shortcuts created by the current user. The loaded data
will be sent through updateQuickReplyShortcut and
updateQuickReplyShortcuts
Returns Ok
Loads more Saved Messages topics. The loaded topics will be sent through
updateSavedMessagesTopic. Topics are sorted by their topic.order in
descending order. Returns a 404 error if all topics have been loaded
Returns Ok
Closes the TDLib instance after a proper logout. Requires an available
network connection. All local data will be destroyed. After the logout
completes, updateAuthorizationState with authorizationStateClosed will be
sent
Returns Ok
Options to be used when a message content is copied without reference to
the original sender. Service messages, messages with messageInvoice,
messagePaidMedia, messageGiveaway, or messageGiveawayWinners content can't
be copied
A giveaway was created for the chat. Use
telegramPaymentPurposePremiumGiveaway, storePaymentPurposePremiumGiveaway,
telegramPaymentPurposeStarGiveaway, or storePaymentPurposeStarGiveaway to
create a giveaway
A message with information about a group call not bound to a chat. If the
message is incoming, the call isn't active, isn't missed, and has no
duration, and getOption("can_accept_calls") is true, then incoming call
screen must be shown to the user. Use getGroupCallParticipants to show
current group call participants on the screen. Use joinGroupCall to accept
the call or declineGroupCallInvitation to decline it. If the call become
active or missed, then the call screen must be hidden
A group containing notifications of type notificationTypeNewMessage and
notificationTypeNewPushMessage with unread mentions of the current user,
replies to their messages, or a pinned message
Informs TDLib that the chat is opened by the user. Many useful activities
depend on the chat being opened or closed (e.g., in supergroups and
channels all updates are received only for opened chats)
Returns Ok
Informs TDLib that the message content has been opened (e.g., the user has
opened a photo, video, document, location or venue, or has listened to an
audio file or voice note message). An updateMessageContentOpened update
will be generated if something has changed
Returns Ok
Informs TDLib that a Web App is being opened from the attachment menu, a
botMenuButton button, an internalLinkTypeAttachmentMenuBot link, or an
inlineKeyboardButtonTypeWebApp button. For each bot, a confirmation alert
about data sent to the bot must be shown once
Returns WebAppInfo
Optimizes storage usage, i.e. deletes some files and returns new storage
usage statistics. Secret thumbnails can't be deleted
Returns StorageStatistics
Parses Bold, Italic, Underline, Strikethrough, Spoiler, CustomEmoji,
BlockQuote, ExpandableBlockQuote, Code, Pre, PreCode, TextUrl,
MentionName, and DateTime entities from a marked-up text. Can be called
synchronously
Returns FormattedText
Posts a new story on behalf of a chat; requires can_post_stories
administrator right for supergroup and channel chats. Returns a temporary
story
Returns Story
Preliminarily uploads a file to the cloud before sending it in a message,
which can be useful for uploading of being recorded voice and video notes.
In all other cases there is no need to preliminary upload a file. Updates
updateFile will be used to notify about upload progress. The upload will
not be completed until the file is sent in a message
Returns File
Ability to change position of the main chat list, archive and mute all new
chats from non-contacts, and completely disable notifications about the
user's contacts joined Telegram
The ability to disallow incoming voice and video note messages in private
chats using setUserPrivacySettingRules with
userPrivacySettingAllowPrivateVoiceAndVideoNoteMessages and to restrict
incoming messages from non-contacts using setNewChatPrivacySettings
Describes an option for gifting Telegram Premium to a user. Use
telegramPaymentPurposePremiumGift for out-of-store payments or payments in
Telegram Stars
Describes an option for creating of Telegram Premium giveaway or manual
distribution of Telegram Premium among chat members. Use
telegramPaymentPurposePremiumGiftCodes or
telegramPaymentPurposePremiumGiveaway for out-of-store payments
Handles a push notification. Returns error with code 406 if the push
notification is not supported and connection to the server is required to
fetch new data. Can be called before authorization
Returns Ok
Contains privacy settings for message read date in private chats. Read
dates are always shown to the users that can see online status of the
current user regardless of this setting
Re-adds quick reply messages which failed to add. Can be called only for
messages for which messageSendingStateFailed.can_retry is true and after
specified in messageSendingStateFailed.retry_after time passed. If a
message is re-added, the corresponding failed to send message is deleted.
Returns the sent messages in the same order as the message identifiers
passed in message_ids. If a message can't be readded, null will be
returned instead of the message
Returns QuickReplyMessages
Reads a part of a file from the TDLib file cache and returns read bytes.
This method is intended to be used only if the application has no direct
access to TDLib's file system, because it is usually slower than a direct
read from the file
Returns Data
Recovers the 2-step verification password with a password recovery code
sent to an email address that was previously set up. Works only when the
current authorization state is authorizationStateWaitPassword
Returns Ok
Registers the currently used device for receiving push notifications.
Returns a globally unique identifier of the push notification subscription
Returns PushReceiverId
Removes gifts from a collection. If the collection is owned by a channel
chat, then requires can_post_messages administrator right in the channel
chat. Returns the changed collection
Returns GiftCollection
Removes stories from an album. If the album is owned by a supergroup or a
channel chat, then requires can_edit_stories administrator right in the
chat. Returns the changed album
Returns StoryAlbum
Removes a custom text composition style from the list of used by the user
styles. If the style was created by the current user, then it can only be
deleted
Returns Ok
Changes order of gifts in a collection. If the collection is owned by a
channel chat, then requires can_post_messages administrator right in the
channel chat. Returns the changed collection
Returns GiftCollection
Changes order of gift collections. If the collections are owned by a
channel chat, then requires can_post_messages administrator right in the
channel chat
Returns Ok
Changes order of story albums. If the albums are owned by a supergroup or
a channel chat, then requires can_edit_stories administrator right in the
chat
Returns Ok
Changes order of stories in an album. If the album is owned by a
supergroup or a channel chat, then requires can_edit_stories administrator
right in the chat. Returns the changed album
Returns StoryAlbum
Replaces current primary invite link for a chat with a new primary invite
link. Available for basic groups, supergroups, and channels. Requires
administrator privileges and can_invite_users right
Returns ChatInviteLink
Instructs application to remove the keyboard once this message has been
received. This kind of keyboard can't be received in an incoming message;
instead, updateChatReplyMarkup with reply_markup_message == null will be
sent
Reports that authentication code wasn't delivered via SMS; for official
mobile applications only. Works only when the current authorization state
is authorizationStateWaitCode
Returns Ok
Reports reactions set on a message to the Telegram moderators. Reactions
on a message can be reported only if
messageProperties.can_report_reactions
Returns Ok
Reports a false deletion of a message by aggressive anti-spam checks;
requires administrator rights in the supergroup. Can be called only for
messages from chatEventMessageDeleted with
can_report_anti_spam_false_positive == true
Returns Ok
Requests to send a 2-step verification password recovery code to an email
address that was previously set up. Works only when the current
authorization state is authorizationStateWaitPassword
Returns Ok
Requests to send a 2-step verification password recovery code to an email
address that was previously set up
Returns EmailAddressAuthenticationCodeInfo
Requests QR code authentication by scanning a QR code on another logged in
device. Works only when the current authorization state is
authorizationStateWaitPhoneNumber, or if there is no pending
authentication query and the current authorization state is
authorizationStateWaitPremiumPurchase, authorizationStateWaitEmailAddress,
authorizationStateWaitEmailCode, authorizationStateWaitCode,
authorizationStateWaitRegistration, or authorizationStateWaitPassword
Returns Ok
Resends an authentication code to the user. Works only when the current
authorization state is authorizationStateWaitCode, the next_code_type of
the result is not null and the server-specified timeout has passed, or
when the current authorization state is authorizationStateWaitEmailCode
Returns Ok
Resends messages which failed to send. Can be called only for messages for
which messageSendingStateFailed.can_retry is true and after specified in
messageSendingStateFailed.retry_after time passed. If a message is
re-sent, the corresponding failed to send message is deleted. Returns the
sent messages in the same order as the message identifiers passed in
message_ids. If a message can't be re-sent, null will be returned instead
of the message
Returns Messages
Resends the authentication code sent to a phone number. Works only if the
previously received authenticationCodeInfo next_code_type was not null and
the server-specified timeout has passed
Returns AuthenticationCodeInfo
Resets the login email address. May return an error with a message
"TASK_ALREADY_EXISTS" if reset is still pending. Works only when the
current authorization state is authorizationStateWaitEmailCode and
authorization_state.can_reset_email_address == true
Returns Ok
Removes 2-step verification password without previous password and access
to recovery email address. The password can't be reset immediately and the
request needs to be repeated after the specified time
Returns ResetPasswordResult
Revokes invite link for a chat. Available in basic groups, supergroups,
and channels. Requires administrator privileges and can_invite_users right
in the chat for own links and owner privileges for other links. If a
primary link is revoked, then additionally to the revoked link returns new
primary link
Returns ChatInviteLinks
Searches for call and group call messages. Returns the results in reverse
chronological order (i.e., in order of decreasing message_id). For optimal
performance, the number of returned messages is chosen by TDLib
Returns FoundMessages
Searches for a specified query in the first name, last name and usernames
of the members of a specified chat. Requires administrator rights if the
chat is a channel
Returns ChatMembers
Searches for messages with given words in the chat. Returns the results in
reverse chronological order, i.e. in order of decreasing message_id.
Cannot be used in secret chats with a non-empty query
(searchSecretMessages must be used instead), or without an enabled message
database. For optimal performance, the number of returned messages is
chosen by TDLib and can be smaller than the specified limit. A combination
of query, sender_id, filter and topic_id search criteria is expected to be
supported, only if it is required for Telegram official application
implementation
Returns FoundChatMessages
Returns information about the recent live locations of chat members that
were sent to the chat. Returns at most one live location message per user
Returns Messages
Searches for the specified query in the title and username of already
known chats. This is an offline method. Returns chats in the order seen in
the main chat list
Returns Chats
Searches for the specified query in the title and username of already
known chats via request to the server. Returns chats in the order seen in
the main chat list
Returns Chats
Searches for messages in all chats except secret chats. Returns the
results in reverse chronological order (i.e., in order of decreasing
(date, chat_id, message_id)). For optimal performance, the number of
returned messages is chosen by TDLib and can be smaller than the specified
limit
Returns FoundMessages
Returns only messages with unread mentions of the current user, or
messages that are replies to their messages. When using this filter the
results can't be additionally filtered by a query or by the sending user
Returns only messages with unread poll votes for the current user. When
using this filter the results can't be additionally filtered by a query or
by the sending user
Returns only messages with unread reactions for the current user. When
using this filter the results can't be additionally filtered by a query or
by the sending user
Searches for outgoing messages with content of the type messageDocument in
all chats except secret chats. Returns the results in reverse
chronological order
Returns FoundMessages
Searches a public chat by its username. Currently, only private chats,
supergroups and channels can be public. Returns the chat if found;
otherwise, an error is returned
Returns Chat
Searches public chats by looking for specified query in their username and
title. Currently, only private chats, supergroups and channels can be
public. Returns a meaningful number of results. Excludes private chats
with contacts and chats from the chat list from the results
Returns Chats
Searches for public channel posts containing the given hashtag or cashtag.
For optimal performance, the number of returned messages is chosen by
TDLib and can be smaller than the specified limit
Returns FoundMessages
Searches for public channel posts using the given query. For optimal
performance, the number of returned messages is chosen by TDLib and can be
smaller than the specified limit
Returns FoundPublicPosts
Searches for public stories by the given address location. For optimal
performance, the number of returned stories is chosen by TDLib and can be
smaller than the specified limit
Returns FoundStories
Searches for public stories containing the given hashtag or cashtag. For
optimal performance, the number of returned stories is chosen by TDLib and
can be smaller than the specified limit
Returns FoundStories
Searches for public stories from the given venue. For optimal performance,
the number of returned stories is chosen by TDLib and can be smaller than
the specified limit
Returns FoundStories
Searches for a given quote in a text. Returns found quote start position
in UTF-16 code units. Returns a 404 error if the quote is not found. Can
be called synchronously
Returns FoundPosition
Searches for messages tagged by the given reaction and with the given
words in the Saved Messages chat; for Telegram Premium users only. Returns
the results in reverse chronological order, i.e. in order of decreasing
message_id. For optimal performance, the number of returned messages is
chosen by TDLib and can be smaller than the specified limit
Returns FoundChatMessages
Searches for messages in secret chats. Returns the results in reverse
chronological order. For optimal performance, the number of returned
messages is chosen by TDLib
Returns FoundMessages
Searches specified query by word prefixes in the provided strings. Returns
0-based positions of strings that matched. Can be called synchronously
Returns FoundPositions
Sends Firebase Authentication SMS to the phone number of the user. Works
only when the current authorization state is authorizationStateWaitCode
and the server returned code of the type
authenticationCodeTypeFirebaseAndroid or authenticationCodeTypeFirebaseIos
Returns Ok
Invites a bot to a chat (if it is not yet a member) and sends it the
/start command; requires can_invite_users member right. Bots can't be
invited to a private chat other than the chat with the bot. Bots can't be
invited to channels (although they can be added as admins) and secret
chats. Returns the sent message
Returns Message
Sends 2-10 messages grouped together into an album on behalf of a business
account; for bots only. Currently, only audio, document, photo and video
messages can be grouped into an album. Documents and audio files can be
only grouped in an album with messages of the same type. Returns sent
messages
Returns BusinessMessages
Sends an ephemeral message which will be received only by one bot in a
chat. Currently, only ephemeral bot commands and replies to bot ephemeral
messages can be sent using the method. The message is persistent across
application restarts only if the message database is used. Returns the
sent message
Returns Message
Sends 2-10 messages grouped together into an album. Currently, only audio,
document, photo and video messages can be grouped into an album. Documents
and audio files can be only grouped in an album with messages of the same
type. Returns sent messages
Returns Messages
Informs TDLib about details of a message view by the user from a chat, a
message thread or a forum topic history. The method must be called if the
message wasn't seen for more than 300 milliseconds, the viewport was
destroyed, or the total view duration exceeded 5 minutes
Returns Ok
Sends a Telegram Passport authorization form, effectively sharing data
with the service. This method must be called after
getPassportAuthorizationFormAvailableElements if some previously available
elements are going to be reused
Returns Ok
Sends a code to the specified phone number. Aborts previous phone number
verification if there was one. On success, returns information about the
sent code
Returns AuthenticationCodeInfo
Sends Firebase Authentication SMS to the specified phone number. Works
only when received a code of the type
authenticationCodeTypeFirebaseAndroid or authenticationCodeTypeFirebaseIos
Returns Ok
Sends an upgraded gift that is available for resale to another user or
channel chat; gifts already owned by the current user must be transferred
using transferGift and can't be passed to the method
Returns GiftResaleResult
Sets the email address of the user and sends an authentication code to the
email address. Works only when the current authorization state is
authorizationStateWaitEmailAddress
Returns Ok
Sets the phone number of the user and sends an authentication code to the
user. Works only when the current authorization state is
authorizationStateWaitPhoneNumber, or if there is no pending
authentication query and the current authorization state is
authorizationStateWaitPremiumPurchase, authorizationStateWaitEmailAddress,
authorizationStateWaitEmailCode, authorizationStateWaitCode,
authorizationStateWaitRegistration, or authorizationStateWaitPassword
Returns Ok
Informs server about an in-store purchase of Telegram Premium before
authorization. Works only when the current authorization state is
authorizationStateWaitPremiumPurchase
Returns Ok
Sets the text shown on a bot's profile page and sent together with the
link when users share the bot. Can be called only if
userTypeBot.can_be_edited == true
Returns Ok
Sets the background in a specific chat. Supported only in private and
secret chats with non-deleted users, and in chats with sufficient boost
level and can_change_info administrator right
Returns Ok
Changes the emoji status of a chat. Use
chatBoostLevelFeatures.can_set_emoji_status to check whether an emoji
status can be set. Requires can_change_info administrator right
Returns Ok
Changes the location of a chat. Available only for some location-based
supergroups, use supergroupFullInfo.can_set_location to check whether the
method is allowed to use
Returns Ok
Changes the status of a chat member; requires can_invite_users member
right to add a chat member, can_promote_members administrator right to
change administrator rights of the member, and can_restrict_members
administrator right to change restrictions of a user. This function is
currently not suitable for transferring chat ownership; use
transferChatOwnership instead. Use addChatMember or banChatMember if some
additional parameters need to be passed
Returns Ok
Changes the tag or custom title of a chat member; requires can_manage_tags
administrator right to change tag of other users; for basic groups and
supergroups only
Returns Ok
Changes the message auto-delete or self-destruct (for secret chats) time
in a chat. Requires change_info administrator right in basic groups,
supergroups and channels. Message auto-delete time can't be changed in a
chat with the current user (Saved Messages) and the chat 777000
(Telegram).
Returns Ok
Changes the Telegram Star amount that must be paid to send a message to a
supergroup chat; requires can_restrict_members administrator right and
supergroupFullInfo.can_enable_paid_messages
Returns Ok
Changes name of a gift collection. If the collection is owned by a channel
chat, then requires can_post_messages administrator right in the channel
chat. Returns the changed collection
Returns GiftCollection
Changes the minimum number of Telegram Stars that must be paid by general
participant for each sent message to a live story call. Requires
groupCall.can_be_managed right
Returns Ok
Informs TDLib that speaking state of a participant of an active group call
has changed. Returns identifier of the participant if it is found
Returns MessageSender
Changes volume level of a participant of an active group call; not
supported for live stories. If the current user can manage the group call
or is the owner of the group call, then the participant's volume level
will be changed for all users with the default volume level
Returns Ok
Changes the login email address of the user. The email address can be
changed only if the current user already has login email and
passwordState.login_email_address_pattern is non-empty, or the user
received suggestedActionSetLoginEmailAddress and
isLoginEmailAddressRequired succeeds. The change will not be applied until
the new login email address is confirmed with checkLoginEmailAddressCode.
To use Apple ID/Google ID instead of an email address, call
checkLoginEmailAddressCode directly
Returns EmailAddressAuthenticationCodeInfo
Sets the current network type. Can be called before authorization. Calling
this method forces all network connections to reopen, mitigating the delay
in switching between different networks, so it must be called whenever the
network is changed, even if the network type remains the same. Network
type is used to check whether the library can use the network at all and
also for collecting detailed network data usage statistics
Returns Ok
Sets the value of an option. (Check the list of available options on
https://core.telegram.org/tdlib/options.) Only writable options can be
set. Can be called before authorization
Returns Ok
Adds an element to the user's Telegram Passport. May return an error with
a message "PHONE_VERIFICATION_NEEDED" or "EMAIL_VERIFICATION_NEEDED" if
the chosen phone number or the chosen email address must be verified first
Returns PassportElement
Informs the user that some of the elements in their Telegram Passport
contain errors; for bots only. The user will not be able to resend the
elements, until the errors are fixed
Returns Ok
Changes the 2-step verification password for the current user. If a new
recovery email address is specified, then the change will not be applied
until the new recovery email address is confirmed
Returns PasswordState
Changes the order of pinned topics in a forum supergroup chat or a chat
with a bot with topics; requires can_manage_topics administrator right in
the supergroup
Returns Ok
Changes the list of pinned gifts on the current user's or the channel's
profile page; requires can_post_messages administrator right in the
channel chat
Returns Ok
Changes the 2-step verification recovery email address of the user. If a
new recovery email address is specified, then the change will not be
applied until the new recovery email address is confirmed. If
new_recovery_email_address is the same as the email address that is
currently set up, this call succeeds immediately and aborts all other
requests waiting for an email confirmation
Returns PasswordState
Changes the list of emojis corresponding to a sticker. The sticker must
belong to a regular or custom emoji sticker set that is owned by the
current user
Returns Ok
Changes the list of keywords of a sticker. The sticker must belong to a
regular or custom emoji sticker set that is owned by the current user
Returns Ok
Changes name of an album of stories. If the album is owned by a supergroup
or a channel chat, then requires can_edit_stories administrator right in
the chat. Returns the changed album
Returns StoryAlbum
Changes privacy settings of a story. The method can be called only for
stories posted on behalf of the current user and if
story.can_set_privacy_settings == true
Returns Ok
Changes the custom emoji sticker set of a supergroup; requires
can_change_info administrator right. The chat must have at least
chatBoostFeatures.min_custom_emoji_sticker_set_boost_level boost level to
pass the corresponding color
Returns Ok
Changes the number of times the supergroup must be boosted by a user to
ignore slow mode and chat permission restrictions; requires
can_restrict_members administrator right
Returns Ok
Shares the phone number of the current user with a mutual contact.
Supposed to be called when the user clicks on
chatActionBarSharePhoneNumber
Returns Ok
Suggests the user to extend their expiring Telegram Star subscriptions.
Call getStarSubscriptions with only_expiring == true to get the number of
expiring subscriptions and the number of required to buy Telegram Stars
Suggests the user to add login email address. Call
isLoginEmailAddressRequired, and then setLoginEmailAddress or
checkLoginEmailAddressCode to change the login email address
Contains information about a suggested post. If the post can be approved
or declined, then changes to the post can be also suggested. Use
sendMessage with reply to the message and suggested post information to
suggest message changes. Use addOffer to suggest price or time changes
Fetches the latest versions of all strings from a language pack in the
current localization target from the server. This method doesn't need to
be called explicitly for the current used/base language packs. Can be
called before authorization
Returns Ok
Terminates all other sessions of the current user. Additionally, the user
must be suggested to delete the connected business bot using
deleteBusinessConnectedBot if there is any
Returns Ok
Returns the received vector of objects containing a number; for testing
only. This is an offline method. Can be called before authorization
Returns TestVectorIntObject
Returns the received vector of objects containing a string; for testing
only. This is an offline method. Can be called before authorization
Returns TestVectorStringObject
Does nothing and ensures that the Update object is used; for testing only.
This is an offline method. Can be called before authorization
Returns Update
Text that must be formatted as if inside a blockquote HTML tag and
collapsed by default to 3 lines with the ability to show full text; not
supported in secret chats
Adds or removes a bot to attachment and side menu. Bot can be added to the
menu, only if userTypeBot.can_be_added_to_attachment_menu == true
Returns Ok
Changes active state for a username of a bot. The editable username can be
disabled only if there are other active usernames. May return an error
with a message "USERNAMES_ACTIVE_TOO_MUCH" if the maximum number of active
usernames has been reached. Can be called only if
userTypeBot.can_be_edited == true
Returns Ok
Toggles whether notifications for new gifts received by a channel chat are
sent to the current user; requires can_post_messages administrator right
in the chat
Returns Ok
Changes the ability of users to save, forward, or copy chat content.
Requires owner privileges in basic groups, supergroups and channels.
Requires Telegram Premium to enable protected content in private chats.
Not available in Saved Messages and private chats with bots or support
accounts
Returns Ok
Changes the pinned state of a chat. There can be up to
getOption("pinned_chat_count_max")/getOption("pinned_archived_chat_count_max")
pinned non-secret chats and the same number of secret chats in the
main/archive chat list. The limit can be increased with Telegram Premium
Returns Ok
Toggles whether a topic is closed in a forum supergroup chat; requires
can_manage_topics administrator right in the supergroup unless the user is
creator of the topic
Returns Ok
Changes the pinned state of a topic in a forum supergroup chat or a chat
with a bot with topics; requires can_manage_topics administrator right in
the supergroup. There can be up to
getOption("pinned_forum_topic_count_max") pinned forum topics
Returns Ok
Toggles whether a gift is shown on the current user's or the channel's
profile page; requires can_post_messages administrator right in the
channel chat
Returns Ok
Toggles whether the current user has sponsored messages enabled. The
setting has no effect for users without Telegram Premium for which
sponsored messages are always enabled
Returns Ok
Changes the pinned state of a Saved Messages topic. There can be up to
getOption("pinned_saved_messages_topic_count_max") pinned topics. The
limit can be increased with Telegram Premium
Returns Ok
Toggles whether sponsored messages are shown in the channel chat; requires
owner privileges in the channel. The chat must have at least
chatBoostFeatures.min_sponsored_message_disable_boost_level boost level to
disable sponsored messages
Returns Ok
Toggles whether aggressive anti-spam checks are enabled in the supergroup.
Can be called only if supergroupFullInfo.can_toggle_aggressive_anti_spam
== true
Returns Ok
Toggles whether messages are automatically translated in the channel chat;
requires can_change_info administrator right in the channel. The chat must
have at least chatBoostFeatures.min_automatic_translation_boost_level
boost level to enable automatic translation
Returns Ok
Toggles whether non-administrators can receive only administrators and
bots using getSupergroupMembers or searchChatMembers. Can be called only
if supergroupFullInfo.can_hide_members == true
Returns Ok
Toggles whether all users directly joining the supergroup need to be
approved by supergroup administrators; requires can_restrict_members
administrator right
Returns Ok
Changes active state for a username of a supergroup or channel, requires
owner privileges in the supergroup or channel. The editable username can't
be disabled. May return an error with a message
"USERNAMES_ACTIVE_TOO_MUCH" if the maximum number of active usernames has
been reached
Returns Ok
Changes active state for a username of the current user. The editable
username can't be disabled. May return an error with a message
"USERNAMES_ACTIVE_TOO_MUCH" if the maximum number of active usernames has
been reached
Returns Ok
Toggles whether new participants of a video chat can be unmuted only by
administrators of the video chat. Requires
groupCall.can_toggle_mute_new_participants right
Returns Ok
Changes the owner of a chat; for basic groups, supergroups and channel
chats only; requires owner privileges in the chat. Use the method
canTransferOwnership to check whether the ownership can be transferred
from the current session
Returns Ok
Extracts text or caption of the given message and translates it to the
given language; must not be used in secret chats. If the current user is a
Telegram Premium user, then text formatting is preserved
Returns FormattedText
Translates a text to the given language; must not be used in secret chats.
If the current user is a Telegram Premium user, then text formatting is
preserved
Returns FormattedText
Removes all pinned messages from a chat; requires can_pin_messages member
right if the chat is a basic group or supergroup, or can_edit_messages
administrator right if the chat is a channel
Returns Ok
Removes all pinned messages from a topic in a forum supergroup chat or a
chat with a bot with topics; requires can_pin_messages member right in the
supergroup
Returns Ok
Removes a pinned message from a chat; requires can_pin_messages member
right if the chat is a basic group or supergroup, or can_edit_messages
administrator right if the chat is a channel
Returns Ok
The list of messages with active live location that need to be updated by
the application has changed. The list is persistent across application
restarts only if the message database is used
Contains active notifications that were shown on previous application
launches. This update is sent only if the message database is used. In
that case it comes once before any updateNotification and
updateNotificationGroup update
Some animated emoji message was clicked and a big animated sticker must be
played if the message is visible on the screen.
chatActionWatchingAnimations with the text of the message needs to be sent
if the sticker is played
A request can't be completed unless reCAPTCHA verification is performed;
for official mobile applications only. The method
setApplicationVerificationToken must be called once the verification is
completed or failed
A request can't be completed unless application verification is performed;
for official mobile applications only. The method
setApplicationVerificationToken must be called once the verification is
completed or failed
A chat draft has changed. Be aware that the update may come in the
currently opened chat but with old content of the draft. If the user has
changed the content of the draft, this update mustn't be applied
The number of online group members has changed. This update with non-zero
number of online group members is sent only for currently opened chats.
There is no guarantee that it is sent just after the number of online
users has changed
The revenue earned from sponsored messages in a chat has changed. If chat
revenue screen is opened, then getChatRevenueTransactions may be called to
fetch new transactions
Basic information about a topic in a channel direct messages chat
administered by the current user has changed. This update is guaranteed to
come before the topic identifier is returned to the application
The TON Gram revenue earned by the current user has changed. If Gram
transaction screen of the chat is opened, then getTonTransactions may be
called to fetch new transactions
Information about a group call participant was changed. The updates are
sent only after the group call is received through getGroupCall and only
if the call is joined or being joined
Describes whether there are some pending notification updates. Can be used
to prevent application from killing, while there are some pending
notifications
A request to send a message has reached the Telegram server. This doesn't
mean that the message will be sent successfully. This update is sent only
if the option "use_quick_ack" is set to true. This update may be sent
multiple times for the same message
A message failed to send. Be aware that some messages being sent can be
irrecoverably deleted, in which case updateDeleteMessages will be received
instead of this update
A new chat has been loaded/created. This update is guaranteed to come
before the chat identifier is returned to the application. The chat field
changes will be reported through separate updates
A new pending text or rich message was received in a chat with a bot. The
message must be shown in the chat for at most
getOption("pending_text_message_period") seconds, replace any other
pending message with the same draft_id, and be deleted whenever any
incoming message from the bot in the message thread is received
Basic information about a quick reply shortcut has changed. This update is
guaranteed to come before the quick shortcut name is returned to the
application
Basic information about a Saved Messages topic has changed. This update is
guaranteed to come before the topic identifier is returned to the
application
The list of saved notification sounds was updated. This update may not be
sent until information about a notification sound was requested for the
first time
Download or upload file speed for the user was limited, but it can be
restored by subscription to Telegram Premium. The notification can be
postponed until a file being downloaded or uploaded is visible to the
user. Use getOption("premium_download_speedup") or
getOption("premium_upload_speedup") to get expected speedup after
subscription to Telegram Premium
The Telegram Star revenue earned by a user or a chat has changed. If
Telegram Star transaction screen of the chat is opened, then
getStarTransactions may be called to fetch new transactions
New terms of service must be accepted by the user. If the terms of service
are declined, then the deleteAccount method must be called with the reason
"Decline ToS update"
Creates a new supergroup from an existing basic group and sends a
corresponding messageChatUpgradeTo and messageChatUpgradeFrom; requires
owner privileges. Deactivates the original basic group
Returns Chat
A privacy setting for managing whether the user can be found by their
phone number. Checked only if the phone number is not known to the other
user. Can be set only to "Allow contacts" or "Allow all"
A list of privacy rules. Rules are matched in the specified order. The
first matched rule defines the privacy setting for a given user. If no
rule matches, the action is not allowed
A deleted user or deleted bot. No information on the user besides the user
identifier is available. It is not possible to perform any active actions
on this type of user
No information on the user besides the user identifier is available, yet
this user has not been deleted. This object is extremely rare and must be
handled like a deleted user. It is not possible to perform any actions on
users of this type
Informs TDLib that messages are being viewed by the user. Sponsored
messages must be marked as viewed only when the entire text of the message
is shown on the screen (excluding the button). Many useful activities
depend on whether the messages are currently being viewed or not (e.g.,
marking messages as read, incrementing a view counter, updating a view
counter, removing deleted messages in supergroups and channels)
Returns Ok
Writes a part of a generated file. This method is intended to be used only
if the application has no direct access to TDLib's file system, because it
is usually slower than a direct write to the destination file
Returns Ok