Campaigns
List recipients
The recipients with their state, the call outcome (outcome), the attempts and the call's call_session_id (the id of GET /v1/calls/{call_id}).
GET https://api.diska.ai/v1/campaigns/{campaign_id}/recipients
Scope: campaigns:read
Parameters
Path
| Name | Type | Required | Description |
|---|---|---|---|
campaign_id | string | Yes | The campaign's ID. |
Query string
| Name | Type | Required | Description |
|---|---|---|---|
status | string | null | No | Only recipients in this state. One of: pending, reserved, calling, in_call, completed, failed, cancelled, excluded. Up to 20 characters. |
limit | integer | No | How many per page. Between 1 and 200. Default: 50. |
offset | integer | No | How many to skip. Minimum 0. Default: 0. |
Examples
curl "https://api.diska.ai/v1/campaigns/<campaign_id>/recipients" \
-H "Authorization: Bearer $DISKA_API_KEY"
import os
import requests
response = requests.get(
"https://api.diska.ai/v1/campaigns/<campaign_id>/recipients",
headers={"Authorization": f"Bearer {os.environ['DISKA_API_KEY']}"},
timeout=30,
)
response.raise_for_status()
print(response.json())
// Node.js 18 or later, in a .mjs file
const response = await fetch('https://api.diska.ai/v1/campaigns/<campaign_id>/recipients', {
headers: { Authorization: `Bearer ${process.env.DISKA_API_KEY}` }
})
if (!response.ok) throw new Error(`${response.status} ${await response.text()}`)
console.log(await response.json())
<?php
$ch = curl_init('https://api.diska.ai/v1/campaigns/<campaign_id>/recipients');
curl_setopt_array($ch, [
CURLOPT_HTTPHEADER => ['Authorization: Bearer ' . getenv('DISKA_API_KEY')],
CURLOPT_RETURNTRANSFER => true,
CURLOPT_TIMEOUT => 30,
]);
$body = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
curl_close($ch);
if ($status >= 400) {
throw new RuntimeException("HTTP $status: $body");
}
print_r(json_decode($body, true));
Try it
Send the request from this page, with your key. The key stays on this page: it is not stored and is only sent to api.diska.ai. Use a test key with the fewest scopes you need.
GET
https://api.diska.ai/v1/campaigns/{campaign_id}/recipientsStarts with dsk_. It stays in this browser tab only.
path
query
query
query
Enter an API key (dsk_…).
Response 200
| Field | Type | Description |
|---|---|---|
items | array | The recipients. |
items[].id | string | Recipient ID. |
items[].phone_e164 | string | Number. |
items[].name | string | null | Name. |
items[].email | string | null | Email. |
items[].variables | object | Variables. |
items[].external_id | string | null | Your own ID. |
items[].status | string | pending, reserved, calling, in_call, completed, failed, cancelled or excluded. |
items[].outcome | string | null | answered, no_answer or unavailable, when the call reached the network. |
items[].attempts | integer | Attempts made. Default: 0. |
items[].failure_code | string | null | Failure code. |
items[].failure_reason | string | null | Failure reason. |
items[].call_session_id | string | null | The call in GET /v1/calls/{call_id}. |
items[].session_id | string | null | The voice session (the webhooks' session_id). |
items[].duration_seconds | integer | null | Call duration. |
items[].next_attempt_at | string | null | Next attempt. |
items[].last_attempt_at | string | null | Last attempt. |
items[].answered_at | string | null | When answered. |
items[].ended_at | string | null | When it ended. |
items[].created_at | string | null | Creation date (ISO 8601). |
items[].has_recording | boolean | true when the call has a recording. Default: false. |
total | integer | Total with this filter. |
limit | integer | Page size. |
offset | integer | This page's offset. |
{
"items": [
{
"id": "5c2e8a14-7d3b-4f9e-a1c6-0b8d2f4e6a93",
"phone_e164": "…",
"name": "Exemplo",
"email": "…",
"variables": {},
"external_id": "5c2e8a14-7d3b-4f9e-a1c6-0b8d2f4e6a93",
"status": "pending",
"outcome": "answered",
"attempts": 0,
"failure_code": "…",
"failure_reason": "…",
"call_session_id": "5c2e8a14-7d3b-4f9e-a1c6-0b8d2f4e6a93",
"session_id": "5c2e8a14-7d3b-4f9e-a1c6-0b8d2f4e6a93",
"duration_seconds": 95,
"next_attempt_at": "2026-10-25T18:40:00Z",
"last_attempt_at": "2026-10-25T18:40:00Z",
"answered_at": "2026-10-25T18:40:00Z",
"ended_at": "2026-10-25T18:41:35Z",
"created_at": "2026-10-25T18:40:00Z",
"has_recording": false
}
],
"total": 1,
"limit": 50,
"offset": 0
}
Errors
| Code | When |
|---|---|
404 | Campaign not found. |
Errors common to every endpoint (401, 403, 422, 429 and 5xx) are in Errors.

