Skip to main content
Glama

gflow_download_media

Fetch an already-generated video from Flow by media ID and write it to disk, recovering clips whose download failed after billing without spending credits.

Instructions

Fetch an already-generated VIDEO from Flow by its media ID and write it to disk. For a generation that finished and was billed but whose download failed — the clip is in the Flow project and the local catalog shows no file for it. Spends no credits: the generation was already paid for. The bytes are verified against the size Flow reports before the file is written. out_dir, if given, must resolve inside the configured output directory. Video only: an image media ID is refused immediately (exit 11) because the signed URL this needs comes from a record only a clip's route emits. See issue #877. The transfer already retries a dropped connection internally, so a failure marked retryable means wait a moment and call again — never immediately, and never in a tight loop: each call opens a browser under a per-profile lease, and a second concurrent call fails on that lease instead (exit 11).

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

Input Schema

NameRequiredDescriptionDefault
out_dirNo
profileNo
media_idYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.79.0

TDQS

A4.5/5.0
Behavior5/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 so: no credits consumed, bytes verified against Flow's reported size before writing, out_dir constrained to the configured output directory, exit code 11 on image IDs or lease contention, and internal retry on dropped connections. Concurrency and safety behavior are disclosed rather than hidden.

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 action and the recovery scenario, and nearly every sentence adds operational value. It runs long and the issue-reference and lease parenthetical could be tightened, but there is no filler.

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?

An output schema exists, so return-value explanation is correctly omitted, and the failure/exit-code behavior is well covered. The only material gap is the undefined 'profile' parameter, which matters for an agent choosing which profile to lease against.

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 coverage is 0%, so the description must compensate. It explains media_id (must be a video media ID) and out_dir (must resolve inside the configured output directory), but the 'profile' parameter is never defined — only implied by the phrase 'per-profile lease'. Two of three parameters gain real meaning; one remains opaque.

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 ('Fetch an already-generated VIDEO from Flow by its media ID and write it to disk'), plus the exact recovery scenario it exists for. An agent can distinguish it from gflow_generate_video or gflow_generate_image without opening a schema.

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?

Gives a precise when-to-use condition ('a generation that finished and was billed but whose download failed'), an exclusion (image media IDs are refused), and explicit retry guidance (wait, don't loop, one call at a time per profile). Nothing about invocation timing 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.