Airgram

Guides
/
/
Methods

api.getLanguagePackString()

Returns a string stored in the local database from the specified localization target and language pack by its key. Returns a 404 error if the string is not found. Can be called synchronously

Parameters GetLanguagePackStringParams:

NameTypeDescription
languagePackDatabasePathstring Path to the language pack database in which strings are stored
localizationTargetstring Localization target to which the language pack belongs
languagePackIdstring Language pack identifier
keystring Language pack key of the string to be returned
Returns ApiResponse interface:
interface ApiResponse {
  _: 'getLanguagePackString' | 'error'
  airgram: Airgram
  request: {
    method: 'getLanguagePackString'
    params: GetLanguagePackStringParams
  }
  response:  | 
  setState: (nextState: Record<string, unknown>) => void
  getState: () => Record<string, unknown>
}