Get the exact read date of one of our messages, sent to a private chat with another user.
Can be only done for private outgoing messages not older than appConfig.pm_read_date_expire_period ».
If the peer
's userFull.read_dates_private
flag is set, we will not be able to fetch the exact read date of messages we send to them, and a USER_PRIVACY_RESTRICTED
RPC error will be emitted.
The exact read date of messages might still be unavailable for other reasons, see here » for more info.
To set userFull.read_dates_private
for ourselves invoke account.setGlobalPrivacySettings, setting the settings.hide_read_marks
flag.
Method schema is available as of layer 172. Switch »
Name | Type | Description |
---|---|---|
peer | InputPeer | The user to whom we sent the message. |
msg_id | int | The message ID. |
Code | Type | Description |
---|---|---|
400 | MESSAGE_ID_INVALID | The provided message id is invalid. |
400 | MESSAGE_NOT_READ_YET | The specified message wasn't read yet. |
400 | MESSAGE_TOO_OLD | The message is too old, the requested information is not available. |
400 | PEER_ID_INVALID | The provided peer id is invalid. |
403 | USER_PRIVACY_RESTRICTED | The user's privacy settings do not allow you to do this. |
403 | YOUR_PRIVACY_RESTRICTED | You cannot fetch the read date of this message because you have disallowed other users to do so for your messages; to fix, allow other users to see your exact last online date OR purchase a Telegram Premium subscription. |
The MTProto API has multiple configuration parameters that can be fetched with the appropriate methods.
Extended user info
When updating the local peer database », all fields from the newly received constructor take priority over the old constructor cached locally (including by removing fields that aren't set in the new constructor).
Global privacy settings
Set global privacy settings
Telegram Premium is an optional subscription service that unlocks additional exclusive client-side and API-side features, while helping support the development of the app.