Upload voice for training
curl --request POST \
--url https://modelslab.com/api/v6/voice/voice_upload \
--header 'Content-Type: application/json' \
--data '
{
"key": "<string>",
"name": "<string>",
"init_audio": "<string>",
"base64": false,
"thumbnail": "<string>"
}
'{
"message": "<string>",
"voice_id": "<string>"
}Speech & Audio API
Voice Upload
Upload an audio file and retrieve a voice_id for use with the Voice-cloning endpoint.
POST
/
voice
/
voice_upload
Upload voice for training
curl --request POST \
--url https://modelslab.com/api/v6/voice/voice_upload \
--header 'Content-Type: application/json' \
--data '
{
"key": "<string>",
"name": "<string>",
"init_audio": "<string>",
"base64": false,
"thumbnail": "<string>"
}
'{
"message": "<string>",
"voice_id": "<string>"
}Request
Make aPOST request to below endpoint and pass the required parameters as a request body.
curl
--request POST 'https://modelslab.com/api/v6/voice/voice_upload' \
Body
json
{
"key":"",
"name":"Jacob",
"init_audio":"https://assets.modelslab.ai/generations/5c3eef10-0eb4-4db8-8b12-fc4eedbf30b9.mp3",
"language":"english"
}
Body
application/json
API key to authorize the request
Display name assigned to the voice being uploaded
URL of audio file to upload. MP3/WAV, 10-25 seconds for optimal results
Language of the voice
Available options:
english, arabic, spanish, german, czech, brazilian portuguese, chinese, dutch, french, hindi, hungarian, italian, japanese, korean, polish, russian, turkish Whether audio file is provided as base64 string
Gender of the audio
Available options:
male, female Thumbnail image URL for the audio
Was this page helpful?
⌘I

