hey_download_attachment
Download an email attachment to disk by providing the email ID and attachment ID from the email's attachments list. Saves the file locally and returns its path, filename, size, and MIME type.
Instructions
Download a single attachment from an email and save it to disk. First call hey_read_email to get the attachments[] array with IDs, filenames, and sizes, then call this tool with the attachment_id to save the file. Returns {local_path, filename, size, mime}.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| email_id | Yes | The email's topic or entry ID (same ID used with hey_read_email — topic IDs are resolved automatically) | |
| save_path | No | Optional path or directory to save into. Must be within ~/. Defaults to ~/Downloads/hey-attachments/<date>/<filename>. Trailing '/' is treated as a directory. Duplicate filenames are auto-numbered (invite-1.ics, invite-2.ics). | |
| attachment_id | Yes | The attachment ID from hey_read_email's attachments array (format: part-N, e.g. 'part-1') |