messages.readSavedHistory
Mark messages as read in a monoforum topic ».
func (c *Client) MessagesReadSavedHistory(ctx context.Context, request *MessagesReadSavedHistoryRequest) (bool, error)
Calling this method
client.Run(ctx, func(ctx context.Context) error {
api := client.API()
res, err := api.MessagesReadSavedHistory(ctx, &tg.MessagesReadSavedHistoryRequest{
// see Parameters
})
if err != nil {
return err
}
_ = res // bool
return nil
})
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
ParentPeer | InputPeerClass | yes | ID of the monoforum group. |
Peer | InputPeerClass | yes | ID of the topic. |
MaxID | int | yes | If a positive value is passed, only messages with identifiers less or equal than the given one will be read. |
Returns
bool
Possible errors
| Code | Type | Description |
|---|---|---|
| 400 | CHAT_ADMIN_REQUIRED | You must be an admin in this chat to do this. |
| 400 | PARENT_PEER_INVALID | The specified parent_peer is invalid. |
References
- Official documentation
- Generated Go reference
- TL definition:
messages.readSavedHistory#ba4a3b5b