Skip to main content
Glama

Get a message attachment

get_messaging_attachment
Read-onlyIdempotent

Download one attachment of a message (a photo, video, voice note, GIF, sticker or file; ids from list_messaging_messages) as base64 with its MIME type. Files over 5 MB are refused as base64: pass link: true instead to get a private link that works for 10 minutes (up to 100 MB), to open or hand to another tool. Read-only.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "account_id": "<account_id>",
      "chat_id": "<chat_id>",
      "message_id": "<message_id>",
      "attachment_id": "<attachment_id>"
    },
    "name": "get_messaging_attachment"
  }
}

Input Schema

NameRequiredDescriptionDefault
linkNo
chat_idYes
account_idYes
message_idYes
attachment_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already cover safety (readOnlyHint, idempotentHint, destructiveHint false), yet the description adds substantive behavior beyond them: a hard 5 MB base64 cap, refusal rather than truncation, a 10-minute link expiry, and a 100 MB limit in link mode. Those limits are exactly what an agent needs to avoid a failed call.

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

Conciseness4/5

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

Three dense sentences, front-loaded with the primary action and followed by the fallback mode with its thresholds. The trailing 'Read-only.' is redundant with the annotations but costs only two words.

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?

No output schema exists, and the description compensates by naming the return form (base64 plus MIME type) and, in link mode, a time-limited private link. Size limits, expiry, and id provenance are all present, leaving nothing an agent would need before calling it.

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

Parameters4/5

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

Schema description coverage is 0%, so the description must carry parameter meaning; it does explain the non-obvious 'link' flag's semantics and trade-offs and the provenance of attachment/message ids. account_id and chat_id are left to their names, which are self-evident, but their role is never stated.

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?

States a specific verb and resource ('Download one attachment of a message') and enumerates the attachment kinds covered (photo, video, voice note, GIF, sticker, file), plus the return form (base64 with MIME type). It also names where the ids come from (list_messaging_messages), so it is distinguishable from picture/media getters in the sibling set.

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?

Gives an explicit conditional: files over 5 MB are refused as base64, so pass link: true instead, and explains why (to open or hand to another tool). It also directs the agent to list_messaging_messages for ids. It does not state exclusions against other retrieval tools, but the mode-selection guidance is unusually concrete.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources