messages.SetChatAvailableReactions

class pyrogram.raw.functions.messages.SetChatAvailableReactions

Change the set of message reactions » that can be used in a certain group, supergroup or channel

Details:
  • Layer: 227

  • ID: 864B2581

Parameters:
  • peer (InputPeer) – Group where to apply changes

  • available_reactions (ChatReactions) – Allowed reaction emojis

  • reactions_limit (int 32-bit, optional) – This flag may be used to impose a custom limit of unique reactions (i.e. a customizable version of appConfig.reactions_uniq_max); this field and the other info set by the method will then be available to users in channelFull and chatFull. If this flag is not set, the previously configured reactions_limit will not be altered.

  • paid_enabled (bool, optional) – If this flag is set and a Bool is passed, the method will enable or disable paid message reactions ». If this flag is not set, the previously stored setting will not be changed.

Returns:

Updates

TL Schema

messages.setChatAvailableReactions#864b2581
flags:#
peer:InputPeer
available_reactions:ChatReactions
reactions_limit:flags.0?int
paid_enabled:flags.1?Bool

= Updates

Parameter Tree

SetChatAvailableReactions
├── peer → InputPeer
│ ├── InputPeerEmpty
│ ├── InputPeerSelf
│ ├── InputPeerChat
│ │ └── chat_id → long
│ ├── InputPeerUser
│ │ ├── user_id → long
│ │ └── access_hash → long
│ ├── InputPeerChannel
│ │ ├── channel_id → long
│ │ └── access_hash → long
│ │ ├── peer → InputPeer
│ │ │ ├── InputPeerEmpty
│ │ │ ├── InputPeerSelf
│ │ │ ├── InputPeerChat
│ │ │ ├── InputPeerUser
│ │ │ ├── InputPeerChannel
│ │ │ ├── InputPeerUserFromMessage
│ │ │ └── InputPeerChannelFromMessage
│ │ ├── msg_id → int
│ │ └── user_id → long
│ ├── peer → InputPeer
│ │ ├── InputPeerEmpty
│ │ ├── InputPeerSelf
│ │ ├── InputPeerChat
│ │ ├── InputPeerUser
│ │ ├── InputPeerChannel
│ │ ├── InputPeerUserFromMessage
│ │ └── InputPeerChannelFromMessage
│ ├── msg_id → int
│ └── channel_id → long
├── available_reactions → ChatReactions
│ ├── ChatReactionsNone
│ ├── ChatReactionsAll
│ │ └── allow_custom → true (optional)
│ └── ChatReactionsSome
│ └── reactions → Vector < Reaction >
│ ├── ReactionEmpty
│ ├── ReactionEmoji
│ │ └── emoticon → string
│ ├── ReactionCustomEmoji
│ │ └── document_id → long
│ └── ReactionPaid
├── reactions_limit → int (optional)
└── paid_enabled → Bool (optional)

Example

await app.invoke(
    SetChatAvailableReactions(
        peer=await app.resolve_peer(chat_id),
        available_reactions=ChatReactionsNone(),
        reactions_limit=0,
        paid_enabled=None,
    )
)