Put your agent on a phone number
Connect Twilio or your own SIP carrier, attach a number, and dial in.
Two steps: a trunk that carries the calls, and a number that points at your agent. Let us configure Twilio for you, or connect your own carrier.
Create a trunk
If you use Twilio
Give us your Twilio credentials and we configure the Twilio side:
curl --fail-with-body -X POST "$KEJUE_API_BASE/sip-trunks" \
-H "Authorization: Bearer $KEJUE_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: 018f4d7b-1111-7abc-9def-2b6f8c11aa01" \
--data '{
"name": "twilio-main",
"provider": "twilio_automated",
"account_sid": "ACxxxxxxxx",
"auth_token": "your-twilio-auth-token"
}'If you bring your own carrier
For a carrier that sends calls to a static address and authenticates you by IP:
curl --fail-with-body -X POST "$KEJUE_API_BASE/sip-trunks" \
-H "Authorization: Bearer $KEJUE_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: 018f4d7b-2222-7abc-9def-2b6f8c11aa02" \
--data '{
"name": "carrier-main",
"provider": "sip",
"sip_signaling_mode": "static_peer",
"inbound_auth_mode": "ip_allowlist",
"inbound_allowed_addresses": ["203.0.113.10"],
"outbound_address": "sip.your-carrier.example",
"outbound_transport": "udp",
"outbound_auth_mode": "credentials",
"auth_username": "acme-bank",
"auth_password": "carrier-password"
}'Then get the addresses your carrier needs:
curl --fail-with-body "$KEJUE_API_BASE/sip-trunks/runtime-info" \
-H "Authorization: Bearer $KEJUE_API_KEY"Add an origination route for every address we return, and allow every range we list on your side. We answer on more than one address, and a carrier pointed at just the first one will drop calls.
A trunk takes a moment to come up. Poll GET /sip-trunks/{id} until its
status is active.
Point a number at your agent
curl --fail-with-body -X POST "$KEJUE_API_BASE/phone-numbers" \
-H "Authorization: Bearer $KEJUE_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: 018f4d7b-3333-7abc-9def-2b6f8c11aa03" \
--data '{
"trunk_id": "TRUNK_ID",
"e164": "+12025550100",
"agent_id": "AGENT_ID",
"direction": "inbound"
}'Numbers come up the same way — poll GET /phone-numbers/{id} until active.
Dial it
Call the number. The agent answers, and the conversation appears in your call list with its transcript and recording.
If something goes wrong
| You see | What to do |
|---|---|
The trunk stays in provisioning or turns failed | GET /sip-trunks/{id} returns last_error_code and last_error. Fix the credentials or addresses they point to, then update the trunk. |
| The number rings out or gives a busy tone | Check that the number is active, attached to a deployed agent, and that your carrier routes it to every address in public_sip_uris. |
| Some inbound calls fail now and then | Your carrier probably routes to only one of our addresses. Add a route for every public_sip_uris entry. |
| Calls from your carrier are rejected (IP allowlist trunks) | Add every signaling address your carrier uses to inbound_allowed_addresses. |
Per-call SIP detail, including the messages your carrier sent, is on each call record. See Calls.
Next
- SIP trunks — registration modes, media encryption, and the controls that stop toll fraud.
- Outbound calls — have the agent dial out.
- Transfers & call actions — hand callers to a human.