Skip to main content
Glama

generate_music

Generate an instrumental music track (no vocals) for a game: an MP3 of 30-120 seconds saved as a music asset in the user's Voidless library. For a single short sound (a hit, a pickup, a click) use generate_sfx instead. 10 credits on every call, whatever the length (each call makes and bills a new track; refunded if it fails); a slow run returns a job for check_generation. Returns the asset ID, the MP3 link and the credits left. For free game music made at once (ten styles, 8-bit or high quality, seamless loops and stingers, as WAV and MIDI), use compose_music.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "prompt": "<prompt>"
    },
    "name": "generate_music"
  }
}

Input Schema

NameRequiredDescriptionDefault
bpmNoTempo in beats per minute, 80-200 (default 100): about 80-100 for calm or exploration music, 120-160 for action or chases
promptYes10-300 characters naming the genre, mood, instruments and where it plays, e.g. 'upbeat chiptune with square-wave lead for a title screen'. Leave tempo and key to bpm and keyScale, which are added to the prompt
durationNoTrack length in seconds, 30-120 (default 60). The price does not change with length
keyScaleNoMusical key and scale, e.g. 'A minor', 'D major' (default 'C major'). Minor keys sound darker or tenser, major keys brighterC major

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • addedInput schema / properties / bpm / description
      Added value: +"Tempo in beats per minute, 80-200 (default 100): about 80-100 for calm or exploration music, 120-160 for action or chases"
    • changedInput schema / properties / duration / description
      Previous value: -"Seconds (30–120)"New value: +"Track length in seconds, 30-120 (default 60). The price does not change with length"
    • changedInput schema / properties / keyScale / description
      Previous value: -"e.g. 'A minor', 'D major'"New value: +"Musical key and scale, e.g. 'A minor', 'D major' (default 'C major'). Minor keys sound darker or tenser, major keys brighter"
    • changedInput schema / properties / prompt / description
      Previous value: -"Genre, mood and instruments, e.g. 'upbeat chiptune for a title screen' (10–300 chars)"New value: +"10-300 characters naming the genre, mood, instruments and where it plays, e.g. 'upbeat chiptune with square-wave lead for a title screen'. Leave tempo and key to bpm and keyScale, which are added to the prompt"
  2. First observed

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Far beyond the annotations: it discloses the exact cost (10 credits per call, length-independent, refunded on failure), that every call creates and bills a new track (consistent with idempotentHint=false but stated in plain terms), and that a slow run returns a job rather than a track. It also describes the return payload (asset ID, MP3 link, credits left), which the absent output schema would otherwise leave opaque.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action and output, then branching rules, then economics and return shape; no filler sentences. Slightly dense in the closing compose_music parenthetical, which packs five qualifiers into one clause, but every element there carries routing information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Complete for a paid generative tool: cost, refund behavior, async fallback, and return values are all covered despite the missing output schema. The only mild gap is failure modes beyond cost refund, though 'refunded if it fails' implies the agent needn't pre-validate.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline would be 3, but the description adds real value: it frames the track as 30-120 seconds (the duration range) and reinforces that price is length-independent, which shapes how an agent will choose a duration. The 'whatever the length' framing directly informs a parameter trade-off the schema states only as a flat note.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Generate an instrumental music track (no vocals)'), plus concrete output characteristics: MP3, 30-120 seconds, saved as a music asset in the user's library. It explicitly distinguishes itself from generate_sfx and compose_music, so an agent can route without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit when-to-use-elsewhere rules: short one-shot sounds go to generate_sfx, and bulk free game music (loops, stingers, WAV/MIDI, ten styles) goes to compose_music. It also names check_generation as the follow-up path for slow runs, leaving nothing to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources