Adding a pronunciation dictionary
Here is some example code for uploading a pronunciation dictionary and printing the responsepronunciation_dictionary_id
and version_id
. You’ll require these identifiers in the request body if you intend to use pronunciation_dictionary_locators
.
All you will need to do is replace API_KEY_HERE
with your actual API key and PATH_HERE
with the actual path to the PLS file you want to upload.
If you need help in understanding how to properly format a PLS / pronunciation dictionary, please refer to the guide here.
Using a pronunciation dictionary
Here is some example code on how to use these identifiers or locators in your text-to-speech call.Headers
Your API key. This is required by most endpoints to access our API programatically. You can view your xi-api-key using the 'Profile' tab on the website.
Body
multipart/form-data
Response
Successful Response
The response is of type object
.