Skip to content
API PlatformDevelopers

Webhook events · orders

order.cancelled/1

Order cancelled. The order was cancelled (order status CANCELLED, with the reason when given) or timed out (order status TIMEOUT, reason "timeout").

Payload

We POST this JSON to your endpoint. Answer any 2xx within 30 seconds. The same id arrives again on a retry — skip ones you have handled.

Payload fields
FieldTypeWhat it is
idrequiredstringEvent id. The same on every retry: use it to skip duplicates.pattern ^evt_[0-9A-HJKMNP-TV-Z]{26}$
typerequiredstringEvent type.always order.cancelled
versionrequiredstringPayload version.always 1
api_versionrequiredstringThe endpoint's API version.
occurred_atrequiredstringWhen it happened.date-time
company_idrequiredintegerYour workspace id.
datarequiredobject
order_idrequiredstringOrder id.1–∞ characters
order_numberrequiredstringThe order number shown to the customer.1–∞ characters
external_order_idstring or nullThe order's id in your store platform (e.g. Shopify), once it is there.
statusrequiredstringAlways cancelled: what this event reports.always cancelled
order_statusstring or nullThe order status after the change: PENDING, IN_PROGRESS, CANCELLED, TIMEOUT or COMPLETED.one of: PENDING, IN_PROGRESS, CANCELLED, TIMEOUT, COMPLETED
payment_statusstring or nullPENDING, PAID_ONLINE or PAID_COD.one of: PENDING, PAID_ONLINE, PAID_COD
payment_methodstring or nullonline or cod (cash on delivery); null until paid or chosen.one of: online, cod
storerequiredobject
catalog_idrequiredintegerCatalog id.1–∞
meta_catalog_idstring or nullWhatsApp (Meta) catalog id.
namestring or nullStore name.
platformstring or nullThe store platform, e.g. SHOPIFY or WOOCOMMERCE; null when none is connected.
phone_number_idstring or nullWhatsApp phone number id the order came in on.
customerrequiredobject
namerequiredstring or nullName.
phonerequiredstring or nullPhone number in E.164.pattern ^\+[1-9][0-9]{7,14}$
emailrequiredstring or nullEmail address.
contact_idrequiredinteger or nullContact id; null when the order is not linked to a contact (today, always null).
currencystring or nullCurrency, ISO 4217.
totalnumber or nullOrder total.
items_countrequiredintegerHow many product lines the order has.0–∞
itemsrequiredarray of objectThe product lines (the first 20).0–20 items
retailer_idrequiredstringYour product id (retailer id) in the catalog.
namestring or nullProduct name.
quantityrequirednumberQuantity.0–∞
unit_pricenumber or nullUnit price.
currencystring or nullCurrency, ISO 4217.
line_totalnumber or nullUnit price times quantity.
items_truncatedrequiredbooleanTrue when there were more than 20 lines.
created_atrequiredstringISO 8601.
updated_atrequiredstringISO 8601.
cancelled_atrequiredstringISO 8601.
cancel_reasonrequiredstring or nullWhy, when given (at most 500 characters); "timeout" for a timed-out order.

Example

{
  "id": "evt_01J8Z7BZQ4F6G8J2K5N7Q9S1VC",
  "type": "order.cancelled",
  "version": "1",
  "api_version": "2026-10-01",
  "occurred_at": "2026-09-24T09:20:00Z",
  "company_id": 1001,
  "data": {
    "order_id": "AB12CD34EF",
    "order_number": "AB12CD34EF",
    "external_order_id": "5551234",
    "status": "cancelled",
    "order_status": "CANCELLED",
    "payment_status": "PENDING",
    "payment_method": null,
    "store": {
      "catalog_id": 7,
      "meta_catalog_id": "1234567890123456",
      "name": "Main store",
      "platform": "SHOPIFY",
      "phone_number_id": "100000000000001"
    },
    "customer": {
      "name": "Ann Lee",
      "phone": "+15550100142",
      "email": "ann.lee@example.com",
      "contact_id": null
    },
    "currency": "AED",
    "total": 149.5,
    "items_count": 2,
    "items": [
      {
        "retailer_id": "TEA-001",
        "name": "Green tea 250 g",
        "quantity": 2,
        "unit_price": 49.75,
        "currency": "AED",
        "line_total": 99.5
      },
      {
        "retailer_id": "CUP-002",
        "name": "Tea cup",
        "quantity": 1,
        "unit_price": 50,
        "currency": "AED",
        "line_total": 50
      }
    ],
    "items_truncated": false,
    "created_at": "2026-09-25T09:00:00.000Z",
    "updated_at": "2026-09-25T11:00:00.000Z",
    "cancelled_at": "2026-09-25T11:00:00.000Z",
    "cancel_reason": "Customer changed their mind"
  }
}

Headers

  • Webhook-Signature: t=…,v1=… — how to check it
  • Webhook-Id (also Webhook-Event-Id): the event id, the same on every retry — skip ones you have handled
  • Webhook-Delivery-Id: this delivery attempt, new on every try