Skip to main content

authorization

Logged-in session

type tg.Authorization struct { /* ... */ }

Fields​

NameTypeRequiredDescription
Currentbool—Whether this is the current session
OfficialAppbool—Whether the session is from an official app
PasswordPendingbool—Whether the session is still waiting for a 2FA password
EncryptedRequestsDisabledbool—Whether this session will accept encrypted chats
CallRequestsDisabledbool—Whether this session will accept phone calls
Unconfirmedbool—Whether the session is unconfirmed, see here » for more info.
Hashint64yesIdentifier
DeviceModelstringyesDevice model
PlatformstringyesPlatform
SystemVersionstringyesSystem version
APIIDintyesAPI ID
AppNamestringyesApp name
AppVersionstringyesApp version
DateCreatedintyesWhen was the session created
DateActiveintyesWhen was the session last active
IPstringyesLast known IP
CountrystringyesCountry determined from IP
RegionstringyesRegion determined from IP

Returned by​

References​