Folder.exclude_chat()

Folder.exclude_chat()

Bound method exclude_chat of Folder.

Always exclude a chat from the folder.

Use as a shortcut for:

await client.edit_folder(
    folder_id=folder_id,
    excluded_chats=[chat_id],
)

Example

await folder.exclude_chat(chat_id)
Parameters:

chat_id (int | str) – Unique identifier (int) or username (str) of the target chat. For your personal cloud (Saved Messages) you can simply use “me” or “self”. For a contact that exists in your Telegram address book you can use his phone number (str).

Returns:

True on success.