Webhooks Overview
Configure account-level real-time HTTP callbacks for delivery receipts and inbound messages across SMS and WhatsApp.
Last updated · Markdown version
Bulkit uses webhooks to notify your server in real time when events occur on your account. Rather than polling the API continuously, Bulkit dispatches an HTTP POST request to your public webhook endpoint whenever:
- an outbound SMS or WhatsApp message changes status (e.g. delivered, failed, read)
- an inbound SMS or WhatsApp message arrives from a customer
Shared Account-Level Webhooks
Webhooks in Bulkit are shared at the account level across all your API keys and campaigns. You configure two endpoints in the Bulkit dashboard under API Keys -> Webhooks:
- DLR Webhook URL (Delivery Reports): Receives status updates (
sms.delivered,sms.failed,sms.blacklisted,whatsapp.receipt.updated). - Inbox Webhook URL (Inbound Messages): Receives customer replies (
sms.received,whatsapp.message.received).
Each endpoint has an Enable switch in the dashboard so you can activate or pause notifications at any time.
Webhook Headers
Bulkit sends the following standard HTTP headers with every webhook POST request:
| Header | Description | Example |
|---|---|---|
Content-Type | MIME format of the request body | application/json |
X-Bulkit-Webhook-Event | The specific event identifier | sms.delivered, whatsapp.message.received |
Receiving Webhook Requests
When Bulkit triggers a webhook, your endpoint should:
- Return HTTP 200 OK promptly: Respond with an HTTP
200status code as soon as the payload is received. - Process asynchronously: Hand off heavy processing, database updates, or external API calls to background job workers (e.g. Celery, Redis queue, BullMQ, Go channels) so your HTTP response is not delayed.
- Handle retries idempotently: Store the unique
outbox_id(SMS) ormessage_id(WhatsApp) so duplicate deliveries can be detected and handled safely.
// Expected response from your server:
HTTP/1.1 200 OK
Content-Type: application/json
{"status": "ok"}Supported Events
Delivery Reports (DLR)
sms.delivered: SMS successfully delivered to the recipient's mobile terminal.sms.failed: SMS delivery failed at the operator network.sms.blacklisted: Outgoing SMS was rejected because the recipient is on the sender blacklist.whatsapp.receipt.updated: WhatsApp delivery status changed (deliveredorread).
Detailed documentation and JSON payloads are available in Delivery Report (DLR) Webhooks.
Inbound Messages
sms.received/sms.inbound: Incoming SMS sent to your shortcode or two-way number.whatsapp.message.received: Inbound WhatsApp customer message (text, image, document, audio, video).
Detailed documentation and JSON payloads are available in Inbound Message Webhooks.