--- openapi: 3.0.3 info: title: Generated API version: "1.0" servers: - url: https://bhashini.ai paths: /authorize: post: responses: "200": description: OK security: - IdToken: [] /v1/synthesize: post: summary: Synthesize speech from text description: Use Bhashini Neural TTS engine to synthesize speech from Unicode text parameters: - name: X-API-KEY in: header description: Specify your API key (consisting of 32 characters) for going beyond rate limits and/or getting access to premium voices schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/TextToSpeechInput' responses: default: description: Synthesized speech content: audio/mpeg: {} "400": description: Invalid languageId/voiceId/text in the request body "401": description: Trying to access premium voice but API key is missing or invalid /v1/translate: post: summary: "Translate text: English->Indic or Indic->English or Indic->Indic" description: Translate text from English to Indian language or Indian language to English or from one Indian language to another. parameters: - name: X-API-KEY in: header description: Specify your API key (consisting of 32 characters) for going beyond character limits schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/TranslateInput' responses: default: description: Text translated into target language content: text/plain: {} "400": description: Invalid inputText/inputLanguage/outputLanguage in the request body /v1/transliterate: post: summary: Transliterate Indic text description: See Indic text in desired script requestBody: content: application/json: schema: $ref: '#/components/schemas/TransliterateInput' responses: default: description: Text transliterated into target script content: text/plain: {} "400": description: Invalid inputText/inputScript/outputScript in the request body /v2/synthesize: post: summary: Synthesize speech from text description: Use Bhashini.AI Neural TTS engine to synthesize speech from Unicode text requestBody: content: application/json: schema: $ref: '#/components/schemas/TextToSpeechInput' responses: default: description: Synthesized speech content: audio/mpeg: {} "400": description: Invalid languageId/voiceId/text in the request body security: - IdToken: [] /v2/translate: post: summary: "Translate text: English->Indic or Indic->English or Indic->Indic" description: Translate text from English to Indian language or Indian language to English or from one Indian language to another. requestBody: content: application/json: schema: $ref: '#/components/schemas/TranslateInput' responses: default: description: Text translated into target language content: text/plain: {} "400": description: Invalid inputText/inputLanguage/outputLanguage in the request body security: - IdToken: [] components: schemas: Language: enum: - Assamese - Bengali - Bodo - Dogri - English - Gujarati - Hindi - Kannada - Kashmiri - Konkani - Maithili - Malayalam - Manipuri - Marathi - Nepali - Odia - Punjabi - Sanskrit - Santali - Sindhi - Tamil - Telugu - Urdu type: string Script: enum: - Devanagari - Bengali - Gurmukhi - Gujarati - Oriya - Tamil - Telugu - Kannada - Malayalam - English - Urdu type: string TextToSpeechInput: description: Input needed for synthesizing speech. required: - text - languageId - voiceId type: object properties: text: description: Unicode text for which speech needs to be synthesized. type: string example: "सौर मंडल में सूर्य और वह खगोलीय पिंड सम्मलित हैं, जो इस मंडल म\ ें एक दूसरे से गुरुत्वाकर्षण बल द्वारा बंधे हैं।" languageId: description: 2-digit laguage code as in ISO 639-1 type: string example: hi voiceId: format: int32 description: "Voice ID: 0 for Female1, 1 for Male1 etc." type: integer example: 0 TranslateInput: description: Input needed for Transliteration. required: - inputText - inputLanguage - outputLanguage type: object properties: inputText: description: Unicode text which needs to be transliterated. type: string example: Chandrayaan-3 is the third and most recent lunar Indian Space Research exploration mission under the Chandrayaan programme of ISRO. It consists of a lander named Vikram and a rover named Pragyan similar to Chandrayaan-2. Its propulsion module behaves like an Orbiter. The propulsion module carries the lander and rover configuration until the spacecraft is in a 100-kilometre (62 mi) lunar orbit. inputLanguage: description: Source language (Indic/English) of input-text type: string allOf: - $ref: '#/components/schemas/Language' example: English outputLanguage: description: Target language (Indic/English) in to which the inputText needs to be translated to type: string allOf: - $ref: '#/components/schemas/Language' example: Hindi TransliterateInput: description: Input needed for Transliteration. required: - inputText - inputScript - outputScript type: object properties: inputText: description: Unicode text which needs to be transliterated. type: string example: கடல்களுக்கான உரோமானியக்கடவுள் நெப்டியூன் என்பவரின் பெயரே ஞாயிற்றுத் தொகுதியில் உள்ள கோளான நெப்டியூன் கோளிற்கு சூட்டப்பட்டது. inputScript: description: Script in which input text is given type: string allOf: - $ref: '#/components/schemas/Script' example: Tamil outputScript: description: Script in which the output text is expected type: string allOf: - $ref: '#/components/schemas/Script' example: Kannada securitySchemes: IdToken: type: http scheme: bearer bearerFormat: JWT JWT: type: http scheme: bearer bearerFormat: JWT