API
Calls API
Start outbound calls and retrieve normalized call records.
Endpoints
| Method | Path | Scope |
|---|---|---|
| GET | /agents | read |
| POST | /calls/outbound | calls:trigger |
| GET | /calls | read |
| GET | /calls/{callId} | read |
| GET | /calls/{callId}/recording | read |
| GET | /calls/export.csv | read |
| GET | /calls/stream | read |
List-call filters
| Query | Description |
|---|---|
| page | Page number beginning at 1. |
| limit | Rows per page from 1 to 100; default 20. |
| agentId | Return calls for one agent. |
| status | Return calls with the selected status. |
| direction | Filter inbound, outbound, or web calls. |
| from | Earliest start timestamp in ISO 8601 format. |
| to | Latest start timestamp in ISO 8601 format. |
Create outbound call
curl
curl -X POST "https://api.vozon.ai/api/v1/calls/outbound" \
-H "Authorization: Bearer avp_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"agentId": "agent_id",
"phoneNumber": "+919876543210",
"metadata": { "customerId": "customer_123" }
}'| Field | Type | Required | Description |
|---|---|---|---|
| agentId | string | Yes | A Live agent belonging to the active organization. |
| phoneNumber | string | Yes | Destination in E.164 format. |
| phoneNumberId | string | No | Specific assigned outbound number; otherwise the latest eligible number is used. |
| metadata | object | No | Fictional or business-safe correlation data returned with the call. |
JavaScript
javascript
const response = await fetch("https://api.vozon.ai/api/v1/calls/outbound", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.VOZON_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
agentId: "agent_id",
phoneNumber: "+919876543210",
metadata: { customerId: "customer_123" },
}),
});
if (!response.ok) throw new Error(`Vozon request failed: ${response.status}`);
const call = await response.json();Python
python
import os
import requests
response = requests.post(
"https://api.vozon.ai/api/v1/calls/outbound",
headers={"Authorization": f"Bearer {os.environ['VOZON_API_KEY']}"},
json={
"agentId": "agent_id",
"phoneNumber": "+919876543210",
"metadata": {"customerId": "customer_123"},
},
timeout=30,
)
response.raise_for_status()
call = response.json()