GramIO API Reference / @gramio/contexts/dist / ChatAdministratorRights
Class: ChatAdministratorRights
Defined in: contexts/index.d.ts:3242
Represents the rights of an administrator in a chat.
Constructors
Constructor
new ChatAdministratorRights(
payload):ChatAdministratorRights
Defined in: contexts/index.d.ts:3244
Parameters
| Parameter | Type |
|---|---|
payload | TelegramChatAdministratorRights |
Returns
ChatAdministratorRights
Properties
| Property | Type | Defined in |
|---|---|---|
payload | TelegramChatAdministratorRights | contexts/index.d.ts:3243 |
Accessors
[toStringTag]
Get Signature
get [toStringTag]():
string
Defined in: contexts/index.d.ts:3246
Returns
string
Methods
canChangeInfo()
canChangeInfo():
boolean
Defined in: contexts/index.d.ts:3260
true, if the user is allowed to change the chat title, photo and other settings
Returns
boolean
canDeleteMessages()
canDeleteMessages():
boolean
Defined in: contexts/index.d.ts:3252
true, if the administrator can delete messages of other users
Returns
boolean
canDeleteStories()
canDeleteStories():
boolean
Defined in: contexts/index.d.ts:3274
true, if the administrator can delete stories posted by other users; channels only
Returns
boolean
canEditMessages()
canEditMessages():
boolean
Defined in: contexts/index.d.ts:3266
true, if the administrator can edit messages of other users and can pin messages; channels only
Returns
boolean
canEditStories()
canEditStories():
boolean
Defined in: contexts/index.d.ts:3272
true, if the administrator can edit stories posted by other users; channels only
Returns
boolean
canInviteUsers()
canInviteUsers():
boolean
Defined in: contexts/index.d.ts:3262
true, if the user is allowed to invite new users to the chat
Returns
boolean
canManageChat()
canManageChat():
boolean
Defined in: contexts/index.d.ts:3250
true, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
Returns
boolean
canManageDirectMessages()
canManageDirectMessages():
boolean
Defined in: contexts/index.d.ts:3278
true, if the administrator can manage direct messages of the channel and decline suggested posts; channels only
Returns
boolean
canManageTags()
canManageTags():
boolean
Defined in: contexts/index.d.ts:3280
true, if the administrator can edit the tags of regular members; for groups and supergroups only
Returns
boolean
canManageTopics()
canManageTopics():
boolean
Defined in: contexts/index.d.ts:3276
true, if the user is allowed to create, rename, close, and reopen forum topics; supergroups only
Returns
boolean
canManageVideoChats()
canManageVideoChats():
boolean
Defined in: contexts/index.d.ts:3254
true, if the administrator can manage video chats
Returns
boolean
canPinMessages()
canPinMessages():
boolean
Defined in: contexts/index.d.ts:3268
true, if the user is allowed to pin messages; groups and supergroups only
Returns
boolean
canPostMessages()
canPostMessages():
boolean
Defined in: contexts/index.d.ts:3264
true, if the administrator can post in the channel; channels only
Returns
boolean
canPostStories()
canPostStories():
boolean
Defined in: contexts/index.d.ts:3270
true, if the administrator can post stories in the channel; channels only
Returns
boolean
canPromoteMembers()
canPromoteMembers():
boolean
Defined in: contexts/index.d.ts:3258
true, if the administrator can add new administrators with a subset of their own privileges or demote administrators that he has promoted, directly or indirectly (promoted by administrators that were appointed by the user)
Returns
boolean
canRestrictMembers()
canRestrictMembers():
boolean
Defined in: contexts/index.d.ts:3256
true, if the administrator can restrict, ban or unban chat members
Returns
boolean
isAnonymous()
isAnonymous():
boolean
Defined in: contexts/index.d.ts:3248
true, if the user's presence in the chat is hidden
Returns
boolean