Skip to main content
Glama

editSpritesheet

Edit a previously generated spritesheet: re-prompt its underlying animation (edit_mode "prompt"), extend the frame beyond its borders ("outpaint"), or repair a bad loop ("fix_loop"). Pass the spritesheet_url you received from animateSprite, animateSpriteKeyframes, transferMotion, or an earlier edit - it must be a spritesheet you generated within the last 7 days; arbitrary external images are not accepted. Omit duration, frames, frame_size, crop and model to keep the source spritesheet's values. A prompt is required for edit_mode "prompt", optional for "outpaint", and not accepted for "fix_loop"; optionally add up to 5 reference images (URL or base64) to guide the edit. The job result is the same result shape as animateSprite (spritesheet URL, frame layout, optional GIF or individual frames). Credits are held when the job is accepted; the final charge is max(rate × produced seconds, the model's minimum charge), never more than for the duration you requested, and the difference (or everything, if the job fails or is cancelled) is refunded. Prompt edits are priced per model (credits/second × duration); "outpaint" and "fix_loop" run a lighter pipeline in which model is ignored and are billed at a flat 1 credit per second of the output duration (the source spritesheet's duration unless you pass one). Outpaint decides the extra margin itself - there is no amount parameter. The result carries the same fields as animateSprite (spritesheet_url, video_url, grid fields); audio is generated only by prompt edits on hydra, so a fix on a hydra sheet comes back without audio_url. Pass an optional request_id to tag the result for later retrieval via listGenerations (type spritesheet). Async generation job: returns {id, status} - poll getApiJob (job and credit contract: see the server instructions).

Credits: edit_mode "fix_loop" / "outpaint": flat 1 credit per second of output, no minimum, model ignored; edit_mode "prompt": per model as listed - credits/s × seconds, per model: Hydra 3/s (shortest duration 3s, so 9 credits minimum), Forge 2/s (min charge 4 credits), Forge Pixel 2/s (min charge 4 credits); see this endpoint's full pricing table in the API docs.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
requestBodyYesPayload for editing a previously generated spritesheet. edit_mode selects the operation - prompt-driven edit (default), outpaint, or loop fixing.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / requestBody / properties / model / description
      Previous value: -"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s, shortest duration 3s, so 9 credits minimum · Most capable all-around model, generates audio\n- \"forge\" (Forge): 2 credits/s, min charge 4 credits · Cost-effective for simple editing tasks\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min charge 4 credits · Best for low-res pixel art animations Default: \"forge\"."New value: +"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s, shortest duration 3s, so 9 credits minimum · Most capable all-around model, generates audio\n- \"forge\" (Forge): 2 credits/s, min charge 4 credits · Cost-effective for simple editing tasks\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min charge 4 credits · Best for low-res pixel art animations Default: \"hydra\"."
  2. Changed1 schema field changed
    • changedInput schema / properties / requestBody / properties / model / description
      Previous value: -"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s, shortest duration 3s, so 9 credits minimum · Most capable model, generates audio\n- \"forge\" (Forge): 2 credits/s, min charge 4 credits · Cost-effective for simple editing tasks\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min charge 4 credits · Best for low-res pixel art animations Default: \"forge\"."New value: +"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s, shortest duration 3s, so 9 credits minimum · Most capable all-around model, generates audio\n- \"forge\" (Forge): 2 credits/s, min charge 4 credits · Cost-effective for simple editing tasks\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min charge 4 credits · Best for low-res pixel art animations Default: \"forge\"."
  3. Changed9 schema fields changed
    • changedInput schema / properties / requestBody / properties / crop / description
      Previous value: -"Crop sprite frames to fit content. Results in smaller spritesheets but inconsistent frame sizes across different animations."New value: +"Crop sprite frames to fit content (omit to keep the source spritesheet's setting). Results in smaller spritesheets but inconsistent frame sizes across different animations."
    • changedInput schema / properties / requestBody / properties / frame_size / description
      Previous value: -"Size of each frame in pixels (width and height). 0 is for maximum resolution. Defaults to the source spritesheet's frame size. Accepted values: 32, 64, 96, 128, 192, 256, 384, 0."New value: +"Size of each frame in pixels (width and height). 0 is for maximum resolution. Omit to keep the source spritesheet's frame size. Accepted values: 32, 64, 96, 128, 192, 256, 384, 0."
    • removedInput schema / properties / requestBody / properties / frame_size / example
      Removed value: -32
    • changedInput schema / properties / requestBody / properties / frames / description
      Previous value: -"Number of frames in the output spritesheet. Defaults to the source spritesheet's frame count. Accepted values: 4, 9, 16, 25, 36, 49, 64."New value: +"Number of frames in the output spritesheet. Omit to keep the source spritesheet's frame count. Accepted values: 4, 9, 16, 25, 36, 49, 64."
    • removedInput schema / properties / requestBody / properties / frames / example
      Removed value: -4
    • removedInput schema / properties / requestBody / properties / loop / example
      Removed value: -true
    • changedInput schema / properties / requestBody / properties / model / description
      Previous value: -"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4 Default: \"forge\"."New value: +"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s, shortest duration 3s, so 9 credits minimum · Most capable model, generates audio\n- \"forge\" (Forge): 2 credits/s, min charge 4 credits · Cost-effective for simple editing tasks\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min charge 4 credits · Best for low-res pixel art animations Default: \"forge\"."
    • removedInput schema / properties / requestBody / properties / model / example
      Removed value: -"forge"
    • changedInput schema / properties / requestBody / properties / request_id / description
      Previous value: -"Optional client-provided identifier, unique per request. Re-sending the same request_id returns the existing job instead of generating again. Also usable with the results endpoint."New value: +"Optional client-provided identifier, unique per request. Re-sending the same request_id returns the existing job instead of generating again. Also usable as the request_id filter of listGenerations."
  4. Changed1 schema field changed
    • changedInput schema / properties / requestBody / properties / model / description
      Previous value: -"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s, min 4\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4 Default: \"forge\"."New value: +"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4 Default: \"forge\"."
  5. Changed3 schema fields changed
    • changedInput schema / properties / requestBody / properties / duration / description
      Previous value: -"Duration in seconds. Available values depend on the model:\n- forge: 1, 1.5, 2, 2.5, 3, 3.5, 4\n- forge-pixel: 1, 1.5, 2, 2.5, 3, 3.5, 4"New value: +"Duration in seconds. Available values depend on the model:\n- hydra: 3, 3.5, 4, 4.5, 5\n- forge: 1, 1.5, 2, 2.5, 3, 3.5, 4, 4.5, 5\n- forge-pixel: 1, 1.5, 2, 2.5, 3, 3.5, 4, 4.5, 5"
    • changedInput schema / properties / requestBody / properties / model / description
      Previous value: -"Model to use. Available models:\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4 Default: \"forge\"."New value: +"Model to use. Available models:\n- \"hydra\" (Hydra): 3 credits/s, min 4\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4 Default: \"forge\"."
    • changedInput schema / properties / requestBody / properties / model / enum
      Previous value: -[
      -  "forge",
      -  "forge-pixel"
      -]New value: +[
      +  "hydra",
      +  "forge",
      +  "forge-pixel"
      +]
  6. Changed12 schema fields changed
    • removedInput schema / properties / requestBody / properties / edit_mode / default
      Removed value: -"prompt"
    • changedInput schema / properties / requestBody / properties / edit_mode / description
      Previous value: -"Edit operation to perform."New value: +"Edit operation to perform. Default: \"prompt\"."
    • removedInput schema / properties / requestBody / properties / gif / default
      Removed value: -false
    • changedInput schema / properties / requestBody / properties / gif / description
      Previous value: -"When true, generates an animated GIF from the spritesheet and returns it in gif_url. Disabled by default to reduce response time."New value: +"When true, generates an animated GIF from the spritesheet and returns it in gif_url. Disabled by default to reduce response time. Default: false."
    • removedInput schema / properties / requestBody / properties / individual_frames / default
      Removed value: -false
    • changedInput schema / properties / requestBody / properties / individual_frames / description
      Previous value: -"When true, extracts each frame from the spritesheet as an individual image and returns the URLs in individual_frame_urls."New value: +"When true, extracts each frame from the spritesheet as an individual image and returns the URLs in individual_frame_urls. Default: false."
    • removedInput schema / properties / requestBody / properties / loop / default
      Removed value: -true
    • changedInput schema / properties / requestBody / properties / loop / description
      Previous value: -"Trim the animation at the beginning or end to create a seamless loop."New value: +"Trim the animation at the beginning or end to create a seamless loop. Default: true."
    • removedInput schema / properties / requestBody / properties / model / default
      Removed value: -"forge"
    • changedInput schema / properties / requestBody / properties / model / description
      Previous value: -"Model to use. Available models:\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4"New value: +"Model to use. Available models:\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4 Default: \"forge\"."
    • removedInput schema / properties / requestBody / properties / spritesheet_with_background / default
      Removed value: -false
    • changedInput schema / properties / requestBody / properties / spritesheet_with_background / description
      Previous value: -"When true, also returns the spritesheet with background intact (before background removal). The with-background spritesheet URL will be in spritesheet_with_background_url."New value: +"When true, also returns the spritesheet with background intact (before background removal). The with-background spritesheet URL will be in spritesheet_with_background_url. Default: false."
  7. Changed1 schema field changed
    • changedInput schema / properties / requestBody / description
      Previous value: -"Payload for editing a previously generated spritesheet. edit_mode selects the operation — prompt-driven edit (default), outpaint, or loop fixing."New value: +"Payload for editing a previously generated spritesheet. edit_mode selects the operation - prompt-driven edit (default), outpaint, or loop fixing."
  8. Changed1 schema field changed
    • changedInput schema / properties / requestBody / properties / request_id / description
      Previous value: -"Optional client-provided identifier for this request. Use this to retrieve results later via the results endpoint."New value: +"Optional client-provided identifier, unique per request. Re-sending the same request_id returns the existing job instead of generating again. Also usable with the results endpoint."
  9. Changed3 schema fields changed
    • changedInput schema / properties / requestBody / properties / duration / description
      Previous value: -"Duration in seconds. Available values depend on the model:\n- forge: 1, 1.5, 2, 2.5, 3, 3.5, 4"New value: +"Duration in seconds. Available values depend on the model:\n- forge: 1, 1.5, 2, 2.5, 3, 3.5, 4\n- forge-pixel: 1, 1.5, 2, 2.5, 3, 3.5, 4"
    • changedInput schema / properties / requestBody / properties / model / description
      Previous value: -"Model to use. Available models:\n- \"forge\" (Forge): 2 credits/s, min 4"New value: +"Model to use. Available models:\n- \"forge\" (Forge): 2 credits/s, min 4\n- \"forge-pixel\" (Forge Pixel): 2 credits/s, min 4"
    • changedInput schema / properties / requestBody / properties / model / enum
      Previous value: -[
      -  "forge"
      -]New value: +[
      +  "forge",
      +  "forge-pixel"
      +]
  10. Added

TDQS

A4.9/5.0
Behavior5/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It covers async job behavior (returns {id,status}, poll getApiJob), credit holding/refund logic, pricing per model and edit mode, output shape parity with animateSprite, audio generation constraints, and the fact that outpaint has no amount parameter. This is exceptionally transparent.

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?

The description is long but densely informative. It is structured with a clear opening statement, then progressive details about parameters, result shape, and pricing. Every sentence adds necessary information; there is no fluff. It could be slightly more concise, but the complexity of the tool justifies the length.

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 the tool's complexity, the lack of an output schema, and the absence of annotations, the description covers everything an agent needs: exact edit modes, parameter semantics, pricing rules, async job handling, credit refund behavior, and the resulting data shape. No critical piece of information is missing for correct invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Although the schema documents every field (100% coverage), the description adds critical meaning beyond the schema: which parameters to omit to inherit source values, conditional requirements per edit_mode, the impact of model on pricing and behavior (ignored for outpaint/fix_loop), and the result-shape details. It also clarifies that reference images are optional and limited to 5.

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 opens with a clear verb-resource statement ('Edit a previously generated spritesheet') and immediately enumerates the three edit modes (prompt, outpaint, fix_loop). It also differentiates from siblings by requiring a spritesheet_url generated by animateSprite, animateSpriteKeyframes, transferMotion, or an earlier edit, and explicitly excludes arbitrary external images.

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?

The description provides explicit when-to-use guidance for each edit mode, states required and optional parameters per mode (e.g., prompt is required for 'prompt', not accepted for 'fix_loop'), and instructs to omit certain parameters to preserve source values. It also warns about the 7-day validity of the source spritesheet and that external URLs are rejected, leaving no ambiguity about preconditions.

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.