Move Email to Trash
move_to_trashMove an email to the Trash folder. Confirmation required; labels are not preserved.
Instructions
Move an email to the Trash folder. Convenience wrapper for move_email targeting Trash. Note: labels are lost when an email is moved — label copies in Labels/ folders are not preserved. Destructive: requires { confirmed: true }.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| emailId | Yes | ||
| confirmed | No | Must be true to execute. See requireDestructiveConfirm. | |
| sourceFolder | No | Folder the UID(s) live in (e.g. INBOX, Folders/Work, Labels/Foo). Strongly recommended whenever the UIDs came from a folder other than INBOX — IMAP UIDs are folder-scoped, so without this the wrong folder may be selected and the operation may silently no-op. Avoid passing 'All Mail' as the source: it is a union view of every folder, not a real location, so moves out of it can silently do nothing — pass the message's actual folder instead. Moving to the folder a message is already in is a no-op. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| success | Yes | ||
| messageId | No | ||
| reason | No |