save_attachment
Save a specific email attachment to disk by specifying the message, mailbox, account, and attachment; the destination folder is created recursively before Mail is contacted.
Instructions
Save a specific attachment from a message to disk. Creates the destination directory recursively before contacting Mail.
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": {
"messageId": "<messageId>",
"mailboxName": "<mailboxName>",
"accountName": "<accountName>",
"attachmentName": "<attachmentName>"
},
"name": "save_attachment"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| savePath | No | The directory path to save the attachment to (default ~/Downloads) | ~/Downloads |
| messageId | Yes | The numeric ID of the message | |
| accountName | Yes | The name of the account containing the mailbox | |
| mailboxName | Yes | The name of the mailbox containing the message | |
| attachmentName | Yes | The name of the attachment to save |