Skip to main content
Glama

gemini_get_result

Destructive

Retrieve a generation started with async: true or handed off by max_wait_ms. Pass the returned job_id: while running it reports status "running"; on completion it returns the normal result (image URLs/paths + meta); on failure it…

Instructions

Retrieve a generation started with async: true or handed off by max_wait_ms. Pass the returned job_id: while running it reports status "running"; on completion it returns the normal result (image URLs/paths + meta); on failure it raises the recorded error, including the case where the generation was killed before it finished. On the hosted connector job records are stored durably and survive a restart; on a local stdio server they live with the process and expire ~10 min after completion, where the output dir / .json sidecar is the fallback. A killed video/music job started with background: true is recovered from its upstream interaction when it finished there.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
job_idYesThe job_id returned by a generation tool called with async: true
output_dirNoWhere to write media recovered from a killed job (default: $GEMINI_OUTPUT_DIR or ~/Downloads/gemini-mcp)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.4.0
    • changedInput schema / properties / output_dir / description
      Previous value: -"Where to write media recovered from a killed job (default: $GEMINI_OUTPUT_DIR or cwd)"New value: +"Where to write media recovered from a killed job (default: $GEMINI_OUTPUT_DIR or ~/Downloads/gemini-mcp)"
  2. Changed1 schema field changedv2.0.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  3. Changed1 schema field changedv1.10.0
    • addedInput schema / properties / output_dir
      Added value: +{
      +  "description": "Where to write media recovered from a killed job (default: $GEMINI_OUTPUT_DIR or cwd)",
      +  "type": "string"
      +}
  4. First observedv1.2.0

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already carry the safety profile (readOnlyHint=false, destructiveHint=true, openWorldHint=true), and the description layers on substantial extra behavior: the 'running' status during polling, that failures raise the recorded error (including killed-before-finish), durability differences between hosted and local stdio, ~10 min post-completion expiry, and the output-dir/sidecar fallback. This is exactly the kind of state and lifecycle context annotations cannot express.

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?

Purpose is front-loaded in sentence one, followed by tightly packed lifecycle behavior; nearly every clause earns its place. The paragraph is dense and long, but the density reflects real complexity rather than filler.

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?

For a complex async-retrieval tool with no output schema, the description covers return shape on success ('image URLs/paths + meta'), failure semantics, persistence/expiry, and recovery of killed background jobs. An agent has everything needed to call and interpret this correctly.

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 meaningful origin context for `job_id` (it comes from an async call or a max_wait_ms handoff) beyond the schema's terse 'returned by a generation tool'. `output_dir` is left to the schema, which documents it fully.

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 precise verb+resource (retrieve a generation started with `async: true` or handed off by `max_wait_ms`) and identifies the exact handle to pass (`job_id`). It clearly positions itself as the retrieval counterpart to the generate/edit siblings, so an agent can tell it apart 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 Guidelines4/5

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

It names the triggering conditions directly: call it after a generation returned a job via `async: true` or a `max_wait_ms` handoff. It stops short of stating explicit when-not-to-use cases or naming an alternative poller, but the gating condition is unambiguous.

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