telegram_bots_api 0.710.0

Telegram bots api simple rust wrapper, and no more.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use crate::api::enums::chat_uid::ChatUId;
use crate::api::structs::chat_permissions::ChatPermissions;
use serde::Serialize;

/// <https://core.telegram.org/bots/api#setchatpermissions>
/// Use this method to set default chat permissions for all members. The bot must be an administrator in the group or a supergroup for this to work and must have the can_restrict_members administrator rights. Returns True on success.
#[derive(Debug, Serialize, Default)]
pub struct SetChatPermissions {
    pub chat_id: ChatUId,
    pub permissions: ChatPermissions,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub use_independent_chat_permissions: Option<bool>,
}