Struct telegram_bot_api::methods::UnbanChatMember
source · [−]pub struct UnbanChatMember {
pub chat_id: ChatId,
pub user_id: i64,
pub only_if_banned: Option<bool>,
}
Expand description
Use this method to unban a previously banned user in a supergroup or channel. The user will not to the group or channel automatically, but will be able to join via link, etc. The bot must be an administrator for this to work. By default, this method guarantees that after the call the user is not a member of the chat, but will be able to join it. So if the user is a member of the chat they will also be removed from the chat. If you don’t want this, use the parameter only_if_banned. Returns True on success.
Fields
chat_id: ChatId
Unique identifier for the target group or username of the target supergroup or channel (in the format @channelusername)
user_id: i64
Unique identifier of the target user
only_if_banned: Option<bool>
Do nothing if the user is not banned
Implementations
Trait Implementations
sourceimpl Clone for UnbanChatMember
impl Clone for UnbanChatMember
sourcefn clone(&self) -> UnbanChatMember
fn clone(&self) -> UnbanChatMember
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for UnbanChatMember
impl Debug for UnbanChatMember
sourceimpl<'de> Deserialize<'de> for UnbanChatMember
impl<'de> Deserialize<'de> for UnbanChatMember
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Methods for UnbanChatMember
impl Methods for UnbanChatMember
sourceimpl Serialize for UnbanChatMember
impl Serialize for UnbanChatMember
Auto Trait Implementations
impl RefUnwindSafe for UnbanChatMember
impl Send for UnbanChatMember
impl Sync for UnbanChatMember
impl Unpin for UnbanChatMember
impl UnwindSafe for UnbanChatMember
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more