Send emoji reactions
The code on this page works with either the default UI or the custom UI.
Send and receive emoji reactions and feedback with the SDK through the IEmojiReactionController.
val emojiReactionController = ZoomSDK.getInstance().inMeetingService.emojiReactionController
IEmojiReactionController emojiReactionController = ZoomSDK.getInstance().getInMeetingService().getEmojiReactionController();
To send reactions, first check that reactions are supported in the current meeting. Then, use sendEmojiReaction.
if (emojiReactionController.isEmojiReactionEnabled) {
emojiReactionController.sendEmojiReaction(SDKEmojiReactionType.Clap)
}
if (emojiReactionController.isEmojiReactionEnabled()) {
emojiReactionController.sendEmojiReaction(SDKEmojiReactionType.Clap);
}
Supported emojis and feedback
The SDKEmojiReactionType enum currently supports only these unicode emojis.
ClapThumbsupHeartJoyOpenmouthTada
Emoji feedback is also supported, but is done through a separate method.
emojiReactionController.sendEmojiFeedback(MobileRTCEmojiFeedbackType.MobileRTCEmojiFeedbackType_Yes)
emojiReactionController.sendEmojiFeedback(MobileRTCEmojiFeedbackType.MobileRTCEmojiFeedbackType_Yes);
These feedback types are supported.
MobileRTCEmojiFeedbackType_YesMobileRTCEmojiFeedbackType_NoMobileRTCEmojiFeedbackType_SpeedUpMobileRTCEmojiFeedbackType_SlowDownMobileRTCEmojiFeedbackType_Away
Get reaction and feedback updates
To get updates related to emoji reaction and feedback, implement the IEmojiReactionControllerEvent interface
and pass it into the IEmojiReactionController using the setEvent method.
val emojiReactionControllerEvent = object : IEmojiReactionControllerEvent {
override fun onEmojiReactionReceived(userId: Long, sdkEmojiReactionType: SDKEmojiReactionType?) {
// Received emoji reaction from user with userId
}
override fun onEmojiReactionReceivedInWebinar(sdkEmojiReactionType: SDKEmojiReactionType?) {
// Received emoji reaction in webinar
}
override fun onEmojiFeedbackReceived(userId: Long, mobileRTCEmojiFeedbackType: MobileRTCEmojiFeedbackType?) {
// Received emoji feedback from user with userId
}
override fun onEmojiFeedbackCanceled(userId: Long) {
// Emoji feedback canceled by user with userId
}
}
emojiReactionController.setEvent(emojiReactionControllerEvent)
IEmojiReactionControllerEvent emojiReactionControllerEvent = new IEmojiReactionControllerEvent() {
@Override
public void onEmojiReactionReceived(long userId, SDKEmojiReactionType sdkEmojiReactionType) {
// Received emoji reaction from user with userId
}
@Override
public void onEmojiReactionReceivedInWebinar(SDKEmojiReactionType sdkEmojiReactionType) {
// Received emoji reaction in webinar
}
@Override
public void onEmojiFeedbackReceived(long userId, MobileRTCEmojiFeedbackType mobileRTCEmojiFeedbackType) {
// Received emoji feedback from user with userId
}
@Override
public void onEmojiFeedbackCanceled(long userId) {
// Emoji feedback canceled from user with userId
}
};
emojiReactionController.setEvent(emojiReactionControllerEvent);
These callbacks are triggered when any participant sends a reaction or feedback in a meeting with the user ID of the participant who sent or canceled the reaction or feedback. There is also a dedicated callback for when webinar attendees anonymously send reactions.