Skip to content

Send Orders to Your CRM (Webhooks)

An order webhook sends each order to a URL you choose: once when it is created, and again every time it changes, such as when it is paid, shipped or cancelled. Use it to keep your CRM or your own app in step with Wylto, or to add orders to a Google Sheet through Zapier, Make or n8n.

It covers every order in Orders: orders sent by a Collect Payment block, WhatsApp catalog orders, and changes your team makes in the inbox or the mobile app.

Settings, Order Management, Webhooks: one webhook URL with Order created, Order updated and Signed badges, a Test button, and a Recent deliveries table
  1. Go to Settings → Order Management and scroll to Webhooks. Click Add webhook.
  2. Paste the Endpoint URL your tool gave you.
  3. Pick the Events: Order created, Order updated, or both.
  4. Optional: add Headers your endpoint needs, such as X-Api-Key or Authorization: Bearer …, and a Signing secret.
  5. Save, then click Test to send a sample. The result shows under Recent deliveries.
Add webhook form with endpoint URL, Order created and Order updated checkboxes, a header row, signing secret and Active switch
EventSent when
ORDER_CREATEDA new order is saved. A catalog order is sent when the customer finishes checkout, not while it is still a draft
ORDER_UPDATEDAnything in the order changes: status, payment status, payment details, items or total, address, contact name, payment link
PINGYou click Test. Sample data only

ORDER_UPDATED tells you what changed in changes, and the status before the change in previous. A change to the order’s last-updated time alone is not sent.

A POST with a JSON body:

{
"triggerEvent": "ORDER_UPDATED",
"createdAt": "2026-12-04T10:04:12Z",
"payload": {
"orderId": "kU3sWq0bM1aXc7Yp2LrT",
"status": "new",
"paymentStatus": "paid",
"paymentMethod": "whatsapp_pay",
"currency": "INR",
"items": [
{ "name": "Skin consultation (30 min)", "price": 499, "quantity": 1 },
{ "name": "Skin analysis report", "price": 250, "quantity": 1 }
],
"subtotal": 749,
"tax": 0,
"total": 749,
"payment": { "amount": 749, "currency": "INR", "transactionId": "pay_Nf2…", "method": "upi" },
"contact": { "id": "…", "name": "Priya Sharma", "email": "priya@example.com", "phone": "919800000000" },
"conversationId": "…",
"source": "whatsapp",
"createdAt": "2026-12-04T10:02:00Z",
"updatedAt": "2026-12-04T10:04:11Z",
"changes": ["paymentStatus", "payment"],
"previous": { "status": "new", "paymentStatus": "pending" }
}
}
FieldWhat it is
orderIdThe order’s id in Wylto. Use it to match events for the same order
statusThe order status your team sets: usually new, processing, shipped, delivered or cancelled
paymentStatuspending, paid or failed. Can be empty for orders that never asked for payment
itemsname, price (per unit) and quantity. Catalog orders also have productId
subtotal, tax, totalIn rupees, like 749 for ₹749
paymentOnly once WhatsApp reports a payment: amount in rupees, transactionId and method (for example upi)
shippingAddressOnly when the order asked for an address
contactThe customer: id, name, phone, email
flowIdFor Collect Payment orders, the chatbot that sent it
createdAt, updatedAtWhen the order was created and last changed, in UTC

Every request also has the headers X-Wylto-Event (the event name) and X-Wylto-Delivery (a unique id for this event).

With a signing secret, each request carries X-Wylto-Signature-256: sha256=<hex>: an HMAC-SHA256 of the raw body, keyed with your secret. Work it out yourself and compare before trusting the request. In Node.js:

const crypto = require('crypto');
function isFromWylto(rawBody, header, secret) {
const expected = 'sha256=' + crypto.createHmac('sha256', secret).update(rawBody).digest('hex');
const a = Buffer.from(header || '');
const b = Buffer.from(expected);
return a.length === b.length && crypto.timingSafeEqual(a, b);
}

In Python:

import hashlib, hmac
def is_from_wylto(raw_body: bytes, header: str, secret: str) -> bool:
expected = 'sha256=' + hmac.new(secret.encode(), raw_body, hashlib.sha256).hexdigest()
return hmac.compare_digest(expected, header or '')

Use the raw body exactly as received; parsing and re-encoding the JSON changes it.

Reply with any 2xx status. We wait up to 10 seconds and do not retry, so a request that fails or times out is not sent again. Recent deliveries shows the last 20 attempts with the order id and status code; hover a row to see the response or error.

We send each event once per webhook. If your endpoint ever sees the same X-Wylto-Delivery twice, ignore the second one.

Every field, header and example for each event is in the API reference.