Справочник API
Receiving Events

Standard event types & payload

The unified envelope every delivery carries and the full catalogue of standard event types. Subscribe per endpoint with subscribed_events using the exact names below, or use ["*"] for all. The envelope is always id / type / provider / account_id / occurred_at / data; the shape of data depends on type.

Event payload

{
  "id": "evt_2f9c1a4b7e",
  "type": "message.received",
  "provider": "whatsapp",
  "account_id": "acc_8c21d0",
  "occurred_at": "2026-06-08T12:34:56Z",
  "data": {
    "account": { "provider_account_ref": "8613800138000" },
    "conversation": { "id": "8613912345678", "type": "user", "title": "Jordan Lee" },
    "sender": { "id": "8613912345678", "name": "Jordan Lee", "type": "user" },
    "message": {
      "id": "wamid.HBgM",
      "text": "Hi - is my order shipped yet?",
      "direction": "inbound",
      "sent_at": "2026-06-08T12:34:55Z"
    }
  }
}

Standard event types

Примечания

  • For media messages, data.message.attachments[] carries a temporary signed OSS url plus type, mimetype, and size.
  • subscribed_events must contain exact event names from above or ["*"]. Unknown names are rejected when you create or update the endpoint.
  • Not every provider emits every event, and some payload fields differ — see "Webhook standard event differences" for the per-provider matrix.
  • message.read and message.delivered carry the exact receipt scope: data.message.ids lists every message covered by the receipt, and read_at / delivered_at give the provider-reported time.
  • WhatsApp inbound messages include data.message.reply_token — an opaque handle you pass back in reply_to.reply_token of POST /v1/messages to send a quoted reply. Store it alongside the message if you plan to reply later.