Skip to main content
Glama

create_track

Generate and add a new track in Ableton Live via MCP. Specify track type (audio, midi, or return) and optional index for precise placement in your project.

Instructions

create track and return raw track

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
indexNo[int] index of track default 0, range [0, track count]
typeYesthe type of track, "return", "audio", "midi"

Implementation Reference

  • The main execution logic for the 'create_track' tool. Creates a MIDI, audio, or return track in Ableton Live at the given index using the song's API methods and returns the raw track object.
    async createTrack({ type, index = 0 }: { type: TrackType, index?: number }) { let track: Track switch (type) { case TrackType.midi: track = await ableton.song.createMidiTrack(index) break case TrackType.audio: track = await ableton.song.createAudioTrack(index) break case TrackType.return: track = await ableton.song.createReturnTrack() break } return track.raw }
  • Registers the `createTrack` method as the MCP tool named 'create_track' using the @tool decorator, including description and input schema definition.
    @tool({ name: 'create_track', description: 'create track and return raw track', paramsSchema: { type: ZodTrackType, index: z.number().optional().default(0).describe('[int] index of track default 0, range [0, track count]'), } })
  • src/main.ts:41-41 (registration)
    Includes the SongTools class in the list of tools passed to the MCP server starter (`startMcp`), enabling registration of all its decorated tools including 'create_track'.
    tools: [BrowserTools, ClipTools, DeviceTools, HistoryTools, SongTools, TrackTools, ExtraTools, ApplicationTools]
  • Defines the input schema for the 'create_track' tool within the @tool decorator: track type (enum via ZodTrackType) and optional index.
    type: ZodTrackType, index: z.number().optional().default(0).describe('[int] index of track default 0, range [0, track count]'), }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/xiaolaa2/ableton-copilot-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server