Skip to main content
Glama
Softeria

Microsoft 365 MCP Server

by Softeria

get-mail-message-mime

get-mail-message-mime
Read-only

Download the raw MIME source (RFC 5322 .eml content) of an Outlook email message by its message ID. Returns the complete original message including headers and encoded attachments.

Instructions

Download the raw MIME source (RFC 5322 .eml content) of an Outlook email message by its message ID. Returns the complete original message including headers and encoded attachments.

đź’ˇ TIP: Download an email message as raw RFC 5322 MIME content (.eml format). Use this when archiving an email to disk preserving all original headers, body, and inline-encoded attachments. Returns the MIME stream as text. Find the message id with list-mail-messages first.

Input Schema

NameRequiredDescriptionDefault
AcceptNoAccept header for the response representation. Defaults to "text/plain". Only set this when Graph asks for a different format — e.g. a 403 SpeakerAttributionNotAllowed on transcript content names the media type to retry with.
fileNameNoName of the file, used as the last segment of the returned resource URI when the server runs with blob output. Optional.
messageIdYesValue for the 'messageId' path segment. Pass it under the name 'messageId', not as 'id'. Use the 'id' field of the message object as returned by Microsoft Graph.
fetchAllPagesNoFollow @odata.nextLink and merge up to 100 pages into one response. Can return enormous payloads—only when the user explicitly needs a full export. Prefer a small $top first, then paginate or narrow with $filter/$search.
includeHeadersNoInclude response headers (including ETag) in the response metadata
excludeResponseNoExclude the full response body and only return success or failure indication
includeHiddenMessagesNoInclude Hidden Messages

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.166.0
    • addedInput schema / properties / fileName
      Added value: +{
      +  "description": "Name of the file, used as the last segment of the returned resource URI when the server runs with blob output. Optional.",
      +  "type": "string"
      +}
  2. Changed1 schema field changedv0.149.1
    • addedInput schema / properties / Accept
      Added value: +{
      +  "description": "Accept header for the response representation. Defaults to \"text/plain\". Only set this when Graph asks for a different format — e.g. a 403 SpeakerAttributionNotAllowed on transcript content names the media type to retry with.",
      +  "type": "string"
      +}
  3. Changed1 schema field changedv0.134.4
    • changedInput schema / properties / messageId / description
      Previous value: -"Path parameter: messageId"New value: +"Value for the 'messageId' path segment. Pass it under the name 'messageId', not as 'id'. Use the 'id' field of the message object as returned by Microsoft Graph."
  4. Changed1 schema field changedv0.131.2
    • changedInput schema / additionalProperties
      Previous value: -falseNew value: +true
  5. Addedv0.114.0
  6. Removedv0.112.2
  7. Addedv0.110.0
  8. Removedv0.108.0
  9. Addedv0.96.0

TDQS

A3.8/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly/openWorld/non-destructive, so the burden is reduced, and the description adds real behavioral value by describing the payload ('complete original message including headers and encoded attachments', 'MIME stream as text'). It omits anything about auth scopes, throttling, or large-message behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The opening sentence and the body of the TIP restate the same fact twice ('raw MIME source (RFC 5322 .eml content)' vs 'raw RFC 5322 MIME content (.eml format)'), which is visible redundancy. It is front-loaded and readable, but a sentence does not earn its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a single-resource download with no output schema and full parameter documentation, the description covers purpose, return payload, and ID sourcing. The remaining gaps (auth requirements, size/throttling caveats) are minor for this tool class.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and every parameter (Accept, fileName, messageId, fetchAllPages, includeHeaders, excludeResponse, includeHiddenMessages) is documented in-schema, so the description only needs to add color. It mentions the messageId source but nothing about the output-affecting flags, so baseline 3 is correct.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (Download) and a distinctive resource (raw MIME source / RFC 5322 .eml content) of an Outlook message, which implicitly separates it from the structured get-mail-message. It never names that sibling explicitly, so differentiation is by resource type rather than by routing language.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The TIP gives clear context ('use this when archiving an email to disk preserving all original headers, body, and inline-encoded attachments') and points the agent at list-mail-messages to obtain the ID. There is no explicit when-not or named alternative for retrieving the parsed message instead.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools