#Hi can I get access to the eleven_v3 model in the API i tried this it did not work $url = 'https://

1 messages · Page 1 of 1 (latest)

limber spearBOT
#
AI-generated Answer for sofianehamza

I understand you're trying to access the eleven_v3 model through the ElevenLabs API, but it seems you've encountered an issue. The problem here is that the model ID you're using is incorrect.

The correct model ID for our latest multilingual model is "eleven_multilingual_v2". The "eleven_v3" model ID you've used in your code doesn't exist in our current API.

Here's how you should modify your code to use the correct model:

$url = 'https://api.elevenlabs.io/v1/text-to-speech/' . $voice_id;
$data = [
    'text' => $text,
    'model_id' => 'eleven_multilingual_v2'
];

When using our Text-to-Speech API, make sure to always use the correct model ID. The "eleven_multilingual_v2" model supports multiple languages and is our most advanced model currently available through the API.

Also, don't forget to include your API key in the headers of your request. Here's an example of how your full API call might look:

$headers = [
    'xi-api-key: YOUR_API_KEY_HERE',
    'Content-Type: application/json'
];

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$response = curl_exec($ch);
curl_close($ch);

Remember to replace 'YOUR_API_KEY_HERE' with your actual ElevenLabs API key. If you continue to experience issues after making these changes, please provide more details about the specific error you're encountering, and I'll be happy to help further.

tranquil cobalt
#

how about v3 it is in alpha