AmityReactionRepository
class provides a convenient method to add, remove, and query reactions for any content. Currently, reactions are supported for Posts, Messages and Comments.AmityReactionRepository
referenceId
String
referenceType
String
reactionName
String
like
', 'love
' , 'wow
'reactionId
String
reactorId
String
reactorDisplayName
String
createdAt
String($date-time)
AmityReactionRepository
class provides two methods which gets detailed information about reactions to the post. Each information is provided though AmityReaction
object.getReactions
method. This method requires: referenceId
, reactionName
and referenceType
as a parameter and provides you with collections of AmityReaction
. referenceId
is the reference id for Post, Message or Comment.AmityReactionRepository
provides addReaction
and removeReaction
methods for adding and removing reactions respectively. Both methods accept the reaction name and postId
as parameters. reaction
parameter is the reaction name. This can be "like", "love", "wow" and other reaction names which has a maximum length of 100 characters. It is case sensitive. This means that "like" and "Like" are two different reactions.