Skip to main content
Glama

items-upload_file

items-upload_file

Upload a file to a case by passing base64-encoded content and filename. Attach it to a note or task with an optional parent ID.

Instructions

Uploads a local file to a case in one MCP call. The agent reads the file from the local filesystem (e.g., via Read or base64 < file), passes the encoded bytes, and the server decodes and stores them in FileStore as a real binary file (identical to POST /api/upload). Best for screenshots and small/medium files — base64 inflates payload ~33%, so for files larger than a few MB use the curl path to /api/upload instead. Use parent_id to attach the file as a child of a note or task in one call.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
case_idYesCase ID (@rid format)
content_base64YesFile content as a base64-encoded string
filenameYesOriginal filename including extension (e.g., 'screenshot.png')
mime_typeNoOptional MIME type override (auto-detected from extension if omitted)
nameNoOptional display name (defaults to filename)
parent_idNoOptional parent item ID (@rid) — attaches the file as a child of a note, task, or folder
Behavior5/5

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

With no annotations, the description fully carries the burden. It explains the read-encode-decode-store process, compares to POST /api/upload, and discusses base64 payload inflation. This gives the agent a thorough understanding of the tool's behavior and limitations.

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?

Four sentences, front-loaded with purpose, no redundant information. Every sentence adds value: purpose, process, constraint, and optional feature.

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?

Covers input parameters, process, and constraints. Missing details about return value or error handling, but for a file upload tool with good parameter descriptions, it is adequately complete. No output schema required.

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 baseline is 3. The description adds value by explaining that content_base64 is the encoded file, parent_id attaches as child, and mime_type auto-detects. It enriches the semantic understanding 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 'Uploads a local file to a case in one MCP call,' specifying the action (upload), resource (file to case), and the mechanism (agent reads file, passes encoded bytes, server decodes). It distinguishes from alternative methods (curl for large files), making the purpose unambiguous.

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?

Provides explicit guidance: best for screenshots and small/medium files, warns about base64 inflation (~33%), recommends curl for larger files, and mentions using parent_id for attachment. Does not explicitly exclude other scenarios, but the context is clear and helpful.

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/mstang/casemgr-mcp'

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