Language Manager for language and localization utilities
Language Manager for language and localization utilities. Provides methods for managing language settings and internationalization.
Methods
setLanguage()
setLanguage(
language):void
Sets the language for API requests. Updates the accept-language header for localized responses.
Parameters
language
Language
Returns
void
Example
sdk.language.setLanguage('es'); // Set to SpanishgetLanguage()
getLanguage():
null|string
Retrieves the currently configured language. Gets the language code from the accept-language header.
Returns
null | string
Example
const currentLanguage = sdk.language.getLanguage();