Telegram MTProto
TL layer 236899 methodsOpenAPI 3.0.3

MTProto reference

account.registerDevice

Register device to receive PUSH notifications

Register device to receive [PUSH notifications](https://core.telegram.org/api/push-updates.md)

NameTypeRequiredDescription
no_mutedtrueNoAvoid receiving (silent and invisible background) notifications. Useful to save battery.
token_typeintYesDevice token type, see [PUSH updates](https://core.telegram.org/api/push-updates.md#subscribing-to-notifications) for the possible values.
tokenstringYesDevice token, see [PUSH updates](https://core.telegram.org/api/push-updates.md#subscribing-to-notifications) for the possible values.
app_sandboxBoolYesIf [(boolTrue)](https://core.telegram.org/constructor/boolTrue.md) is transmitted, a sandbox-certificate will be used during transmission.
secretbytesYesFor FCM and APNS VoIP, optional encryption key used to encrypt push notifications
other_uidsVector<long>YesList of user identifiers of other users currently using the client

Responses

Bool

MTProto RPC

  • 400 · TOKEN_EMPTY — The specified token is empty.
  • 400 · TOKEN_INVALID — The provided token is invalid.
  • 400 · TOKEN_TYPE_INVALID — The specified token type is invalid.
  • 400 · WEBPUSH_AUTH_INVALID — The specified web push authentication secret is invalid.
  • 400 · WEBPUSH_KEY_INVALID — The specified web push elliptic curve Diffie-Hellman public key is invalid.
  • 400 · WEBPUSH_TOKEN_INVALID — The specified web push token is invalid.

Telegram documentation ↗

Пользователи users.getFullUser
POST users.getFullUser

Получить подробный профиль пользователя

Возвращает расширенные сведения о пользователе. В ответе могут быть описание профиля и связанные пользователи или чаты.

ПользователиTL: users.getFullUserДоступен пользователям и ботам

Параметры запроса

Параметр
id
Тип
InputUser
Обязательный
Да
Описание
Пользователь, сведения о котором нужно получить.
Тип InputUser

Указывает пользователя для дальнейшего взаимодействия.

КонструкторПоляОписание
inputUseruser_id: longID пользователяaccess_hash: longЗначение access_hash из конструктора userУказывает пользователя для дальнейшего взаимодействия.
inputUserSelf—Текущий пользователь
inputUserFromMessagepeer: InputPeerЧат, в котором встретился пользовательmsg_id: intID сообщенияuser_id: longID пользователяПользователь с признаком min из конкретного сообщения чата
inputUserEmpty—Пустой конструктор, который не указывает пользователя

Авторизация Telegram

Сессия хранится в этой вкладке. Запрос выполняется напрямую к Telegram.