manage_tracks
Track operations on a timeline. action: 'mute' | 'unmute' | 'solo' | 'unsolo' (audio only; any solo silences non-solo tracks) | 'hide' | 'show' | 'rename' (needs name) | 'duck' | 'unduck' (audio only: dip this track under speech detected on the other audio tracks — transcript word timings when available, energy VAD otherwise) | 'merge' (needs intoTrackId: moves every clip of trackId onto another track of the same kind; refuses the WHOLE move if any clip would overlap, or if the source carries transitions) | 'delete' (an EMPTY track; refuses one that holds clips — deleting those is remove_clips, by name) | 'tidy' (NO trackId: drops the empty leftover tracks and renumbers). Track ids come from get_timeline. TIDYING UP, AND WHY ORDER MATTERS. Track counts only ratchet up while you build: a spare appears above whatever you fill, and the video and audio counts are kept EQUAL. That last rule is the one that surprises people — five video tracks force five audio tracks, however empty. So:
'merge' the tracks that hold clips but need not be separate (captions from several passes, b-roll that never overlaps). This is what actually lowers the count.
'tidy' once at the end. It settles both sides on one spare above the taller one and reports removedTracks. 'delete' on a single empty track usually reports removedTracks: 0 — the invariant puts it straight back to keep the counts equal. That is not a failure, it is why 'tidy' exists. Neither ever touches a clip, and both keep an empty track you renamed, muted, hid, soloed, unlocked or set to duck.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | New name (rename only). | |
| token | Yes | The session token `connect` returned. Pass it on every call — it says which browser to drive. | |
| action | Yes | mute | unmute | solo | unsolo | hide | show | rename | duck | unduck | merge | delete | tidy | |
| trackId | No | Track to modify. Required for every action except 'tidy'. | |
| projectId | Yes | Project id from get_projects. | |
| timelineId | Yes | Target timeline. | |
| intoTrackId | No | Destination track (merge only) — same kind as trackId. |