Twilio uses webhooks (status callbacks) to notify your application about SMS delivery status, voice call events, and messaging updates. Twilio webhooks are essential for building reliable communication workflows.
Twilio webhooks are HTTP POST requests that Twilio sends to your server when specific events occur in your account. Rather than continuously polling the Twilio API for updates, webhooks deliver real-time notifications the moment something happens — a payment completes, a user signs up, a deployment finishes, or any other tracked event.
Debugging these webhooks can be challenging because they originate from Twilio's servers, not your browser. You can't simply open DevTools to inspect them. That's where WebhookVault comes in — capture every Twilio webhook, inspect the full payload and headers, and replay them to your local development server.
| Event | Description |
|---|---|
| Message Status Callback | Fired when an SMS status changes (queued, sent, delivered, failed) |
| Incoming Message | Fired when your Twilio number receives an SMS or MMS |
| Voice Status Callback | Fired when a voice call status changes (ringing, in-progress, completed) |
| Recording Completed | Fired when a call recording is available for download |
Follow these steps to start capturing and debugging Twilio webhooks using WebhookVault.
Sign up for a free WebhookVault API key and create an endpoint to capture Twilio webhooks.
curl -X POST https://webhookvault.anethoth.com/api/v1/endpoints \
-H "Authorization: Bearer wv_your_key" \
-H "Content-Type: application/json" \
-d '{"name": "Twilio Webhooks"}'
# Response:
# {"url": "https://webhookvault.anethoth.com/hook/abc123", "inspect_url": "https://webhookvault.anethoth.com/inspect/abc123"}
Go to the Twilio Console > Phone Numbers > Active Numbers Select your Twilio phone number Under Messaging, set the webhook URL to your WebhookVault endpoint For status callbacks, configure the Status Callback URL in your API call
Once Twilio sends a webhook, you can inspect every detail through the WebhookVault API or web inspector.
curl https://webhookvault.anethoth.com/api/v1/endpoints/abc123/requests \
-H "Authorization: Bearer wv_your_key"
# Returns all captured Twilio webhook requests with full headers, body, and metadata
Replay any captured Twilio webhook to your local development server for testing.
curl -X POST https://webhookvault.anethoth.com/api/v1/endpoints/abc123/requests/1/replay \
-H "Authorization: Bearer wv_your_key" \
-H "Content-Type: application/json" \
-d '{"url": "http://localhost:3000/webhook"}'
# The original Twilio webhook is replayed to your local server
Here is an example of a typical Twilio webhook payload. Use WebhookVault to capture real payloads from your Twilio account for accurate testing.
{
"AccountSid": "ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"ApiVersion": "2010-04-01",
"Body": "Hello from Twilio!",
"From": "+15551234567",
"To": "+15559876543",
"MessageSid": "SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"MessageStatus": "delivered",
"NumMedia": "0",
"SmsStatus": "delivered"
}
Here are the most common issues developers encounter when working with Twilio webhooks, and how to resolve them.
For incoming message webhooks, Twilio expects a TwiML XML response. Configure your WebhookVault endpoint to return appropriate TwiML.
Twilio validates requests using the X-Twilio-Signature header. Ensure your auth token and full URL (including https://) are correct.
Twilio cannot reach localhost URLs. Use WebhookVault to capture webhooks and replay them to your local server.
Twilio expects a response within 15 seconds. For long processing, acknowledge immediately and process asynchronously.
Twilio webhooks are HTTP callbacks that Twilio sends to your server when specific events occur. Instead of polling the Twilio API for changes, webhooks push real-time notifications to your application, making your integration more efficient and responsive.
Use WebhookVault to capture Twilio webhooks in the cloud, then replay them to your localhost. Create a WebhookVault endpoint, configure Twilio to send webhooks to it, and use the replay API to forward captured requests to http://localhost:3000/webhook (or your local port).
Most webhook providers, including Twilio, sign their webhook payloads to prove authenticity. Check the Twilio documentation for the specific signature header and verification algorithm. Use WebhookVault to capture and inspect the raw headers to debug signature verification issues.
Unlike ngrok, WebhookVault captures and stores every webhook request with full headers and payloads. You can replay any Twilio webhook to your local server as many times as needed, inspect historical requests, and share webhook data with your team. No tunnel to maintain or port to expose.
Create a free WebhookVault endpoint in seconds. Capture, inspect, and replay Twilio webhooks with zero configuration.
Get Free API Key