> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

# Package: feedback

# Namespace: commentV1

# Webhook link: https://dev.wix.com/docs/api-reference/account-level/studio-workspace/feedback/comment-v1/comment-created.md

# Webhook Permissions Scopes IDs:
Read Site Feedback: SCOPE.PARTNERS.FEEDBACK_READ

## Introduction

Triggered when a comment is created.

---

## REST API

### Schema

```
Webhook: Comment Created
Description: Triggered when a comment is created.
Event body:
 - name: id | type: string | description: Unique event ID. Allows clients to ignore duplicate events.
 - name: entityFqdn | type: string | description: Fully qualified domain name of the entity associated with the event.
 - name: slug | type: string | description: Event name.
 - name: entityId | type: string | description: ID of the entity associated with the event.
 - name: eventTime | type: string (date-time) | description: Event timestamp.
 - name: triggeredByAnonymizeRequest | type: boolean | description: Whether the event was triggered as a result of a privacy regulation application such as GDPR.
 - name: originatedFrom | type: string | description: If present, indicates the action that triggered the event.
 - name: createdEvent | type: object | description: Created event details.
    - name: entity | type: Comment | description: The created entity.
        - name: id | type: string | description: Comment GUID.
        - name: revision | type: string | description: Revision number, which increments by 1 each time the comment is updated. To prevent conflicting changes, the current revision must be passed when updating the comment.
        - name: createdDate | type: string | description: Date and time the comment was created.
        - name: updatedDate | type: string | description: Date and time the comment was updated.
        - name: feedbackId | type: string | description: GUID of the [feedback session](https://dev.wix.com/docs/api-reference/account-level/studio-workspace/feedback/feedback-session-v1/introduction.md) the comment belongs to.  A feedback session scopes a round of review on a site and carries an expiration date. Once a session lapses it accepts no new comments, but the comments already in it stay readable and can still be triaged and replied to.
        - name: commenterId | type: string | description: GUID of the commenter who left the comment.
        - name: message | type: string | description: Text of the comment.
        - name: status | type: Status | description: Triage status of the comment.  Every comment starts as `NEW`. [Update Comment Status](https://dev.wix.com/docs/api-reference/account-level/studio-workspace/feedback/comment-v1/update-comment-status.md) is the only way for the site owner to change it, and a commenter can't set the status of their own comment. A comment does return to `NEW` on its own when the commenter replies to it, whatever it was triaged as; a reply from anyone else leaves the status alone. The commenter can also reopen a `RESOLVED` comment, which returns it to `NEW`.
           - enum:
           -     NEW: The comment hasn't been read yet.
           -     OPEN: The comment has been read but isn't resolved.
           -     RESOLVED: The comment has been dealt with.
        - name: commentLocation | type: CommentLocation | description: Where on the page the comment is anchored.
           - name: pageId | type: string | description: GUID of the editor page the comment was left on.
           - name: x | type: number | description: Horizontal position of the comment on the page.
           - name: y | type: number | description: Vertical position of the comment on the page.
           - name: breakpoint | type: Breakpoint | description: Responsive-design breakpoint the comment was left at.
              - name: id | type: string | description: Breakpoint GUID.
              - name: minWidth | type: integer | description: Lowest viewport width the breakpoint applies to, in pixels.
              - name: maxWidth | type: integer | description: Highest viewport width the breakpoint applies to, in pixels.
           - name: innerPath | type: string | description: Inner path of the Wix dynamic page the comment was left on.
           - name: position | type: Position | description: Position of the comment relative to the element it's attached to.
              - name: selector | type: string | description: DOM selector of the target element.
              - name: offsetXPct | type: number | description: Horizontal offset within the element, as a percentage of its width.
              - name: offsetYPct | type: number | description: Vertical offset within the element, as a percentage of its height.
              - name: innerPath | type: string | description: Inner path of the Wix dynamic page the element is on.
        - name: replies | type: array<CommentReply> | description: Replies to the comment, ordered oldest first.  A reply is addressed by its index in this list, so indexes shift when an earlier reply is deleted. Pass the comment's current `revision` when updating or deleting a reply to be sure the index you're addressing is still the one you read.
           - name: message | type: string | description: Text of the reply.
           - name: createdDate | type: string | description: Date and time the reply was created.
           - name: replier | type: Replier | description: Who wrote the reply.
              - ONE-OF:
                 - name: wixUserOptions | type: WixUserOptions | description: The Wix user who wrote the reply, when `type` is `WIX_USER`.
                    - name: accountId | type: string | description: GUID of the account the Wix user was logged in to when they replied. This isn't necessarily the account that owns the site.  A `WIX_USER` replier with no `accountId` is the agency that owns the site.
              - name: type | type: Type | description: What kind of identity wrote the reply.
                   - enum:
                   -     COMMENTER: The comment's commenter. Their name comes from the commenter with the comment's `commenterId`.
                   -     WIX_USER: A Wix user: a user of the agency that owns the site, or of a collaborator account. Details are in `wixUserOptions`.  A `WIX_USER` replier with no `accountId` is the agency that owns the site.

```

### Examples


```curl
{
  "id": "52269077-05f2-4b59-ba4f-36ef8c4c1e11",
  "entityFqdn": "wix.partners.feedback.v1.comment",
  "slug": "created",
  "entityId": "8046df3c-7575-4098-a5ab-c91ad8f33c47",
  "createdEvent": {
    "entityAsJson": "{\"comment\":{\"id\":\"8046df3c-7575-4098-a5ab-c91ad8f33c47\",\"revision\":1,\"createdDate\":\"2026-09-16T09:14:22.104Z\",\"updatedDate\":\"2026-09-16T09:14:22.104Z\",\"feedbackId\":\"3f1a6c2e-9b47-4b1e-8c55-2d7a9f0e5b31\",\"commenterId\":\"e2f06b91-8d4a-4c37-b519-3a7c60d8e4f2\",\"message\":\"The hero image looks stretched on mobile.\",\"status\":\"NEW\",\"commentLocation\":{\"pageId\":\"c1dmp\",\"x\":412.5,\"y\":980.25},\"replies\":[]}}"
  },
  "eventTime": "2026-09-16T09:14:22.104800Z",
  "triggeredByAnonymizeRequest": false
}

```

---

## JavaScript SDK

### Schema

```
Webhook: onCommentCreated
Description: Triggered when a comment is created.
Payload: CommentCreatedEnvelope
  - name: entity | type: Comment | description: none
     - name: _id | type: string | description: Comment GUID.
     - name: revision | type: string | description: Revision number, which increments by 1 each time the comment is updated. To prevent conflicting changes, the current revision must be passed when updating the comment.
     - name: _createdDate | type: Date | description: Date and time the comment was created.
     - name: _updatedDate | type: Date | description: Date and time the comment was updated.
     - name: feedbackId | type: string | description: GUID of the [feedback session](https://dev.wix.com/docs/api-reference/account-level/studio-workspace/feedback/feedback-session-v1/introduction.md) the comment belongs to.  A feedback session scopes a round of review on a site and carries an expiration date. Once a session lapses it accepts no new comments, but the comments already in it stay readable and can still be triaged and replied to.
     - name: commenterId | type: string | description: GUID of the commenter who left the comment.
     - name: message | type: string | description: Text of the comment.
     - name: status | type: Status | description: Triage status of the comment.  Every comment starts as `NEW`. [Update Comment Status](https://dev.wix.com/docs/api-reference/account-level/studio-workspace/feedback/comment-v1/update-comment-status.md) is the only way for the site owner to change it, and a commenter can't set the status of their own comment. A comment does return to `NEW` on its own when the commenter replies to it, whatever it was triaged as; a reply from anyone else leaves the status alone. The commenter can also reopen a `RESOLVED` comment, which returns it to `NEW`.
         - enum:
         -     NEW: The comment hasn't been read yet.
         -     OPEN: The comment has been read but isn't resolved.
         -     RESOLVED: The comment has been dealt with.
     - name: commentLocation | type: CommentLocation | description: Where on the page the comment is anchored.
        - name: pageId | type: string | description: GUID of the editor page the comment was left on.
        - name: x | type: number | description: Horizontal position of the comment on the page.
        - name: y | type: number | description: Vertical position of the comment on the page.
        - name: breakpoint | type: Breakpoint | description: Responsive-design breakpoint the comment was left at.
           - name: _id | type: string | description: Breakpoint GUID.
           - name: minWidth | type: integer | description: Lowest viewport width the breakpoint applies to, in pixels.
           - name: maxWidth | type: integer | description: Highest viewport width the breakpoint applies to, in pixels.
        - name: innerPath | type: string | description: Inner path of the Wix dynamic page the comment was left on.
        - name: position | type: Position | description: Position of the comment relative to the element it's attached to.
           - name: selector | type: string | description: DOM selector of the target element.
           - name: offsetXPct | type: number | description: Horizontal offset within the element, as a percentage of its width.
           - name: offsetYPct | type: number | description: Vertical offset within the element, as a percentage of its height.
           - name: innerPath | type: string | description: Inner path of the Wix dynamic page the element is on.
     - name: replies | type: array<CommentReply> | description: Replies to the comment, ordered oldest first.  A reply is addressed by its index in this list, so indexes shift when an earlier reply is deleted. Pass the comment's current `revision` when updating or deleting a reply to be sure the index you're addressing is still the one you read.
        - name: message | type: string | description: Text of the reply.
        - name: _createdDate | type: Date | description: Date and time the reply was created.
        - name: replier | type: Replier | description: Who wrote the reply.
           - ONE-OF:
              - name: wixUserOptions | type: WixUserOptions | description: The Wix user who wrote the reply, when `type` is `WIX_USER`.
                 - name: accountId | type: string | description: GUID of the account the Wix user was logged in to when they replied. This isn't necessarily the account that owns the site.  A `WIX_USER` replier with no `accountId` is the agency that owns the site.
           - name: type | type: Type | description: What kind of identity wrote the reply.
                 - enum:
                 -     COMMENTER: The comment's commenter. Their name comes from the commenter with the comment's `commenterId`.
                 -     WIX_USER: A Wix user: a user of the agency that owns the site, or of a collaborator account. Details are in `wixUserOptions`.  A `WIX_USER` replier with no `accountId` is the agency that owns the site.
  - name: metadata | type: EventMetadata | description: none
     - name: instanceId | type: string | description: App instance GUID.
     - name: eventType | type: string | description: Event type.
     - name: identity | type: IdentificationData | description: The identification type and identity data.
        - ONE-OF:
           - name: anonymousVisitorId | type: string | description: GUID of a site visitor that has not logged in to the site.
           - name: memberId | type: string | description: GUID of a site visitor that has logged in to the site.
           - name: wixUserId | type: string | description: GUID of a Wix user (site owner, contributor, etc.).
           - name: appId | type: string | description: GUID of an app.
        - name: identityType | type: WebhookIdentityType | description: 
             - enum: UNKNOWN, ANONYMOUS_VISITOR, MEMBER, WIX_USER, APP
     - name: accountInfo | type: AccountInfo | description: Details related to the account
        - name: accountId | type: string | description: GUID of the Wix account associated with the event.
        - name: parentAccountId | type: string | description: GUID of the parent Wix account. Only included when accountId belongs to a child account.
        - name: siteId | type: string | description: GUID of the Wix site associated with the event. Only included when the event is tied to a specific site.
     - name: _id | type: string | description: Event GUID. With this GUID you can easily spot duplicated events and ignore them.
     - name: entityFqdn | type: string | description: Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities. For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
     - name: slug | type: string | description: Event action name, placed at the top level to make it easier for users to dispatch messages. For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
     - name: entityId | type: string | description: GUID of the entity associated with the event.
     - name: eventTime | type: Date | description: Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`.
     - name: triggeredByAnonymizeRequest | type: boolean | description: Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).
     - name: originatedFrom | type: string | description: If present, indicates the action that triggered the event.
     - name: entityEventSequence | type: string | description: A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number. You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.

```

### Examples


```javascript
import { comments } from '@wix/feedback';

comments.onCommentCreated((event) => {
    // handle your event here
});
```


```javascript
import { createClient, AppStrategy } from '@wix/sdk';
import { comments } from '@wix/feedback';

const wixClient = createClient({
  auth: AppStrategy({
    appId: 'MY-APP-ID',
    publicKey: 'YOUR_APP_PUBLIC_KEY',
  }),
  modules: {
      comments,
    },
});

wixClient.comments.onCommentCreated((event) => {
    // handle your event here
});
```

---