Skip to main content
Glama

read_attachment

Read-only

Read ONE attachment. Images are returned as images; text/JSON/CSV/Markdown files as text; PDFs as text plus page images; Word/Excel/PowerPoint/OpenDocument/EPUB as text plus embedded pictures; zip archives as a content listing + local path; other files (video, audio, huge images, legacy .doc/.xls/.ppt) are saved locally and the path returned. attachment is an attachment id or a Mewboard file URL taken from an issue or comment (/api/files/).

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": {
      "attachment": "<attachment>"
    },
    "name": "read_attachment"
  }
}

Input Schema

NameRequiredDescriptionDefault
rawNodefault false: ALSO return the original file untouched as an embedded document (up to 20 MB), for clients that read PDFs / Office files natively
attachmentYesattachment id (from list_attachments, get_issue or read_issue)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / attachment / description
      Added value: +"attachment id (from list_attachments, get_issue or read_issue)"
  2. First observed

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already cover the safety profile (readOnlyHint=true, destructiveHint=false, openWorldHint=false), and the description goes well beyond them by disclosing the per-format return contract, the fact that some files are written to disk and only a path is returned, and the 20 MB ceiling on the embedded original. This is exactly the behavioural context an agent needs to decide whether the tool is worth calling for a given file.

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?

Front-loaded with the action and scope, then a single semicolon-separated enumeration of format-to-output mappings with zero filler. The long middle sentence is dense but every clause carries distinct information an agent would otherwise have to discover by trial.

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?

With no output schema, the description carries the return-value burden and does so thoroughly, and it explains the disk-path fallback. What is missing for a 5 is failure behaviour: nothing says what happens for an invalid id, a missing permission, or an oversized request.

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 coverage is 100%, so the baseline is 3, but the description adds real meaning the schema lacks: it documents that the attachment parameter also accepts a Mewboard file URL (/api/files/<id>), whereas the schema description mentions only ids. It does not further explain the raw flag's interaction with the listed formats, so it is not a 5.

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 ("Read ONE attachment") and immediately disambiguates scope with the capitalised "ONE". It then enumerates exactly what comes back for each file family, so an agent can predict the result before calling.

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

Usage Guidelines3/5

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

The description makes the read case obvious and tells you the accepted input forms (attachment id or a Mewboard file URL from /api/files/<id>), which is practical guidance. However, it never states when not to use it or points to a specific alternative such as listing attachments first; guidance remains implied rather than explicit.

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.