set_bot_name()¶
- Client.set_bot_name()¶
Use this method to get the current / owned bot name for the given user language.
Note
If the current account is an User, can be called only if the
for_my_bothascan_be_editedproperty set to True.Usable by Users Bots
- Parameters:¶
name (``str``) – New bot name; 0-64 characters. Pass an empty string to remove the dedicated name for the given language.
language_code (``str``, *optional*) – A two-letter ISO 639-1 language code or an empty string
for_my_bot (``int`` | ``str``, *optional*) – Unique identifier (int) or username (str) of the bot for which profile photo has to be updated instead of the current user. The bot should have
can_be_editedproperty set to True.
- Raises:¶
RPCError –
- Returns:¶
``bool`` (True on success.)
Example
await app.set_bot_name("Pyrogram Assistant")