Model API'si
ElevenLabs Music
Videona ya da başka bir projene uygun müzik üret. İstediğin tarzı, tempoyu ve kullanılacak enstrümanları tarif et.
Model kimliği
elevenlabs/music/v2.5Bu modelin kendi kimliği olan başka modları da var: elevenlabs/music.
Çalıştır
Girdiye ücret teklifi al, bu teklifle üretimi başlat, ardından işin durumunu sorgula. Önce RAYWAKE_API_KEY değişkenini ayarla; ayrıntılar için Kimlik doğrulama sayfasına bak.
# 1. Price the exact input (quotes are valid for up to 10 minutes)
curl -s https://api.raywake.com/v1/quotes \
-H "Authorization: Bearer $RAYWAKE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "elevenlabs/music/v2.5",
"input": {
"prompt": "A red ceramic cup on a wooden table, soft morning light"
}
}'
# 2. Start the generation with the quote_id from step 1
curl -s https://api.raywake.com/v1/generate \
-H "Authorization: Bearer $RAYWAKE_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{"model": "elevenlabs/music/v2.5", "quote_id": "QUOTE_ID", "input": {"prompt":"A red ceramic cup on a wooden table, soft morning light"}}'
# 3. Poll until the status is terminal
curl -s https://api.raywake.com/v1/jobs/JOB_ID \
-H "Authorization: Bearer $RAYWAKE_API_KEY"Girdi
| Alan | Tür | Açıklama |
|---|---|---|
prompt | string | The text prompt describing the music to generate |
composition_plan | object | The chunk-based composition plan for the music |
music_length_ms | integer | The length of the song to generate in milliseconds. Used only in conjunction with prompt. Must be between 3000ms and 600000ms. Optional - if not provided, the model will choose a length based on the prompt. |
force_instrumental | boolean | If true, guarantees that the generated song will be instrumental. If false, the song may or may not be instrumental depending on the prompt. Can only be used with prompt. |
seed | integer | Random seed to initialize the music generation process. Can only be used with composition_plan. The same seed with the same parameters gives more consistent results, but exact reproducibility is not guaranteed. |
output_format | string (enum) | Output format of the generated audio. Formatted as codec_sample_rate_bitrate. So an mp3 with 22.05kHz sample rate at 32kbs is represented as mp3_22050_32. Note that the μ-law format (sometimes written mu-law, often approximated as u-law) is commonly used for Twilio audio inputs. |
Çıktı
Başarılı bir iş, sonuçlarını outputs altında listeler; dosyalar bizim tarafımızda saklanır. Tüm alanlar için İşler sayfasına bak.
"outputs": [
{ "type": "audio", "url": "https://…", "mime_type": "audio/mpeg", "thumbnail_url": null }
]Fiyatlandırma
- en fazla, varsayılan ayarlar$4,76/ üretim
Girdinin kesin ücreti ücret teklifinden gelir. Bakiye nasıl kesinleşir?