ChatAdministratorRights

@Serializable
data class ChatAdministratorRights(val isAnonymous: Boolean, val canManageChat: Boolean, val canDeleteMessages: Boolean, val canRestrictMembers: Boolean, val canPromoteMembers: Boolean, val canChangeInfo: Boolean, val canInviteUsers: Boolean, val canPostMessages: Boolean? = null, val canEditMessages: Boolean? = null, val canPinMessages: Boolean? = null, val canManageVideoChats: Boolean, val canManageTopics: Boolean? = null, val canPostStories: Boolean, val canEditStories: Boolean, val canDeleteStories: Boolean)

Represents the rights of an administrator in a chat.

Api reference

Constructors

Link copied to clipboard
constructor(isAnonymous: Boolean, canManageChat: Boolean, canDeleteMessages: Boolean, canRestrictMembers: Boolean, canPromoteMembers: Boolean, canChangeInfo: Boolean, canInviteUsers: Boolean, canPostMessages: Boolean? = null, canEditMessages: Boolean? = null, canPinMessages: Boolean? = null, canManageVideoChats: Boolean, canManageTopics: Boolean? = null, canPostStories: Boolean, canEditStories: Boolean, canDeleteStories: Boolean)

Properties

Link copied to clipboard

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

Link copied to clipboard

True, if the administrator can delete messages of other users

Link copied to clipboard

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

Link copied to clipboard

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

Link copied to clipboard

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

Link copied to clipboard

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

Link copied to clipboard

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

Link copied to clipboard

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

Link copied to clipboard

True, if the administrator can manage video chats

Link copied to clipboard
val canPinMessages: Boolean? = null

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

Link copied to clipboard

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

Link copied to clipboard

True, if the administrator can post stories to the chat

Link copied to clipboard

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)

Link copied to clipboard

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

Link copied to clipboard

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