Skip to main content
Glama

attachments

List attachment metadata, view inline content for text/JSON/XML, or download attachment files from a specified email message.

Instructions

Inspect or retrieve email attachments. action=list (default) returns metadata for all attachments on messageId (id, name, contentType, size, isInline) — read-only. action=view returns inline content for text/JSON/XML attachments via attachmentId; binary types require download. action=download saves the attachment to disk at outputDir (default system tmpdir, auto-created) and returns the saved file path. messageId is required for all actions; attachmentId is required for view/download. Use outputVerbosity to control list field count.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
actionNoAction to perform (default: list)
messageIdYesEmail message ID (required)
attachmentIdNoAttachment ID (action=view/download, required)
outputDirNoDirectory to save file (action=download, default: system tmpdir). Auto-created if missing.
savePathNoDEPRECATED alias for `outputDir`. Will be removed in v3.8.0.
Behavior4/5

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

Annotations indicate non-read-only and non-destructive behavior. The description adds behavioral details: list is read-only, view returns inline content only for text/JSON/XML, download auto-creates outputDir, and savePath is deprecated. No contradictions.

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

Conciseness5/5

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

The description is concise and well-structured, using action-oriented breakdowns. Every sentence provides essential information without redundancy.

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

Completeness5/5

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

Given the tool's complexity (three actions, five parameters including deprecated), the description covers all key behaviors and constraints. It explains what each action returns and handles edge cases like binary vs text attachments.

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

Parameters5/5

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

Schema coverage is 100%, but the description adds significant meaning: explains action defaults, lists returned metadata fields, describes file type handling for view, notes auto-creation of outputDir, and flags deprecated savePath. This goes well beyond the schema.

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

Purpose5/5

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

The description clearly states the tool's purpose: 'Inspect or retrieve email attachments' with three specific actions (list, view, download). It distinguishes from sibling tools like read-email by focusing solely on attachments.

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 description provides explicit guidance for when to use each action (list for metadata, view for inline content, download for binary files) and states required parameters. It lacks exclusions or comparisons to alternatives but offers clear context.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/littlebearapps/outlook-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server