get_audio_from_sample
Retrieve audio bytes for a chosen ElevenLabs voice sample using voice_id and sample_id, and save the result to output_path or receive it inline as base64.
Instructions
Get Audio From Sample Returns audio/* bytes; pass output_path to save them.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"voice_id": "<voice_id>",
"sample_id": "<sample_id>"
},
"name": "get_audio_from_sample"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| voice_id | Yes | Voice ID to be used, you can use https://api.elevenlabs.io/v1/voices to list all the available voices. | |
| sample_id | Yes | Sample ID to be used, you can use GET https://api.elevenlabs.io/v1/voices/{voice_id} to list all the available samples for a voice. | |
| output_path | No | Where to write the returned bytes. Relative paths resolve against ELEVENLABS_OUTPUT_DIR. Omit it to get the data inline as base64 (small files only). |