Skip to main content

ElevenLabs Text-to-Sound

Generate realistic sound effects from text descriptions using ElevenLabs' advanced AI sound synthesis technology.

Supported Models

  • elevenlabs-text-to-sound: ElevenLabs Text-to-Sound Effects service

Parameters

ParameterTypeRequiredDescription
textstringYesDescription of the sound effect to generate
duration_secondsnumberYesDuration of the sound effect in seconds (range: 0.5 to 30)
prompt_influencenumberYesHow closely the generation follows the prompt
output_formatstringYesAudio output format
loopbooleanNoEnable seamless looping of the generated sound (default: false)

Output Format Options

  • mp3_44100_128 - MP3, 44.1kHz, 128kbps
  • mp3_22050_32 - MP3, 22.05kHz, 32kbps
  • mp3_44100_192 - MP3, 44.1kHz, 192kbps
  • mp3_44100_32 - MP3, 44.1kHz, 32kbps
  • mp3_44100_64 - MP3, 44.1kHz, 64kbps
  • mp3_44100_96 - MP3, 44.1kHz, 96kbps

Request Example

API Playground

http://localhost:3000/api/features

Generated cURL Command:

curl -X POST "http://localhost:3000/api/features" \
-H "API-KEY: c919a70cfbef2ab75b870d7148973926854e4605245a5fde8dc537198568b584" \
-H "Content-Type: application/json" \
-d '{
"type": "TEXT_TO_SOUND",
"model": "elevenlabs-text-to-sound",
"conversationId": "TEXT_TO_SOUND",
"promptObject": {
"text": "A dog barking in the distance, followed by gentle rain falling on leaves",
"duration_seconds": 5,
"prompt_influence": 0.3,
"output_format": "mp3_44100_128",
"loop": false
}
}'

Response Format

{
"aiRecord": {
"uuid": "bb5c2d5d-8f8b-4888-b646-b253dd8969f3",
"userId": "c937fbcc-fa8f-4565-a440-c4d87f56fcb2",
"teamId": "a4e176b2-dabb-451e-9c58-62b451fa9630",
"teamUser": {
"teamId": "a4e176b2-dabb-451e-9c58-62b451fa9630",
"userId": "c937fbcc-fa8f-4565-a440-c4d87f56fcb2",
"userName": "Dương Nguyễn",
"userAvatar": "https://lh3.googleusercontent.com/a/ACg8ocLqgsNsHRfmWF9d-E1RvJetVsEzxNOsOg-NXWNTpMxLDPJbwELI=s96-c",
"status": "ACTIVE",
"role": "ADMIN",
"creditLimit": 100000000,
"usedCredit": 1108243,
"createdAt": "2025-10-20T04:13:40.847Z",
"createdBy": "SYSTEM",
"updatedAt": "2025-10-21T10:51:55.853Z",
"updatedBy": "SYSTEM"
},
"model": "elevenlabs-text-to-sound",
"type": "TEXT_TO_SOUND",
"metadata": null,
"rating": null,
"feedback": null,
"conversationId": null,
"status": "SUCCESS",
"createdAt": "2025-10-21T10:52:19.827Z",
"aiRecordDetail": {
"promptObject": {
"loop": false,
"text": "A dog barking in the distance, followed by gentle rain falling on leaves",
"output_format": "mp3_44100_128",
"duration_seconds": 5,
"prompt_influence": 0.3
},
"resultObject": [
"development/audios/2025_10_21_17_52_25_414_538984.mp3"
],
"responseObject": {}
},
"additionalData": null,
"temporaryUrl": ""
}
}

Use Cases

  • Sound Design: Create custom sound effects for videos, games, and multimedia projects
  • Audio Production: Generate ambient sounds, foley effects, and background audio
  • Content Creation: Add realistic sound effects to podcasts, videos, and presentations
  • Game Development: Generate dynamic sound effects based on in-game events
  • Film Production: Create custom sound effects for scenes and transitions

Tips for Best Results

  1. Be Specific: Describe the sound in detail including texture, distance, and environment
  2. Duration: Shorter durations (2-5 seconds) often produce more focused effects
  3. Prompt Influence: Higher values (0.5-0.8) make the output follow your description more closely
  4. Looping: Enable for background ambience or continuous effects
  5. Examples:
    • "Thunder rumbling in the distance during a heavy storm"
    • "Footsteps on gravel getting closer"
    • "Ocean waves crashing against rocks"
    • "Keyboard typing in a quiet office"
    • "Wind chimes tinkling in a gentle breeze"