Receive WhatsApp Messages and Delivery Events via Webhooks
Set up a webhook endpoint to receive inbound WhatsApp messages and delivery events from Pilot Status in real time, with Node.js and Python examples.
To receive inbound WhatsApp messages and delivery events in real time, register a webhook: an HTTPS endpoint on your system that Pilot Status calls with a JSON POST for each event.
Full CRUD is available: GET /v1/webhooks, GET/PATCH/DELETE /v1/webhooks/{id}, and GET /v1/webhooks/{id}/logs for recent delivery attempts. With a number-scoped key the webhook attaches to that key’s number; with a tenant-scoped key pass whatsappNumberId in the body (or the x-whatsapp-number-id header).
Event gating is explicit: an empty events list dispatches nothing — there is no implicit “subscribe to all”. Use "*" to receive every event. On PATCH, eventsreplaces the entire list (no merge), and the webhook’s number cannot be changed after creation.
To pause deliveries without deleting, PATCH with { "active": false }. The signing secret is never returned by any endpoint.
For media messages, mediaLink, mediaType, mediaCaption, and mediaFilename appear when the provider exposes them (e.g. Meta Cloud API). See the Events reference for every event and field.
Reply with POST /v1/messages/send using the sender’s number as the destination:
curl -X POST "https://pilotstatus.com.br/v1/messages/send" \ -H "x-api-key: ps_your_key_here" \ -H "Content-Type: application/json" \ -d '{ "text": "Thanks, we got your message!", "destinationNumber": "+5511999999999" }'
message.reply fires when a contact quotes one of your messages — use quotedMessageId to match it against the messageId from your original message.sent. message.read only fires when the recipient has read receipts enabled.