Interface Session

Contains information about one session in a Telegram application used by the current user. Sessions must be shown to the user in the returned order.

interface Session {
    @type: "session";
    api_id: number;
    application_name: string;
    application_version: string;
    can_accept_calls?: boolean;
    can_accept_secret_chats?: boolean;
    device_model: string;
    device_type: SessionDeviceType;
    id: string;
    ip_address: string;
    is_current?: boolean;
    is_official_application?: boolean;
    is_password_pending?: boolean;
    is_unconfirmed?: boolean;
    last_active_date: number;
    location: string;
    log_in_date: number;
    platform: string;
    system_version: string;
}

Properties

@type: "session"
api_id: number

Telegram API identifier, as provided by the application.

application_name: string

Name of the application, as provided by the application.

application_version: string

The version of the application, as provided by the application.

can_accept_calls?: boolean

True, if incoming calls can be accepted by the session.

can_accept_secret_chats?: boolean

True, if incoming secret chats can be accepted by the session.

device_model: string

Model of the device the application has been run or is running on, as provided by the application.

device_type: SessionDeviceType

Session device type based on the system and application version, which can be used to display a corresponding icon.

id: string

Session identifier.

ip_address: string

IP address from which the session was created, in human-readable format.

is_current?: boolean

True, if this session is the current session.

is_official_application?: boolean

True, if the application is an official application or uses the api_id of an official application.

is_password_pending?: boolean

True, if a 2-step verification password is needed to complete authorization of the session.

is_unconfirmed?: boolean

True, if the session wasn't confirmed from another session.

last_active_date: number

Point in time (Unix timestamp) when the session was last used.

location: string

A human-readable description of the location from which the session was created, based on the IP address.

log_in_date: number

Point in time (Unix timestamp) when the user logged in.

platform: string

Operating system the application has been run or is running on, as provided by the application.

system_version: string

Version of the operating system the application has been run or is running on, as provided by the application.