Skip to main content
Glama

Upload a file

upload_file

Upload a SMALL file inline as base64 to get a single-use upload_ref for a run file-input param. The bytes are validated (type/size) and duration-probed. Inline is capped at 64MB - use upload_from_url for video or large 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": {
      "data_base64": "<data_base64>"
    },
    "name": "upload_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
filenameNooptional original filename (advisory only; the server assigns a safe name)
data_base64Yesthe file bytes, standard base64-encoded. SMALL files only (<=64MB); use upload_from_url for video or large files

Output Schema

NameRequiredDescriptionDefault
noteYes
media_typeYes
upload_refYes
duration_minYes

Schema Changelog

Changes observed during successful MCP inspections.

No schema history has been recorded yet.

TDQS

A4.5/5.0
Behavior4/5

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

Annotations only say it is a non-read-only, non-idempotent, non-destructive, closed-world call; the description adds substantive behavior: bytes are validated for type/size and duration-probed, the reference is single-use, and there is a hard 64MB cap. It doesn't cover auth requirements or rate limits, but the added context is well beyond the annotation baseline.

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?

Three short sentences, front-loaded with the action and scope, then the validation behavior, then the routing constraint. Every sentence earns its place and nothing is repeated.

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?

An output schema exists, and the description still tells the agent what to expect back (a single-use upload_ref) and how to feed it into a run file-input param. Combined with the size cap and alternative routing, an agent has everything needed to call it correctly.

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

Parameters3/5

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

Schema description coverage is 100% and already explains both filename (advisory, server assigns safe name) and data_base64 (standard base64, <=64MB). The description restates the 64MB/base64 guidance without adding new parameter-level meaning, so the baseline 3 applies.

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 (upload) and resource (SMALL file inline as base64) plus the resulting artifact (single-use upload_ref for a run file-input param). An agent can distinguish it from upload_from_url immediately because the size/type scope is stated.

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

Usage Guidelines5/5

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

Explicitly says inline is for small files and names the alternative ('use upload_from_url for video or large files'), giving both the when-to-use and the when-to-use-something-else condition. Nothing is left to inference.

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