add_image_layer
Add an image layer. The asset must already exist at users//assets// (uploaded via the editor's drag-drop, or POST /api/upload-asset/ with the raw bytes and an X-Filename header). To duplicate an existing layer, reuse its filename — the editor auto-assigns a fresh id.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | Centre x in 1080-wide base coords. | |
| y | Yes | Centre y in 1920-tall base coords. | |
| block | No | OPTIONAL timeline window — {start, duration} in composition frames. OMIT IT (the default) and the layer is ALWAYS PRESENT: a persistent overlay that holds for the whole composition, which is what an agent-placed watermark / lower-third almost always wants. Pass it to place a bounded CLIP instead (what the editor's own add does: 5 s at the playhead). Keyframes on a blocked layer are sampled RELATIVE to `start`. | |
| width | Yes | Width in px (must be > 0). | |
| height | Yes | Height in px (must be > 0). | |
| filename | Yes | Asset filename in the project's assets bucket, e.g. star.png. | |
| projectId | Yes | Opaque project id (a v4 UUID, from list_projects/create_project). Selects which existing project this call mutates. |