Lyria 3.5
lyria-3.5
Google's flagship music generation model that first plans the structure of intro, verse, chorus, and so on, then generates a complete song with vocals and lyrics, supports singing in multiple languages, and can be called via the unified HiAPI.ai API
Try lyria-3.5
Input
Showcases
View all showcasesOutput
audioPricing
lyria-3.5 per song
| Unit Price | $0.090 |
|---|
Positioning Overview
Lyria 3.5 is a model for text-to-music scenarios, callable through the unified HiAPI.ai interface. It can generate a complete song from a music description (genre, instruments, mood, structure), or directly submit lyrics with [Verse] and [Chorus] section markers for sung performance, with optional song length, BPM, title, and random seed. The output is a complete song with vocals, suitable for developers who need to quickly obtain a well-structured finished product, for content scoring, multilingual songs, and creative demo validation.
Core Highlights
- Organizes the whole song by section, rather than stitching fragments — before generation it plans the intro, verse, chorus, bridge, and other structures, so the finished product has clear sections and coherent flow.
- Either a description or lyrics alone can produce a song — supplying only a music description yields an instrumental or vocal work; supplying only lyrics goes straight into sung generation.
- Song length and tempo can be constrained in the request — you can specify a target duration of 1 to 240 seconds and a numeric BPM, making it easy to reserve length according to placement.
Capabilities
Generating a whole song from a text description: use a description of up to 10,000 characters to specify genre, instruments, mood, and structure, and directly obtain a complete track, reducing manual arrangement and editing steps.
Lyrics-driven vocals: submit lyrics containing section markers to generate a song with vocals, and optionally fill in a title, producing a lyrics-and-music demo ready for direct listening.
Controllable duration and tempo: you can request a target duration of 1 to 240 seconds and specify BPM; the actual output duration may deviate from the requested value, so design around ranges rather than exact values.
Random seeds and reproducible attempts: you can pass numeric seeds to organize multiple rounds of generation, but the same settings do not guarantee identical audio output, making it suitable for variant exploration rather than deterministic reproduction.
Audio-only output: returns a finished audio file that can go directly into an asset library or downstream distribution workflow, with no further format conversion needed.
Use Cases
- Short-video and podcast scoring for content creators — input a music brief describing atmosphere and rhythm to get background music matching the finished video's length, ready to drop onto the editing timeline.
- Lyrics audition demos for music creators — submit lyrics marked with [Verse] and [Chorus] to produce a listenable sung version, used for validating lyrical and melodic ideas and comparing versions.
- Custom scoring for advertising and brand content — generate original tracks that fit the visual tone from genre, instrument, and mood descriptions, serving as scoring drafts for campaign assets.
- Music prototypes for games and interactive media — use descriptions plus BPM and duration constraints to batch-generate atmospheric segments as early prototypes for level or interface music for team review.
Limitations and Selection Advice
It supports only text and lyrics input and does not accept image guidance; the output is a watermarked audio file, and generation results cannot be cached. A single track lasts from seconds to several minutes, so it is not suitable for cases requiring long continuous scoring or lossless high-fidelity delivery. The actual output duration and audio details are not guaranteed to match the request parameters exactly, and the same seed cannot reproduce the same result. If you need precisely controllable audio editing, stem separation, or deterministic reproduction, evaluate other solutions; this model is better suited to quickly producing structurally complete finished songs.
What's new
View changelog →- New model Added lyria-3.5 API documentation for song generation from a…
Create a generation task
https://api.hiapi.ai/v1/tasks Headers
AuthorizationstringRequiredAccount API key. Required on every request. Example: Bearer YOUR_HIAPI_API_KEY. Get your API key
Content-TypestringOptionalThe request body is always parsed as JSON; when sent, only application/json (optionally with charset) is accepted — any other value returns 415. Example: application/json.
Idempotency-KeystringOptionalIdempotency key, up to 255 bytes. Retries with the same key from the same account create the task only once; replays return the original taskId.
On network timeouts or client retries, the same key creates the task only once — no double charges (scope: the API key's account). Use a business-unique identifier as the key (e.g. "order-42"); replays return the original taskId, and keys expire 24 hours after the first request. See the Unified Async API overview for the full scenario matrix.
Body
modelstringRequiredCurrent fixed value: lyria-3.5
routestringOptionalCurrent fixed value: default
inputobjectRequired
Business parameters for lyria-3.5 and route default — see the parameter table below.
bpmstringOptionalpattern ^[1-9][0-9]*(\.[0-9]+)?$Optional. Specifies the tempo (BPM) of the generated track, passed as a numeric string with a minimum value of 1.
seedstringOptionalminLength 1pattern ^[0-9]+$Optional. Random seed, passed as a numeric string; identical settings do not guarantee identical generated audio.
titlestringOptionalOptional. Specifies a title for the generated song.
lengthintegerOptionalmin 1max 240Optional. Requested audio duration in seconds, ranging from 1 to 240; the actual output duration may differ.
lyricsstringOptionalminLength 1pattern \SOptional. Lyrics content, which may use section tags such as [Verse] and [Chorus]; at least one of lyrics or music description must be provided.
promptstringOptionalminLength 1maxLength 10000pattern \SOptional. Music description, used to specify style, instruments, mood, and structure; at least one of music description or lyrics must be provided.
callbackobjectOptional
Terminal-state notification config. When omitted, no callback is delivered — poll the task yourself. See the callback note below.
Provide callback.url when creating a task and HiAPI POSTs to your service once the task reaches a terminal state — no polling needed. The callback payload mirrors the task detail structure; signature verification, delivery retries and idempotency are documented on the Unified Async API overview page.
urlstringRequiredRequired when callback is present. A POST is sent to this URL once the task reaches a terminal state; must be a valid http(s) URL.
whenstringOptionalDefault: "final"Only final is supported today — notified on both success and fail.
finalstoragestringOptionalDefault: "temp"Artifact storage tier: temp (default, retained about 7 days) or persistent (long-term, billed by size). Insufficient balance or exceeding the storage cap silently downgrades to temp; the effective tier is shown in the task detail response.
temppersistentRequest examples
# Submit an async task; returns a taskId immediately (no waiting for generation)
curl -X POST "https://api.hiapi.ai/v1/tasks" \
-H "Authorization: Bearer $HIAPI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "lyria-3.5",
"input": {}
}' const res = await fetch("https://api.hiapi.ai/v1/tasks", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.HIAPI_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
model: "lyria-3.5",
input: {}
}),
});
const task = await res.json();
// { code: 200, message: "success", data: { taskId } } import os, requests
res = requests.post(
"https://api.hiapi.ai/v1/tasks",
headers={"Authorization": f"Bearer {os.environ['HIAPI_API_KEY']}"},
json={
"model": "lyria-3.5",
"input": {}
},
)
print(res.json()) # { code, message, data: { taskId } } 200 OK
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-01HZTQ8BX2N3GM3YFK4Z9D7VQR"
}
} 400 Bad Request
{
"code": 400,
"message": "invalid request",
"data": null,
"error_code": "INVALID_REQUEST"
} Get task detail
https://api.hiapi.ai/v1/tasks/:id Response fields
taskIdstringRequiredTask ID, always prefixed with tk-hiapi-.
modelstringRequiredResolved full model name. Tasks submitted with the route parameter return base@route (e.g. gpt-image-2/text-to-image@ext); otherwise identical to the name passed at creation.
routestringOptionalPresent only when the task was submitted with an explicit route parameter; echoes the submitted value.
statusstringRequiredTask status.
queued Queued, not started yet.
handling Being processed.
archiving Processing finished, artifacts being prepared.
success Terminal: completed, artifacts available (output returned).
fail Terminal: failed (error returned).
After submission, check status: success and fail are terminal, everything else is non-terminal. Poll every 1–3 seconds until terminal. On success, download artifacts from output[].url and transfer them before expireAt; pass storage: "persistent" at creation time when long-term retention is needed.
creatednumberRequiredTask creation time (Unix seconds).
completednumberRequiredUnix seconds when the task reached a terminal state; fixed to 0 while not terminal.
outputarrayOptional
Present only when status == success. Artifact list — always an array; a single task may return multiple types at once (e.g. video + first_frame).
Array [ object ]
Array items
urlstringRequiredArtifact URL, directly downloadable.
typestringRequiredCurrent possible values: video, image, audio, first_frame, last_frame, thumbnail; more may be added later.
expireAtnumberRequiredUnix seconds until which the artifact remains accessible; download or transfer before it expires.
errorobjectOptional
Present only when status == fail.
codestringRequiredBusiness error code.
messagestringRequiredError description.
Response examples
Success
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-01HZTQ8BX2N3GM3YFK4Z9D7VQR",
"model": "happyhorse-1-0",
"status": "success",
"created": 1777282033,
"completed": 1777282099,
"output": [
{
"url": "https://cdn.hiapi.ai/tasks/.../video.mp4",
"type": "video",
"expireAt": 1777886899
}
]
}
} Processing (non-terminal)
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-...",
"model": "happyhorse-1-0",
"status": "archiving",
"created": 1777282033,
"completed": 0
}
} Failed
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-...",
"model": "happyhorse-1-0",
"status": "fail",
"created": 1777282033,
"completed": 1777282099,
"error": {
"code": "TASK_FAILED",
"message": "task failed"
}
}
} Articles
View all articles →Related Models
View all models →Same Type
-
MiniMax Music 3 MiniMax $0.0026 /second -
MiniMax Music 2.6 MiniMax $0.210 /song -
ElevenLabs ElevenLabs $0.0029 /second -
Mureka 9.5 Mureka $0.322 per request -
Mirelo SFX 2.0 Mirelo AI $0.021 /second -
Lyria 3 Pro Google $0.140 /song -
MiniMax Music 1.5 MiniMax $0.070 /song -
Gemini 3.1 Flash TTS Google -- -
Qwen Audio 3.0 TTS Alibaba $0.030 /1,000 characters
Same Provider
-
Nano Banana 2 Lite Google $0.033 /image -
Gemini Omni 1.1 Flash Google $0.450 /video -
Nano Banana 2 Google $0.036 /image -
Nano Banana Google $0.021 /image -
Gemini Omni Google -- -
Imagen 4 Google $0.030 /image -
Veo 3.1 Fast Google $0.170 /second -
Nano Banana Pro Google $0.057 /image -
Lyria 3 Pro Google $0.140 /song -
Google Virtual Try-On Google $0.107 /image -
Gemini 3.1 Flash TTS Google -- -
Veo 3.1 Google $0.290 /second



