Webhooks
Handle Twilio call status updates
Status callback posted by Twilio as a call transitions through queued / ringing / in-progress / completed / busy / no-answer / failed. Updates the Call record with final status, duration, and end timestamp and emits a socket event so the agent UI reflects the change.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
text/plain
application/json
curl -X POST "https://example.com/api/webhook/calls/twilio/status" \ -H "Content-Type: application/json" \ -d '{ "CallSid": "CA5f7b1c2e8a1d4e0012c3b4a5", "CallStatus": "completed", "CallDuration": "42", "Duration": "1", "From": "+14165550100", "To": "+12362320246" }'"OK"