Skip to main content
Glama

Handoff: Send Files to Users & Agents

fetch_shared_file

Download a file from a share url or token. Use this when you were given a Handoff url and need the bytes. Honors expiry, open limits, approval, and agent audience. anyone_with_link needs no key. An agent audience uses your API key. Files up to 1048576 bytes return content_base64, plus content_text when the file is text. Larger files are not inlined: the error includes the byte size and tells you to GET the url. A successful inline return counts as an open. A file over the inline limit does not.

Input Schema

NameRequiredDescriptionDefault
api_keyNoSecret API key from signup. Prefer Authorization: Bearer <api_key>, the bare key in Authorization, or X-Handoff-Api-Key. Pass this only when you cannot set headers. Do not write it into a file you share.
url_or_tokenYesShare url returned by create_share_link, or the 64-character token.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

No annotations are provided, so the description carries the full load and does so well: it discloses access gates (expiry, open limits, approval, agent audience), the exact inline ceiling of 1048576 bytes, what is returned on success (content_base64, plus content_text for text files), what happens on oversized files (error carrying byte size and a GET instruction), and the side effect that only a successful inline return counts as an open. That is precisely the mutation/side-effect information an agent needs.

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 purpose, then the trigger, then access rules, then the size/return contract. Every sentence carries a distinct fact (limits, return fields, error behavior, open counting) with no filler, though the density is high and would benefit from light grouping of the size/return rules.

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?

Given no output schema and no annotations, the description fully covers the return contract (base64/text fields, size threshold), the failure path for large files, the auth modes, and the open-counting side effect. An agent can call this correctly and interpret both success and the oversized-file error without further guessing.

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, but the description adds real meaning beyond the schema: it ties api_key usage to the 'agent audience' access mode and confirms url_or_token accepts either a share url or the token. It does not elaborate on the header-preferred auth detail, which the schema already covers.

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 ('Download a file') plus the accepted identifier form ('from a share url or token'), and scopes it to being handed a Handoff url and needing bytes. That reads clearly against siblings like create_share_link, list_files, and get_share_status without ambiguity.

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?

Explicit trigger: 'Use this when you were given a Handoff url and need the bytes.' It also splits the auth path by audience ('anyone_with_link needs no key. An agent audience uses your API key'), which effectively tells the caller which mode applies. It stops short of naming a sibling alternative or stating an explicit when-not-to-use case.

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.