setMessageReaction

inline fun setMessageReaction(messageId: Long, reaction: List<ReactionType>? = null, isBig: Boolean? = null): SetMessageReactionAction

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. Bots can't use paid reactions. Returns True on success.

Api reference

Parameters

chatId

Unique identifier for the target chat or username of the target channel (in the format @channelusername)

messageId

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.

reaction

A JSON-serialized 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. Paid reactions can't be used by bots.

isBig

Pass True to set the reaction with a big animation


inline fun setMessageReaction(messageId: Long, vararg reaction: ReactionType, isBig: Boolean? = null): SetMessageReactionAction
fun setMessageReaction(messageId: Long, isBig: Boolean? = null, reaction: ListingBuilder<ReactionType>.() -> Unit): SetMessageReactionAction