gmail

Fetch message by message ID

TOOL
Slug
GMAIL_FETCH_MESSAGE_BY_MESSAGE_ID
Version
20261125_00
Toolkit
gmail
Fetches a Gmail message by its message ID in the requested format and returns formatted message details. Available fields depend on the format.
format
STRING
Format for message content. 'minimal': lightest (ID, thread ID, labels only). 'metadata': headers and message metadata without body content - ideal for summarization, analysis, or when you only need subject/sender/timestamp (recommended for most use cases). 'full': complete MIME structure with 50+ headers, nested parts, and base64url-encoded body data - heavy payload, only use when you need the complete raw MIME structure for parsing attachments or body content. 'raw': entire RFC 2822 formatted message as base64url string.
Default: "full"
user_id
STRING
User's email address or 'me' for the authenticated user.
Default: "me"
message_idrequired
STRING
The Gmail API message ID (hexadecimal string, typically 15-16 characters like '19b11732c1b578fd'). Must be obtained from Gmail API responses (e.g., List Messages, Search Messages). Do NOT use email subjects, dates, sender names, or custom identifiers. Do NOT use `threadId` (use GMAIL_FETCH_MESSAGE_BY_THREAD_ID for threads), the Message-ID email header, or any fabricated value — only IDs from Gmail API list/search responses.