Skip to main content

ronami_core/payloads/
set_message_reaction.rs

1//! Generated by `codegen_payloads`, do not edit by hand.
2
3use serde::Serialize;
4
5use crate::types::MessageId;
6use crate::types::ReactionType;
7use crate::types::Recipient;
8use crate::types::True;
9
10impl_payload! {
11    /// Use this method to change the chosen reactions on a message. Service messages can't be reacted to. Automatically forwarded messages from a channel to its discussion group have the same available reactions as messages in the channel. Returns True on success.
12    #[derive(Debug, PartialEq, Eq, Hash, Clone, Serialize)]
13    pub SetMessageReaction (SetMessageReactionSetters) => True {
14        required {
15            /// Unique identifier for the target chat or username of the target channel (in the format @channelusername)
16            pub chat_id: Recipient [into],
17            /// Identifier of the target message. If the message belongs to a media group, the reaction is set to the first non-deleted message in the group instead.
18            #[serde(flatten)]
19            pub message_id: MessageId,
20        }
21        optional {
22            /// New list of reaction types to set on the message. Currently, as non-premium users, bots can set up to one reaction per message. A custom emoji reaction can be used if it is either already present on the message or explicitly allowed by chat administrators.
23            pub reaction: Vec<ReactionType> [collect],
24            /// Pass True to set the reaction with a big animation
25            pub is_big: bool,
26        }
27    }
28}