vaegram 0.3.0

Telegram MTProto client library for users and bots
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
use crate::Client;
use crate::errors::Result;
use crate::raw::functions;
use crate::types::PeerRef;

impl Client {
    /// Marks all unread mentions in a chat as read.
    pub async fn read_mentions(&self, chat_id: impl Into<PeerRef>) -> Result<()> {
        let (chat_id, peer) = self.resolve(&chat_id.into()).await?;
        self.affected_history(chat_id, &functions::messages::ReadMentions { peer, top_msg_id: None }).await
    }
}