All webhooks
Calls
Call recording ready
call.recording_readyFires after a call recording has finished processing and is available for download. Recordings are produced asynchronously, so this event arrives shortly after call.completed, not at the same time. The audio file is delivered as a standard message attachment: fetch it through the authenticated media API using recording.message_id / recording.attachment_id — no public URL is included in the webhook payload.
HTTP request
AISAR sends a signed POST request to your webhook_url:
http
POST {webhook_url}
Content-Type: application/json
X-AISAR-Signature: sha256=...
{
"event": "call.recording_ready",
"event_id": "evt_01JXXXXXXXXXXXXXXXXXXXXX",
"timestamp": "2026-06-06T12:02:45.000000Z",
"company_id": 1,
"data": {
"call_id": 123,
"direction": "inbound",
"status": "completed",
"from_number": "77001234567",
"to_number": "77001234567",
"contact_id": 42,
"conversation_id": 100,
"channel_id": 5,
"external_call_id": "wacall_abc123",
"duration_sec": 150,
"started_at": "2026-06-06T12:00:00+00:00",
"answered_at": "2026-06-06T12:00:08+00:00",
"ended_at": "2026-06-06T12:02:38+00:00",
"recording": {
"message_id": 7788,
"attachment_id": 9911,
"duration_sec": 150,
"mime_type": "audio/wav"
}
}
}The X-AISAR-Signature header carries an HMAC-SHA256 signature of the request body — use it to verify the request came from AISAR.
Example payload
json
{
"event": "call.recording_ready",
"event_id": "evt_01JXXXXXXXXXXXXXXXXXXXXX",
"timestamp": "2026-06-06T12:02:45.000000Z",
"company_id": 1,
"data": {
"call_id": 123,
"direction": "inbound",
"status": "completed",
"from_number": "77001234567",
"to_number": "77001234567",
"contact_id": 42,
"conversation_id": 100,
"channel_id": 5,
"external_call_id": "wacall_abc123",
"duration_sec": 150,
"started_at": "2026-06-06T12:00:00+00:00",
"answered_at": "2026-06-06T12:00:08+00:00",
"ended_at": "2026-06-06T12:02:38+00:00",
"recording": {
"message_id": 7788,
"attachment_id": 9911,
"duration_sec": 150,
"mime_type": "audio/wav"
}
}
}Payload fields
| Field | Type | Description |
|---|---|---|
call_id | integer | Internal call ID (stable across all lifecycle events of this call) |
direction | string | inbound (from contact) or outbound (placed by operator) |
status | string | Call status: completed |
from_number | string | Caller number. For inbound calls — the customer; for outbound — your WhatsApp Business number |
to_number | string | Callee number. For inbound calls — your WhatsApp Business number; for outbound — the customer |
contact_id | integer|null | Contact ID |
conversation_id | integer|null | Conversation ID |
channel_id | integer | WhatsApp Business channel ID |
external_call_id | string|null | Provider-specific call ID (WhatsApp/SIP) |
duration_sec | integer | Talk time in seconds |
started_at | string|null | ISO 8601 timestamp the call started ringing |
answered_at | string | ISO 8601 timestamp the call connected |
ended_at | string | ISO 8601 timestamp the call ended |
recording.message_id | integer | ID of the timeline message the recording is attached to |
recording.attachment_id | integer | ID of the recording attachment |
recording.duration_sec | integer|null | Recording length in seconds |
recording.mime_type | string | Recording MIME type (e.g. audio/wav) |