Skip to content

Webhook deliveries ​

3 endpoints. Every path below is relative to the API base URL and already includes the /api/v1 prefix — see conventions for authentication, pagination, errors and idempotency.

Endpoint
GET/webhook-deliveriesList webhook deliveries newest first, filterable by endpoint, event type, status or call
GET/webhook-deliveries/{delivery}Retrieve one delivery, including the per-attempt log
POST/webhook-deliveries/{delivery}/redeliverQueue a replay of a delivery as a new row that reuses the original event_id

Endpoints ​

List webhook deliveries newest first, filterable by endpoint, event type, status or call ​

GET/webhook-deliveries
  • Requires webhook.read.
  • Filters are webhook_endpoint_id, event_type, status and call_id. attempt_log is omitted from list rows.
bash
curl -X GET "$CALLAGENT_API_URL/webhook-deliveries" \
  -H "Authorization: Bearer $CALLAGENT_API_KEY" \
  -H "Accept: application/json"
js
const response = await fetch(`${process.env.CALLAGENT_API_URL}/webhook-deliveries`, {
  method: 'GET',
  headers: {
    Authorization: `Bearer ${process.env.CALLAGENT_API_KEY}`,
    Accept: 'application/json',
  },
});

if (!response.ok) {
  const { error } = await response.json();
  throw new Error(`${error.type}: ${error.message}`);
}

const { data } = await response.json();
php
<?php

$handle = curl_init(getenv('CALLAGENT_API_URL') . '/webhook-deliveries');

curl_setopt_array($handle, [
    CURLOPT_CUSTOMREQUEST => 'GET',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . getenv('CALLAGENT_API_KEY'),
        'Accept: application/json',
    ],
]);

$body = json_decode(curl_exec($handle), true);
$status = curl_getinfo($handle, CURLINFO_HTTP_CODE);
curl_close($handle);

if ($status >= 400) {
    throw new RuntimeException("{$body['error']['type']}: {$body['error']['message']}");
}

$data = $body['data'];
python
import os, requests

response = requests.get(
    f"{os.environ['CALLAGENT_API_URL']}/webhook-deliveries",
    headers={"Authorization": f"Bearer {os.environ['CALLAGENT_API_KEY']}"},
    timeout=30,
)
response.raise_for_status()
data = response.json()["data"]

Responses

StatusBody
200Array of WebhookDeliveryResource

Errors

StatusWhen it happens
403The presenting API key does not carry the webhook.read scope

Example response, generated from the schema:

json
{
  "data": [
    {
      "id": "01JQ0000000000000000000000",
      "object": "string",
      "webhook_endpoint_id": "01JQ0000000000000000000000",
      "event_id": "01JQ0000000000000000000000",
      "event_type": "string",
      "status": "string",
      "attempts": 1,
      "max_attempts": 1,
      "response_status": 1,
      "duration_ms": 30,
      "error": "string",
      "call_id": "01JQ0000000000000000000000",
      "assistant_id": "01JQ0000000000000000000000",
      "next_attempt_at": "2026-01-01T12:00:00+00:00",
      "delivered_at": "2026-01-01T12:00:00+00:00",
      "failed_at": "2026-01-01T12:00:00+00:00",
      "redelivery_of_id": "01JQ0000000000000000000000",
      "created_at": "2026-01-01T12:00:00+00:00",
      "payload": {},
      "request_headers": {},
      "response_headers": {},
      "response_body": "string",
      "attempt_log": []
    }
  ]
}

Retrieve one delivery, including the per-attempt log ​

GET/webhook-deliveries/{delivery}
  • Requires webhook.read.

Path parameters

NameTypeRequiredNotes
deliverystringyesThe delivery ID
bash
curl -X GET "$CALLAGENT_API_URL/webhook-deliveries/01JQ0000000000000000000000" \
  -H "Authorization: Bearer $CALLAGENT_API_KEY" \
  -H "Accept: application/json"
js
const response = await fetch(`${process.env.CALLAGENT_API_URL}/webhook-deliveries/01JQ0000000000000000000000`, {
  method: 'GET',
  headers: {
    Authorization: `Bearer ${process.env.CALLAGENT_API_KEY}`,
    Accept: 'application/json',
  },
});

if (!response.ok) {
  const { error } = await response.json();
  throw new Error(`${error.type}: ${error.message}`);
}

const { data } = await response.json();
php
<?php

$handle = curl_init(getenv('CALLAGENT_API_URL') . '/webhook-deliveries/01JQ0000000000000000000000');

curl_setopt_array($handle, [
    CURLOPT_CUSTOMREQUEST => 'GET',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . getenv('CALLAGENT_API_KEY'),
        'Accept: application/json',
    ],
]);

$body = json_decode(curl_exec($handle), true);
$status = curl_getinfo($handle, CURLINFO_HTTP_CODE);
curl_close($handle);

if ($status >= 400) {
    throw new RuntimeException("{$body['error']['type']}: {$body['error']['message']}");
}

$data = $body['data'];
python
import os, requests

response = requests.get(
    f"{os.environ['CALLAGENT_API_URL']}/webhook-deliveries/01JQ0000000000000000000000",
    headers={"Authorization": f"Bearer {os.environ['CALLAGENT_API_KEY']}"},
    timeout=30,
)
response.raise_for_status()
data = response.json()["data"]

Responses

StatusBody
200WebhookDeliveryResource

Errors

StatusWhen it happens
403The presenting API key does not carry the webhook.read scope
404No such delivery in this organization

Example response, generated from the schema:

json
{
  "data": {
    "id": "01JQ0000000000000000000000",
    "object": "string",
    "webhook_endpoint_id": "01JQ0000000000000000000000",
    "event_id": "01JQ0000000000000000000000",
    "event_type": "string",
    "status": "string",
    "attempts": 1,
    "max_attempts": 1,
    "response_status": 1,
    "duration_ms": 30,
    "error": "string",
    "call_id": "01JQ0000000000000000000000",
    "assistant_id": "01JQ0000000000000000000000",
    "next_attempt_at": "2026-01-01T12:00:00+00:00",
    "delivered_at": "2026-01-01T12:00:00+00:00",
    "failed_at": "2026-01-01T12:00:00+00:00",
    "redelivery_of_id": "01JQ0000000000000000000000",
    "created_at": "2026-01-01T12:00:00+00:00",
    "payload": {},
    "request_headers": {},
    "response_headers": {},
    "response_body": "string",
    "attempt_log": [
      {}
    ]
  }
}

Queue a replay of a delivery as a new row that reuses the original event_id ​

POST/webhook-deliveries/{delivery}/redeliver

The replay carries the same event_id, so a receiver that deduplicates on it will recognise the repeat.

  • Requires webhook.write.
  • Only succeeded, failed or dead deliveries replay; the 422 message says "completed or failed", which does not match those status values.

Path parameters

NameTypeRequiredNotes
deliverystringyesThe delivery ID
bash
curl -X POST "$CALLAGENT_API_URL/webhook-deliveries/01JQ0000000000000000000000/redeliver" \
  -H "Authorization: Bearer $CALLAGENT_API_KEY" \
  -H "Accept: application/json"
js
const response = await fetch(`${process.env.CALLAGENT_API_URL}/webhook-deliveries/01JQ0000000000000000000000/redeliver`, {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.CALLAGENT_API_KEY}`,
    Accept: 'application/json',
  },
});

if (!response.ok) {
  const { error } = await response.json();
  throw new Error(`${error.type}: ${error.message}`);
}

const { data } = await response.json();
php
<?php

$handle = curl_init(getenv('CALLAGENT_API_URL') . '/webhook-deliveries/01JQ0000000000000000000000/redeliver');

curl_setopt_array($handle, [
    CURLOPT_CUSTOMREQUEST => 'POST',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . getenv('CALLAGENT_API_KEY'),
        'Accept: application/json',
    ],
]);

$body = json_decode(curl_exec($handle), true);
$status = curl_getinfo($handle, CURLINFO_HTTP_CODE);
curl_close($handle);

if ($status >= 400) {
    throw new RuntimeException("{$body['error']['type']}: {$body['error']['message']}");
}

$data = $body['data'];
python
import os, requests

response = requests.post(
    f"{os.environ['CALLAGENT_API_URL']}/webhook-deliveries/01JQ0000000000000000000000/redeliver",
    headers={"Authorization": f"Bearer {os.environ['CALLAGENT_API_KEY']}"},
    timeout=30,
)
response.raise_for_status()
data = response.json()["data"]

Responses

StatusBody
202data-wrapped object

Errors

StatusWhen it happens
403The presenting API key does not carry the webhook.write scope
404No such delivery in this organization
422The delivery is not in a replayable state

Example response, generated from the schema:

json
{
  "data": {
    "id": "01JQ0000000000000000000000",
    "object": "string",
    "webhook_endpoint_id": "01JQ0000000000000000000000",
    "event_id": "01JQ0000000000000000000000",
    "event_type": "string",
    "status": "string",
    "attempts": 1,
    "max_attempts": 1,
    "response_status": 1,
    "duration_ms": 30,
    "error": "string",
    "call_id": "01JQ0000000000000000000000",
    "assistant_id": "01JQ0000000000000000000000",
    "next_attempt_at": "2026-01-01T12:00:00+00:00",
    "delivered_at": "2026-01-01T12:00:00+00:00",
    "failed_at": "2026-01-01T12:00:00+00:00",
    "redelivery_of_id": "01JQ0000000000000000000000",
    "created_at": "2026-01-01T12:00:00+00:00",
    "payload": {},
    "request_headers": {},
    "response_headers": {},
    "response_body": "string",
    "attempt_log": [
      {}
    ]
  }
}

Documented against the code. Anything not yet implemented is labelled, never described as working.