{
"call_id": "<string>",
"payload": {
"type": "complete",
"response_body": {},
"call_data": {
"call_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"phone_number": "<string>",
"total_duration": 123,
"enhanced_transcript": {},
"report": {},
"recording_url": "<string>",
"permanent_recording_url": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z"
},
"call_started": "2023-11-07T05:31:56Z",
"retry_attempt_number": 1,
"root_call_id": "<string>",
"next_retry_at": "2023-11-07T05:31:56Z"
}
}Webhooks
Receive a call outcome
Sarj POSTs this notification to the webhook URL configured in the dashboard. This describes your receiver, not an endpoint on the Sarj API. Acknowledge within 5 seconds after durably storing the event; deduplicate on call_id. payload.type selects complete or a not-completed outcome. complete identifies the started-call payload shape, including voicemail; inspect payload.call_data.status for the outcome. Authentication uses the optional stored credential/header configured for your webhook, not your Sarj API key.
WEBHOOK
callEnded
{
"call_id": "<string>",
"payload": {
"type": "complete",
"response_body": {},
"call_data": {
"call_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"phone_number": "<string>",
"total_duration": 123,
"enhanced_transcript": {},
"report": {},
"recording_url": "<string>",
"permanent_recording_url": "<string>",
"started_at": "2023-11-07T05:31:56Z",
"ended_at": "2023-11-07T05:31:56Z"
},
"call_started": "2023-11-07T05:31:56Z",
"retry_attempt_number": 1,
"root_call_id": "<string>",
"next_retry_at": "2023-11-07T05:31:56Z"
}
}
