CLI reference: mail
Read and manage Thunderbird mail. Reads work on any plan; sends/edits are ordinary commands (no separate opt-in on the CLI). Part of the CLI reference.
| Command | What it does |
|---|---|
mail folders | List indexed folders with message counts |
mail search [query] | Full-text search (subject + body) with --from --to --subject --folder --account --since --until --limit --snippet |
mail list | Recent messages in a folder (--folder INBOX --limit 20) |
mail show <id> | One message body by gloda id or Message-ID (--text --html --raw --include-headers) |
mail fetch | Trigger Thunderbird’s Get Messages (new-mail check) now — all accounts, or one via --account-key |
mail thread <id> | The full conversation for a message |
mail send | Compose + send (--to --subject --text/--html, or --draft / --template / --later) |
mail draft | Alias for mail send --draft |
mail edit-draft <id> | Edit an existing draft — only the fields you pass change (--subject --to --cc --bcc --text/--html, or --text-file/--html-file) |
mail reply <id> / mail reply-all <id> | Reply to the sender / all recipients |
mail forward <id> | Forward a message (--to) |
mail move <id> --to <folder> | Move a message — or many via --ids a,b / a selector (--query --folder --account, --max) |
mail mark <id> | Update flags (--read --unread --star --unstar --tags); bulk via --ids / selector |
mail delete <id> | Trash a message (--hard to skip); bulk via --ids / selector |
mail attachments <id> | List a message’s attachments (index, filename, type, size) |
mail attachment-save <id> | Save attachments to disk (--index <n> or --all, --out <dir>) |
mail folder-create --account --name | Create a folder (nested Parent/Child supported) |
mail folder-rename --account --path --name | Rename a folder |
mail folder-delete --account --path | Delete a folder (special-use folders protected) |
mail empty-trash --account | Permanently delete everything in an account’s Trash |
# Find the newest message from a sender, gist included, no follow-up fetchatbridge mail search --from "newsletter@example.com" --limit 1 --snippet --prettyWas this page helpful?
Thanks for the feedback!