Webhooks
Comments Webhooks
The Comments
component will emit webhook notifications whenever an action type
occurs on a comment.
To read more about how to setup webhooks with our SDK, click here.
List of Action Types
Action Type | Description |
---|---|
newlyAdded | When the first comment in a thread is added |
added | When a new comment is added. Not used for the first comment in a thread - see newlyAdded |
updated | When an existing comment content gets updated |
deleted | When an existing comments gets deleted |
approved | When the comment is approved by the moderator. This is only applicable if you have turned on Moderator Mode. |
assigned | When a comment gets assigned to a user |
statusChanged | When a comment has its status changed (e.g. in progress, resolved, opened) |
priorityChanged | When a comment has its priority changed (e.g. P0, P1, P2 or custom set priorities) |
accessModeChanged | When a comment is changed from private to public or vice-versa |
accepted | When a comment gets accepted by the moderator. This is only applicable if you have turned on Moderator Mode. |
rejected | When a comment gets rejected by the moderator. This is only applicable if you have turned on Moderator Mode. |
reactionAdded | When a reaction is added to a comment. |
reactionDeleted | When a reaction is removed from a comment. |
subscribed | When a user subscribes to a comment annotation using the option in the UI. |
unsubscribed | When a user unsubscribes from a comment annotation using the option in the UI. |
Webhook Data
Field | Type | Required | Description |
---|---|---|---|
webhookId | string | Yes | The unique identifier for the webhook event. |
commentAnnotation | CommentAnnotation | Yes | The target CommentAnnotation object on which the event happened. |
targetComment | Comment | Optional | The target Comment object on which the event happened. This field will not be present if the event was at CommentAnnotation level. Eg: deleted the entire comment annotation, resolved comment, approved comment. |
actionType | string | Yes | This can have the values listed above |
notificationSource | string | Yes | Indicates the source of the notification |
actionUser | string | Yes | Contains information about the user who performed the action, including their name, email, and user ID. |
metadata | string | Yes | This field contains additional metadata related to the annotation, such as the API key, client document ID, document ID, and information about various locations where the annotation is associated with a web page. |
Was this page helpful?