Lyria 3.5 has no duration field: how to ask for a 45-second track
Sume's music router rejects duration and duration_seconds. Write the length into the prompt, with section timestamps, and pay a flat $0.125 per generation.

You cannot set a duration on Sume's music router: duration and duration_seconds are rejected, so you ask for the length in the prompt, such as "a 45-second track". Every generation costs a flat $0.125, so a prompt that misses the length costs the same as one that hits it.
Prompt styles and what they cost
Two ways to express length, both inside prompt (1 to 5,000 characters):
| Style | Example text in prompt | Price |
|---|---|---|
| Plain length | A 45-second track. | $0.125 |
| Section map | [0:00-0:15] Intro: soft piano. [0:15-0:45] Build: add strings. | $0.125 |
| Rerolls (3 attempts) | same prompt, three keys | $0.375 |
A request that sets length and keeps the negatives positive
negative_prompt must be omitted or an empty string; a non-empty value fails with 400 negative_prompt_unsupported. Say what to leave out inside the prompt itself.
curl -X POST https://api.sume.com/v1/music-router/generate \
-H "Authorization: Bearer $SUME_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: explainer-bed-01" \
-d '{"prompt": "Calm corporate bed, 100 BPM. [0:00-0:15] Intro: soft piano. [0:15-0:45] Build: add strings, light pulse. A 45-second track. Instrumental, no vocals."}'What to check
If you need an exact length, trim or loop in a follow-up step (Timeline audio is $0.01 per job) rather than regenerating.
- Measure the returned file; the length is a request, not a guarantee.
- Read result.lyrics when present for the section map the model reports.
- Read job.request.routed_model to see the engine that ran.
Sources
Related posts
More in Developers
- MCP authorization spec: 6 requirements vs what Sume documents
The MCP authorization spec asks for resource metadata, PKCE and a resource parameter. Here is what hosted Sume MCP documents for each, and what stays open.
- Sume hosted MCP from a CI runner: API key or OAuth?
A headless runner cannot finish the OAuth consent page. Hosted Sume MCP also takes an API key as Bearer or x-api-key. What that session can call, and the rules.
- MCP generate_video max_spend_usd for Wan 3.0: 480p, 720p, 1080p
What to put in max_spend_usd when an MCP client calls generate_video for Wan 3.0: $0.625 to $7.50 for 10 and 30 seconds. Includes the dry_run body.
- MCP read-only OAuth session: which Sume tools you do and do not see
With OAuth mcp:read, hosted Sume MCP hides write and paid tools and returns insufficient_scope if you call them. What tools_list shows with Write off and on.
Written by Sume