Voice Selection
Finding a Speaker IDCopied!
To use the Replica API for most speech generation tasks, you'll need a speaker ID.
Although it might not seem obvious at first, voices on Replica are grouped by several different IDs with the speaker ID representing the combination of both the desired voice and style.
The required information is available on the /library/voices
endpoint.
Example API request to get available voices:
import requests
url = "https://api.replicastudios.com/v2/library/voices"
headers = {
"X-Api-Key": "..." # Replace with your API key
}
response = requests.get(url, headers=headers)
voices = response.json()
The response will include voice details including:
-
UUID (Do note this is the voice's UUID, not quite what we're after)
-
Name
-
Available styles
-
Voice characteristics
-
Sample audio URLs
For example, here is a truncated example of "Freya" from the library:
{
"uuid": "2bfc6875-308c-4101-bf4d-7c279bc56db2",
"name": "Freya",
"avatar_url": "https://static.replicastudios.com/production/uploads/avatars/2bfc6875-308c-4101-bf4d-7c279bc56db2.jpg",
"hero_image_url": "https://static.replicastudios.com/production/uploads/avatars/2bfc6875-308c-4101-bf4d-7c279bc56db2_heroimage.png",
"hero_sample_url": "https://static.replicastudios.com/production/uploads/previews/2bfc6875-308c-4101-bf4d-7c279bc56db2_herosample_1698884342198.wav",
"description": "The female action lead. Whatever your storyline in the realm of the magical or medieval, Freya will blast through or come swinging in to the rescue. With a wide voice range, she'll challenge any man, monster or machine. ",
"metadata": {
"accent": "British",
"gender": "female",
"voiceAge": "youngadult"
},
"characteristics": [
"Authoritative",
"Brave",
"Clear",
"Commanding"
],
"default_sample": null,
"default_style": {
...
},
"styles": [
{
"uuid": "07e62901-72c4-46e5-b009-aa0938d749df",
"name": "Serious",
"description": null,
"speaker_id": "9b1f5c24-a18b-4b9e-a785-b3a3b3b8751a",
"avatar_url": "https://static.replicastudios.com/production/uploads/avatars/07e62901-72c4-46e5-b009-aa0938d749df_style_avatar.jpg",
"samples": [
{
"uuid": "cee6c584-af5a-4b8f-84cf-06723d887c54",
"text": "You can’t keep running from this. Sooner or later you’ll have to face the truth.",
"url": "https://static.replicastudios.com/production/uploads/previews/5ba7b998-cba8-4ec8-9524-ca69e06ae4de.mp3"
}
],
"capabilities": {
"tts.vox_1_0": true,
"tts.vox_2_0": false,
"sts.vox_1_0": true,
"sts.vox_2_0": false
}
},
...
]
}
If you then select the style you want, you'll see the speaker_id as a field under the style.
In the above example, the speaker_id is 9b1f5c24-a18b-4b9e-a785-b3a3b3b8751a
for the style "Serious".
Voices also have a default_style
field, which (when not truncated) will have the same format as styles
.
If you're unsure which style to use, you can use the default_style
field to get a feel for the voice.
Finding a Performer Style IDCopied!
Each voice (or 'performer' in this case) can have multiple styles. When querying the /library/voices
endpoint, you'll receive style information in the response including:
-
Style UUID
-
Style name
-
Speaker ID
-
Sample audio for that style
-
Capabilities (supported model versions)
The style UUID is used as the performer_style_id
parameter when making speech-to-speech generation requests.
Using a Voicelab Voice PresetCopied!
What is Voicelab? Learn more about it here.
Voice presets allow you to save specific voice configurations for reuse. When making a speech generation request, you can include the voice_preset_id
parameter alongside the speaker_id
parameter.
Your voice presets are available in the /my/voices
endpoint, alongside style/speaker IDs that will work alongside it.
Voice presets are only available on certain subscription tiers. Check your account settings for availability.