Connection flow
Endpoint
Request body
| Field | Type | Required | Description |
|---|---|---|---|
room_name | string | Yes | LiveKit room name created by the SIP dispatch rule |
caller_number | string | Yes | Caller’s phone number |
dialed_number | string | Yes | DID that was called — used to look up bot ID |
call_id | string | No | Optional call ID. Generated if not provided. |
Response
Audio format
| Property | Value |
|---|---|
| Encoding | LINEAR16 (signed 16-bit PCM) |
| Sample rate | 16,000 Hz |
| Channels | Mono |
| Transport | LiveKit SDK (WebRTC) |
Bot ID lookup
VoxCore resolves the bot ID from the dialled number by calling VoxBridge:{"bot_id": "..."}. If no bot is mapped to the DID, the call is rejected.
Hangup behavior
Bot-initiated: VoxCore callstransport.disconnect(), which leaves the LiveKit room. LiveKit SIP infrastructure tears down the phone call.
Customer hangup: LiveKit fires on_participant_left. VoxCore captures disconnected_by = "customer" and winds down the pipeline.
Transfer: VoxCore calls the LiveKit SIP transfer API (lkapi.sip.transfer_sip_participant()) to transfer the call to another number.
Prerequisites
- LiveKit server with SIP trunks configured
- SIP dispatch rule pointing to VoxCore’s
/livekit/dispatchendpoint - DID → bot ID mapping in VoxBridge
- Environment variables:
LIVEKIT_URL,LIVEKIT_API_KEY,LIVEKIT_API_SECRET