Skip to main content
Glama
Jira MCP Server

Jira MCP Server

by khanglvm

jira_get_attachment

Download a Jira issue attachment by attachment ID or by issue key and filename; images return inline and other files are saved to a temp path with metadata.

Instructions

Download a Jira issue attachment. Use when user wants to:

  • View an attached image (returned as a viewable image content block)

  • Fetch/download an attached file by id, or by issue + filename

Provide either attachmentId, OR both issueKey and filename to resolve it. Images are returned inline as an image block; other files are saved to a temp path and returned with metadata (plus inline base64 only when small, <256KB). Note: legacy Jira Server v2 API — bytes are fetched from the absolute content URL.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "jira_get_attachment"
  }
}

Input Schema

NameRequiredDescriptionDefault
filenameNoAttachment filename to match within the issue
issueKeyNoIssue key/ID (use with filename to resolve the attachment)
attachmentIdNoNumeric attachment id to download

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.7.1

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does well: it discloses the return modality (images inline as an image block), the side effect (other files written to a temp path), a payload threshold (<256KB base64 inlining), and the backend constraint (legacy Jira Server v2, absolute content URL). Auth/permission requirements and failure behavior for large or missing attachments are not covered.

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, then a tight bullet list of use cases and a single-parenthetical behaviors section; virtually no filler. Density around the 256KB/base64 detail is slightly awkward but each clause conveys operative behavior.

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?

No output schema exists, and the description compensates by describing return shapes for both image and file cases, including temp-path + metadata. Adequate for a 3-optional-param tool; only error/permission cases are unaddressed.

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 schema documents each field; the description still adds the key semantic the schema does not express — the mutual-exclusion/alternate-resolution contract between attachmentId and the issueKey+filename pair. It doesn't clarify filename matching semantics (exact vs. partial, ambiguity on duplicates).

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?

Opens with a specific verb+resource ("Download a Jira issue attachment") and immediately enumerates the two concrete outcomes — inline image block vs. downloaded file — which distinguishes it from the sibling jira_list_attachments, which only enumerates.

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?

Explicitly states when to use it (view an image, fetch a file by id, or by issue + filename) and gives a concrete resolution rule: either attachmentId OR both issueKey and filename. No explicit exclusion or named alternative for listing attachments, so it stops short of a 5.

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