Getting Started

In this guide, you’ll learn how to automatically transcribe live streaming audio in real time using Reverie’s SDKs, which are supported for use with the Reverie API.

Before you start, you’ll need to follow the steps in the Get your API Credentials to obtain your API KEY & APP ID.

Make your first Call

Make your first API Call using the cURL request. Add your own API Credentials where it says <YOUR-APP-ID> & <YOUR-API-KEY> and then run the following example in a terminal or your favorite API client.

curl --location --request POST 'https://revapi.reverieinc.com/' \
--header 'Content-Type: application/json' \
--header 'REV-API-KEY: <YOUR API KEY>' \
--header 'REV-APP-ID: <YOUR APP-ID>' \
--header 'src_lang: en' \
--header 'tgt_lang: hi' \
--header 'domain: generic' \
--header 'REV-APPNAME: localization' \
--header 'REV-APPVERSION: 3.0' \
--data '{
    "data": [
        "Reverie Language Technologies was established in 2009.",
        "The company head office is located in Bengaluru."
    ]
}'

By default, The API will return the strings in the target language.

SDKs

Reverie has several SDKs that can make it easier to use the API. Follow these steps to use the SDK of your choice to make a Reverie Localization request.

Install Dependencies

npm i @reverieit/reverie-client

Translate Text to your preferred language

The following code shows how to convert the text to your preferred language.

const ReverieClient = require("reverie-client");

const reverieClient = new ReverieClient({
  apiKey: "YOUR-API-KEY",
  appId: "YOUR-APP-ID",
});

async function translateText() {
  const translation = await reverieClient.translate({
    text: "Hey there, how are you doing?",
    src_lang: "en",
    tgt_lang: "or",
  });
  console.log(translation);
}

translateText();

Results

In order to see the results from Reverie, you must run the application. Run your application from the terminal. Your transcripts will appear in your shell.

# Run your application using the file you created in the previous step
# Example:
npm start

Analyzing the Response

The API returns a responseList, which is an array containing the localized content. Each item includes the inString, representing the original input text in the source language, and the corresponding outString, which contains the translated text in the requested target language.

Key Features

Rapid Content Localization

The Localization API quickly adapts English content into Indic languages, localizing single or multiple sentences in a fraction of the time for a seamless user experience.

Context-Aware Localization

Our API analyzes the domain and context of the content, ensuring accurate localization by adapting terms like “book” to suit the industry or intent (e.g., booking tickets vs. reading books).

Cultural Nuance Adaptation

Go beyond translation by capturing cultural references, simplifying text, and adjusting for local conventions like measurement systems to resonate with the target audience.

Wide Language Support

Localize content into 16 Indic languages, including Hindi, Bengali, Tamil, Telugu, Marathi, and more, ensuring broad accessibility across diverse regions.

High-Quality Localization

Deliver clear, natural, and culturally relevant translations that align with user expectations, enhancing comprehension and engagement.

Custom Localization Solutions

Collaborate with us to tailor localization for your brand, ensuring the tone, style, and terminology align with your specific needs and audience.

Supported Languages

LanguageLanguage Code
Hindihi
Englishen
Assameseas
Bengalibn
Gujaratigu
Kannadakn
Konkanikok
Malayalamml
Marathimr
Maithilimai
Odiaor
Punjabipa
Tamilta
Telugute
Nepaline
Urduur

Supported Domains

Domain ID (For v3.0)Domain ID (For v2.0)Description
generic0Default domain; localizes content regardless of specific domain.
government1Trained for accurate localization of government terminologies.
travel2Localizes travel industry terminologies accurately.
ecommerce3Localizes content for the ecommerce domain.
infotainment4Translates content for the media and entertainment domain.
bfsi5Accurately translates banking, financial services, and insurance content.
food6Translates grocery industry terminologies into target languages.
education7Translates content from academic books.
medical8Serves the healthcare industry with accurate translations.

Sample Code

FAQs

API Messages

Status CodeStatus TypeStatusDescription
2SuccessLOOKUP_MODERATEDAPI fetched localization content from the database.
3SuccessMT_SUCCESSSource content translated using Neural Machine Translation (NMT).
4SuccessLOOKUP_UNMODERATEDLocalized content in database, but verification status is “unmoderated.”
5SuccessLOOKUP_INPROGRESSLocalized content in database; content moderation in progress.
6SuccessLOOKUP_PARTIALAPI partially localized a segment from LookUp DB.
10SuccessT13N_SUCCESSAPI fetched content from transliteration.
-2ErrorUNLOCALIZEDRequested content is transliterated, not translated.
-3ErrorROSETTA_ERRORError occurred while preprocessing the sentence.
-4ErrorMT_ERRORError occurred during NMT translation.
-5ErrorMT_TIME_OUTTimeout error while fetching response from NMT Engine.
-6ErrorLOCMAN_ERRORError occurred while processing content in LocMan.
-7ErrorSEGMENTATION_API_ERRORError while segmenting the sentence.
403Errorunauthorized to use this src/tgt languageInvalid or unauthorized language code provided.
403ErrorInvalid REV-API-KEY or REV-APP-IDInvalid credentials provided.
403Errorusage exhaustedProvided credit limit is exhausted.
403ErrorAPI key expiredAPI key provided has expired.
403Errorunauthorized to use this APIUser is not authorized to use the Localization API.
403ErrorPlease provide data stringData is missing.
403ErrorTarget language is mandatoryTarget language (tgt_lang) is missing.
403ErrorSource language is mandatorySource language (src_lang) is missing.