Skip to main content
Glama

Edit image

edit_image

Edit an existing image node with a new instruction prompt (e.g. "make the sky pink"), producing a new image node. Use redo_generation to re-roll the same inputs instead. Spends credits. Returns immediately with a new nodeId and status; poll get_generation_status until it is COMPLETED or FAILED.

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": {
      "threadId": "<threadId>",
      "nodeId": "<nodeId>",
      "prompt": "<prompt>"
    },
    "name": "edit_image"
  }
}

Input Schema

NameRequiredDescriptionDefault
nodeIdYesThe image node to edit.
promptYesEdit instruction.
qualityNoImage quality. Defaults to high.
modelKeyNoOptional model key from list_models.
threadIdYesThread containing the node.
aspectRatioNoAspect ratio. Defaults to auto.
sourceFileIdsNoOptional extra input image file ids.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Beyond the annotations, the description discloses that the call spends credits, is asynchronous, returns immediately with a new nodeId and status, and requires polling get_generation_status until COMPLETED or FAILED. It also clarifies that a new image node is produced, which is valuable behavioral context for a mutation tool.

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?

The description is three tight sentences with no filler. The core action, alternative, cost, and async polling requirement are all front-loaded and easy to scan.

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 tool with a fully described input schema and no output schema, the description supplies the missing return behavior: new nodeId and status, plus the polling requirement. It covers what an agent needs to invoke the tool and handle the response 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%, so all seven parameters are already documented in the input schema. The description adds only a prompt example and does not provide additional parameter meaning, so the baseline score is appropriate.

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?

The description states a specific verb and resource: editing an existing image node with an instruction prompt, producing a new image node. It includes a concrete example and explicitly distinguishes the tool from redo_generation, so an agent can identify its role among siblings.

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?

It explicitly says to use redo_generation instead when re-rolling the same inputs, and instructs polling get_generation_status after the immediate return. This gives clear when-to-use and follow-up guidance, including the key alternative.

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