Skip to content

Callbacks ​

Generated from DialerDigital/core commit 0fc18008b3c8 — spec openapi/dialer-v1.yaml v0.134.0. Do not edit by hand; see How this reference is built. Download the OpenAPI spec.

Español

Consumer-agreed redial appointments.

Endpoints ​

MethodPathSummary
GET/v1/callbacksCallback queue view / due feed
POST/v1/callbacksSchedule a consumer-agreed redial
POST/v1/callbacks/{id}/completepending → done
POST/v1/callbacks/{id}/cancelpending → cancelled
POST/v1/callbacks/{id}/misspending → missed

Callback queue view / due feed ​

http
GET /v1/callbacks

due=now (also true/1) is the runner-facing due feed (pending AND scheduled_at <= now, priority then time order); otherwise the queue view filtered by status (default pending, soonest first; done, cancelled and missed list the most recent appointment first). agent_id scopes to the callbacks that agent created. The queue view pages by keyset: pass the previous next_cursor as cursor (opaque; null on the last page). due=now is not paged.

Parameters

NameInTypeRequiredDescription
duequerynow · true · 1no
statusquerypending · done · cancelled · missedno
campaign_idquerystring (uuid)no
debt_idquerystring (uuid)no
agent_idquerystring (uuid)no
limitqueryintegernoPage size (default 100, max 1000).
cursorquerystringnoOpaque keyset cursor from the previous page's next_cursor.

Responses

200 ​

Callbacks matching the view.

FieldTypeRequiredDescription
callbacksarray of Callbackyes
callbacks[].idstring (uuid)no
callbacks[].tenant_idstring (uuid)no
callbacks[].debt_idstring (uuid)no
callbacks[].contact_phonestringno
callbacks[].campaign_idstring (uuid) | nullno
callbacks[].agent_idstring (uuid) | nullno
callbacks[].scheduled_atstring (date-time)no
callbacks[].notestring | nullno
callbacks[].priorityintegerno
callbacks[].statuspending · done · cancelled · missedno
callbacks[].created_atstring (date-time)no
callbacks[].updated_atstring (date-time)no
next_cursorstring,nullnoOpaque cursor for the next page; null on the last page.

400 — BadRequest ​

Malformed request (shape/type errors, invalid filters, bad timestamps).

json
{
  "error": {
    "code": "bad_request",
    "message": "from must be RFC-3339"
  }
}

401 — Unauthorized ​

Missing, unknown or revoked API key (or, on /v1/admin/*, a bad/unset admin token; on webhooks, a bad/missing signature). A dashboard session (ddu_) that a newer login of the same person ended answers the code session_superseded instead (tenant flag single_session_enforced), so the screen can say why it was signed out; a logout, an expired or an unknown token stay unauthorized.

json
{
  "error": {
    "code": "unauthorized",
    "message": "invalid or revoked API key"
  }
}

429 — ApiKeyRateLimited ​

This API key is over its request quota, or the tenant's keys together are over the tenant ceiling (core#2503) (code rate_limited). The request was not processed. Wait Retry-After seconds and retry; a refusal is not counted against the budget, so that wait is always enough. Bounded per API key and, above the keys, per tenant (api_tenant_requests_per_minute): a sibling key is unaffected until the tenant's keys together reach that ceiling. The quota applies to every operation reachable with a dd_ key, so the operations that name a more specific 429 (call control, dispositions, SMS, …) can ALSO answer this one with its X-RateLimit-* headers.

json
{
  "error": {
    "code": "rate_limited",
    "message": "API key request quota exceeded; retry after the interval in Retry-After"
  }
}

Schedule a consumer-agreed redial ​

http
POST /v1/callbacks

contact_phone must already be a contact of the debt (the gates need line/locale data) → 422 otherwise; less than the tenant's minimum notice (callback_min_notice_seconds, 10 minutes by default) → 422; the number is in R16 quarantine → 422 (the platform will not promise a call it cannot make); unknown debt → 404; bad timestamp → 400. campaign_id defaults to the ONE campaign whose population holds the debt — its own campaign_id, or the campaign of a list it is in. A debt in MORE than one campaign (its own and a list's, or two lists') has no default: omitting campaign_id, or sending it null, is 422 — the platform does not pick a campaign for the caller. The campaign runner dials due callbacks BEFORE fresh leads.

agent_id is the callback's CREATOR and is optional (a callback may have no agent). Who may name whom (ADR #133, ADR #134). The agent_id is bound by the PRINCIPAL, the same rule on every verb that reads one: a dd_ machine key names any agent of its tenant; a ddw_ only its own; a ddu_ login session linked to an agent seat acts as THAT seat — agent_id may be omitted (filled with the seat) or repeat it, and naming another agent is 403 forbidden; a ddu_ session with NO linked seat may name another agent only with users.role = account_admin — a member is 403 role_forbidden — once the tenant's catalog key ddu_author_role_enforced is on (born off: until then the seatless session keeps the dd_ contract on this verb).

Request body (JSON, required)

FieldTypeRequiredDescription
debt_idstring (uuid)yes
contact_phonestringyesE.164 of an existing contact of the debt.
scheduled_atstring (date-time)yesRFC 3339, at least the tenant's callback_min_notice_seconds (10 minutes by default) in the future.
campaign_idstring (uuid)no
agent_idstring (uuid)no
notestringno
priorityintegerno
json
{
  "debt_id": "5a4b3c2d-1e0f-4a9b-8c7d-6e5f4a3b2c1d",
  "contact_phone": "+13125551001",
  "scheduled_at": "2026-07-06T16:30:00Z",
  "note": "postman: consumer pidió el martes"
}

Responses

201 ​

Scheduled callback.

FieldTypeRequiredDescription
callbackobject (Callback)yes
callback.idstring (uuid)no
callback.tenant_idstring (uuid)no
callback.debt_idstring (uuid)no
callback.contact_phonestringno
callback.campaign_idstring (uuid) | nullno
callback.agent_idstring (uuid) | nullno
callback.scheduled_atstring (date-time)no
callback.notestring | nullno
callback.priorityintegerno
callback.statuspending · done · cancelled · missedno
callback.created_atstring (date-time)no
callback.updated_atstring (date-time)no

400 — BadRequest ​

Malformed request (shape/type errors, invalid filters, bad timestamps).

json
{
  "error": {
    "code": "bad_request",
    "message": "from must be RFC-3339"
  }
}

401 — Unauthorized ​

Missing, unknown or revoked API key (or, on /v1/admin/*, a bad/unset admin token; on webhooks, a bad/missing signature). A dashboard session (ddu_) that a newer login of the same person ended answers the code session_superseded instead (tenant flag single_session_enforced), so the screen can say why it was signed out; a logout, an expired or an unknown token stay unauthorized.

json
{
  "error": {
    "code": "unauthorized",
    "message": "invalid or revoked API key"
  }
}

403 — Forbidden ​

The tenant is suspended. A dashboard session (ddu_) of a tenant whose login policy (ADR 227) is in mode enforce answers 403 with the code login_policy_denied on a request from an address or at an hour the policy does not allow — the same body for both; the session is not revoked and a later request inside the policy goes through. A widget token (ddw_) of a seat is held to the same policy on every request (core#2406, flag widget_login_honors_policy). A synthetic (demo) tenant answers 403 with the code synthetic_tenant on every route that would reach a third party — manual dial, external transfer or conference leg, SMS send (core#2251, ADR #280 addendum). No payment changes it.

json
{
  "error": {
    "code": "forbidden",
    "message": "tenant is suspended"
  }
}

404 — NotFound ​

Unknown id, malformed (non-UUID) id OR another tenant's id — RLS returns zero rows, so all three are indistinguishable by design (no existence leak, never a 403 for foreign ids).

json
{
  "error": {
    "code": "not_found",
    "message": "resource not found for this tenant"
  }
}

422 — Unprocessable ​

Shape is fine, semantics are not (broken domain rule).

json
{
  "error": {
    "code": "unprocessable",
    "message": "scheduled_at is closer than the minimum notice for a callback (10 minutes unless the tenant's callback_min_notice_seconds says otherwise)"
  }
}

429 — ApiKeyRateLimited ​

This API key is over its request quota, or the tenant's keys together are over the tenant ceiling (core#2503) (code rate_limited). The request was not processed. Wait Retry-After seconds and retry; a refusal is not counted against the budget, so that wait is always enough. Bounded per API key and, above the keys, per tenant (api_tenant_requests_per_minute): a sibling key is unaffected until the tenant's keys together reach that ceiling. The quota applies to every operation reachable with a dd_ key, so the operations that name a more specific 429 (call control, dispositions, SMS, …) can ALSO answer this one with its X-RateLimit-* headers.

json
{
  "error": {
    "code": "rate_limited",
    "message": "API key request quota exceeded; retry after the interval in Retry-After"
  }
}

pending → done ​

http
POST /v1/callbacks/{id}/complete

Status machine pending → done|cancelled|missed (terminal); 409 on re-transition.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yesResource UUID. Malformed or cross-tenant ids read as 404.

Responses

200 ​

The completed callback.

FieldTypeRequiredDescription
callbackobject (Callback)yes
callback.idstring (uuid)no
callback.tenant_idstring (uuid)no
callback.debt_idstring (uuid)no
callback.contact_phonestringno
callback.campaign_idstring (uuid) | nullno
callback.agent_idstring (uuid) | nullno
callback.scheduled_atstring (date-time)no
callback.notestring | nullno
callback.priorityintegerno
callback.statuspending · done · cancelled · missedno
callback.created_atstring (date-time)no
callback.updated_atstring (date-time)no

401 — Unauthorized ​

Missing, unknown or revoked API key (or, on /v1/admin/*, a bad/unset admin token; on webhooks, a bad/missing signature). A dashboard session (ddu_) that a newer login of the same person ended answers the code session_superseded instead (tenant flag single_session_enforced), so the screen can say why it was signed out; a logout, an expired or an unknown token stay unauthorized.

json
{
  "error": {
    "code": "unauthorized",
    "message": "invalid or revoked API key"
  }
}

404 — NotFound ​

Unknown id, malformed (non-UUID) id OR another tenant's id — RLS returns zero rows, so all three are indistinguishable by design (no existence leak, never a 403 for foreign ids).

json
{
  "error": {
    "code": "not_found",
    "message": "resource not found for this tenant"
  }
}

409 — Conflict ​

Invalid state transition, uniqueness conflict, or a seat that is busy/reserved.

json
{
  "error": {
    "code": "conflict",
    "message": "invalid state transition"
  }
}

429 — ApiKeyRateLimited ​

This API key is over its request quota, or the tenant's keys together are over the tenant ceiling (core#2503) (code rate_limited). The request was not processed. Wait Retry-After seconds and retry; a refusal is not counted against the budget, so that wait is always enough. Bounded per API key and, above the keys, per tenant (api_tenant_requests_per_minute): a sibling key is unaffected until the tenant's keys together reach that ceiling. The quota applies to every operation reachable with a dd_ key, so the operations that name a more specific 429 (call control, dispositions, SMS, …) can ALSO answer this one with its X-RateLimit-* headers.

json
{
  "error": {
    "code": "rate_limited",
    "message": "API key request quota exceeded; retry after the interval in Retry-After"
  }
}

pending → cancelled ​

http
POST /v1/callbacks/{id}/cancel

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yesResource UUID. Malformed or cross-tenant ids read as 404.

Responses

200 ​

The cancelled callback.

FieldTypeRequiredDescription
callbackobject (Callback)yes
callback.idstring (uuid)no
callback.tenant_idstring (uuid)no
callback.debt_idstring (uuid)no
callback.contact_phonestringno
callback.campaign_idstring (uuid) | nullno
callback.agent_idstring (uuid) | nullno
callback.scheduled_atstring (date-time)no
callback.notestring | nullno
callback.priorityintegerno
callback.statuspending · done · cancelled · missedno
callback.created_atstring (date-time)no
callback.updated_atstring (date-time)no

401 — Unauthorized ​

Missing, unknown or revoked API key (or, on /v1/admin/*, a bad/unset admin token; on webhooks, a bad/missing signature). A dashboard session (ddu_) that a newer login of the same person ended answers the code session_superseded instead (tenant flag single_session_enforced), so the screen can say why it was signed out; a logout, an expired or an unknown token stay unauthorized.

json
{
  "error": {
    "code": "unauthorized",
    "message": "invalid or revoked API key"
  }
}

404 — NotFound ​

Unknown id, malformed (non-UUID) id OR another tenant's id — RLS returns zero rows, so all three are indistinguishable by design (no existence leak, never a 403 for foreign ids).

json
{
  "error": {
    "code": "not_found",
    "message": "resource not found for this tenant"
  }
}

409 — Conflict ​

Invalid state transition, uniqueness conflict, or a seat that is busy/reserved.

json
{
  "error": {
    "code": "conflict",
    "message": "invalid state transition"
  }
}

429 — ApiKeyRateLimited ​

This API key is over its request quota, or the tenant's keys together are over the tenant ceiling (core#2503) (code rate_limited). The request was not processed. Wait Retry-After seconds and retry; a refusal is not counted against the budget, so that wait is always enough. Bounded per API key and, above the keys, per tenant (api_tenant_requests_per_minute): a sibling key is unaffected until the tenant's keys together reach that ceiling. The quota applies to every operation reachable with a dd_ key, so the operations that name a more specific 429 (call control, dispositions, SMS, …) can ALSO answer this one with its X-RateLimit-* headers.

json
{
  "error": {
    "code": "rate_limited",
    "message": "API key request quota exceeded; retry after the interval in Retry-After"
  }
}

pending → missed ​

http
POST /v1/callbacks/{id}/miss

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)yesResource UUID. Malformed or cross-tenant ids read as 404.

Responses

200 ​

The missed callback.

FieldTypeRequiredDescription
callbackobject (Callback)yes
callback.idstring (uuid)no
callback.tenant_idstring (uuid)no
callback.debt_idstring (uuid)no
callback.contact_phonestringno
callback.campaign_idstring (uuid) | nullno
callback.agent_idstring (uuid) | nullno
callback.scheduled_atstring (date-time)no
callback.notestring | nullno
callback.priorityintegerno
callback.statuspending · done · cancelled · missedno
callback.created_atstring (date-time)no
callback.updated_atstring (date-time)no

401 — Unauthorized ​

Missing, unknown or revoked API key (or, on /v1/admin/*, a bad/unset admin token; on webhooks, a bad/missing signature). A dashboard session (ddu_) that a newer login of the same person ended answers the code session_superseded instead (tenant flag single_session_enforced), so the screen can say why it was signed out; a logout, an expired or an unknown token stay unauthorized.

json
{
  "error": {
    "code": "unauthorized",
    "message": "invalid or revoked API key"
  }
}

404 — NotFound ​

Unknown id, malformed (non-UUID) id OR another tenant's id — RLS returns zero rows, so all three are indistinguishable by design (no existence leak, never a 403 for foreign ids).

json
{
  "error": {
    "code": "not_found",
    "message": "resource not found for this tenant"
  }
}

409 — Conflict ​

Invalid state transition, uniqueness conflict, or a seat that is busy/reserved.

json
{
  "error": {
    "code": "conflict",
    "message": "invalid state transition"
  }
}

429 — ApiKeyRateLimited ​

This API key is over its request quota, or the tenant's keys together are over the tenant ceiling (core#2503) (code rate_limited). The request was not processed. Wait Retry-After seconds and retry; a refusal is not counted against the budget, so that wait is always enough. Bounded per API key and, above the keys, per tenant (api_tenant_requests_per_minute): a sibling key is unaffected until the tenant's keys together reach that ceiling. The quota applies to every operation reachable with a dd_ key, so the operations that name a more specific 429 (call control, dispositions, SMS, …) can ALSO answer this one with its X-RateLimit-* headers.

json
{
  "error": {
    "code": "rate_limited",
    "message": "API key request quota exceeded; retry after the interval in Retry-After"
  }
}

Nothing in these docs is legal advice — always confirm compliance posture with your own counsel.