Skip to main content
Glama

attachment_begin

Start a chunked file upload and return an uploadId to pass to attachment_chunk, so files larger than a single message can be sent in pieces.

Instructions

Start receiving a file from the client. Returns an uploadId to pass to attachment_chunk. Uploads are chunked because a single message has transport ceilings; 8 MiB of raw bytes (about 10.7 MiB base64) per chunk is comfortable.

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

Input Schema

NameRequiredDescriptionDefault
mimeNoMIME type, if the client knows it.
nameYesOriginal filename as the user's picker gave it. This is DISPLAY metadata -- it is reported back verbatim by commit, so do not sanitise it on the way in.
sizeNoTotal bytes, when known.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior3/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 contribute genuine behavior: why uploads are chunked (transport ceilings) and the 8 MiB raw / ~10.7 MiB base64 chunk ceiling. However it omits operational traits an agent needs for a stateful upload: whether the upload session expires, whether stale uploadIds must be discarded, and any auth or concurrency constraints.

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?

Two sentences, front-loaded with the action and the return value, then the transport rationale as supporting context. Nothing is redundant and no sentence could be dropped without losing information.

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?

For a three-parameter, mutation-adjacent start tool with no output schema, the description covers the return value (uploadId), the immediate next call, and the chunk sizing constraint that governs the whole flow. What is missing is lifecycle detail on the created upload session (expiry, abandonment, error cases), which is the notable remaining gap given there are no annotations to lean on.

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%, so all three parameters (name, mime, size) are already documented in the schema, including the useful note that name is display metadata reported verbatim by commit. The description adds no parameter-level meaning beyond that, which is the baseline case when the schema does the heavy lifting.

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 ('Start receiving a file from the client') and immediately distinguishes the step by naming the follow-up sibling attachment_chunk. An agent can tell this apart from attachment_commit, attachment_chunk and the read-side siblings without opening any schema.

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?

The workflow is made explicit: call this first, take the returned uploadId and pass it to attachment_chunk. That is real routing guidance rather than implied usage. It stops short of exclusions, e.g. it never says what to do if an upload is abandoned or how this differs from attachment_commit/attachment_read.

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