Skip to main content

Reactions

Readers can react to comments. A reaction is a toggle: re-sending the same reaction type removes it. Sending a different type adds it alongside — a reader can hold several reaction types on one comment at once.

Toggle a reaction

POST /api/v1/comments/{commentId}/reactions
X-API-Key: ek_…
X-RSMG-Engage-Identity: <assertion>
X-RSMG-Engage-Identity-Signature: t=…,v1=…,kid=…
Content-Type: application/json

{ "reaction_type": "like" }

The reacting reader comes from the identity assertion.

The default allowed types are like, love, laugh, surprise, sad, and angry; your tenant can override the set via the allowedReactions setting. An unknown type returns 422.

Read counts

GET /api/v1/comments/{commentId}/reactions
X-API-Key: ek_…

Returns aggregate counts per reaction type. To learn which types the current reader has applied, use the comment list read with the viewer's assertion — each comment is enriched with the viewer's reactions there.

Real-time echoes

A toggle emits a reaction_toggled SSE event. That event carries an externalUserId field — the reacting reader's external id — so a widget that knows readers only by your ids can suppress the echo of its own reader's action by matching externalUserId === <viewer external id>. See Real-time (SSE).

Full schemas are under Reactions in the API Reference.