Skip to main content
Glama

upload_task_attachment

Attach a file to a task from base64 content (fileName + mimeType + contentBase64). Max 25 MB. Any project contributor or above can attach (VIEWERs cannot). The file is stored and a TaskAttachment row is created, exactly like a human upload. For integrity, ALSO pass sizeBytes (raw byte length) and/or sha256 (hex of the raw bytes): the tool then REJECTS a truncated or garbled upload instead of silently storing a corrupt file. Strongly recommended for binaries (docx/xlsx/pdf/png), where base64 sent through the model can truncate.

Input Schema

NameRequiredDescriptionDefault
sha256NoOptional but recommended: SHA-256 of the RAW file bytes, 64-char hex. Rejected if the decoded bytes do not match (catches truncated/garbled base64).
taskIdYesThe task to attach to.
fileNameYesOriginal file name incl. extension, e.g. "chart.png".
mimeTypeYesMIME type, e.g. "image/png", "text/csv", "application/pdf".
sizeBytesNoOptional but recommended: exact byte length of the RAW file. Rejected if the decoded length differs (catches truncation).
contentBase64YesBase64-encoded file bytes. Max 25 MB decoded.
idempotencyKeyNoOptional idempotency key. Pass a stable unique value (e.g. a UUID) to make this create safe to retry: calling again with the same key within 24h - even from a new session after a reconnect - replays the original result and creates no duplicate. Org-scoped; works across conversations.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / sha256
      Added value: +{
      +  "description": "Optional but recommended: SHA-256 of the RAW file bytes, 64-char hex. Rejected if the decoded bytes do not match (catches truncated/garbled base64).",
      +  "type": "string"
      +}
    • addedInput schema / properties / sizeBytes
      Added value: +{
      +  "description": "Optional but recommended: exact byte length of the RAW file. Rejected if the decoded length differs (catches truncation).",
      +  "type": "number"
      +}
  2. Added

TDQS

A4.3/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing the 25 MB cap, the minimum permission tier (contributor or above; VIEWERs cannot), that storage mirrors a human upload and creates a TaskAttachment row, and that truncated/garbled base64 is actively REJECTED rather than silently stored. This is exactly the extra behavioral context annotations cannot carry.

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-loads the core action and limits first, then layers permissions, storage semantics, and the integrity recommendation. Every clause carries information, though the integrity guidance is slightly repetitive across description and schema.

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?

For a mutation tool with no output schema, the description is essentially complete: permissions, size limits, side effects, retry semantics (via the idempotencyKey param), and failure modes are all covered. Only the exact returned identity/format is unstated, which is minor.

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; the description earns an extra point by explaining the *purpose* of the optional sizeBytes/sha256 params (integrity enforcement, truncation detection) rather than just restating them, which adds rationale the schema field text alone does not fully convey.

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 and resource (attach a file to a task) plus the exact mechanism (base64 content with fileName + mimeType + contentBase64). The phrase 'from base64 content' implicitly distinguishes it from URL/SharePoint-based siblings, though no sibling is named directly.

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?

Clear context for use plus a concrete 'strongly recommended' when-to-do-more instruction (pass sizeBytes/sha256 for binaries). It does not explicitly route the agent to alternatives like attach_file_from_url or attach_link when those would be preferable, so it stops short of full when/when-not guidance.

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.