TDLib options

TDLib has many options that affect the behavior of the library. Each option has a name and a value. Value may be of one of the following types:

Type of value Default value Value range
Integer 0 32-bit integer
Boolean false True or false
String Any Unicode string

List of options supported by TDLib

Options not mentioned in this list may be safely ignored.

Name Type Writable Description
disable_contact_registered_notifications Boolean Yes If true, notifications about the user's contacts who have joined Telegram will be disabled
disable_top_chats Boolean Yes If true, support for top chats and statistics collection is disabled.
ignore_inline_thumbnails Boolean Yes If true, prevents file thumbnails sent by the server along with messages from being saved on the disk
language_pack_database_path String Yes Path to a database for storing language pack strings, so that this database can be shared between different accounts. By default, language pack strings are stored only in memory.
language_pack_id String Yes Identifier of the currently used language pack from the current localization target
localization_target String Yes Name for the current localization target (currently supported: “android”, “android_x”, “ios”, “macos” and “tdesktop”)
online Boolean Yes Online status of the current user
prefer_ipv6 Boolean Yes If true, IPv6 addresses will be preferred over IPv4 addresses
use_pfs Boolean Yes If true, Perfect Forward Secrecy will be enabled for interaction with the Telegram servers for cloud chats
use_quick_ack Boolean Yes If true, quick acknowledgement will be enabled for outgoing messages
use_storage_optimizer Boolean Yes If true, the background storage optimizer will be enabled
animation_search_bot_username String No Username of a bot which can be used in inline mode for animations search
authorization_date Integer No Point in time (Unix timestamp) when authorization was received
basic_group_size_max Integer No Maximum number of members in a basic group
call_connect_timeout_ms Integer No Maximum time to wait for call connection creation to be passed to libtgvoip
call_packet_timeout_ms Integer No Maximum time to wait for call packet delivery to be passed to libtgvoip
favorite_stickers_limit Integer No Maximum number of favorite stickers
forwarded_messages_count_max Integer No Maximum number of forwarded messages per one request
message_caption_length_max Integer No Maximum length of a message caption
message_text_length_max Integer No Maximum length of a message text
my_id Integer No Identifier of the current user
pinned_chat_count_max Integer No Maximum number of pinned cloud chats. The same amount of secret chats can be pinned locally
photo_search_bot_username String No Username of a bot which can be used in inline mode for photos search
suggested_language_pack_id String No Identifier of the language pack, suggested for the user by the server
supergroup_size_max Integer No Maximum number of members in a supergroup
t_me_url String No Current value of t.me URL, i.e. https://t.me/
test_mode Boolean No If true, the test environment is being used instead of the production environment
venue_search_bot_username String No Username of a bot which can be used in inline mode for venues search
version String No TDLib version

Additionally any option beginning with ‘x’ or ‘X’ is writeable and can be safely used by the application to persistently store some small amount of data.