diff --git a/src/api_traits/async_telegram_api.rs b/src/api_traits/async_telegram_api.rs index af7c1db..1901c1b 100644 --- a/src/api_traits/async_telegram_api.rs +++ b/src/api_traits/async_telegram_api.rs @@ -106,6 +106,7 @@ use crate::api_params::StopPollParams; use crate::api_params::UnbanChatMemberParams; use crate::api_params::UnbanChatSenderChatParams; use crate::api_params::UnhideGeneralForumTopicParams; +use crate::api_params::UnpinAllChatMessagesParams; use crate::api_params::UnpinAllForumTopicMessagesParams; use crate::api_params::UnpinChatMessageParams; use crate::api_params::UploadStickerFileParams; @@ -645,6 +646,13 @@ pub trait AsyncTelegramApi { self.request("unpinChatMessage", Some(params)).await } + async fn unpin_all_chat_messages( + &self, + params: &UnpinAllChatMessagesParams, + ) -> Result, Self::Error> { + self.request("unpinAllChatMessages", Some(params)).await + } + async fn leave_chat( &self, params: &LeaveChatParams, diff --git a/src/api_traits/telegram_api.rs b/src/api_traits/telegram_api.rs index 64f34f7..e29e837 100644 --- a/src/api_traits/telegram_api.rs +++ b/src/api_traits/telegram_api.rs @@ -105,6 +105,7 @@ use crate::api_params::StopPollParams; use crate::api_params::UnbanChatMemberParams; use crate::api_params::UnbanChatSenderChatParams; use crate::api_params::UnhideGeneralForumTopicParams; +use crate::api_params::UnpinAllChatMessagesParams; use crate::api_params::UnpinAllForumTopicMessagesParams; use crate::api_params::UnpinChatMessageParams; use crate::api_params::UploadStickerFileParams; @@ -606,6 +607,13 @@ pub trait TelegramApi { self.request("unpinChatMessage", Some(params)) } + fn unpin_all_chat_messages( + &self, + params: &UnpinAllChatMessagesParams, + ) -> Result, Self::Error> { + self.request("unpinAllChatMessages", Some(params)) + } + fn leave_chat(&self, params: &LeaveChatParams) -> Result, Self::Error> { self.request("leaveChat", Some(params)) }