creator-mcp

v0.2.3
@lottiefiles/creator-mcp Checked 3 days ago Published 1 month ago

MCP server for LottieFiles Creator

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

read_scene

Read the current Creator scene. Returns scene dimensions, framerate, duration, all layers, current selection, render order, visual bounds, scene-center deltas, and clipping/off-canvas flags. Call this once at the start of most turns to understand what's on the canvas. Use each layer's `ordering` and `layout` blocks to avoid wrong-layer, wrong-stack, and off-canvas mistakes. A layer may also carry an `occlusion` block (`likely_hidden: true`, `occluded_by: [ids]`) when an opaque layer in front of it covers it — treat that layer as INVISIBLE on the canvas (e.g. a label buried behind a button fi…

apply_keyframes

Add keyframes to ONE animatable property on ONE layer. This is the preferred tool for simple single-property animations (rotate, fade, slide, pulse, recolor). If you need to animate multiple properties on the same layer, plan separate tool calls in the order they should be applied; Creator serializes native tool execution through the dispatcher. **POLISH TURNS (snappier / smoother / tighter / less bouncy / fix timing / more premium / etc.) — call `read_keyframes` FIRST on every animated layer in scope BEFORE calling this tool.** The conversation history's view of existing keyframes is stale…

ParameterTypeDescription
keyframes *array
layer_id *stringLayer id from `read_scene` (e.g. 'qttDVXo7OQ').
property *string
clear_firstbooleanIf true, clear existing keyframes on this property before adding. Default false.

apply_motion_preset

Apply a Motion Preset from the user's Motion System to a single layer. A preset is a multi-property keyframe collection for supported layer transform properties (position + scale + rotation + opacity, any subset) with a duration. This bakes the preset's keyframes into the layer — there's NO link semantics, future preset edits don't propagate. Preset trimPath data is not currently baked by the native gateway; use `apply_keyframes` on `trim_start`/`trim_end` for stroke reveals. Use this when the user names a preset (e.g. 'apply our brand entrance to this card'). For single-property motion (ju…

ParameterTypeDescription
layer_id *stringTarget layer.
preset_id *stringPreset id from `list_motion_system_items({ type: 'motion_presets' })`.
modestringDefault 'replace' (clears existing keyframes on the preset's target properties first). 'add' preserves existing keyframes and inserts the preset's absolute values shifted to the current playhead.

apply_motion_path

Make a layer's position FOLLOW a path shape — Creator's 'apply path to motion' feature. Each vertex of the path becomes a position keyframe and the path's bezier in/out tangents become the keyframe's spatial tangents, so the layer curves smoothly along the path instead of jumping in straight-line segments between waypoints. **Reach for this when the user wants a custom curving motion** — 'have the ball arc over the obstacle', 'make the icon trace an S-curve', 'follow this road', 'orbit around the logo', 'fly across the scene'. The path is a regular path shape created via `create_shape`/`b…

ParameterTypeDescription
end_frame *numberFrame for the last vertex. Must be > start_frame.
path_layer_id *stringPath layer id from `read_scene`. A shape layer wrapping exactly one path shape, or a path shape directly. Multi-path layers are ambiguous and rejected.
start_frame *numberFrame for the first vertex.
target_layer_id *stringLayer whose position will follow the path.
auto_orientbooleanWhen true, keyframe rotation so the target faces the direction of travel. Default false.
constant_speedbooleanWhen true (default), space keyframes by arc length so the motion is uniform along the path. When false, space evenly in time (long segments will appear to speed up).
remove_sourcebooleanWhen true (default), delete the source path layer after applying. Set to false to keep the path visible.

set_anchor_point

Move a layer's ANCHOR POINT — the pivot for rotation and scale. Mirrors Creator's property-panel 9-grid anchor selector. Compensates the layer's position so the visible rendering DOES NOT JUMP when the anchor moves; if position is animated, every position keyframe shifts together so the motion shape is preserved. **Reach for this BEFORE animating rotation or scale** whenever the verb implies a specific pivot: - 'door opens / swings from the left hinge' → `direction: 'left'`, then animate rotation - 'drawer slides down from the top' / 'curtain drops' → `direction: 'top'`, then animate sc…

ParameterTypeDescription
layer_id *stringLayer whose anchor to move. Must have transform.anchorPoint.
directionstring9-grid preset. Mapped to the corresponding corner / edge / midpoint of the layer's local bounding box. Pass this OR `position`, not both.
positionobjectCustom anchor in layer-local pixels. Pass this OR `direction`, not both.

create_shape

**BEFORE CALLING: check the creation order.** New layers are inserted at the TOP of the render stack. If this turn creates multiple layers, emit the calls in BOTTOM→TOP order — the background FIRST, the foreground LAST. A card background MUST be created BEFORE its content; a sky rectangle MUST be created BEFORE the logo on it. (Reorder APIs exist if needed via `reorder_layer`, but planning the order is cheaper.) Create a new shape layer with a vector primitive. Supports rectangle, ellipse, polygon (regular N-gon), star, and arbitrary bezier path. By default it gets a solid fill (`fill_col…

ParameterTypeDescription
shape *string
fillstringOptional named Flat-UI accent, e.g. 'peter-river','carrot','emerald','sun-flower','alizarin','belize-hole','pomegranate'. ONE chromatic hue; purple/violet never (unknown names are ignored). Wins over…
fill_colorSolid fill RGB (0-255), OR the string 'none' for a stroke-only shape. Pass a real object like {r:66,g:133,b:244}; JSON strings are accepted only for compatibility. Omit for a default gray fill.
fill_scenebooleanSizes + positions the rectangle to cover the entire active scene. **Use ONLY when an exported full-scene background is actually required** (gradient design, unsolvable contrast, explicit user ask). Fo…
inner_radiusnumberStar only: radius to the inner points.
inner_roundnessnumberStar only: rounds the inner corners. Default 0.
namestring
opacitynumber
outer_radiusnumberPolygon: radius to the vertices. Star: radius to the outer points.
outer_roundnessnumberPolygon/star: rounds the outer corners (0 = sharp, 100 = fully rounded). Default 0.
pathobjectPath only: raw bezier points (vertex + tangents relative to vertex) with open/closed flag. Use closed:false for lines/curves; open paths default to stroke/no fill because fill-only open paths do not d…
pointsnumberPolygon/star: number of points/sides. 3 = triangle, 5 = pentagon or 5-pointed star. Default 5.
positionobject
radius_tokenstringRectangle only: corner radius from the design scale — xs=2 sm=4 md=8 lg=24, `pill`=stadium (half the shorter side). Wins over numeric `roundness`. Prefer this over a raw `roundness` so cards/buttons…
rolestringOptional. Resolves a DEFAULT slate fill when `fill_color` is OMITTED. 'accent' = slate-700 NEUTRAL default (NOT a chromatic hue — pass `fill` for chroma). An explicit `fill_color` always wins; ignor…
rotationnumberDegrees, default 0.
roundnessnumberRectangle only: corner radius in pixels (0 = sharp, larger = more rounded). Strongly recommended for any 'card', 'panel', 'sheet', 'modal', 'button' rectangle — sharp 90° corners read as wireframe,…
scaleobjectPercentage; default { x: 100, y: 100 }.
sizeobjectRequired for rectangle/ellipse unless `fill_scene: true`. Ignored for polygon/star/path (those use their own sizing params).
strokeobjectOptional inline stroke (outline). Combine with `fill_color: 'none'` for a ring/outline in ONE call, or with a fill for a filled-and-outlined shape.

bend_shape

Bend one edge of an existing rectangle/square-like SHAPE_LAYER by replacing its first shape with a 5-point bezier path, OR animate an already-bent path by keyframing its pathData. Use this for prompts like 'bend the top of this square', 'curve the bottom edge', 'bow the card inward', or 'animate the bend'. Static bend: pass `amount` (typical 8-24px). Animated bend: pass `animate: true`; the tool reuses an existing bent PATH shape when present, infers its bounds, and writes pathData keyframes directly. Do NOT fake bend animation with scale keyframes. `tangent_width` controls how broad/smooth t…

ParameterTypeDescription
edge *stringWhich edge to bend inward.
layer_id *string
amountnumberBend amount in pixels. Positive values bend the edge inward toward the center. Default 16.
amplitudenumberAnimated bend peak in pixels. Defaults to `amount`, then 20.
animatebooleanWhen true, animates the bend by keyframing pathData. Use for "animate the bend", "pulse the bend", or "make it flex".
clear_firstbooleanWhen animating, clears existing pathData keyframes first. Default true.
decaynumberSpring decay per oscillation. Default 0.6.
frames_per_oscillationnumberTiming density for each oscillation. Default 4.
oscillationsnumberOscillations per pulse. Default 5.
preserve_fillbooleanWhen true, preserves the first SOLID fill by recreating it after the path so the bent path renders with the same color. Default true.
repeat_countnumberNumber of spring pulses to create. For a repeated 5s loop at 30fps, use 3 pulses with repeat_interval_frames 50 or 5 pulses with interval 30.
repeat_interval_framesnumberFrame spacing between repeated spring pulses. Default 30.
replace_originalbooleanWhen true, removes the first existing shape before creating the bent path. Default true.
sizeobjectFallback size for the original rectangle if it can't be inferred from the first shape.
start_framenumberFirst animation pulse start frame. Default 0.
tangent_widthnumberBezier tangent width in layer-local pixels. Larger values make a broader/smoother bow. Default 60.

create_text

**BEFORE CALLING: check the creation order.** New text layers are inserted at the TOP of the render stack. If this turn also creates a card / background / banner, create the background FIRST and THIS text layer LAST — otherwise the text will land beneath the background. (Reorder APIs exist if needed via `reorder_layer`, but planning the order is cheaper.) Create a new native TEXT_LAYER with the given content and optional native TextDocument style. Returns `layer_id` so you can immediately animate it with `apply_keyframes` (opacity for fade-in, position for slide, scale for pop). For letter-…

ParameterTypeDescription
text *stringThe text content to display.
alignstringHorizontal alignment. `left` / `center` / `right` are plain alignment — each line is placed at that edge and nothing is stretched; these are what you want for headlines, labels and single-line text.…
center_in_scenebooleanIf true, place the rendered text bounding box at scene center using rendered bounds when available and measured text bounds as fallback. Use whenever the user asks for centered text; overrides `positi…
fillstringOptional named Flat-UI accent (kebab, e.g. 'peter-river'). Wins over `role`; only applies when `fill_color` is omitted; purple/unknown ignored. **Name collision: `fill` here is a palette NAME STRING â…
fill_color
font_familystringFont family, e.g. Inter.
font_namestringDirect Creator font asset name, e.g. "Inter Bold". Prefer font_family/font_variant when known.
font_sizenumber
font_variantstringFont variant/style, e.g. Bold.
line_heightnumber
namestringLayer name. Without one, the layer is named after `text` (numbered when a sibling has that name) and follows later `set_text` calls until it is renamed.
opacitynumber
positionobjectVisual center target for the text bounds. Ignored if center_in_scene is true.
rolestringOptional. Resolves a DEFAULT slate text fill when `fill_color` is omitted: heading=slate-900, body=slate-600, caption=slate-500. Sets COLOR ONLY (not size/line-height — use `font_size` / create_text…
rotationnumberDegrees, default 0.
scaleobjectPERCENTAGE, default `{ x: 100, y: 100 }` — matching AE / Creator semantics, NOT a 0–1 multiplier. `{ x: 1, y: 1 }` renders the text at ONE PERCENT of its size (an invisible speck), which is the cl…
stroke_color
stroke_widthnumber
text_capsstring
trackingnumberNative text tracking / letter spacing value. For "slight tracking", use 2-8. Avoid 20+ unless the user explicitly asks for very wide spacing.
wrap_widthnumberMax rendered width (in scene pixels) before text wraps to a new line. **Use ONLY when the text needs to wrap inside a fixed-width column** (e.g. paragraph copy, multi-line body text in a card). Omit f…

create_text_group

**USE THIS for any prompt that asks for 2+ text layers as a coherent composition** — hero slides, title+subtitle+footer, label+value pairs, multi-line callouts. One tool call lays out the whole group with sensible typography defaults and centers it on the scene as a unit. Why this exists: composing the same layout out of `create_text` + `align_layer` typically takes 6-15 tool calls (create each, align each, shrink if clipped, re-center). This tool runs the equivalent sequence server-side with one response, picking Cal Sans (the project default), role-derived sizes (H2 = ½ × H1), and the c…

ParameterTypeDescription
items *array
gapnumberPixels of vertical space between items. Defaults to ~50% of the H1 size (e.g. 22px on a 512 canvas).
layoutstringDefault and only option for now. More layouts will land as needed.
scene_anchorWhere the group's center lands. 'center' (default) puts the group at scene center. 'top-center' / 'bottom-center' bias to upper/lower third. `{x, y}` for arbitrary.

create_button

Build a button / pill / chip in ONE call. Composes a rounded fill panel + a CENTERED label + optical padding (vertical < horizontal) + a WCAG-AA contrast-correct label color + correct z-order (label in front) + an auto elevation, grouped into one animatable precomp. **Use this instead of hand-rolling `create_shape` + `create_text` + `reorder_layer`** for any button/pill/chip/CTA/tag. It can't get the z-order, padding, radius, or label contrast wrong, and you never have to reference a layer id you're still creating. `variant`: `button` (md/8 radius), `pill` (stadium — auto-clamps to half th…

ParameterTypeDescription
label *stringThe button text.
elevationShadow tier. Omit for auto-resting on a filled button; false/'none' suppresses.
fillstringOptional named Flat-UI accent, e.g. 'peter-river','emerald','sun-flower'. Only used when `fill_color` is omitted. Do not pass RGB here.
fill_colorSolid fill RGB object (default Slate-700), OR 'none' for an outlined button. Pass a real object like {r:6,g:182,b:212}; JSON strings are accepted only for compatibility.
font_sizenumberLabel size. Default 20 (14 for chip).
font_variantstringDefault 'Regular'.
groupbooleanGroup panel + label into one precomp. Default true.
label_colorOverride the auto-picked label color (kept only if it passes AA).
namestring
originWhere the button centers. Default 'scene-center'.
paddingOverride the optical padding (keep vertical < horizontal).
radius_tokenstringOverride the variant corner radius. pill = stadium clamp.
strokeobjectOutline. Required when `fill_color: 'none'`.
variantstringDefault 'button'. 'pill' = stadium corners; 'chip' = smaller.

create_reference_board

Build a whole multi-section REFERENCE BOARD in ONE call — a title plus a stack of labelled sections. **This is the right tool for "illustrate my motion system", a style guide, a color-palette board, a token/spec sheet, an icon or feature list, or any reference overview.** Do NOT hand-place a board out of many `create_text` + `create_shape` calls — that scatters off-center, drops sections off-grid, and floats the title in the middle (the #1 failure mode). This composes everything into ONE `layout` column (origin scene-center), so the board is centered, evenly gapped, edge-aligned, safe-zone…

ParameterTypeDescription
sections *arrayThe board sections, top to bottom. Each needs a content kind.
alignstringDefault 'start' (content left-flush, whole block centered).
captionstringOptional footer caption.
gapnumberGap between sections. Default 40.
groupbooleanGroup the whole board into one precomp. Default false.
originWhere the board centers. Default 'scene-center'.
subtitlestringOptional subtitle under the title.
titlestringBoard title, shown large at the top.

set_text

Update the text content of an existing TEXT_LAYER using native TextDocument APIs. A layer named after its text is renamed to the new text, unless a state machine interaction targets its name. By default the tool preserves the current visual bounds center after the text changes, so the layer does not jump when the new string is wider or narrower. **RESPONSE — verify before saying "Done":** returns `visual_center`, `visual_bounds`, and `scene_fit`. A string swap can push the new bounds past the canvas edge — check `scene_fit.clipped` / `scene_fit.overflow.{left,right,top,bottom}` after EVER…

ParameterTypeDescription
layer_id *string
text *string
recenterbooleanDefaults true. Keeps the previous visual bounds center after changing text.

set_text_style

Update native TextDocument styling on an existing TEXT_LAYER. Supports font size, font family/variant or font name, fill color, stroke color/width, alignment, line height, tracking, caps, and `wrap_width` (for paragraph copy that needs to wrap inside a fixed-width column). Setting `wrap_width` without an explicit `align` uses center alignment; pass `align: "left"` to keep a conventional paragraph column. Pass `fill_color: null` to clear the fill override, `stroke_color: null` to clear the stroke color override, and `stroke_width: null` to clear the stroke width override. By default it preserve…

ParameterTypeDescription
layer_id *string
alignstringHorizontal alignment. `left` / `center` / `right` are plain alignment — each line is placed at that edge and nothing is stretched; these are what you want for headlines, labels and single-line text.…
fill_color
font_familystring
font_namestringDirect Creator font asset name, e.g. "Inter Bold". Prefer font_family/font_variant when known.
font_sizenumber
font_variantstring
line_heightnumber
recenterbooleanDefaults true. Keeps the previous visual bounds center after changing style.
stroke_color
stroke_width
text_capsstring
trackingnumberNative text tracking / letter spacing value. For "slight tracking", use 2-8. Avoid 20+ unless the user explicitly asks for very wide spacing.
wrap_widthnumberMax rendered width (in scene pixels) before text wraps. **Use ONLY when the text needs to wrap inside a fixed-width column.** Omit for headlines, subtitles, footers, and any single-line text. Internal…

measure_text_units

Return per-line, per-word, and per-character bounds for an existing text layer. Uses the same canvas.measureText pipeline that powers `read_scene`'s `measured_bounds`, but exposes the cumulative pen position per glyph so per-character recipes can place each new layer at the source's exact kerning — no `bounds.width / char_count` approximation. When to call (REQUIRED before splitting): - Any per-character recipe (typewriter, per-character-rise, bottom-up-letters, top-down-letters, kinetic-center-build, short-slide-*). - Any per-word recipe where each word needs its own layer (per-word-crossf…

ParameterTypeDescription
layer_id *stringText layer id from `read_scene`. Pass the source phrase's layer id before splitting it.
granularitystringWhich units to return. Default 'all' (words + characters per line). Use 'character' for per-character recipes, 'word' for per-word, 'line' for per-line.

split_text

Split a text layer into one new text layer per character, word, or line at exact `measure_text_units` positions. Copies the source font/style to every new layer and (by default) deletes the source so the new layers don't render on top of the original. Replaces the manual `measure_text_units` → `delete_layer` → loop-of-create_text dance. When to call: - Any per-character recipe (typewriter, per-character-rise, bottom-up-letters, top-down-letters) — pass `granularity: 'character'`. - Any per-word recipe (per-word-crossfade, spring-scale-in) — pass `granularity: 'word'`. - Any per-line r…

ParameterTypeDescription
granularity *string'character' = one layer per glyph, 'word' = one layer per /\S+/ run, 'line' = one layer per \n-separated row.
layer_id *stringSource text layer id (from `read_scene`).
animateobjectApply a staggered entrance to the split units IN ONE CALL — strongly preferred over a manual per-letter `apply_keyframes` loop (which is ≈3N calls and easy to mis-center). The stagger reads each u…
copy_stylebooleanCopy the source's font, tracking, fill, stroke, alignment, line_height, and caps to every new layer. Default true. Set false only when each unit needs a different style.
delete_sourcebooleanDelete the source layer after splitting. Default true. Set false only when you need both source and split copies in the scene at the same time.

stagger_layers

Apply a staggered entrance to MANY existing layers in ONE call — each layer enters slightly after the previous, reading as one cascading sequence. This replaces the per-layer `set_anchor_point` + 2×`apply_keyframes` loop (≈3N calls) that the agent used to hand-roll for letter cascades, card grids, list reveals, etc. The stagger reads EACH layer's own resting position, so it's safe on already-distinct layers (split-text letters at their kerned spots, grid cards at their slots) — unlike `copy_animation`, which would copy one layer's absolute position onto all the others and collapse them…

ParameterTypeDescription
layer_ids *arrayLayers to stagger, in cascade order (first enters first).
directionstringSlide-in direction (preset 'slide' only). Default 'up'.
distancenumberSlide travel in px (preset 'slide' only). Default 40.
duration_framesnumberEach layer's entrance duration. Default 16.
easingstringEasing preset NAME as a bare string, e.g. 'gentle-out' — NOT the `{ type: 'PRESET', name }` object that `apply_keyframes` takes, and no LINEAR / CUBIC_BEZIER here. Default 'gentle-out'. To re-ease a…
fadebooleanFade opacity 0→100 alongside. Default true.
per_item_delay_framesnumberFrames between each layer's start. If the user gives a literal number ("10-frame stagger") use it verbatim. Default 4.
presetstring'slide' = move in + fade (default), 'scale' = grow from 0 (centers each anchor), 'fade' = opacity only.
start_framenumberFrame the first layer starts. Default 0.

animate_entrance

Animate ONE layer's entrance (a settle-into-place reveal) WITHOUT supplying any position coordinate. The tool reads the layer's OWN resting transform and animates relative to it, so the layer settles back EXACTLY where it rests. **This is the SAFE path for a TEXT reveal.** A text layer's `position` keyframes live in RAW transform (baseline / box-origin) space — which is DIFFERENT from `visual_center` and from the `position` arg you passed to `create_text` (that arg is the visual center). Reusing the visual center as a `position` keyframe value silently throws the text off-canvas (the cause…

ParameterTypeDescription
layer_id *stringThe layer to animate in.
directionstringSlide-in direction for rise/rise-fade. Default 'up'.
distancenumberSlide travel in px for rise/rise-fade. Default 40.
easingstringEasing preset NAME as a bare string, e.g. 'gentle-out' — NOT the `{ type: 'PRESET', name }` object that `apply_keyframes` takes. Default 'gentle-out'. To re-ease afterwards use `retime_keyframes({ o…
framesnumberEntrance duration in frames. Default 16.
start_framenumberFrame the entrance starts (holds offset/invisible before). Default 0.
stylestring'rise-fade' = slide up + fade (default), 'rise' = slide only, 'fade' = opacity only, 'scale' = grow from centered anchor + fade.

list_fonts

List font families available in the active project — Creator's curated presets, Google Fonts, OS-installed local fonts (when permission has been granted), and project-uploaded font assets. Use this when the user names a specific font you're not sure is loaded ('animate "Acme" in Bebas Neue letter-by-letter'), or when you need to recommend a fallback that's actually present. When to call: - User names a font you're not certain exists in this project (brand fonts, niche typefaces). - You're about to call `create_text` / `set_text_style` with a specific `font_name` and want to verify the famil…

ParameterTypeDescription
sourcestringFilter the result to one font origin. 'all' (default) returns every loaded family.

center_layer

Reposition an EXISTING layer so its visual center lands on a SPECIFIC target point (e.g. a callout at `(180, 380)`, or anywhere off-center). For text, this uses rendered bounds when Creator has them and measured text bounds otherwise, so it avoids the top-left/origin centering bug. **For aligning to scene center (the common case), use `align_layer({ direction: 'horizontal-center' })` + `align_layer({ direction: 'vertical-center' })` instead — that's Creator's own alignment path and the more reliable default.** Use `center_layer` only when the target is not the scene center. For a brand-new…

ParameterTypeDescription
layer_id *string
targetobjectTarget center point. Defaults to scene center when omitted.

set_fill

Set (or replace) the fill on a SHAPE_LAYER. Supports SOLID colors AND linear/radial gradients. **Picking a default color (no brand defined, no mood specified):** check `list_slots` and `list_motion_system_items` first. If both empty and the user didn't name a color, stay MONOCHROME — Slate-700 `{r:51,g:65,b:85}` for accents / buttons, Slate-50 `{r:248,g:250,b:252}` for surfaces. Indigo / purple / pink / teal as defaults read as AI slop. When the user DOES name a color or mood, pick from the Flat UI defo palette (see `motion-aesthetics` skill) instead of inventing Tailwind values. ONE chroma…

ParameterTypeDescription
fill *The paint to apply, as an OBJECT: `{ type: 'SOLID', color: {r,g,b} }`, `{ type: 'GRADIENT_LINEAR', stops: [...] }`, or `{ type: 'GRADIENT_RADIAL', stops: [...] }`. **Not the same `fill` as `create_sha…
layer_id *stringLayer id from `read_scene`, or a `group_id` from its `nested_paints` (or a selected group id) to paint just that group.
replace_firstbooleanIf true (default), remove fills[0] before adding. If false, append.

set_stroke

Set (or replace) the stroke on a SHAPE_LAYER. Mirror of `set_fill` but for outlines/lines, plus a `width` (pixels). Supports SOLID and gradient strokes (same stop structure as set_fill). Defaults to replacing `strokes[0]`. Pass `replace_first: false` to append. After the stroke exists, you can animate its width over time with `apply_keyframes` property 'stroke_width'. On a layer whose paths all sit inside groups (see `read_scene` → `nested_paints`), the groups' own strokes are updated in place, same as `set_fill`; pass a `group_id` as `layer_id` to update one group.

ParameterTypeDescription
fill *The stroke's paint, as an OBJECT — `{ type: 'SOLID', color: {r,g,b} }` or a gradient, same shape as `set_fill.fill`. Named `fill` because a stroke is painted with a fill; it is NOT the palette NAME…
layer_id *stringLayer id from `read_scene`, or a `group_id` from its `nested_paints` (or a selected group id) to paint just that group.
width *numberStroke width in pixels.
replace_firstbooleanIf true (default), replace strokes[0]; else append.

animate_paint

Keyframe fill or stroke paint directly. Use this for true animated gradients: create/ensure a gradient fill or stroke, then animate `gradient_stops`, `gradient_start`, `gradient_end`, or radial highlight properties. Use `solid_color` for a SOLID paint color cycle. This is the preferred tool for prompts like 'add animated gradients', 'make the gradient sweep', or 'animate the stroke colors'.

ParameterTypeDescription
keyframes *array
layer_id *stringLayer id from `read_scene`, or a `group_id` from its `nested_paints` (or a selected group id) to animate just that group.
property *string
target *string
clear_firstboolean
ensure
paint_indexinteger

animate_property

Keyframe extended properties not covered by apply_keyframes, including paint opacity/color, gradient handles, shape geometry, mask path/opacity, text animator colors, and scene-layer time mapping. Use this when the property is explicitly named and a typed high-level tool is not a better fit. **Which sub-object gets animated** — the `property` picks a list on the layer, and `target_id`/`target_index` pick one entry in that list. **Both are optional and default to the FIRST entry**, which is what you want on the common single-mask / single-fill / single-shape layer: - `mask_path`, `mask_opaci…

ParameterTypeDescription
keyframes *array
layer_id *string
property *string
clear_firstbooleanClear existing keyframes on the resolved property first. **Defaults to TRUE here** (unlike `apply_keyframes`, which defaults to false). Pass false to merge.
target_idstringExact id of the sub-object to animate — a `mask_id` from `create_mask`, a `shape_id` from `add_shape_to_layer`, or a fill/stroke id. Wins over `target_index`. Omit it (and `target_index`) to animate…
target_indexnumberZero-based index into the list the `property` selects (masks / shapes / fills / strokes / text animators). **Defaults to 0 — the first entry.** Ignored when `target_id` is given. Use this only when…

set_blend_mode

Set a layer's blend mode. One of: normal, multiply, screen, overlay, darken, lighten, color-dodge, color-burn, hard-light, soft-light, difference, exclusion, hue, saturation, color, luminosity. Common uses: - `screen` → glow / shine / highlight layers (fades to black = invisible) - `multiply` → shadows / darkening overlays - `overlay` / `soft-light` → color tinting - `difference` → inverting effects

ParameterTypeDescription
blend_mode *string
layer_id *string

add_drop_shadow

Attach a native Drop Shadow effect to a layer. Renders in Creator's preview and in dotlottie-web (the default Lottie player). lottie-web silently drops it. Use for: card/panel shadows, button lift, soft glow (distance=0 + large blur), text shadow. **Replaces the legacy 'duplicate dark rectangle behind the card' workaround** — call this instead. **Prefer `elevation` for UI surfaces.** Pass `elevation:'resting'|'raised'|'floating'` to attach a tuned TWO-shadow stack (a tight contact shadow + a soft ambient one, slate-tinted) in one call — this reads far more premium than a single hand-tune…

ParameterTypeDescription
layer_id *string
anglenumber
blurnumber
colorobject
distancenumber
elevationstringAttach a tuned two-shadow elevation stack instead of a single shadow. Overrides color/opacity/angle/distance/blur. resting = card at rest, raised = hover, floating = modal.
namestringOptional effect name (shows in Creator effects panel).
opacitynumber

add_blur

Attach a native Gaussian Blur effect to a layer. Renders in Creator's preview and in dotlottie-web. lottie-web silently drops it. Use for: blurred backgrounds, focus/defocus effects, soft glow with drop_shadow distance=0, glassy/frosted surfaces. Param tips: - `sigma` (px): blur strength. 5-10 = subtle, 15-25 = noticeable, 30-60 = dreamy/dramatic. Default 10. - `direction`: 1 = both axes (default), 2 = horizontal only, 3 = vertical only. - `wrap`: 0 = clamp edges (default, normal). 1 = repeat. Almost always leave at 0.

ParameterTypeDescription
layer_id *string
direction
namestring
sigmanumber
wrap

add_color_overlay

Attach a native Fill effect that overlays a solid color on the layer (multiply-style recolor). Renders in dotlottie-web; lottie-web drops it. Use for: recoloring imported SVG/image content without editing the source paths, hover-state overlays, themed tints. For shape layers you usually want `set_fill` instead — this is for cases where the layer's intrinsic fill should stay and a color washes over it. Param tips: - `color` required, RGB 0-255. - `opacity` 0-1 (Lottie Fill convention, not 0-255). Default 1 (full overlay).

ParameterTypeDescription
color *object
layer_id *string
namestring
opacitynumber

add_tint

Attach a native Tint effect (two-color recolor: dark pixels → black color, light pixels → white color, with adjustable intensity). Renders in dotlottie-web; lottie-web drops it. Use for: duotone treatments, retro/poster looks, single-color overlays that preserve luminance variation. NOT for replacing a single fill color — use `set_fill` for that. Param tips: - `black` color maps to the darkest pixels (default {0,0,0}). - `white` color maps to the brightest pixels (default {255,255,255}). - `intensity` 0-100: 0 = no effect, 100 = full duotone replacement (default 100).

ParameterTypeDescription
layer_id *string
blackobject
intensitynumber
namestring
whiteobject

add_tritone

Attach a native Tritone effect (three-color recolor: highlight + midtone + shadow). Renders in dotlottie-web; lottie-web drops it. Use for: cinematic color grading, three-tone aesthetic treatments (sepia, vintage, dusk), branded recolors with more depth than `add_tint`. Param tips: - `highlight` color maps to brightest pixels (default white). - `midtone` color maps to middle luminance (default gray). - `shadow` color maps to darkest pixels (default black). - `intensity` 0-100: 0 = no effect, 100 = full recolor (default 100).

ParameterTypeDescription
layer_id *string
highlightobject
intensitynumber
midtoneobject
namestring
shadowobject

list_layer_effects

Return the effects currently attached to a layer, with their ids, types, and enabled state. Call this before stacking another effect, before removing one, or whenever you need to know what's already there.

ParameterTypeDescription
layer_id *string

remove_layer_effect

Remove a specific effect from a layer. Call `list_layer_effects` first to get the `effect_id`. Other effects on the layer are left intact.

ParameterTypeDescription
effect_id *string
layer_id *string

update_layer_effect

Nudge one slot on an existing effect without removing and re-adding it. Use this when the user asks to refine an effect ('a bit more blur', 'darken the shadow', 'rotate the shadow direction') — much cheaper than `remove_layer_effect` + `add_*` and preserves the slot order. **Slot indices** (match the parser order — see add_* tool docs): - Drop shadow: 0=color, 1=opacity (0-255), 2=angle (degrees), 3=distance (px), 4=blur (px) - Gaussian blur: 0=sigma, 1=direction (1=both | 2=horizontal | 3=vertical), 2=wrap (0|1) - Fill (color overlay): 2=color, 6=opacity (0-1) - Tint: 0=black color, 1=wh…

ParameterTypeDescription
effect_id *string
layer_id *string
slot_index *integer
value *

list_themes

List the themes embedded in this file. Themes group design-token slots (brand colors, named text strings, etc.). The Default theme is always present; users can add named alternates (e.g. 'Dark', 'Holiday'). Returns `{ themes: [{ id, slot_count, is_active }] }`. Call before `list_slots` if the user references a specific theme by name, or to confirm that any tokens exist before suggesting slot-based edits.

list_slots

List design-token slots defined in the file. Each slot has ONE stable id (e.g. 'brand-red') but can supply different VALUES per theme — Default theme might have brand-red as crimson, a Dark theme might have it as burgundy. The toolkit renders whichever value the currently active theme provides. Use before inventing hardcoded values whenever the user names a brand concept ('brand red', 'primary blue', 'the header color', 'our headline text'). Filter with `type` to narrow (e.g. COLOR for fill/stroke pickers, TEXT for headline strings). Returns `{ slots: [{ id, type, values_by_theme: { themeI…

ParameterTypeDescription
theme_idstringOptional theme id to scope the list. Omit to list slots from all themes. Defaults to no filter; use 'Default' for the always-present built-in theme.
typestringOptional slot type filter. Omit to list every slot across every theme.

list_motion_system_items

Read the user's Motion System library — a separate design library from the file's theme slots. Returns colors / gradients / fonts / easings / durations / motion presets that the user has saved (typically synced from Workflow). Use this when the user names a brand value (e.g. 'brand red', 'standard ease-out', 'fast duration') and `list_slots` did NOT find a match — motion system is the fallback library. The values are returned for inline use (set_fill with the rgb you found, apply_keyframes with the control_points you found, etc.) — they are NOT linked tokens. For multi-property motion pr…

ParameterTypeDescription
typestringWhich asset family to read. Omit to get a `{ count, ids }` summary across all families. 'colors' returns solid colors only; 'gradients' returns linear/radial gradients (motion-system stores both under…

create_slot

Create a new design-token slot (motion token) by capturing the current value of a layer property. The slot's value comes FROM the layer — you cannot create a slot from an arbitrary RGB/text input. The typical agent flow is: (a) `set_fill` (or set rotation/opacity/scale/etc.) on the layer to the target value, then (b) `create_slot` to capture it as a named token. By default the source layer is linked to the new slot so future updates propagate. **SCALAR slots** (rotation / opacity / skew / skew_axis / stroke_width) share one slot type, so they REQUIRE `property_context` to pick the source pr…

ParameterTypeDescription
layer_id *stringSource layer whose property value gets captured into the new slot. Must already have a property of the requested kind (e.g. COLOR slot needs a shape layer with a fill or stroke; SCALAR + rotation need…
slot_id *stringUnique slot name (becomes the SlotJSON.assetId — also what `list_slots` returns as `id`). Lowercase, digits, underscore, dash; 1–64 chars. e.g. 'brand-red', 'header-text'.
type *stringSlot type. COLOR = fill/stroke colors. TEXT = reusable strings. GRADIENT = gradient fills/strokes. POSITION = layer position. VECTOR = layer scale. SCALAR = rotation / opacity / skew / skew_axis / str…
link_sourcebooleanWhen true (default), the source layer is linked to the new slot — future updates propagate. Set to false only if you want to create the slot without linking the source.
opacity_sourcestringFor SCALAR + `property_context: 'opacity'` only. 'layer' (default) captures the layer transform opacity; 'fill' captures the fill paint's opacity. Ignored otherwise.
property_contextstringREQUIRED for SCALAR slots; ignored for other types. Picks which scalar property to capture: 'rotation' (transform), 'opacity' (transform OR fill — see `opacity_source`), 'skew' / 'skew_axis' (transf…
shape_typestringFor COLOR / GRADIENT slots on shape layers, which paint to capture. Defaults to FILL (COLOR) or GRADIENT_FILL (GRADIENT). Ignored for TEXT/POSITION/VECTOR/SCALAR.

create_slot_from_value

Create a new COLOR design-token slot DIRECTLY from a value — no source layer required, no scratch-shape dance. Use this when the agent has a `{r, g, b}` in hand (e.g. from `list_motion_system_items`) and wants to register it as a token the user can link future layers to. **When to use this vs `create_slot`:** - `create_slot_from_value`: agent has a value, no source layer. Common after a motion-system lookup: 'tokenize the motion-system primary color' → `list_motion_system_items` → `create_slot_from_value`. - `create_slot`: agent wants to capture a layer's existing fill/stroke/etc. value…

ParameterTypeDescription
color *objectRGB components 0-255; optional alpha 0-1 (defaults to 1).
slot_id *stringUnique slot name. Lowercase, digits, underscore, dash; 1-64 chars. e.g. 'brand-red', 'header-text'. If the user gives an unsupported name (spaces, punctuation, uppercase), normalize and mention it in…
type *stringCurrently only 'COLOR' is supported. Use `create_slot` (capture-from-layer) for other slot types.

update_slot_value

Change the value of an existing design-token slot in one theme. Every layer linked to the slot updates automatically when that theme is the active one — this is the canonical 'recolor everything that uses brand-red' / 'shift all opacity tokens by 20%' operation. **Themes are per-value scopes.** A slot has one id but multiple values, one per theme. By default this writes to the currently active theme (the one the canvas is rendering). Pass `theme_id` to write to a non-active variant — useful for setting 'Dark' theme colors without leaving the active theme. The response's `applied_to_active…

ParameterTypeDescription
slot_id *stringThe slot id (from `list_slots`).
colorobjectNew color for a COLOR slot. Components in 0–255; alpha 0–1.
gradientobjectNew gradient for a GRADIENT slot. Provide stops sorted by offset (0 = start, 1 = end). Each stop carries its color + alpha; the gateway splits them into the Lottie color/alpha track shape.
positionobjectNew position for a POSITION slot (scene-space pixels). `{ x: 256, y: 256 }` = scene center on a 512×512 scene.
scalarnumberNew number for a SCALAR slot. Interpretation depends on which property this slot represents (use `list_slots` to confirm). Units: degrees (0..360) for rotation / skew / skew_axis; percent (0..100) for…
scaleobjectNew scale for a VECTOR slot. `{ x: 100, y: 100 }` = 100% (unchanged); `{ x: 150, y: 150 }` = 1.5×. Uniform scale is the same value on both axes.
textstringNew string for a TEXT slot. Replaces the slot text content; font / size / alignment are unchanged.
theme_idstringWhich theme's value to update. Defaults to the currently active theme (what the canvas renders). Use `list_themes` to see options. Updating a non-active theme is silent on the canvas until the user sw…

add_theme

Create a new theme. The new theme starts with copies of the Default theme's slots (so every slot id continues to render with a value when this theme is active). Use this when the user asks for a 'Dark' / 'Holiday' / etc. variant before customizing values. After creating, the agent typically wants to (a) `select_theme` to make it active, and (b) `update_slot_value({ theme_id, color | text })` per slot to give the new theme its own values. **Naming rules:** lowercase / digits / underscore / dash, 1–64 chars. Convert unsupported user-facing names before calling this tool (for example, 'Holida…

ParameterTypeDescription
id *stringRequested theme id. Lowercase / digits / underscore / dash; 1–64 chars. e.g. 'dark', 'holiday', 'high-contrast'.

select_theme

Switch the currently active theme. The canvas immediately re-renders using the new theme's slot values — every layer linked to a token shifts to the new theme's value for that slot. Use when the user says 'switch to Dark', 'preview the Holiday theme', 'show me what this looks like with the alt theme'. Also useful right after `update_slot_value({ theme_id: 'Dark', ... })` if the user wants to see the change live. Returns `{ active_theme }`. Throws if the theme id doesn't exist.

ParameterTypeDescription
theme_id *stringTheme id to activate. Use `list_themes` to enumerate. 'Default' is always valid.

remove_theme

Delete a theme and all its per-slot value variants. Slot ids stay; only the per-theme values defined in this theme are removed. The Default theme cannot be removed — that always exists. Use when the user asks to drop a variant they no longer want ('get rid of the Holiday theme'). If the deleted theme was active, the active theme falls back to Default. Returns `{ removed: true, theme_id }`. Throws if the theme is 'Default' or doesn't exist.

ParameterTypeDescription
theme_id *stringTheme id to delete. Cannot be 'Default'.

list_segments

List the named animation segments (markers) on the active scene. Each segment is a name + a frame range (start_frame, end_frame). Segments are used by Lottie players to loop / play named ranges and by dotLottie state machines as playback targets. Returns `{ segments: [{ id, name, start_frame, end_frame, duration_frames }] }`. Empty array means the scene has no segments yet. Call before `add_segment` if you need to check for duplicate names, before `add_state` on a state machine that targets a segment, or whenever the user asks 'what segments / loops / chapters does this animation have?'.

add_segment

Add a named segment (marker) to the active scene's timeline. Segments are reusable named frame ranges — players can loop on one, dotLottie state machines can reference one by name. Returns `{ segment_id, name, start_frame, end_frame }`. The `segment_id` is the toolkit node id; subsequent rename / remove / select calls take this id. **Name uniqueness:** segments don't enforce unique names at the toolkit level, but the agent should avoid duplicate names (state machines reference segments by name and a collision is ambiguous). Call `list_segments` first if unsure.

ParameterTypeDescription
end_frame *numberInclusive end frame. Must be >= start_frame. Typically <= the scene end frame, but the toolkit allows beyond.
name *stringHuman-readable segment name (e.g. 'intro', 'loop', 'outro'). Plain text — any characters allowed.
start_frame *numberInclusive start frame. Must be >= 0 and <= end_frame.

rename_segment

Rename an existing segment. Other properties (frames) are unchanged. If state machines reference the old name, they will NOT auto-update — the agent or user must fix those references separately. Returns `{ segment_id, name }`.

ParameterTypeDescription
name *stringNew segment name.
segment_id *stringSegment id from `list_segments`.

remove_segment

Delete a segment from the active scene. Layer timing and keyframes are NOT affected — segments are pure metadata. If state machines reference this segment, they will break at runtime; clean those up separately. Returns `{ removed: true, segment_id }`.

ParameterTypeDescription
segment_id *stringSegment id from `list_segments`.

select_segment

Set the editor's work-area to a segment's frame range so the user can preview / scrub within it. Visible only in the timeline UI; does not change the underlying segment data. Use after `add_segment` if the user wants to immediately preview the new segment, or when they say 'jump to the intro segment'. Returns `{ segment_id, start_frame, end_frame }`.

ParameterTypeDescription
segment_id *stringSegment id from `list_segments`.

list_state_machines

List the interactivity state machines defined in this file. Each one is `{ id, name, state_count, transition_count, is_active }`. Returns the active state machine id separately as `active_state_machine_id`. State machines are runtime configurations — Lottie players use them to switch playback based on events (click, hover, completion). Most files have 0 or 1 machine.

add_state_machine

Create a new interactivity state machine. The new (or reused) machine becomes the active one. After creating, add states with `add_state` and link them with `add_transition`. Designate one state as the entry point with `set_initial_state`. **Auto-reuse of empty default machines.** Creator files ship with an empty `StateMachine1`. If you call `add_state_machine` and one or more empty machines (zero states, inputs, and interactions) already exist, this tool reuses the first one — renaming it to your requested name — instead of creating a duplicate. The response includes `reused: true` and `…

ParameterTypeDescription
name *stringHuman-readable name, e.g. 'Hover Reveal', 'Idle / Click'.

set_active_state_machine

Switch which state machine is active in the editor. Subsequent `add_state` / `add_transition` calls operate on this one. Returns `{ active_state_machine_id }`.

ParameterTypeDescription
state_machine_id *stringId from `list_state_machines`.

remove_state_machine

Delete an entire state machine and all its states / transitions / inputs / interactions. Returns `{ removed: true, state_machine_id }`.

ParameterTypeDescription
state_machine_id *stringId from `list_state_machines`.

list_states

List the states in the active state machine. Each is `{ id, name, type, segment, autoplay, loop, mode, is_initial, transitions: [{ id, to_state_id, trigger?, type }] }`. Returns `state_machine_id` and `initial_state_id` at the top level for convenience. Empty array means the active machine has no states yet.

add_state

Add a new playback state to the active state machine. States represent a playback config — what segment plays, whether it loops, autoplay, etc. The state starts with no transitions; add them with `add_transition`. `segment` references a segment NAME from `list_segments` (not id). If the segment doesn't exist, the player will fail at runtime — call `list_segments` first to verify, or accept that the user might add the segment later. State names must be unique within a machine (case-insensitive — 'Idle' and 'IDLE' collide). Returns `{ state_id, name, segment }`.

ParameterTypeDescription
name *stringHuman-readable state name, e.g. 'Idle', 'Hover', 'Clicked'.
autoplaybooleanStart playing as soon as this state is entered. Default true for most states.
loopbooleanLoop the segment indefinitely. Default false.
loop_countnumberNumber of times to loop. Ignored unless loop is true.
modestringPlayback direction for this state's segment. Default 'Forward'. - 'Forward' — plays first frame → last frame. - 'Reverse' — plays last frame → first frame. - 'Bounce' — PING-PONG: forward, t…
must_completebooleanIf true, the segment must finish before any transition can fire. Default false.
segmentstringSegment NAME (not id) to play in this state. Omit for a state that doesn't play anything (rare).
speednumberPlayback speed multiplier (e.g. 1.0, 0.5, 2.0). Default 1.

add_global_state

Add a GlobalState to the active state machine. Unlike regular states, a GlobalState's transitions are checked FIRST every tick, regardless of which state is currently active — so they fire from ANY state. Use this when the user says 'from any state when X, go to Y' or 'no matter where we are' or 'always allow Z'. Adding identical transitions to every regular state is the wrong shape — use GlobalState instead. **Constraints:** A GlobalState cannot have incoming transitions (the gateway rejects `add_transition` calls targeting one). Each machine can have at most ONE GlobalState — the gate…

ParameterTypeDescription
name *stringName for the global state. Convention: 'GLOBAL STATE' (uppercase, with space).

remove_state

Delete a state from the active state machine. Any transitions pointing TO this state are automatically removed. If the deleted state was the initial state, the machine loses its entry point — set a new initial state with `set_initial_state`. Returns `{ removed: true, state_id }`.

ParameterTypeDescription
state_id *stringState id from `list_states`.

update_state

Update fields on an existing state. Only the fields you pass are changed; everything else is preserved. Returns `{ state_id, ...updated_fields }`.

ParameterTypeDescription
state_id *stringState id from `list_states`.
autoplaybooleanStart playing as soon as this state is entered.
loopbooleanLoop the segment indefinitely.
loop_countnumberNumber of times to loop. Ignored unless `loop` is true.
modestringPlayback direction for this state's segment. Default 'Forward'. - 'Forward' — plays first frame → last frame. - 'Reverse' — plays last frame → first frame. - 'Bounce' — PING-PONG: forward, t…
must_completebooleanIf true, the segment must finish before any transition can fire.
namestring
segmentstringNew segment name. Use empty string to clear.
speednumberPlayback speed multiplier (e.g. 1.0, 0.5, 2.0).

set_state_actions

Set entry and/or exit actions on a state. Entry actions fire when the state machine ENTERS the state; exit actions fire when LEAVING. Common uses: 'on enter set isPlaying = true, on leave set false', or 'on enter increment session counter'. Semantics: passing `entry_actions: [...]` REPLACES the existing entry array. Passing `entry_actions: []` clears it. OMITTING the field leaves the existing actions untouched — pass only the field you want to change. Actions follow the same 13-shape vocabulary as `add_pointer_interaction` (SetNumeric, SetBoolean, Toggle, Fire, SetTheme, etc.).

ParameterTypeDescription
state_id *stringState id (from `list_states`) to set actions on.
entry_actionsarrayActions that fire when this state is entered. Pass `[]` to clear the existing array; OMIT to leave it untouched. Same 13-variant vocabulary as `add_pointer_interaction.actions[]`.
exit_actionsarrayActions that fire when this state is exited. Pass `[]` to clear the existing array; OMIT to leave it untouched. Same 13-variant vocabulary as `entry_actions`.

set_initial_state

Designate which state the machine enters first at runtime. Every state machine needs exactly one initial state. Returns `{ initial_state_id }`.

ParameterTypeDescription
state_id *stringState id from `list_states`.

add_transition

Add a transition from one state to another in the active state machine. Transitions can fire immediately when the from-state's segment completes (no trigger), or in response to an event like 'click', 'pointerEnter', 'pointerExit' (pass `trigger_event`). **If you pass `trigger_event`, you MUST also call `add_pointer_interaction` with a matching `fire_event` — or the transition will never fire at runtime.** `trigger_event` is just a NAME the transition listens for; nothing emits that name until a pointer interaction is wired to fire it. A transition with `trigger_event: 'click'` and no matchi…

ParameterTypeDescription
from_state_id *stringState the transition leaves.
to_state_id *stringState the transition arrives at.
duration_msnumberRequired when type is 'Tweened'. Tween duration in milliseconds.
easingarrayRequired when type is 'Tweened'. Cubic-bezier control points [x1, y1, x2, y2]. Example: [0.4, 0, 0.2, 1] for material-style ease-in-out.
guardsarrayInput-comparison guards. Each guard tests one input value at runtime; ALL guards must pass for the transition to fire. Combine with `trigger_event` to require both an event AND a condition (e.g. trans…
trigger_eventstringEvent NAME this transition listens for (a string, not a literal event type). Common conventions: 'click', 'pointerEnter', 'pointerExit'. **If you set this, you MUST also call `add_pointer_interaction`…
typestringDefault 'Transition' (immediate). 'Tweened' interpolates over duration_ms with the given easing.

remove_transition

Remove a transition from a state. Returns `{ removed: true, transition_id }`.

ParameterTypeDescription
state_id *stringState id that owns the transition.
transition_id *stringTransition id from `list_states`.

list_interactions

List the interactions defined on the active state machine. Interactions BIND runtime pointer / state events to actions — usually a `Fire` action that emits a named event a transition listens for. **Without an interaction, transition `trigger_event` guards never fire.** If you added an `add_transition({ trigger_event: 'click' })`, you must also `add_pointer_interaction({ pointer_event: 'Click', fire_event: 'click' })` for the click to do anything at runtime. Returns `{ interactions: [{ id, type, layer_name, state_name, actions, fires_event }] }`. `type` is the pointer event name (Click / Po…

add_pointer_interaction

Bind a pointer event (Click, PointerEnter, etc.) on a layer to one or more state-machine actions. This is the wiring that makes `trigger_event` and input mutations actually fire at runtime. Two call shapes — pass EITHER `fire_event` (shorthand) OR `actions[]` (full vocabulary), never both: 1. `fire_event: 'click'` — shorthand for a single `Fire` action against the named event input. Pairs with `add_transition({ trigger_event: 'click' })`. Match exactly, case-sensitive. 2. `actions: [...]` — full action vocabulary. Each action targets an input by name or carries its own value. The 13 a…

ParameterTypeDescription
layer_id *stringLayer id to bind the pointer event to (from `read_scene`). REQUIRED — scene-level pointer interactions don't fire in the player. Pick the most semantically meaningful clickable layer (a button, a ca…
pointer_event *stringWhich pointer interaction fires this event. Click + PointerEnter / PointerExit are the most common.
actionsarrayFull action vocabulary. Mutually exclusive with `fire_event`. Each entry is one of the 13 action variants below; multiple actions fire in order. Must contain at least one action.
fire_eventstringSHORTHAND for a single Fire action. Event name to emit; must match the `trigger_event` you used on a transition (case-sensitive). Common values: 'click', 'hover', 'leave'. Mutually exclusive with `act…

add_state_interaction

Add a state-event interaction that fires actions when a state's playback reaches a milestone. Use `OnComplete` for 'when this state's segment finishes' or `OnLoopComplete` for 'each time this state's segment loops'. Not to be confused with `add_transition`: a transition WITHOUT `trigger_event` also fires on segment completion, but it transitions to ANOTHER state. Use `add_state_interaction` when you want to fire actions (Fire, Increment, SetTheme, OpenUrl, etc.) on completion WITHOUT changing state. The action vocabulary is identical to `add_pointer_interaction.actions[]` — 13 variants cov…

ParameterTypeDescription
actions *arrayActions to fire when the trigger hits. Same 13-variant vocabulary as `add_pointer_interaction.actions[]`. Multiple actions fire in order. Must contain at least one action.
state_id *stringState id (from `list_states`) whose milestone fires the interaction.
trigger *stringWhich playback milestone fires this interaction. `OnComplete` fires once when the state's segment ends. `OnLoopComplete` fires every time the segment loops back.

remove_interaction

Remove an interaction from the active state machine. Returns `{ removed: true, interaction_id }`.

ParameterTypeDescription
interaction_id *stringInteraction id from `list_interactions`.

list_inputs

List the typed inputs (variables) on the active state machine. Inputs are how state machines store runtime values — booleans for toggle state, numerics for progress / counters, strings for labels, and events for one-shot triggers. Inputs feed guards on transitions and actions in interactions. Returns `{ inputs: [{ id, name, type, value? }] }`. The `value` is the initial value at machine start (events don't have one).

add_input

Add a typed input variable to the active state machine. Inputs power guard transitions (e.g. transition fires when `isHovered === true`) and action targets (e.g. an action that sets `progress` to 50). Types: - `Boolean` — initial_value must be 'true' or 'false' (string). - `Numeric` — initial_value must be a stringified number. - `String` — initial_value is a plain string. - `Event` — pure one-shot trigger; do not pass initial_value. Returns `{ input_id, name, type }`.

ParameterTypeDescription
name *stringVariable name — referenced by guards and actions. e.g. 'isHovered', 'progress', 'currentTab'.
type *stringInput type. Boolean for toggles, Numeric for counters/progress, String for labels, Event for one-shot triggers.
initial_valuestringInitial value as a string. For Boolean pass 'true' or 'false'; for Numeric pass a numeric string like '0'; for String any text; OMIT for Event.

update_input

Update an existing input's name or value. Renaming an input also updates all references to it across guards and actions automatically (theme-manager handles the cascade). Returns `{ input_id, name, value }`.

ParameterTypeDescription
input_id *stringInput id from `list_inputs`.
namestring
valuestringNew value as a string (matches the input type).

remove_input

Delete an input. All guards / actions that reference it are also cleaned up automatically. Returns `{ removed: true, input_id }`.

ParameterTypeDescription
input_id *stringInput id from `list_inputs`.

import_asset

**BEFORE CALLING: check the creation order.** Imported assets are inserted at the TOP of the render stack. If this turn creates multiple layers, emit the calls in BOTTOM→TOP order — the backdrop / sky / base image FIRST, foreground layers LAST. (Reorder APIs exist if needed via `reorder_layer`, but planning the order is cheaper.) Import an SVG, Lottie, or image into the active scene as a new layer. This is the preferred tool whenever the user pastes SVG markup, provides a URL for an image/Lottie, or asks to add an existing asset. Returns the new layer's id so you can immediately animate i…

ParameterTypeDescription
asset_type *stringSVG: use inline `content`. LOTTIE/IMAGE: use `url`. Inline SVG content is the common case when the user pastes markup.
contentstringRaw SVG markup (for asset_type='SVG'). Mutually exclusive with `url`.
namestringOptional override for the imported layer's name.
positionobjectOptional {x, y} to position the imported layer.
scaleobjectOptional {x, y} scale percentage (100 = 100%).
urlstringURL to fetch (for asset_type='LOTTIE' or 'IMAGE'). Mutually exclusive with `content`.

vectorize_image

Convert an existing PNG/JPG image layer into editable vector shape layers using Creator's vectorizer. Use this when the user asks to vectorize, trace, convert an image/logo/photo to vectors, or make an imported raster image editable. Defaults to the selected image layer when `layer_id` is omitted. The generated vector layers are inserted above the source and selected; after at least one vector layer is created, the original raster is preserved but hidden so it does not render or export twice. Restore it with `set_layer_visibility({ layer_id: source_layer_id, visible: true })` when the user wan…

ParameterTypeDescription
layer_idstringImage layer id from `read_scene`. Optional when an image layer is selected.

remove_keyframes

Remove keyframes from a single property on a single layer. Omit `frame_range` to clear all keyframes on that property; pass `frame_range: { from, to }` to remove only keyframes whose frame falls in the inclusive range. Use this before calling `apply_keyframes` with the same property when you want to fully replace an existing animation rather than merge with it — or just pass `clear_first: true` on `apply_keyframes` for the common case.

ParameterTypeDescription
layer_id *string
property *string
frame_rangeobject

duplicate_layer

Duplicate an existing layer N times and return the new layer IDs. Optional `stagger_frames` offsets each duplicate's timelineOffset by that many frames (i × stagger) — use for stagger/wave effects. Optional `offset` shifts each duplicate's position by (i × offset.x, i × offset.y) — use for arrays and rows. Common flows: - 'make a row of 5 dots spaced 40px apart': duplicate_layer with count=4 (+ the source = 5 total) and offset={x:40,y:0}, then a single apply_keyframes call on the source animates the base motion. - 'stagger 5 letters': duplicate_layer with count=4 and stagger_frames=3;…

ParameterTypeDescription
layer_id *stringSource layer id from `read_scene`.
countnumberHow many duplicates to create. Default 1. Capped at 24 to keep the timeline sane.
name_prefixstringOptional base name. Copies are suffixed ' 1', ' 2', etc. Defaults to the source layer's name.
offsetobjectPer-copy position shift. Copy i gets source.position + i*offset. Ignored if the source layer has animated position (copy keyframes untouched).
stagger_framesnumberPer-copy timelineOffset step, in frames. Copy i (1-indexed) gets source.timelineOffset + i*stagger_frames.

tile_layer

Fill the active scene with a grid of copies of a layer. This is the tool to reach for whenever the user says 'tile across the scene', 'fill with a grid of', 'cover with', 'scatter N', or 'pattern the background with'. It ALWAYS uses `Math.floor` for auto cols/rows so tiles never spill outside the scene bounds. Behavior: - `tile_width` / `tile_height` default to the source layer's visual bounds (read via getBounds). For a polygon with outerRadius 50, that's ~100×100. - `cols` / `rows` default to `floor((scene_dim − 2*margin + gap) / (tile_dim + gap))` so the grid exactly fits. Pass either e…

ParameterTypeDescription
layer_id *stringSource layer to duplicate into the grid.
alternate_flipbooleanWhen true, rotate odd-indexed rows by 180°. Use for triangle tessellation and pointing alternating directions.
colsnumberExplicit column count. Omit to auto-fit from tile_width + margin + gap.
gapobjectSpacing between tiles in pixels. Default { x: 0, y: 0 } (tiles touch).
marginobjectInset from scene edges in pixels. Default { x: 0, y: 0 }.
rowsnumberExplicit row count. Omit to auto-fit.
tile_heightnumberOverride the per-tile height step. Defaults to source bounds height.
tile_widthnumberOverride the per-tile width step. Defaults to the source layer's visual bounds width (via getBounds).

reorder_layer

Restack a layer relative to another in the active scene's render order. Use when creation order was wrong or the user asks to put one layer above/below/in-front-of/behind another. Z-ORDER (index 0 = front/top, per read_scene `ordering`): - To put the layer ON TOP of the sibling (visible in front — e.g. a label over a button fill, text over a circle): `position: 'in_front_of'`. - To put the layer UNDER the sibling (behind — e.g. a shadow behind a card, a backdrop behind content): `position: 'behind'`. USE `in_front_of` / `behind` — they say exactly what you mean. The legacy `before` / `…

ParameterTypeDescription
layer_id *stringLayer to move.
position *stringWhere to place the target relative to the sibling. `in_front_of` = on top (visible over it); `behind` = under it. (`before` = same as in_front_of, `after` = same as behind — legacy, easy to invert.)
sibling_layer_id *stringReference layer that stays in place; the target moves relative to it.

group_layers

Group multiple active-scene root layers by converting them into a nestable precomposition layer. Creator's native shape-group command only groups drawable shapes inside a shape layer, so root-level layer grouping is represented as a precomp. Use this when the user asks to group several layers, package a component, or create a reusable/nestable precomp from existing layers. Pass layer IDs from `read_scene` in the intended visual set.

ParameterTypeDescription
layer_ids *arrayRoot layer ids to precompose/group.
namestringOptional name for the resulting precomposition layer.

create_shape_group

Create an empty group inside an existing SHAPE_LAYER or group. Use this to build composed single-layer components like cards, icons, badges, and shadows without creating many top-level layers. **RESPONSE — keep `group_id`, it is the only way to address the group afterwards:** returns `{ group_id, parent_id, name }`. `read_scene` returns LAYERS, not the shape/group tree inside them, so this response is your only source of the id. Feed `group_id` straight into `add_shape_to_layer({ parent_id: group_id })` to fill the group and into `set_group_transform({ group_id })` to move / fade the whole…

ParameterTypeDescription
parent_id *stringContainer to create the group inside: a SHAPE_LAYER id (the `layer_id` returned by `create_shape`) or another group id (a `group_id` returned by an earlier `create_shape_group`). Non-shape layers are…
namestringOptional group name, e.g. "card-shadow". Defaults to Creator's.

add_shape_to_layer

Add a rectangle, ellipse, polygon, star, or path to an existing SHAPE_LAYER or group. Use with create_shape_group to build one composed unit with internal groups. **RESPONSE:** returns `{ parent_id, shape_id, shape, fill_id, stroke_id }` (`fill_id` / `stroke_id` only when you passed `fill` / `stroke`). Keep `shape_id` — it is the `target_id` for `animate_property` on shape geometry (`shape_size`, `rectangle_roundness`, `shape_path`, …), and `read_scene` does not list the shapes inside a layer. If the fill or stroke fails to attach, the whole call is rolled back (the shape is removed) and…

ParameterTypeDescription
parent_id *stringContainer to add the shape to: a SHAPE_LAYER id (from `create_shape`) or a `group_id` from `create_shape_group`.
shape *string
fillPAINT OBJECT — `{ type: 'SOLID', color: {r,g,b} }` or a gradient, same shape as `set_fill.fill`. NOT the palette NAME STRING that `create_shape.fill` takes.
inner_radiusnumber
inner_roundnessnumber
namestring
outer_radiusnumber
outer_roundnessnumber
pathobject
pointsnumber
roundnessnumber
sizeobject
strokePAINT OBJECT plus an optional `width` (px, default 1) — e.g. `{ type: 'SOLID', color: {r,g,b}, width: 2 }`. NOT the `{ color, width }` shape that `create_shape.stroke` takes.

set_group_transform

Set or keyframe a shape group transform/opacity property. Use this when a composed unit has internal groups that should move or fade together. Pass EITHER `value` (a static set) OR `keyframes` (an animation) — the call throws if you pass neither. `keyframes` wins when both are given. Returns `{ group_id, property, keyframes_added }`; `keyframes_added` is 0 for a static `value` set.

ParameterTypeDescription
group_id *stringGroup id from the `create_shape_group` response. `read_scene` lists layers, not the groups inside them, so that response (or an earlier `add_shape_to_layer` parent) is where this id comes from.
property *string
clear_firstbooleanClear existing keyframes on this group property before writing. **Defaults to TRUE here** (unlike `apply_keyframes`, which defaults to false). Pass false to merge with what is already there.
keyframesarray
valueStatic value to set (no animation). `{x, y}` for position/scale, a number for rotation (degrees) / opacity (0-100). Omit when passing `keyframes`.

reorder_shape

Restack a child shape or group relative to a sibling inside the same shape container — to fix internal card/icon order without rebuilding the layer. Z-order: `position: 'in_front_of'` draws the node ON TOP of the sibling, `'behind'` draws it under. Use `in_front_of`/`behind` (clear); `before`/`after` are legacy aliases that invert intuitively (`before` = on top).

ParameterTypeDescription
node_id *string
position *string`in_front_of` = on top of the sibling; `behind` = under it. (`before`=in_front_of, `after`=behind — legacy.)
sibling_id *string

set_layer_time

Retime an existing layer on the timeline. Any combination of start_frame, end_frame, and timeline_offset can be set — omitted values stay as-is. - `start_frame` / `end_frame`: when the layer is visible in the parent scene. - `timeline_offset`: how far the layer's internal timeline is shifted (negative = play later). This is the stagger primitive — give each sibling a different offset. Prefer this over `apply_keyframes` on opacity when the user asks to 'delay' or 'stagger' layers — this is cheaper, correct, and doesn't collide with existing opacity animations.

ParameterTypeDescription
layer_id *string
end_framenumber
start_framenumber
timeline_offsetnumber

retime_keyframes

Shift, scale, reverse, evenly distribute, or RE-EASE keyframes on one layer property WITHOUT rebuilding values. Use for timing/feel polish like "shift this 10 frames later", "make the bounce twice as fast", or "make it springier". **To change the EASING / feel (springy, snappy, smoother, bouncy, more/less overshoot) use `operation: 'set_easing'` with `easing` — NOT apply_keyframes.** set_easing swaps only the easing curve and preserves every frame and value. Rewriting the animation via apply_keyframes forces you to restate all values and risks corrupting positions (e.g. collapsing a stagger…

ParameterTypeDescription
layer_id *string
operation *string
property *string
easingEasing for operation 'set_easing' (required by it, ignored by every other operation). 'overshoot-soft'/'overshoot-hard' = springy/bouncy; 'snappy-out' = snappy; 'smooth-in-out' = smooth. Applied to th…
end_framenumberWindow end for 'reverse' (the mirror is `start + end - frame`) and 'distribute_evenly' (the last keyframe lands here). Defaults to the property's LAST existing keyframe. Ignored by 'shift_frames', 'sc…
offsetnumberFrames to move every keyframe by, for operation 'shift_frames'. POSITIVE = later, NEGATIVE = earlier. Defaults to 0 (a silent no-op), so always pass it for that operation. Ignored by every other opera…
scalenumberPositive time multiplier for operation 'scale_time', applied to each keyframe's distance from the origin (`start_frame`, else the first keyframe). Must be greater than 0; invalid values are rejected w…
start_framenumberWindow start. For 'scale_time' this is the ORIGIN the scaling pivots around (keyframes at this frame do not move). For 'reverse' and 'distribute_evenly' it is the start of the frame window. Defaults t…

delete_layer

Remove ONE layer from the scene by id. If the scene digest selection is non-empty and the user says 'delete this', 'remove it', 'delete selected', etc., use the selected layer id(s) with this tool. For multiple selected layers, call this tool once per selected id. Returns `{ layer_id, removed: true }`.

ParameterTypeDescription
layer_id *string

create_mask

Add a mask to a layer. Masks clip the layer's visible content to an arbitrary shape — use for reveal wipes ('reveal from left'), clipping images/Lotties to a shape ('mask this image to a circle'), and any 'show only the part inside' request. For the common shapes, pass one of the shorthands: - `shape: "rectangle"` + `rect: { x, y, width, height }` — axis-aligned rectangle in LAYER-local coordinates. - `shape: "ellipse"` + `ellipse: { cx, cy, width, height }` — center-defined ellipse, width/height being the bounding box. Plugin synthesizes a 4-point cubic bezier approximation (standard…

ParameterTypeDescription
layer_id *string
shape *string
ellipseobjectRequired when `shape` is "ellipse"; omit for other mask shapes.
modestringDefault 'add'. 'add' = show ONLY the content inside the mask outline (the normal clip/reveal). 'subtract' = cut a HOLE — hide the content inside the outline and show everything outside it.
opacitynumberMask opacity, not an enable/disable strength. Default 100. For an ADD mask, 100 shows the content inside the outline and 0 makes the masked layer fully transparent. For a SUBTRACT mask, 100 fully cuts…
pathobjectRequired when `shape` is "path"; omit for other mask shapes.
rectobjectRequired when `shape` is "rectangle"; omit for other mask shapes.

update_mask

Update an existing mask path, opacity, or mode. Use after create_mask when the reveal shape needs tuning without recreating the mask. Only the fields you pass change; omitted fields are left alone. Returns `{ layer_id, mask_id, updated: { path, opacity, mode } }` — each `updated` flag reports whether that field was part of this call.

ParameterTypeDescription
layer_id *stringLayer that owns the mask.
mask_idstringMask id from the `create_mask` response. Omit to update the layer's FIRST mask — `read_scene` does not list mask ids, so on a single-mask layer omitting this is the normal path. Errors with "mask no…
modestring'add' = show ONLY the content inside the mask outline (the normal clip/reveal). 'subtract' = cut a HOLE — hide the content inside the outline and show everything outside it. Omit to leave the curren…
opacitynumberMask opacity. For an ADD mask, 100 shows inside the outline and 0 makes the masked layer fully transparent. For a SUBTRACT mask, 100 fully cuts inside and 0 cuts nothing. Use `remove_mask` to restore…
pathobjectReplacement mask outline, in LAYER-LOCAL coordinates.

remove_mask

Remove one mask from a layer. Pass mask_id when known; otherwise removes the first mask only. Returns `{ layer_id, mask_id, removed: true }`.

ParameterTypeDescription
layer_id *string
mask_idstring

set_matte

Apply a track/alpha matte: use another layer's alpha/shape as the visibility matte for this layer. This is THE premium-reveal primitive — what AE calls 'Alpha Matte'. Typical flow: 1. User has (or you create) the layer to be revealed (the logo, image, text). 2. User has (or you create) a second layer whose shape defines the reveal region (a growing circle, a wipe rectangle, a word-shaped text layer). 3. Call `set_matte({ layer_id: target, matte_layer_id: matteSource })`. The native tool sets `matteSource.isMatte = true` so the matte layer itself becomes invisible in the render while still…

ParameterTypeDescription
layer_id *stringThe layer whose visibility will be gated by the matte.
matte_layer_id *stringThe layer whose shape defines the matte region. The native tool flips its `isMatte` flag so it stops rendering as its own layer.
invertedbooleanWhen true, show the target OUTSIDE the matte shape (subtract). Default false (show inside).

remove_matte

Clear the track matte from a layer.

ParameterTypeDescription
layer_id *string

rename_node

Rename a layer, shape, group, mask, or scene node by id. Use for cleanup and making generated structures understandable. A renamed text layer keeps its name when its text changes.

ParameterTypeDescription
name *string
node_id *string

set_layer_visibility

Show or hide one active-scene layer.

ParameterTypeDescription
layer_id *string
visible *boolean

set_layer_lock

Lock or unlock one active-scene layer.

ParameterTypeDescription
layer_id *string
locked *boolean

flip_layer

Mirror a layer horizontally or vertically. Wraps `layer.flip(direction)`. Use for 'mirror this', 'flip horizontally', 'face the other way'. Works on any layer type.

ParameterTypeDescription
direction *string
layer_id *string

align_layer

**Use this as your first choice for centering or aligning layers to the scene.** Wraps Creator's own alignment math — the exact same path the property-panel 'align center' / 'align left' / 'align top' buttons run. Works reliably across text, shape, and image layers. `horizontal-center` aligns the layer's visual bounds to the scene's horizontal midpoint; `vertical-center` to the vertical midpoint. For a fully-centered layer, emit BOTH in order: one tool call with `direction: 'horizontal-center'` and then one with `direction: 'vertical-center'`. Same for 'top-left' → `top` + `left`, and so…

ParameterTypeDescription
direction *string
layer_id *string

align_layers

Align a SET of existing layers to a shared edge derived from the set itself — the multi-layer counterpart of `align_layer` (which only aligns ONE layer to a SCENE edge). Use this to FIX a row/column you (or the user) hand-placed that came out ragged or misaligned: e.g. make a column of labels share a LEFT edge, or a row of icons share a TOP edge. `edge`: which edge to make flush — `left`/`right`/`horizontal-center` (x-axis) or `top`/`bottom`/`vertical-center` (y-axis). Edge-anchored by each layer's RENDERED visual bounds (so text aligns by its real left/right edge, not its baseline anchor…

ParameterTypeDescription
edge *string
layer_ids *arrayThe layers to align to each other (≥2).
toCoordinate to align to: 'min' | 'max' | 'first' | 'mean' | a number. Omit for sensible defaults (min for left/top, max for right/bottom, mean for centers).

layout

Lay out multiple items in a ROW or COLUMN with EVEN spacing and shared-edge alignment — in ONE call. **Use this instead of hand-placing positions** for any multi-item arrangement: nav menus, button rows, lists, label stacks, feature rows, and especially LEGENDS / swatch grids / spec-sheet rows / icon lists (a swatch legend = a column of `{swatch, label}` row-blocks — hand-placing those overlaps the label onto the swatch). It creates the items (or arranges existing layers), measures each rendered size, and computes even gaps + alignment so the result is correct by construction — no pixel…

read_keyframes

Read the current keyframes on a layer's keyframe-tool properties. Use this whenever the user asks to TUNE, POLISH, or MODIFY an existing animation ('make the bounce snappier', 'slow down the fade', 'shift this 10 frames later', 'make the rotation smoother') — so you can see what's actually there before changing it, instead of rebuilding from scratch. Without `property`, returns a map of the core properties handled by `apply_keyframes` (`position`, `scale`, `rotation`, `opacity`, `fill_color`, trim path fields, and `stroke_width`). With `property`, returns just that explicit core or extended…

ParameterTypeDescription
layer_id *string
propertystringOptional — restrict to one core or extended keyframe-tool property. Omit to read all core keyframe-tool properties on the layer.

copy_animation

Copy keyframes from one layer's core keyframe-tool properties onto another. The classic use: 'match this layer's animation to the others,' 'copy the rotation from the big triangle to the small one,' 'give this the same entrance as that one.' By default, animated core properties from `apply_keyframes` are copied — pass `properties` to restrict. Extended `animate_property` fields such as masks, shape paths, gradients, text animator fields, and time mapping are not copied by this tool. Pass `frame_offset` to shift all copied keyframes by N frames, which stacks with this tool for manual stagger…

ParameterTypeDescription
source_layer_id *string
target_layer_id *string
clear_first_on_targetbooleanWhen true (default), clear each property's existing keyframes on the target before copying. When false, merge with existing.
frame_offsetnumberShift every copied keyframe's `frame` by this many frames. Negative = play earlier, positive = play later. Default 0.
propertiesarrayOptional — which core keyframe-tool properties to copy. Omit to copy all animated core properties on the source.

list_scenes

List every scene in the current project plus which one is active. Cheap read. Use when the user refers to scenes by name ('switch to the outro', 'work on the vertical') so you can find the right `scene_id`, or when deciding whether to create a new scene vs. switch to an existing one. Returns active scene id, and for each scene: id, name, size, framerate, duration, layer_count, and is_nestable (whether the scene can be used as a source for a nested scene layer).

create_scene

Create a new scene (a.k.a. composition / artboard) in the project. Use for 'make a vertical variant', 'add a second scene for the outro', 'new 1080×1920 version', 'start fresh on a new composition'. All fields optional — omit to inherit defaults. If size is omitted, Creator uses its default (typically 1920×1080). Provide explicit size when the user asks for a specific aspect ratio (9:16 → 1080×1920, 1:1 → 1080×1080, etc.). **IMPORTANT**: `activate` defaults to true, meaning the newly created scene becomes the active scene. Any layer IDs you had from before (in history or from a rec…

ParameterTypeDescription
activatebooleanSwitch to the new scene immediately (default true). Set false to create but keep the current scene active.
durationnumberScene duration in seconds.
frameratenumberFrames per second. Default: Creator's fallback.
namestringScene name as shown in Creator's scene picker.
sizeobject

switch_scene

Switch Creator's active scene. Provide either `scene_id` (exact) or `name` (exact or case-insensitive substring match across scenes). Use `list_scenes` first if you're not sure what's available. **IMPORTANT**: After this tool runs, any layer_id from prior turns is INVALID — those layers live in the scene you just switched away from. Call `read_scene` before using any layer-targeting tool on the new active scene. If you switched temporarily into a selected precomp/source scene, switch back to the original active scene before ending the turn.

ParameterTypeDescription
namestringScene name. Exact first, then case-insensitive substring. Errors if 0 or more than 1 match.
scene_idstringExact scene id from `list_scenes`. Preferred.

set_current_frame

Move the active scene's playhead to a specific frame. Use this after creating reveal/draw-on/fade-in animations where frame 0 is intentionally invisible (`trim_end: 0`, opacity 0, offscreen position) so the Creator canvas is left on a representative visible frame. This changes the editor preview frame only; it does not add animation keyframes or alter layer timing.

ParameterTypeDescription
frame *integerScene frame to show in Creator. Creator clamps to the scene range.
add_to_historybooleanWhether this navigation should enter undo history. Default false; leave false for Motion Copilot preview positioning.

set_scene_background

Set the PREVIEW background color of the active scene. **This is preview-only — the color is NOT exported with the final animation; exports always have a transparent background.** Use this whenever you want to see how the design reads against a specific surface (e.g. dark mode preview, brand tint preview, contrast check for white-on-X) WITHOUT polluting the scene with a background rectangle layer. **Strongly prefer this over creating a background SHAPE LAYER.** Motion-design convention: animations float on transparency so they can be composited anywhere. Adding a background rectangle layer a…

ParameterTypeDescription
color *objectRGB color, channels 0–255.

set_scene_settings

Update the active scene size, framerate, duration, and/or origin point. Use for prompts like "make this 1080x1920", "make it 60fps", or "extend to 8 seconds".

ParameterTypeDescription
durationnumber
frameratenumber
origin_pointobject
sizeobject

create_scene_layer

Place an existing NESTABLE scene/precomp into the active scene as a SceneLayer (nested composition / component / precomp). Use this for professional card, panel, logo, or UI units only when `list_scenes` reports the source scene has `is_nestable: true`. Important: newly created top-level scenes that report `is_nestable: false`; those cannot be used as scene-layer sources. Do not create a fresh scene and immediately try to place it unless `list_scenes` confirms it is nestable. For generated cards/panels, prefer a single grouped ShapeLayer when no nestable source exists. Provide `source_scene_…

ParameterTypeDescription
end_framenumberOptional layer end frame.
namestringOptional name for the created SceneLayer.
opacitynumberOptional initial opacity.
positionobject
scaleobjectOptional initial scale in percent. Applied after layer creation.
source_scene_idstringExact source scene id from `list_scenes`.
source_scene_namestringSource scene name. Exact first, then case-insensitive substring. Errors if 0 or more than 1 match.
start_framenumberOptional layer start frame.

break_scene_layer

Destructively break an active-scene scene/precomp layer into independent editable layers. Use only when the user explicitly asks to break apart, detach, ungroup, or extract a nested scene. Do not use for normal edits to a precomp/scene layer contents; switch to the source scene and edit there instead.

ParameterTypeDescription
layer_id *string

apply_bounce

Drop or lift a layer with physics-correct bounce keyframes. **Use this for any prompt mentioning bounce / drop / fall / land / gravity**. Computes a parametric trajectory: each successive bounce decays in BOTH amplitude and duration, which is the part hand-tuned bounces always miss (uniform-timing decay reads as wrong). **Position-only by design.** Squash-and-stretch is a separate concern — call `apply_squash` afterward if the user explicitly asked for a 'playful' / 'cartoon' / 'springy' bounce. A bare 'bounce' should not deform the layer's scale. Defaults pick a 'snappy but natural' bounc…

ParameterTypeDescription
layer_id *stringLayer to animate.
to *numberResting value the bounce settles to. For a 'drop and bounce', this is the floor y (greater than `from`). For a 'lift in', it's the peak y (less than `from`). Required.
axisstringPosition axis to bounce on. Default 'y' (gravity-driven drop).
clear_firstbooleanReplace existing position keyframes. Default true.
elasticitynumberEnergy retained per bounce, 0-0.99. 0.65 is the playful default.
fromnumberStarting value for the chosen axis. Defaults to the layer's current static position on that axis.
gravitynumberGravity in pixels/second². Default 4000.
max_bouncesnumberMax bounces to generate. Default 4.
start_framenumberFrame at which the bounce begins. Default 0.

apply_squash

Add squash-and-stretch scale keyframes at specified impact frames. **Only call this when the user explicitly asks for 'playful' / 'cartoon' / 'springy' / 'squashy' / 'with squash and stretch' on top of a bounce.** A bare 'bounce' should NOT include squash — leave the layer's scale untouched. **CRITICAL — `impact_frames` MUST be the literal array returned by `apply_bounce`'s response. NEVER invent them, NEVER estimate them, NEVER guess at multiples of a frame number.** This tool is SEQUENTIALLY DEPENDENT on `apply_bounce`: emit `apply_bounce` first, READ its response's `impact_frames` arra…

ParameterTypeDescription
impact_frames *arrayFrames where squash should fire. Use the `impact_frames` array returned by `apply_bounce`. Skipping the first impact for a 'bounces but doesn't squash on first contact' feel is fine.
layer_id *string
clear_firstbooleanReplace existing scale keyframes. Default true.
decay_per_impactnumberSquash strength multiplier per successive impact. Default 0.7 — preserves visible squash for ~3 bounces.
min_spacing_framesnumberSkip impacts whose preceding/following bounce is shorter than this many frames (their squash window would overlap neighbors). Default 5.
rationumberSquash extent at the FIRST impact. 1.15 = subtle, 1.3 = playful, 1.5 = cartoon. Default 1.3.

apply_coupled_shadow

Animate an existing shadow layer to track a bouncing object. **Always use this for shadows under bouncing balls** — it solves all five shadow bugs (A: position pinned at ball center, B: shadow wider than object, C: inverted scale direction, D: copying ball.scale onto shadow, E: redundant static keyframes) by computing every value from the ball's existing position keyframes via the rule: `shadow.position.y = ball.y_at_rest + ball_radius` (CENTER, not top) `shadow.scale.x = widthRatio × ball_diameter` (interpolates between apex and impact ratios; flat `scale.y`) `shadow.opacity = inverse of…

ParameterTypeDescription
ball_layer_id *stringThe bouncing ball layer (must have animated position).
shadow_layer_id *stringThe shadow ellipse layer. Will be resized to ball_diameter × ball_diameter and have its position + scale + opacity keyframed.
clear_firstbooleanReplace existing scale + opacity keyframes on the shadow. Default true.
flatnessnumberShadow vertical extent as a multiplier of ball diameter. Default 0.3. Stays constant — the shadow doesn't pulse vertically.
opacity_at_apexnumber0-1 ratio. Default 0.30 (30%).
opacity_at_impactnumber0-1 ratio. Default 0.75 (75%). Bug guard: pass a ratio, NOT a percentage — values > 1 throw.
width_ratio_at_apexnumberShadow width at apex, as a multiplier of ball diameter. 0.45 default — visibly shrunk but not a dot.
width_ratio_at_impactnumberShadow width at impact, as a multiplier of ball diameter. 1.0 = matches ball, 1.1 = slightly wider (default), 1.3 = noticeably wider. Never > 1.5 or it stops looking like the ball's shadow.