For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
CommunityAPI StatusAPI PricingSign Up
DocumentationAPI ReferencesCookbookIntegrationDeveloper Tools
DocumentationAPI ReferencesCookbookIntegrationDeveloper Tools
  • API Reference
    • Introduction
    • Authentication
    • Access to Beta APIs
    • Meta Prompt Guide
  • Endpoints
      • POSTCreate
      • GETList
      • GETGet
      • PUTUpdate
      • DELDelete
LogoLogo
CommunityAPI StatusAPI PricingSign Up
EndpointsPronunciation Dictionary

Update

||View as Markdown|
PUT
https://api.sarvam.ai/text-to-speech/pronunciation-dictionary
PUT
/text-to-speech/pronunciation-dictionary
$curl -X PUT "https://api.sarvam.ai/text-to-speech/pronunciation-dictionary?dict_id=dict_id" \
> -H "api-subscription-key: <apiSubscriptionKey>" \
> -H "Content-Type: multipart/form-data" \
> -F file=@string
1{
2 "dictionary_id": "p_5cb7faa6",
3 "updated_pronunciations": {
4 "hi-IN": {
5 "B2B": "business to business"
6 },
7 "en-IN": {
8 "teting": "testing"
9 }
10 }
11}
Update an existing pronunciation dictionary by uploading a JSON file. You can add new words, change existing pronunciations, or both — entries not included in the uploaded file remain unchanged. **Limits:** Max 100 words per dictionary, 1 MB file size. The response includes the `dictionary_id` and the updated pronunciation mappings for verification.
Was this page helpful?
Previous

Delete

Next
Built with

Update an existing pronunciation dictionary by uploading a JSON file. You can add new words, change existing pronunciations, or both — entries not included in the uploaded file remain unchanged.

Limits: Max 100 words per dictionary, 1 MB file size.

The response includes the dictionary_id and the updated pronunciation mappings for verification.

Authentication

api-subscription-keystring
API Key authentication via header

Query parameters

dict_idstringRequired
ID of the dictionary to update

Request

This endpoint expects a multipart form containing a file.
filefileRequired

Response

Successful Response
dictionary_idstring
Unique identifier of the updated dictionary.
updated_pronunciationsmap from strings to maps from strings to strings

The new pronunciation data after the update, organized as {language_code: {word: pronunciation}}.

Errors

400
Bad Request Error
403
Forbidden Error
404
Not Found Error
413
Content Too Large Error
422
Unprocessable Entity Error
429
Too Many Requests Error
500
Internal Server Error