Voice Applications
Bundle a set of webhook URLs into a reusable Voice Application that you can attach to phone numbers and SIP endpoints.
Voice Applications
A Voice Application is a named bundle of webhook URLs (voice_url, fallback_url, hangup_url) that defines call behaviour. Instead of repeating the same URLs on every phone number you provision, you create one Application and attach it to many numbers and SIP endpoints. Edit the Application once, every attached resource updates.
You don't have to use Applications — every call API also accepts inline answer_url etc. Applications exist for the case where you want to manage call routing centrally.
What an Application is
An Application has:
name— your label.voice_url/voice_method— the URL TryVoxPOSTs to (orGETs from) when a call comes in or starts ringing. Returns VoxML.fallback_url/fallback_method— used ifvoice_urlfails or returns invalid VoxML.hangup_url/hangup_method— fired when the call ends with the final disposition.status_callback_url/status_callback_method— fired on every state transition (queued,ringing,answered,ended).status—activeorinactive. Inactive Applications are inert — incoming calls fall through.
Endpoints
All paths are scoped to the authenticated account. You don't pass auth_id in the URL; the API key's tenant is derived from the credentials.
| Method | Path | Purpose |
|---|---|---|
POST | /v1/voice/applications | Create an Application |
GET | /v1/voice/applications | List Applications |
GET | /v1/voice/applications/{id} | Get one Application |
PATCH | /v1/voice/applications/{id} | Update an Application |
DELETE | /v1/voice/applications/{id} | Delete an Application |
* | /v1/voice/endpoints[...] | Manage SIP endpoints — register a SIP softphone or PBX trunk to an Application. |
Lifecycle
CREATE ───► ATTACH to number / SIP endpoint ───► receives calls
│
▼
UPDATE the URLs anytime
│
▼
DELETE when retiredAttaching to a number
After creating an Application, attach it to a phone number you own:
curl -X PUT https://api.tryvox.io/v1/account/$TRYVOX_AUTH_ID/numbers/+919876543210 \
-u $TRYVOX_AUTH_ID:$TRYVOX_AUTH_TOKEN \
-H "Content-Type: application/json" \
-d '{"application_id": "app_8f7a4b2e91c24f3d9a1e2c4b6d8f0a1c"}'See Configure a Number for the full request shape.
Attaching to a SIP endpoint
A SIP endpoint represents a registered softphone or PBX. Each endpoint has its own credentials and an application_id pointer — calls placed by that endpoint are routed through the Application.
See SIP Endpoints.
Quick example
Create an Application and pull it back to confirm:
# Create
APP=$(curl -s -X POST https://api.tryvox.io/v1/voice/applications \
-u $TRYVOX_AUTH_ID:$TRYVOX_AUTH_TOKEN \
-H "Content-Type: application/json" \
-d '{
"name": "Main IVR",
"voice_url": "https://your-app.com/answer",
"voice_method": "POST",
"fallback_url": "https://your-app.com/fallback",
"hangup_url": "https://your-app.com/hangup"
}')
echo "$APP"
# Pull the ID back out of the response
APP_ID=$(echo "$APP" | jq -r .id)
# Verify
curl -u $TRYVOX_AUTH_ID:$TRYVOX_AUTH_TOKEN \
https://api.tryvox.io/v1/voice/applications/$APP_IDNotes
- Update is a
PATCH, notPUT. Pass only the fields you want to change. - Deleting an Application does not delete attached numbers or SIP endpoints, but those resources start failing inbound routing until you re-attach a different Application or set inline URLs.
- There's no soft-delete. A
DELETEis final; you'd need to recreate (with a newid) to bring it back. voice_methoddefaults toPOSTif you don't set it. Same for the other_methodfields.