tgbot-cpp
Loading...
Searching...
No Matches
TgBot::ChatAdministratorRights Struct Reference

Represents the rights of an administrator in a chat. More...

#include <Types.h>

Public Types

using Ptr = std::shared_ptr<ChatAdministratorRights>

Public Attributes

bool isAnonymous { }
 True, if the user's presence in the chat is hidden.
bool canManageChat { }
 True, if the administrator can access the chat event log, get boost list, see hidden supergroup and channel members, report spam messages, ignore slow mode, and send messages to the chat without paying Telegram Stars. Implied by any other administrator privilege.
bool canDeleteMessages { }
 True, if the administrator can delete messages of other users.
bool canManageVideoChats { }
 True, if the administrator can manage video chats.
bool canRestrictMembers { }
 True, if the administrator can restrict, ban or unban chat members, or access supergroup statistics.
bool canPromoteMembers { }
 True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that they have promoted, directly or indirectly (promoted by administrators that were appointed by the user).
bool canChangeInfo { }
 True, if the user is allowed to change the chat title, photo and other settings.
bool canInviteUsers { }
 True, if the user is allowed to invite new users to the chat.
bool canPostStories { }
 True, if the administrator can post stories to the chat.
bool canEditStories { }
 True, if the administrator can edit stories posted by other users, post stories to the chat page, pin chat stories, and access the chat's story archive.
bool canDeleteStories { }
 True, if the administrator can delete stories posted by other users.
std::optional< bool > canPostMessages { }
 Optional. True, if the administrator can post messages in the channel, approve suggested posts, or access channel statistics; for channels only.
std::optional< bool > canEditMessages { }
 Optional. True, if the administrator can edit messages of other users and can pin messages; for channels only.
std::optional< bool > canPinMessages { }
 Optional. True, if the user is allowed to pin messages; for groups and supergroups only.
std::optional< bool > canManageTopics { }
 Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only.
std::optional< bool > canManageDirectMessages { }
 Optional. True, if the administrator can manage direct messages of the channel and decline suggested posts; for channels only.
std::optional< bool > canManageTags { }
 Optional. True, if the administrator can edit the tags of regular members; for groups and supergroups only. If omitted, defaults to the value of can_pin_messages.

Detailed Description

Represents the rights of an administrator in a chat.

Definition at line 1552 of file Types.h.

Member Typedef Documentation

◆ Ptr

Definition at line 1553 of file Types.h.

Member Data Documentation

◆ canChangeInfo

bool TgBot::ChatAdministratorRights::canChangeInfo { }

True, if the user is allowed to change the chat title, photo and other settings.

Definition at line 1594 of file Types.h.

◆ canDeleteMessages

bool TgBot::ChatAdministratorRights::canDeleteMessages { }

True, if the administrator can delete messages of other users.

Definition at line 1571 of file Types.h.

◆ canDeleteStories

bool TgBot::ChatAdministratorRights::canDeleteStories { }

True, if the administrator can delete stories posted by other users.

Definition at line 1615 of file Types.h.

◆ canEditMessages

std::optional<bool> TgBot::ChatAdministratorRights::canEditMessages { }

Optional. True, if the administrator can edit messages of other users and can pin messages; for channels only.

Definition at line 1627 of file Types.h.

◆ canEditStories

bool TgBot::ChatAdministratorRights::canEditStories { }

True, if the administrator can edit stories posted by other users, post stories to the chat page, pin chat stories, and access the chat's story archive.

Definition at line 1610 of file Types.h.

◆ canInviteUsers

bool TgBot::ChatAdministratorRights::canInviteUsers { }

True, if the user is allowed to invite new users to the chat.

Definition at line 1599 of file Types.h.

◆ canManageChat

bool TgBot::ChatAdministratorRights::canManageChat { }

True, if the administrator can access the chat event log, get boost list, see hidden supergroup and channel members, report spam messages, ignore slow mode, and send messages to the chat without paying Telegram Stars. Implied by any other administrator privilege.

Definition at line 1566 of file Types.h.

◆ canManageDirectMessages

std::optional<bool> TgBot::ChatAdministratorRights::canManageDirectMessages { }

Optional. True, if the administrator can manage direct messages of the channel and decline suggested posts; for channels only.

Definition at line 1644 of file Types.h.

◆ canManageTags

std::optional<bool> TgBot::ChatAdministratorRights::canManageTags { }

Optional. True, if the administrator can edit the tags of regular members; for groups and supergroups only. If omitted, defaults to the value of can_pin_messages.

Definition at line 1650 of file Types.h.

◆ canManageTopics

std::optional<bool> TgBot::ChatAdministratorRights::canManageTopics { }

Optional. True, if the user is allowed to create, rename, close, and reopen forum topics; for supergroups only.

Definition at line 1638 of file Types.h.

◆ canManageVideoChats

bool TgBot::ChatAdministratorRights::canManageVideoChats { }

True, if the administrator can manage video chats.

Definition at line 1576 of file Types.h.

◆ canPinMessages

std::optional<bool> TgBot::ChatAdministratorRights::canPinMessages { }

Optional. True, if the user is allowed to pin messages; for groups and supergroups only.

Definition at line 1632 of file Types.h.

◆ canPostMessages

std::optional<bool> TgBot::ChatAdministratorRights::canPostMessages { }

Optional. True, if the administrator can post messages in the channel, approve suggested posts, or access channel statistics; for channels only.

Definition at line 1621 of file Types.h.

◆ canPostStories

bool TgBot::ChatAdministratorRights::canPostStories { }

True, if the administrator can post stories to the chat.

Definition at line 1604 of file Types.h.

◆ canPromoteMembers

bool TgBot::ChatAdministratorRights::canPromoteMembers { }

True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that they have promoted, directly or indirectly (promoted by administrators that were appointed by the user).

Definition at line 1589 of file Types.h.

◆ canRestrictMembers

bool TgBot::ChatAdministratorRights::canRestrictMembers { }

True, if the administrator can restrict, ban or unban chat members, or access supergroup statistics.

Definition at line 1582 of file Types.h.

◆ isAnonymous

bool TgBot::ChatAdministratorRights::isAnonymous { }

True, if the user's presence in the chat is hidden.

Definition at line 1558 of file Types.h.


The documentation for this struct was generated from the following file: