Skip to main content
POST
POST /v1/audio/sound-effects generates a sound effect from a text description, such as a door creak, footsteps, or an ambience bed, and returns the audio file as the response body. Set loop for a sound that repeats seamlessly.
string
required
Set to eleven-sound-effects-v2.
string
required
What the sound should be, up to 1,000 characters.
number
default:"5"
Length in seconds, from 0.5 to 30. Billed rounded up to whole seconds.
number
From 0 to 1. Higher values follow the prompt more closely.
boolean
true makes a sound that loops seamlessly.
string
default:"mp3"
mp3, opus, or pcm. See Output formats.
Fields that aren’t listed here return invalid_request.

Response

A successful request returns HTTP 200 with the audio as the body. The Content-Type matches response_format: audio/mpeg, audio/ogg, or audio/pcm. The response carries x-gateway-execution-id.

Billing

The request is billed for duration_seconds, rounded up to whole seconds, at $0.003 per second. When you omit duration_seconds, the gateway requests and bills 5 seconds ($0.015). A 2.5-second effect bills 3 seconds ($0.009), and the 30-second maximum costs $0.09. Failed requests aren’t charged. This endpoint rejects Idempotency-Key. If a request times out, check your Console request logs before you retry.

Errors

See Errors for rate limits and provider failures.