Skip to main content
Glama

Set animation

clip.set_animation
Idempotent

Entrance, exit and loop presets layered over the clip transform (video://catalog/animations): e.g. in {name: "pop", duration_frames: 12}, loop {name: "float"}; a loop runs the whole clip, or only from_frame to to_frame of it (loop {name: "shake", from_frame: 30, to_frame: 45} for a jolt). null removes one. Returns the new timeline_id (edit that one next), what changed, and where each changed clip now sits.

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": {
      "clip_id": "<clip_id>",
      "timeline_id": "<timeline_id>"
    },
    "name": "clip.set_animation"
  }
}

Input Schema

NameRequiredDescriptionDefault
inNoEntrance, from the clip start
outNoExit, ending at the clip end
loopNoRepeats over the clip, or over from_frame to to_frame of it
clip_idYes
previewNoinline: image in the result; link: URI that renders on read; nonelink
timeline_idYesTimeline handle; every edit returns a new one

Output Schema

NameRequiredDescriptionDefault
parentYesThe version this edit started from
changedYesWhat the edit added, removed or modified; a clip or transition says its track and where it now sits (frames, end exclusive)
clip_idNoThe clip this edit made or acted on (each tool says which)
previewYes
clip_idsNoEvery clip this edit made or acted on, linked ones included (each tool says which)
track_idNo
warningsYes
placementsNoWhere each clip the edit moved, cropped, masked or animated shows, sequence pixels; for a title or caption, the area it can draw in, not the text itself
timeline_idYesThe new version: edit this one next (older ids stay valid)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / properties / placements / description
      Previous value: -"Where each clip the edit moved, cropped, masked or animated shows, sequence pixels"New value: +"Where each clip the edit moved, cropped, masked or animated shows, sequence pixels; for a title or caption, the area it can draw in, not the text itself"
  2. Changed5 schema fields changed
    • addedOutput schema / properties / changed / description
      Added value: +"What the edit added, removed or modified; a clip or transition says its track and where it now sits (frames, end exclusive)"
    • addedOutput schema / properties / clip_id / description
      Added value: +"The clip this edit made or acted on (each tool says which)"
    • addedOutput schema / properties / clip_ids / description
      Added value: +"Every clip this edit made or acted on, linked ones included (each tool says which)"
    • changedOutput schema / properties / parent / description
      Previous value: -"Timeline handle; every edit returns a new one"New value: +"The version this edit started from"
    • changedOutput schema / properties / timeline_id / description
      Previous value: -"Timeline handle; every edit returns a new one"New value: +"The new version: edit this one next (older ids stay valid)"
  3. Changed2 schema fields changed
    • addedOutput schema / properties / placements / items / properties / frames / items / properties / corners
      Added value: +{
      +  "description": "Corner pin: where the picture corners land, top left, top right, bottom right, bottom left",
      +  "items": {
      +    "properties": {
      +      "x": {
      +        "type": "number"
      +      },
      +      "y": {
      +        "type": "number"
      +      }
      +    },
      +    "required": [
      +      "x",
      +      "y"
      +    ],
      +    "type": "object"
      +  },
      +  "maxItems": 4,
      +  "minItems": 4,
      +  "type": "array"
      +}
    • changedOutput schema / properties / placements / items / properties / frames / items / properties / picture / description
      Previous value: -"The whole picture, before crop and mask and rotation"New value: +"The whole picture, before crop and mask and rotation; for a corner pin, the box around its corners"
  4. Changed3 schema fields changed
    • changedInput schema / properties / loop / anyOf
      Previous value: -[
      -  {
      -    "properties": {
      -      "name": {
      -        "enum": [
      -          "pulse",
      -          "sway",
      -          "shake",
      -          "float",
      -          "spin",
      -          "flicker"
      -        ],
      -        "type": "string"
      -      },
      -      "period_frames": {
      -        "exclusiveMinimum": 0,
      -        "maximum": 100000,
      -        "type": "integer"
      -      },
      -      "strength": {
      -        "default": 1,
      -        "maximum": 5,
      -        "minimum": 0,
      -        "type": "number"
      -      }
      -    },
      -    "required": [
      -      "name"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "properties": {
      +      "from_frame": {
      +        "description": "Frame from the clip start where it begins, its first repeat starting there; like keyframes it stays on that moment of the source through trims and splits. Default the clip start",
      +        "maximum": 10000000,
      +        "minimum": -10000000,
      +        "type": "integer"
      +      },
      +      "name": {
      +        "enum": [
      +          "pulse",
      +          "sway",
      +          "shake",
      +          "float",
      +          "spin",
      +          "flicker"
      +        ],
      +        "type": "string"
      +      },
      +      "period_frames": {
      +        "exclusiveMinimum": 0,
      +        "maximum": 100000,
      +        "type": "integer"
      +      },
      +      "strength": {
      +        "default": 1,
      +        "maximum": 5,
      +        "minimum": 0,
      +        "type": "number"
      +      },
      +      "to_frame": {
      +        "description": "Frame from the clip start it stops before, back at rest. Default the clip end",
      +        "maximum": 10000000,
      +        "minimum": -10000000,
      +        "type": "integer"
      +      }
      +    },
      +    "required": [
      +      "name"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / properties / loop / description
      Previous value: -"Repeats for the whole clip"New value: +"Repeats over the clip, or over from_frame to to_frame of it"
    • addedOutput schema / properties / placements
      Added value: +{
      +  "description": "Where each clip the edit moved, cropped, masked or animated shows, sequence pixels",
      +  "items": {
      +    "properties": {
      +      "clip_id": {
      +        "type": "string"
      +      },
      +      "complete": {
      +        "description": "true: values move in straight lines between entries; false: evenly sampled",
      +        "type": "boolean"
      +      },
      +      "frames": {
      +        "items": {
      +          "properties": {
      +            "frame": {
      +              "description": "From the clip start",
      +              "type": "number"
      +            },
      +            "opacity": {
      +              "type": "number"
      +            },
      +            "picture": {
      +              "description": "The whole picture, before crop and mask and rotation",
      +              "properties": {
      +                "h": {
      +                  "type": "number"
      +                },
      +                "w": {
      +                  "type": "number"
      +                },
      +                "x": {
      +                  "type": "number"
      +                },
      +                "y": {
      +                  "type": "number"
      +                }
      +              },
      +              "required": [
      +                "x",
      +                "y",
      +                "w",
      +                "h"
      +              ],
      +              "type": "object"
      +            },
      +            "rotation": {
      +              "type": "number"
      +            },
      +            "source": {
      +              "anyOf": [
      +                {
      +                  "properties": {
      +                    "h": {
      +                      "type": "number"
      +                    },
      +                    "w": {
      +                      "type": "number"
      +                    },
      +                    "x": {
      +                      "type": "number"
      +                    },
      +                    "y": {
      +                      "type": "number"
      +                    }
      +                  },
      +                  "required": [
      +                    "x",
      +                    "y",
      +                    "w",
      +                    "h"
      +                  ],
      +                  "type": "object"
      +                },
      +                {
      +                  "type": "null"
      +                }
      +              ],
      +              "description": "The part of the source that shows, source pixels"
      +            },
      +            "visible": {
      +              "anyOf": [
      +                {
      +                  "properties": {
      +                    "h": {
      +                      "type": "number"
      +                    },
      +                    "w": {
      +                      "type": "number"
      +                    },
      +                    "x": {
      +                      "type": "number"
      +                    },
      +                    "y": {
      +                      "type": "number"
      +                    }
      +                  },
      +                  "required": [
      +                    "x",
      +                    "y",
      +                    "w",
      +                    "h"
      +                  ],
      +                  "type": "object"
      +                },
      +                {
      +                  "type": "null"
      +                }
      +              ],
      +              "description": "What it shows: crop and mask applied, rotated, inside the frame; null: nothing"
      +            }
      +          },
      +          "required": [
      +            "frame",
      +            "picture",
      +            "rotation",
      +            "opacity",
      +            "visible",
      +            "source"
      +          ],
      +          "type": "object"
      +        },
      +        "type": "array"
      +      }
      +    },
      +    "required": [
      +      "clip_id",
      +      "frames",
      +      "complete"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  5. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations declare this is a non-destructive, idempotent write, and the description adds genuinely useful behavior on top: it states that a null clears the preset and that the call returns a new timeline_id which the agent must use for the next edit, plus what changed and where clips re-sit. It does not explicitly restate that setting is reversible, but 'null removes one' implicitly covers cleanup.

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 and catalog reference are front-loaded, and the inline examples are compact and load-bearing rather than decorative. The single dense sentence runs long with multiple parenthetical asides, which slightly taxes scanning, but no clause is wasted.

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?

For a six-parameter tool with an output schema and 83% schema coverage, the description covers the parts an agent must reason about: preset categories, sub-range looping, clearing with null, and the timeline_id chaining convention. The preview parameter is left entirely to the schema, which is a minor but real gap given it defaults to 'link'.

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 83%, so the schema already explains duration_frames, from_frame/to_frame and period_frames. The description adds value through worked examples ('pop' with duration_frames 12, bare loop 'float', a 'shake' jolt from frame 30 to 45) and by making clear that null is a valid value for in/out/loop, but it does not clarify strength, period_frames, or the preview enum, which rely on schema text alone.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names the specific resource (entrance, exit and loop presets) and positions it precisely relative to a sibling capability: the presets are 'layered over the clip transform', which separates it from clip.set_transform. It falls just short of a 5 because the operative verb ('set'/'apply') is implied rather than stated, though the resource and scope are unambiguous.

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?

Usage is spelled out at the slot level: 'in' is the entrance from the clip start, 'out' is the exit ending at the clip end, 'loop' repeats over the whole clip or a from_frame/to_frame sub-range, and null removes a preset. What is missing is explicit routing language against named alternatives (e.g. when to use this instead of clip.set_transform or transition.set).

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.