gmail_message_read
Fetch a single Gmail message by ID in minimal, metadata, full, or raw format. Optionally save large messages or attachments with attachments to a file and get a short YAML summary.
Instructions
Read a single Gmail message by id. format is minimal (ids/labels only), metadata (headers + snippet only), full (default; parsed MIME structure), or raw (base64url-encoded RFC 2822 source) — Gmail's own wire values verbatim. When output_file is set, writes the rendered message to that path and returns a short YAML summary instead of the inline body — use it for large messages or ones with attachments that would exceed the response size limit. Read-only. Mirrors omni-dev gmail read. Output is YAML.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| format | No | `minimal` (ids/labels only), `metadata` (headers + snippet), `full` (default; parsed MIME structure), or `raw` (base64url RFC 2822 source). Matches Gmail's own wire values verbatim. | |
| account | No | Selects a named Gmail account instead of the ambient `--account`/`OMNI_DEV_GMAIL_ACCOUNT` resolution — e.g. `work`. Omit to use the resolved default account (or the legacy single-account credentials, if no named accounts are configured). Call `gmail_account_list` to discover configured names. | |
| message_id | Yes | Gmail message id. Required. | |
| output_file | No | When set, writes the rendered message to this path and returns a short YAML summary (path/bytes/format) instead of the inline body — use for large messages/attachments that would blow past the context window. |