Skip to content

MCP: edit operations

track.update

Sets a track's name, flags (hidden, muted, locked, solo, magnet) or volume.

Last updated:

Sets the given fields. hidden applies to visual tracks, the others to both kinds. locked refuses every edit of the items of the track (E_INVALID_STATE) until it is unlocked. solo plays only the soloed tracks: the picture of visual tracks when one is solo, and the sound of every track. volume is a factor from 0 to 4 on the volume of the items of the track; 1 clears it. magnet packs the items of the track from frame 0 with no gap, now and after every later edit (a locked track is not repacked).

Arguments#

ArgumentTypeRequiredNotes
hiddenbooleannoVisual tracks only.
lockedbooleannoTrue refuses every edit of the items of the track until it is false again.
magnetbooleannoTrue keeps the items of the track packed from frame 0 with no gap, closing the gaps now and after every edit.
mutedbooleanno
namestringnoThe track name; "" clears it.; max length 60
solobooleannoTrue plays only the soloed tracks (the picture of visual tracks, the sound of all).
track_idstringyespattern ^trk_[0123456789abcdefghjkmnpqrstvwxyz]{10}$
volumenumbernoFactor on the volume of the items of the track, 0 to 4; 1 is neutral.; min 0; max 4

Errors#

Scope#

Scope edit. The scope is the one an API key needs in network mode. Run stuarty command:help track.update for the same description from the binary, or call the command_help tool.

Next steps#

As an MCP call

tools/call
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "edit",
    "arguments": {
      "project_id": "prj_7k2m9x4q1b",
      "base_revision": 12,
      "operations": [
        {
          "op": "track.update",
          "args": {
            "hidden": true,
            "track_id": "trk_f6g7h8j9k0"
          }
        }
      ]
    }
  }
}

As a batch file for the CLI

batch.json
[
  {
    "op": "track.update",
    "args": {
      "hidden": true,
      "track_id": "trk_f6g7h8j9k0"
    }
  }
]
Terminal
stuarty edit --project prj_7k2m9x4q1b --ops batch.json --json

Over HTTP

curl
curl -X POST "http://127.0.0.1:7878/api/v1/projects/prj_7k2m9x4q1b/edit" \
  -H "Authorization: Bearer $STUARTY_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "base_revision": 12,
  "operations": [
    {
      "op": "track.update",
      "args": {
        "hidden": true,
        "track_id": "trk_f6g7h8j9k0"
      }
    }
  ]
}'

The ids in the example are illustrative: read the real ones with project_get.