Received, Authentication-Results, DKIM and ARC signatures) and all attachments. Use it to debug delivery or authentication, investigate a suspicious message, turn a real message into a test fixture, or hand it to another tool as an .eml file.
The tool result is the filename, size and a URL — never the message content; the agent saves the file out-of-band, e.g. with curl -o. To read a message, use get_email; for a single attachment, use download_attachment.
Parameters
Example
Call
Result
How the URL works
- The URL works exactly like the one
download_attachmentmints: an unguessable token bound server-side to the granting user’s session and this one message, no bearer needed, reusable for 24 hours. GETon the URL streams the source asmessage/rfc822with aContent-Dispositionfilename; there is no size cap.- The filename is the message’s subject (or its id when the subject is empty), with quotes, slashes and control characters replaced by
_, capped at 200 bytes (UTF-8), plus.eml. - Only single messages: to save a whole conversation, call the tool once per message id from
get_thread.
Errors
Email not found: <emailId>. Nothing was downloaded. Use search_emails or get_thread to find the message id.— no message with that id in the caller’s mailbox.