Webhooks

Comment & Post Events

comment.created, comment.updated, comment.deleted, post.created, post.deleted - Instagram post comments

These five events cover Instagram post comments - the social side of Wexio, separate from direct messages. A client's Instagram integration ingests their posts and the comments on them.

Subscribe with COMMENT_CREATED, COMMENT_UPDATED, COMMENT_DELETED, POST_CREATED, POST_DELETED.

Comment and post payloads are deliberately flat: they carry IDs, not expanded objects. A comment gives you postId and commenterId rather than the post and the commenter - resolve those yourself if you need them.

comment.created

type: comment.created

Someone commented on one of the client's posts, or replied to an existing comment.

data

type Data = { comment: CommentPayload };

See CommentPayload.

Example

{
  "id": "evt_d6e7f809-1223-3445-5667-788990011223",
  "type": "comment.created",
  "timestamp": "2026-09-30T18:40:00.000Z",
  "data": {
    "comment": {
      "id": "6805a1c2a6f9f35f6e66f2d1",
      "postId": "6805a0f1a6f9f35f6e66f2c0",
      "commenterId": "6805a1b0a6f9f35f6e66f2cc",
      "externalCommentId": "17912345678901234",
      "text": "do you deliver to the north side?",
      "hidden": false,
      "deleted": false,
      "createdAt": "2026-09-30T18:40:00.000Z"
    }
  },
  "meta": {
    "eventId": "evt_d6e7f809-1223-3445-5667-788990011223",
    "event": "comment.created",
    "occurredAt": "2026-09-30T18:40:00.000Z",
    "organisationId": "6716b2f0a1c34d0012ab89ef",
    "externalId": "crmco-client-5541",
    "partnerId": "6716b1001c34d0012ab89abc",
    "apiVersion": "2026-04-01",
    "attempt": 1
  }
}

rootCommentId is present on replies and absent on top-level comments - use it to thread.

comment.updated

type: comment.updated

The comment changed. In practice this is most often a moderation change: hidden flipped.

data

type Data = { comment: CommentPayload };

There is no previous on comment events. Compare against your stored copy.

Example - the comment was hidden

{
  "id": "evt_e7f80912-2334-4556-6778-899001122334",
  "type": "comment.updated",
  "timestamp": "2026-09-30T18:45:00.000Z",
  "data": {
    "comment": {
      "id": "6805a1c2a6f9f35f6e66f2d1",
      "postId": "6805a0f1a6f9f35f6e66f2c0",
      "commenterId": "6805a1b0a6f9f35f6e66f2cc",
      "text": "do you deliver to the north side?",
      "hidden": true,
      "deleted": false,
      "updatedAt": "2026-09-30T18:45:00.000Z"
    }
  },
  "meta": {
    "eventId": "evt_e7f80912-2334-4556-6778-899001122334",
    "event": "comment.updated",
    "occurredAt": "2026-09-30T18:45:00.000Z",
    "organisationId": "6716b2f0a1c34d0012ab89ef",
    "externalId": "crmco-client-5541",
    "partnerId": "6716b1001c34d0012ab89abc",
    "apiVersion": "2026-04-01",
    "attempt": 1
  }
}

comment.deleted

type: comment.deleted

The comment was deleted.

data

type Data = { comment: CommentPayload };

Unlike message and chat deletes, this one carries the full comment payload rather than a trimmed one. The delete is a soft-delete on Wexio's side, so hidden and deleted reflect the stored flags at the moment of emission - treat the event itself, not those flags, as the signal that the comment is gone.

post.created

type: post.created

Wexio recorded a post from the client's connected Instagram account.

data

type Data = { post: PostPayload };

See PostPayload.

Example

{
  "id": "evt_f8091223-3445-5667-7889-900112233445",
  "type": "post.created",
  "timestamp": "2026-09-30T12:00:05.000Z",
  "data": {
    "post": {
      "id": "6805a0f1a6f9f35f6e66f2c0",
      "integrationId": "67f95b0126a4d1c9e3f0aa44",
      "channel": "INSTAGRAM",
      "externalPostId": "17998877665544332",
      "caption": "New wood-fired menu 🔥",
      "username": "pizzeriaroma",
      "isDeleted": false,
      "publishedAt": "2026-09-30T12:00:00.000Z",
      "createdAt": "2026-09-30T12:00:05.000Z"
    }
  },
  "meta": {
    "eventId": "evt_f8091223-3445-5667-7889-900112233445",
    "event": "post.created",
    "occurredAt": "2026-09-30T12:00:05.000Z",
    "organisationId": "6716b2f0a1c34d0012ab89ef",
    "externalId": "crmco-client-5541",
    "partnerId": "6716b1001c34d0012ab89abc",
    "apiVersion": "2026-04-01",
    "attempt": 1
  }
}

publishedAt is when the post went live on the channel; createdAt is when Wexio first saw it. They differ for posts ingested after the fact.

post.deleted

type: post.deleted

The post is gone. It fires on a real transition only - a repeat delete against an already-deleted post emits nothing.

data

type Data = { post: PostPayload };

How complete the payload is depends on the path. Two different deletions emit this event:

  • The post disappeared from Instagram (Wexio marks it deleted during a sync). Wexio has only the post's ID at that point, so the payload is minimal: id is populated, integrationId comes back as an empty string, and channel, externalPostId, caption, username and the timestamps are omitted.
  • The post was permanently removed in Wexio (after it was already deleted on Instagram). The full record is in hand here, so the payload is complete.

Match on data.post.id and treat every other field as optional, whichever path you are handling.

Comments belonging to the post are deleted with it, and you do not get a comment.deleted per comment - cascade on your side from this one event.

On this page