action
Manage email organization by ID. Move messages to specific folders, archive them, or classify them as spam, seen, or done.
Instructions
Sort or flag emails by ID: archive, markAsDone (= archive), moveToInbox, moveToTrash, moveToFolder (needs folder; a plain name means that folder in the email's own mailbox), markAsSpam, markAsSeen, markAsUnseen, pin, unpin, or unsubscribe (only shows the unsubscribe link or address; nothing is clicked or sent). Nothing is deleted for good; moved emails get new IDs, so list the folder again. A read-only mailbox refuses. Returns a short confirmation. To send a draft use send_email; to remove a draft use draft(delete).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"action_name": "<action_name>",
"message_ids": "<message_ids>"
},
"name": "action"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| folder | No | For moveToFolder: the folder to move them to. | |
| action_name | Yes | What to do: archive, markAsDone, moveToInbox, moveToTrash, moveToFolder, markAsSpam, markAsSeen, markAsUnseen, pin, unpin or unsubscribe. | |
| message_ids | Yes | The emails' IDs, like ['INBOX#1234']. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |