insync_download_attachment
Download one attachment from a secure message using its master ID and index from the attachment list; get a local file path, inline file, or signed link.
Instructions
Download one file attached to a secure message. Identify it by the message’s master id and the attachment’s position (index) from insync_list_attachments. On a local install the file is saved to disk and the path returned; on a hosted server it comes back inline (up to 10 MiB), or as a short-lived signed download link when larger. The download goes through the portal — never direct storage.
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": {
"master_id": "<master_id>",
"index": "<index>"
},
"name": "insync_download_attachment"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| index | Yes | The attachment’s 0-based position from insync_list_attachments. | |
| master_id | Yes | The message’s master id (TODOMasterId) from insync_list_messages. | |
| output_dir | No | Directory to save into (local install only; ignored on a hosted server, which returns the file inline or as a link). Defaults to INSYNC_OUTPUT_DIR or ~/Downloads; must resolve inside an allowed root. |