Read an attachment
read_attachmentExtract text content from email attachments inline. Supports PDFs, text, CSV, JSON, ICS, and EML files, ideal for reviewing invoices, reports, or presentations without downloading.
Instructions
Extract an attachment's TEXT inline — PDFs via pypdf, plus text/csv/json/ics/eml. Use for invoices, decks, reports. Binary/image types must use save_attachment instead.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| uid | Yes | ||
| folder | No | Default INBOX. | |
| filename | No | Which attachment (partial match OK). Optional if there is only one. | |
| uidvalidity | No | UIDVALIDITY reported alongside the uid. Pass it back so a mailbox resync cannot make this act on the wrong message. |