transfer_chat_ownership()¶
- async Client.transfer_chat_ownership()¶
Set new chat owner.
Usable by Users Bots- Parameters:
chat_id (
int|str) – Unique identifier (int) or username (str) of the target chat.user_id (
int|str) – Unique identifier (int) or username (str) of the new owner. The ownership can’t be transferred to a bot or to a deleted user.password (
str) – The 2-step verification password of the current user.
- Returns:
bool– True on success.
Example
await app.transfer_chat_ownership(chat_id, user_id, "password")