Skip to content

Latest commit

 

History

History
424 lines (286 loc) · 11.6 KB

File metadata and controls

424 lines (286 loc) · 11.6 KB

tlgr folder

13 operations. Every one takes the global flags (--json, --plain, -a/--account, --results-only, --select, --dry-run, --yes, --no-input, --flood-wait-max, -v) anywhere on the line.

Command Summary
folder add Add chats to a folder
folder create Create a chat folder
folder delete Delete a chat folder
folder edit Edit a chat folder
folder join Preview and join a shared folder link
folder list List chat folders in display order
folder remove Remove chats from a folder
folder reorder Set the display order of chat folders
folder share delete Revoke a folder share link
folder share list List a folder's shareable invite links
folder share set Create or edit a folder's shareable invite link
folder suggested list List the chat folders Telegram suggests, and add one
folder update list New chats the owner added to a shared folder

folder add

Add chats to a folder.

tlgr folder add <FOLDER> [CHAT]... [OPTIONS]

mutating · idempotent (reports already) · returns Folder

Argument Type Required Meaning
FOLDER text yes Folder id or name.
CHAT chat one or more Chats to add.
Flag Type Default Meaning
--pin flag Add to the pinned list instead.
$ tlgr folder add Work @alice --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.folder-add-chat

folder create

Create a chat folder.

Peers are batched into one updateDialogFilter; adding them one at a time is what earns a FLOOD_WAIT on a folder with thirty chats.

tlgr folder create <TITLE> [OPTIONS]

mutating · returns Folder

Argument Type Required Meaning
TITLE text yes Folder title.
Flag Type Default Meaning
--bots flag Include bots.
--channels flag Include channels.
--color text Tag colour 0-6, or 'none' (Premium).
--contacts flag Include every contact.
--emoji text Folder icon.
--exclude chat Always exclude.
--exclude-archived flag Drop archived chats.
--exclude-muted flag Drop muted chats.
--exclude-read flag Drop fully read chats.
--groups flag Include groups.
--include chat Always include.
--no-title-animation flag Do not animate custom emoji in the title.
--non-contacts flag Include non-contacts.
--pin chat Pin inside the folder.
$ tlgr folder create "Work" --groups --emoji 💼 --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.folder-create

folder delete

Delete a chat folder.

A folder you made is a filter: deleting it keeps every chat. A shared folder you joined can take its chats with it, which is why --leave-chats exists and defaults to keeping them.

tlgr folder delete <FOLDER> [OPTIONS]

mutating · destructive (needs --yes off a TTY) · returns FolderDeleted

Argument Type Required Meaning
FOLDER text yes Folder id or name.
Flag Type Default Meaning
--leave-chats text none none (default)

Also invocable as: tlgr folder leave

$ tlgr folder delete Work --json
Catalog coverage (2 full, 0 partial)

Full: dialogs.chatlist-leave, dialogs.folder-delete

folder edit

Edit a chat folder.

Every flag is a paired switch (--groups/--no-groups) because 'leave it alone' and 'turn it off' are different requests, and the whole filter is rewritten in one call.

tlgr folder edit <FOLDER> [OPTIONS]

mutating · returns Folder

Argument Type Required Meaning
FOLDER text yes Folder id or name.
Flag Type Default Meaning
--add, --include chat Add a chat.
--bots/--no-bots flag Include bots.
--channels/--no-channels flag Include channels.
--clear-exclude flag Empty the exclude list.
--clear-include flag Empty the include list.
--color text Tag colour 0-6, or 'none' (Premium).
--contacts/--no-contacts flag Include every contact.
--emoji text Folder icon.
--exclude chat Always exclude.
--exclude-archived/--no-exclude-archived flag Drop archived chats.
--exclude-muted/--no-exclude-muted flag Drop muted chats.
--exclude-read/--no-exclude-read flag Drop read chats.
--groups/--no-groups flag Include groups.
--no-title-animation/--no-no-title-animation flag Animate custom emoji in the title.
--non-contacts/--no-non-contacts flag Include non-contacts.
--pin chat Pin inside the folder.
--remove chat Remove a chat.
--title text New title.
$ tlgr folder edit Work --title "Work & clients" --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.folder-edit

folder join

Preview and join a shared folder link.

Without --chats or --all this only previews: the reply lists what the link offers and joins nothing.

tlgr folder join <LINK> [OPTIONS]

mutating · returns ChatlistJoin

Argument Type Required Meaning
LINK text yes t.me/addlist/, or a bare slug.
Flag Type Default Meaning
--chats chat Which offered chats to join.
--all-chats flag Join every offered chat.
$ tlgr folder join t.me/addlist/AbCdEf --json
Catalog coverage (3 full, 0 partial)

Full: contacts-users.resolve-folder-link, dialogs.chatlist-check, dialogs.chatlist-join

folder list

List chat folders in display order.

Shared folders (is_chatlist) carry no type flags, and the 'All chats' placeholder appears as id 0 so folder reorder can position it. --tags on|off is the one write here and it honours --dry-run itself, so listing stays available under it.

tlgr folder list [OPTIONS]

returns FolderList

Flag Type Default Meaning
--tags on off
--with-counts flag Evaluate each folder over the dialog list.
$ tlgr folder list --json
Catalog coverage (3 full, 0 partial)

Full: dialogs.folder-emoticon-title, dialogs.folder-list, dialogs.folder-tags

folder remove

Remove chats from a folder.

tlgr folder remove <FOLDER> [CHAT]... [OPTIONS]

mutating · idempotent (reports already) · returns Folder

Argument Type Required Meaning
FOLDER text yes Folder id or name.
CHAT chat one or more Chats to remove.
Flag Type Default Meaning
--exclude flag Also exclude, so a type flag cannot pull it back in.
$ tlgr folder remove Work @alice --exclude --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.folder-remove-chat

folder reorder

Set the display order of chat folders.

tlgr folder reorder [FOLDER]... [OPTIONS]

mutating · idempotent (reports already) · returns FolderOrder

Argument Type Required Meaning
FOLDER text one or more Folders in the order you want them.
$ tlgr folder reorder main Work Family --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.folder-reorder

folder share delete

Revoke a folder share link.

tlgr folder share delete <FOLDER> <SLUG> [OPTIONS]

mutating · destructive (needs --yes off a TTY) · returns ShareDeleted

Argument Type Required Meaning
FOLDER text yes Folder id or name.
SLUG text yes The link to revoke.
$ tlgr folder share delete Work AbCdEf --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.chatlist-invite-delete

folder share list

List a folder's shareable invite links.

tlgr folder share list <FOLDER> [OPTIONS]

paginated (LOCAL cursor) · returns Page[ChatlistInvite]

Argument Type Required Meaning
FOLDER text yes Folder id or name.

Pagination is transport-level: --limit/-n, --cursor TOKEN, --all (walked inside the daemon, paced by the account's own rate limiter).

$ tlgr folder share list Work --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.chatlist-invite-list

folder share set

Create or edit a folder's shareable invite link.

tlgr folder share set <FOLDER> [OPTIONS]

mutating · returns ChatlistInvite

Argument Type Required Meaning
FOLDER text yes Folder id or name.
Flag Type Default Meaning
--all-eligible flag Every chat of the folder that may be shared.
--chats chat Chats the link carries.
--slug text Edit this link instead of creating one.
--title text Link title.

Also invocable as: tlgr folder share create, tlgr folder share edit

$ tlgr folder share set Work --all-eligible --json
Catalog coverage (2 full, 0 partial)

Full: dialogs.chatlist-invite-create, dialogs.chatlist-invite-edit

folder suggested list

List the chat folders Telegram suggests, and add one.

tlgr folder suggested list [OPTIONS]

mutating · paginated (LOCAL cursor) · idempotent (reports already) · returns Page[SuggestedFolder]

Flag Type Default Meaning
--add text Add the suggested folder with this title.

Pagination is transport-level: --limit/-n, --cursor TOKEN, --all (walked inside the daemon, paced by the account's own rate limiter).

$ tlgr folder suggested list --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.folder-suggested

folder update list

New chats the owner added to a shared folder.

tlgr folder update list <FOLDER> [OPTIONS]

mutating · idempotent (reports already) · returns ChatlistUpdates

Argument Type Required Meaning
FOLDER text yes Shared folder id or name.
Flag Type Default Meaning
--dismiss flag Hide the update badge.
--join text all

Also invocable as: tlgr folder updates

$ tlgr folder update list Work --json
Catalog coverage (1 full, 0 partial)

Full: dialogs.chatlist-updates