messages.readHistory

Marks message history as read.

messages.affectedHistory#b7de36f2 pts:int seq:int offset:int = messages.AffectedHistory;
---functions---
messages.readHistory#b04f2510 peer:InputPeer max_id:int offset:int = messages.AffectedHistory;

Parameters

Name Type Description
peer InputPeer Target user or group
max_id int If a positive value is passed, only messages with identifiers less or equal than the given one will be read

Result

messages.AffectedMessages

Only users can use this method

This method can be invoked over a business connection ยป

Possible errors

Code Type Description
400 BUSINESS_CONNECTION_INVALID The connection_id passed to the wrapping invokeWithBusinessConnection call is invalid.
400 CHANNEL_PRIVATE You haven't joined this channel/supergroup.
400 CHAT_ID_INVALID The provided chat id is invalid.
400 MSG_ID_INVALID Invalid message ID provided.
400 PEER_ID_INVALID The provided peer id is invalid.

Related pages

Business

Users can turn their Telegram account into a business account, gaining access to business features such as opening hours, location, quick replies, automated messages, custom start pages, chatbot support, and more.