The Javascript SDK provides 2 methods:
- init
- switchLanguage
init API method
This is used to initialize Teral on your website. The method expects a configuration object. The only required field is the apiKey.
For a list of all configuration values, please visit
Example:
Teral.init({apiKey : "abc" })
For a list of all the different options please visit https://teral.io/docs/javascript-sdk/configuration
switchLanguage API method
This method is used to switch to a different language. It expects one parameter which is the 2 letter code of the language you would like to switch to.
For example, to switch the page to French (fr), you simply call this method
Teral.switchLanguage("fr")