Connect your app to Waflo
When something happens in your website or app, send one event to Waflo. A rule decides what happens next.
Set up in a few minutes
In Settings → Integrations, name your connection and click Create Integration. Copy its Webhook URL.
Copy the key when it appears. Save it in your server’s secret settings as WAFLO_API_KEY. Save the URL as WAFLO_WEBHOOK_URL.
Set the event type to order_created. Map the customer phone to customer.phone, then choose a message and save.
Your API key is the secret for basic setup. Waflo creates it for you. Keep it out of browser code and public repositories. If lost, use Rotate Key and update your server; the old key stops working.
Send one event
Use an HTTPS POST with JSON and your API key. Your rule reads fields from this payload.
event_type must match the rule name exactly.
customer.phone is required. Use an Indian number with country code, such as +91….
Fields like order.number can fill a message or approved template.
{
"event_type": "order_created",
"external_id": "ORDER-1021",
"customer": {
"name": "Example Customer",
"phone": "+919876543210",
"email": "customer@example.com"
},
"order": {
"number": "ORDER-1021",
"total": "1250.00"
}
}Important: external_id helps you identify an event, but Waflo does not automatically deduplicate it. Do not resend a successful event.
Choose your language
These examples run on your server. Replace the example order and customer with your own data.
curl --request POST "$WAFLO_WEBHOOK_URL" \
--header "Authorization: Bearer $WAFLO_API_KEY" \
--header "Content-Type: application/json" \
--data '{"event_type":"order_created","external_id":"ORDER-1021","customer":{"name":"Example Customer","phone":"+919876543210"},"order":{"number":"ORDER-1021","total":"1250.00"}}'Send to the Webhook URL shown in your own Waflo integration, not to a URL copied from another account.
Check that it worked
Send one test event to a number you control, then open the integration’s Events list.
Waflo handled the rule. Check message delivery separately.
No enabled rule or matching flow was found for that event.
Open the event to see why it could not be processed.
Common questions and errors
Where do I add a webhook secret? Put the Waflo API key in your server’s secret or environment-variable settings. Send it as Authorization: Bearer YOUR_KEY. No separate secret is needed for the basic flow.
401 Invalid API key? Check that you are using the key for this connection. If you rotated it, update your server with the new key.
422 or no message? Check the customer phone, WhatsApp connection, matching event rule, and message choice. Free text only works within the 24-hour customer service window; otherwise select an approved template. Learn about templates →
Will a successful POST mean delivered? No. It confirms Waflo handled the event; WhatsApp delivery has its own status. Avoid blind retries, which can create another message.