Skip to main content
Glama

Generate Music

generate_music
Destructive

Use this to create an AI music track (full songs with vocals, or instrumentals). Three models: music-3.0 (default, 200 credits — songs from a prompt and/or lyrics, lyrics optimizer on by default so a prompt alone works), mureka-v9 (60 credits — sings the user's EXACT lyrics verbatim, or instrumental/BGM), and lyria-3 (100 credits — high-fidelity from a rich prompt, can condition on up to 10 reference images), and sonilo-music (instrumental/background music of an EXACT length via duration, 5–360 s — priced PER SECOND at 4 credits/s with a 10-second minimum, no vocals). VIDEO-TO-MUSIC: pass a video URL (upload_media first for local files) and sonilo-video-music composes a licensed soundtrack for the clip's content, pacing and mood — priced per second of the video's measured length (15 credits/s, 10 s minimum, ≤360 s). Flat price per track (per second for the Sonilo models), charged on success only; each call starts a new paid job. Submits an async job and returns a numeric job_id — music takes a minute or three: poll check_generation_status with the job_id AND type "music" every 15–30 seconds, then share the finished track's listen/download link with the user (chat can't embed audio players).

Input Schema

NameRequiredDescriptionDefault
modelNoMusic model id. Omit for the default (music-3.0 — latest MiniMax, all-purpose songs, 200 credits; passing a video auto-selects sonilo-video-music). Alternatives: music-2.6 (previous generation, same price), mureka-v9 (sings exact lyrics, cheapest at 60), lyria-3 (high-fidelity, image conditioning, 100), sonilo-music (instrumental/background music of an exact length, priced per second — pass duration). Call list_models for details.
videoNoVideo-to-music: URL of a video (≤360 s, ≤30 MB for public URLs) to compose a licensed soundtrack FOR — the music follows the clip's content, pacing and mood, and matches its length. Must be a URL — upload local files with upload_media first. Uses sonilo-video-music: 15 credits per second of the video's measured duration (10-second minimum). prompt becomes optional direction (genre/mood/instrumentation); no lyrics or duration.
formatNomusic-2.6/music-3.0 only: output audio format, wav (default) or mp3.
imagesNolyria-3 only: up to 10 reference images to condition the mood — each a URL, data URI, or raw base64 (upload local files with upload_media).
lyricsNoLyrics to sing. mureka-v9 sings them VERBATIM ([verse]/[chorus] tags supported); music-2.6/music-3.0 polish them unless lyrics_optimizer is false; lyria-3 treats them as optional guidance.
promptNoStyle/mood description of the track. Required for lyria-3 (10–2000 chars) and for instrumental tracks; optional on music-2.6/music-3.0 when lyrics are given.
durationNosonilo-music only: track length in seconds (5–360, default 30). Billed per second with a 10-second minimum (4 credits/s → 30 s = 120 credits). Other music models ignore length (sonilo-video-music sizes the music to the video).
instrumentalNoGenerate an instrumental track (no vocals). music-2.6/music-3.0 and mureka-v9 (mureka requires a prompt in this mode).
vocal_genderNomureka-v9 only: preferred vocal gender for songs (default auto).
lyrics_optimizerNomusic-2.6/music-3.0 only. Write/polish lyrics from the prompt — DEFAULT TRUE (matches web/API). Set false to sing the provided lyrics as-is.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already declare readOnly=false, openWorld=true, destructive=true, but the description adds substantial context the annotations cannot: it submits an async job returning a numeric job_id, takes 'a minute or three', must be polled via check_generation_status with type "music" every 15–30s, is charged on success only, starts a new paid job each call, and returns a listen/download link that chat cannot embed. This is exactly the extra behavior an agent needs.

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

Conciseness3/5

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

Front-loaded with the core purpose, but it is one dense wall of text mixing model selection, pricing, video-to-music and async/polling flow, with notable repetition of what the schema param descriptions already state. Given the 10-param, 4-model complexity some length is justified, but structure (bullets/sections) would have improved scannability.

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

Completeness5/5

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

For a high-complexity tool with no output schema, the description covers everything an agent needs: cost model, async submission and polling contract, the exact follow-up tool and cadence, and how to deliver the result to the user. No obvious gap remains for correct invocation.

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

Parameters3/5

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

Schema description coverage is 100% and the schema already documents model pricing, video constraints, duration billing and per-model parameter applicability in detail; the description largely restates this (model prices, per-second billing, lyrics behavior). It adds cross-parameter interaction (passing a video auto-selects sonilo-video-music), but that is also mirrored in the schema. Baseline 3 is appropriate when the schema does the heavy lifting.

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+resource ('create an AI music track') and immediately scopes it (full songs with vocals, or instrumentals), clearly separating it from sibling generators like generate_image, generate_video and generate_sound_effect. The four-model breakdown further pins down exactly what this tool produces.

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?

Explicit routing rules: which model to pick for songs vs exact lyrics vs instrumental, when to pass a `video` URL for video-to-music (with upload_media as the prerequisite for local files), and when to use the duration-based Sonilo path. It even points to list_models for deeper detail and names the follow-up tool for polling.

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.