Generate a music track
studio_musicCosts the price of one AI music track for the project (a track already bought for this genre and length re-selects free). confirm_cents is the most you agree to pay: the step charges what it costs, never more, and refuses with price_changed (charging nothing) when it costs more. Call it with confirm_cents: 0 to learn the price of a paid step (the answer is price_changed with price_cents; nothing is charged). A free step (a standard voice, a visual already bought) just runs. Idempotency is keyed on (this token, this tool, idempotency_key), not on the arguments.
Args: project_id: project. genre: 1-40 chars, e.g. "lofi". confirm_cents: the most the user agreed to pay, in cents. idempotency_key: unique per purchase (recommended).
Returns: {ok, job_id|null, reused?, cents, poll}: poll studio_get_project until project.music_generating is false.
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": {
"project_id": "<project_id>",
"confirm_cents": "<confirm_cents>",
"genre": "<genre>"
},
"name": "studio_music"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| genre | Yes | ||
| project_id | Yes | A project id from studio_list_projects. | |
| confirm_cents | Yes | The most the user agreed to pay, in whole cents (0 learns the price). | |
| idempotency_key | No | Any unique string (1-200 printable chars) so a retry never buys twice. |