apply_thread_action
Apply mailbox actions like archive, trash, or mark-read to all messages in a thread at once. Supports dry run and unread-only scope to preview or limit impact.
Instructions
Apply a reversible mailbox action to every message in a normalized thread at once. Use when you want to act on a full thread identified by threadId (e.g. archive or mark-read an entire conversation). Supports dryRun, unreadOnly to scope impact, and syncBefore to refresh the index first. Prefer batch_email_action when you have explicit emailIds rather than a threadId.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| threadId | Yes | Thread id from get_threads or get_actionable_threads. | |
| action | Yes | ||
| targetFolder | No | Required when action is move. | |
| unreadOnly | No | Only apply the action to unread messages in the thread. | |
| continueOnError | No | Continue applying the action after an individual failure. | |
| dryRun | No | Preview the impact without mutating the mailbox. | |
| syncBefore | No | Refresh the local mailbox index from IMAP before resolving the thread. |