Download a call recording (user, pbx)
/call-recording
Streams the audio recording for a call. Pick the file with type; no storage
path is needed:
- no
type, ortype=all→ the combined recording (caller + callee) type=caller→ the caller legtype=callee→ the callee leg
The download_url values in call history and call detail already point here
with the right id and type, so they can be followed with the same token.
The older path parameter still works; when both are sent, type wins.
Authentication accepts either a user personal access token or a PBX-owned
API key. A PBX API key must carry the call-history ability/scope. No other
token is needed: use the same token as for call history and call detail.
Example: GET /call-recording?id=47679936&type=caller returns the caller's
track as audio/wav. Each request returns one file.
Rate-limited to 120 requests per minute per principal.
User bearer token. Default authentication for customer-facing endpoints.
Obtain a token by calling POST /login with your credentials, then send it
on every subsequent request as Authorization: Bearer <token>. The token
inherits the permissions and PBX scope of the authenticated user.
- HTTP Authorization Scheme
bearer- Bearer format
Bearer <token>
all caller callee Responses
Authorization Token is missingerrorsobject
https://cockpit.voxbi.com/api/v1/call-recording
curl -X GET 'https://cockpit.voxbi.com/api/v1/call-recording' \
-H 'Authorization: Bearer YOUR_TOKEN'
const response = await fetch('https://cockpit.voxbi.com/api/v1/call-recording', {
method: 'GET',
headers: {
'Content-Type': 'application/json',
'Authorization': `Bearer ${YOUR_TOKEN}`,
},
});
const data = await response.json();
console.log(data);
import requests
response = requests.get('https://cockpit.voxbi.com/api/v1/call-recording',
headers={'Authorization': f'Bearer {YOUR_TOKEN}'}
)
response.raise_for_status()
data = response.json()
print(data)
<?php
$context = stream_context_create([
'http' => [
'method' => 'GET',
'header' => "Content-Type: application/json\r\nAuthorization: Bearer YOUR_TOKEN",
],
]);
$response = file_get_contents('https://cockpit.voxbi.com/api/v1/call-recording', false, $context);
$data = json_decode($response, true);
print_r($data);
{ … }
private, must-revalidatekeep-aliveapplication/jsonOrigin6057