Model ID
Use with the Workers AI binding, the AI Gateway REST API, or the Unified API.
Calling the provider directly? Use the provider's model name instead, including with provider-native endpoints or the provider's own SDK. For example, Anthropic's name for anthropic/claude-opus-4.8 is claude-opus-4-8.
- Third-party
- Zero data retention
Google's Lyria 3.5 model generates full-length MP3 songs from text prompts and optional image prompts.
| Model Info | |
|---|---|
| More information | link ↗ |
| Zero data retention | Yes |
| Pricing |
|
const response = await env.AI.run(
'google/lyria-3.5',
{
prompt:
'A soulful alternative pop song about starting over, with two verses, a memorable chorus, a contrasting bridge, warm electric piano, expressive vocals, and a powerful final chorus',
},
)
console.log(response)curl https://api.cloudflare.com/client/v4/accounts/$CLOUDFLARE_ACCOUNT_ID/ai/run \
--header "Authorization: Bearer $CLOUDFLARE_API_TOKEN" \
--header "Content-Type: application/json" \
--data '{
"model": "google/lyria-3.5",
"input": {
"prompt": "A soulful alternative pop song about starting over, with two verses, a memorable chorus, a contrasting bridge, warm electric piano, expressive vocals, and a powerful final chorus"
}
}'{
"state": "Completed",
"result": {
"audio": "https://examples.aig.cloudflare.com/google/lyria-3.5/full-length-alternative-pop.mp3"
}
}prompt
stringrequiredminLength: 1maxLength: 5000image
stringminLength: 1Base64-encoded image used as visual inspirationaudio
stringGenerated music as an audio URL