Skip to main content

langpack.getLangPack

Get localization pack strings

func (c *Client) LangpackGetLangPack(ctx context.Context, request *LangpackGetLangPackRequest) (*LangPackDifference, error)

Calling this method

client.Run(ctx, func(ctx context.Context) error {
api := client.API()

res, err := api.LangpackGetLangPack(ctx, &tg.LangpackGetLangPackRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // *LangPackDifference
return nil
})

Parameters

NameTypeRequiredDescription
LangPackstringyesPlatform identifier (i.e. android, tdesktop, etc).
LangCodestringyesEither an ISO 639-1 language code or a language pack name obtained from a language pack link.

Returns

*LangPackDifference

Possible errors

CodeTypeDescription
400LANGUAGE_INVALIDThe specified lang_code is invalid.
400LANG_CODE_NOT_SUPPORTEDThe specified language code is not supported.
400LANG_PACK_INVALIDThe provided language pack is invalid.

References