elevenlabs dubbing

FREEMIUM
Por Thomcle | Atualizado hace un mes | Artificial Intelligence/Machine Learning
Popularidade

8.8 / 10

Latência

27,276ms

Nível de serviço

95%

Health Check

N/A

Voltar para todas as discussões

Dubbing API returning Internal server error

Rapid account: Mario Pdo Kkamz A
mario-pdoKkamzA
hace 4 meses
def get_dubbed_audio(transcription, language, voice_name):
    url = "https://elevenlabs-dubbing1.p.rapidapi.com/dubbing"

    payload = {
        "audio_duration_seconds": 47.809886621315194,
        "elevenlabs_api_key": elevenlabs_key,
        "spoken_language": language,
        "transcription": transcription,
        "voice_name": voice_name
    }
    headers = {
        "content-type": "application/json",
        "X-RapidAPI-Key": "...",
        "X-RapidAPI-Host": "elevenlabs-dubbing1.p.rapidapi.com"
    }

    response = requests.post(url, json=payload, headers=headers)

    return response

Am I doing something wrong?

Rapid account: Thomcle
Thomcle Commented hace 4 meses

The only error I can see is that you define the “voice_name” key in the playload, which hasn’t existed for a few days. Please replace the value of the key with “voice_id” and set it to the id of a voice (available in the json file of the enpoint /get_voices or at the end of the documentation page).

payload = {
“audio_duration_seconds”: 47.809886621315194,
“elevenlabs_api_key”: elevenlabs_key,
“spoken_language”: language,
“transcription”: transcription,
“voice_id”: voice_id
}

(Note that this allows you to use the API key of your elevenlabs account to access a wider range of voices than those indicated in the json file of available voices. Internal server error may occur for other reasons: please check that the value of each is indicated as requested.)

Junte-se à discussão - adicione o comentário abaixo:

Efetue login / inscreva-se para postar novos comentários