Skip to content

miniproto.types.User

User(id: int, access_hash: int | None = None, is_bot: bool = False, username: str | None = None, phone: str | None = None, first_name: str | None = None, last_name: str | None = None, is_self: bool = False, raw: object | None = None) -> None

Normalized Telegram user returned by peer and authorization helpers.

Attributes:

  • id (int) – Telegram user identifier.
  • access_hash (int | None) – Optional hash used to address the user.
  • is_bot (bool) – Whether the account is a bot.
  • username (str | None) – Optional public username.
  • phone (str | None) – Optional phone number supplied by Telegram.
  • first_name (str | None) – Optional first name.
  • last_name (str | None) – Optional last name.
  • is_self (bool) – Whether this is the authorized account.
  • raw (object | None) – Optional underlying TL object for low-level inspection.