Skip to content

miniproto.updates.state.EntityReference

EntityReference(id: int, kind: PeerKind, access_hash: int | None = None, username: str | None = None, phone: str | None = None, title: str | None = None, updated_at: datetime = utc_now()) -> None

Persistent, normalized peer data learned while processing updates.

Attributes:

  • id (int) – Telegram peer identifier.
  • kind (PeerKind) – Peer category used as part of the cache key.
  • access_hash (int | None) – Optional hash needed to construct an input peer or channel.
  • username (str | None) – Optional username observed in update entities.
  • phone (str | None) – Optional phone number observed in a user entity.
  • title (str | None) – Optional display title or user full name.
  • updated_at (datetime) – Observation timestamp; aware input retains its timezone and naive input assumes UTC.