eleven_music
How to Make a Call
API Schemas
Generate a music sample
post
Body
modelstring ¡ enumRequiredPossible values:
promptstring ¡ max: 2000Required
A text description that can define the genre, mood, instruments, vocals, tempo, structure, and even lyrics of the track. It can be high-level (âpeaceful meditation with voiceoverâ) or detailed (âsolo piano in C minor, 90 BPM, raw and emotionalâ). Use keywords to control genre, emotional tone, vocals (e.g., a cappella, two singers harmonizing), structure (e.g., âlyrics begin at 15 secondsâ), or provide custom lyrics directly in the prompt.
music_length_msinteger ¡ milliseconds ¡ min: 10000 ¡ max: 300000OptionalDefault:
The length of the song to generate in milliseconds. This parameter may not always be respected by the model, and the actual audio length can differ.
10000Responses
200Success
application/json
post
/v2/generate/audio200Success
Retrieve the generated music sample from the server
get
Authorizations
AuthorizationstringRequired
Bearer key
Query parameters
generation_idstringRequiredExample:
<REPLACE_WITH_YOUR_GENERATION_ID>Responses
200Success
application/json
get
/v2/generate/audio200Success
Full Example: Generating and Retrieving the Audio From the Server
lo-fi pop hip-hop ambient music, slow intro: 10 s, then faster and with loud bass: 10 s"Last updated
Was this helpful?