Get Campaign

Campaigns

Get Campaign

Returns one broadcast or calling campaign with its current state and counts. Poll it while a campaign is sending to follow its progress; finishedAt is set when it ends or is cancelled, and lastError says why a campaign stopped, when it did.

GET/campaigns/{id}

Path parameters

idstringrequired
The campaign's id (cmp_…), as Create Campaign and List Campaigns return it.

Headers

Katexs-Workspacestring
Developers only: the customer workspace this request acts in — its org_… id from POST /customers. Leave it out to act in your own workspace. Refused with 404 (Workspace not found.) when the id is unknown, is not one of your customers, or is not an org_… id; 410 when that customer was deleted (restore it with POST /customers/{id}/restore until it is erased); 403 when the key belongs to one customer workspace (it cannot act as another); 400 when your workspace is not a developer workspace. /customers/* and GET /customers/usage are your own workspace's and refuse the header with 400: call them without it.

Example request

bash
curl "https://app.katexs.com/api/v1/campaigns/{id}" \
  -H "Authorization: Bearer $KATEXS_API_KEY"

Responses

StatusDescription
200The campaign.
400Katexs-Workspace was sent from a workspace that is not a developer workspace.
401The key is missing, wrong or revoked. The answer is always the same, whichever it is.
403The key's access level (read-only or build) does not allow this request, the plan does not include it, or a customer's key named another workspace in Katexs-Workspace. code says which: key_scope_read, key_scope_build, workspace_header_forbidden, or forbidden.
404No campaign with that id in this workspace.
410The customer named in Katexs-Workspace was deleted. POST /customers/{id}/restore brings it back until its erase date.
429Over a per-minute limit. Wait for Retry-After seconds. code and limit say which limit: rate_limit_resources (240 requests a minute for the workspace), rate_limit_family (2,400 across a developer's customers), rate_limit_calls, rate_limit_messages, rate_limit_codes, rate_limit_code_recipient, concurrent_calls or number_daily_limit.

Response fields

idstringrequired
The campaign's id.
agentstringrequired
A calling campaign: the agent that makes the calls. A broadcast: the agent that answers replies to it.
namestringrequired
The campaign's name, as the console lists it.
kindstringrequired
whatsapp for a broadcast, voice for a calling campaign. One of: whatsapp, voice.
statusstringrequired
draft until launched (a scheduled campaign stays a draft until scheduledAt), sending while it runs, paused when stopped for now, then sent, failed (it could not run; see lastError) or cancelled. One of: draft, sending, paused, sent, failed, cancelled.
templatestring | nullrequired
A broadcast's template name. null on a calling campaign.
purposestring | nullrequired
A calling campaign's opening line: the sentence the agent opens each call with, copied from the agent when the campaign was created (editing the agent later does not change it). null on a broadcast.
countsobjectrequired
How far the campaign has got, person by person.
scheduledAtstring (date-time) | nullrequired
When a scheduled campaign starts itself. null when it is started by hand.
startedAtstring (date-time) | nullrequired
When it started sending. null while a draft.
finishedAtstring (date-time) | nullrequired
When it finished or was cancelled. null while it can still send.
createdAtstring (date-time)required
When it was created.
lastErrorstring | nullrequired
Why the campaign last stopped or failed, when it did. Cleared when it is launched or resumed.
200 response
{
  "id": "cmp_9a3b7c21-4d5e-4f60-8a1b-2c3d4e5f6a7b",
  "agent": "ag_5c4a5f93-2b1e-4c0a-9d3f-7e8a1b2c3d4e",
  "name": "Diwali sale — VIP customers",
  "kind": "whatsapp",
  "status": "sent",
  "template": "diwali_offer_v2",
  "purpose": null,
  "counts": {
    "recipients": 1200,
    "sent": 1177,
    "delivered": 1148,
    "read": 893,
    "replied": 71,
    "failed": 9,
    "skipped": 14
  },
  "scheduledAt": null,
  "startedAt": "2026-10-05T09:00:00.000Z",
  "finishedAt": "2026-10-05T09:41:17.000Z",
  "createdAt": "2026-10-04T16:20:11.482Z",
  "lastError": null
}

Last updated November 2026 · Found a problem? Email support@katexs.com