add_audio_overlay
Add an audio overlay (mp3/m4a/wav/ogg) scheduled at a frame-aligned start. The asset must already exist at users//assets//. 30 fps; convert seconds with frames = round(s * 30). Plays in the editor preview and is mixed into the MP4 export.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| gain | No | Linear gain 0..2. Default 1. | |
| endFrame | No | Optional end frame; omit to play the asset's full natural length from startFrame. | |
| filename | Yes | Audio asset filename in the project's assets bucket. | |
| projectId | Yes | Opaque project id (a v4 UUID, from list_projects/create_project). Selects which existing project this call mutates. | |
| startFrame | Yes | Frame at which the overlay starts (0-indexed, 30 fps). | |
| fadeInFrames | No | Linear fade-in length in frames. Default 0. | |
| fadeOutFrames | No | Linear fade-out length in frames. Default 0. | |
| sourceLayerId | No | Optional video layer element id ("video.<id>") to weld this overlay to. When set, the editor renders the overlay as a waveform footer on that clip and drags it with the clip instead of showing a standalone bottom row. |