editor.sound.effect.add
Adds a sound effect to a clip with sound.
JSON-RPC 2.0project.write
settings is {key: value}: numbers within the setting's range, switches true or false, choices by name, colours "#RRGGBB".
Parameters
- clipstringrequiredThe clip's id, from editor.timeline.get.
- kindstringrequiredA sound effect kind (
audio.*) or its name. - settingsobjectIts settings.
- onbooleanOn or off. Default on.
- canvasstringA canvas's id or name, shown first. Default: the canvas shown.
Result
- (the effect){ id: string, kind: string, name: string, on: boolean, settings: object }The effect.
Errors
Invalid params (-32602) for an unknown kind or setting, or a clip with no sound. A state error (-32005) when no Editor project is open, or the open one is read-only because a newer Lightair made it. Invalid params (-32602) for a clip id that can't be read; not found (-32004) for a clip that isn't on the canvas.
Events
Subscribers to events get editor.changed.
From an AI agent
The MCP server's editor_sound (action: effect_add) reaches this method.
Example
{ "jsonrpc": "2.0", "id": 1, "method": "editor.sound.effect.add", "params": {}}lightair call editor.sound.effect.addconst result = lightair.call("editor.sound.effect.add", {});