Update elements
update_elementsUpdate many elements across one or more clips in a single tool call. Replaces the per-element tool — always batch.
Each item can update position/timing fields alone, or type-specific fields via type_data (use get_element_schema in 'update' mode to see what's settable for an element_type). Items within one call are applied in order; partial success is fine.
Grouping: pass group: "<name>" to move an element into a named group (created on demand), or group: "" to pull it back out to the clip root. Several items sharing a name collect into one group — the way to tidy loose elements into units the user can move or hide together. Grouping never changes coordinates. It does affect z-order: a group's members render contiguously at the group's slot, and a NEW group takes the slot of its first member, so grouping already-adjacent elements keeps their z-position while grouping scattered ones pulls them together at the lowest member's slot.
Customising a component: after add_elements(component_id=...), set its content here with type_data.parameter_values on the animation element it returned.
Concurrency: parallel-safe (conflict domain: the individual element), same as add_elements — fan out across subagents freely; the server merges per-element under a per-guide lock. Two edits to the same element id serialize. Do NOT run concurrently with whole-clip/whole-project mutations on the same guide (update_clips on that clip, structural clip ops, add_audio, update_project).
Keyframes: pass a top-level keyframes array (sibling of x/y/type_data, NOT inside type_data) to set, or null to clear. Per-entry shape: { timestamp, positionX?, positionY?, width?, height?, interpolation? } in canvas pixels; positionX/Y use the element's alignment-aware origin.
Text elements: pass fit_to_lines: N to run an automatic widen + font-shrink pass after the entry's regular update lands. The server reshapes the element so the rendered text wraps to at most N lines without overlapping its neighbours.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| updates | Yes | Element updates — at least one entry. | |
| project_id | Yes | Project ID |