> ## Documentation Index
> Fetch the complete documentation index at: https://docs.nixflex.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get a voice campaign

> Read one owned voice campaign, its saved schedule and current progress. Check wider-hours confirmation without retrieving recipients.

**FIXED · campaign** **MUST** Resume covers only unattempted work in the existing running launch, and neither resume nor reuse replays completed work.\
reuse\_campaign\_id replaces settings and recipients atomically only on an owned, never-launched voice draft or scheduled campaign. A launch claim prevents replacement. SMS creation always generates a fresh ID, even if the request forwards this field. Omit it for SMS.

**NOT OFFERED → do this instead · campaign** A launched or finished campaign cannot run again. For another run create a campaign with a fresh ID, selected recipients and reviewed settings. The dashboard’s Use again button follows the same rule for voice: it edits a campaign that never launched, otherwise it opens a new campaign filled with the original settings and recipients for review before launch. SMS campaigns have no Use again button.

**YOU CAN CHANGE · campaign** Use schedule\_type=schedule, scheduled\_date (YYYY-MM-DD), timezone, window\_days and optional paired window\_start\_minutes/window\_end\_minutes. UTC date checks, local windows and capacity apply.

**SCOPE · campaign** `DELETE /v1/calls/batch/{id}` deletes a voice campaign. Voice and SMS have separate cancel routes. Cancel stops future work. Running attempts may finish.

For one owned sender, send business\_number (encode + as %2B) on `GET /v1/campaigns` or `GET /v1/sms/campaigns`. Omit for account scope. Keep the same number and status through SMS cursors. Restart paging if either changes. Voice include\_totals=true covers returned campaigns only (default 50, max 200).

Pickup rate = answered attempts / all attempts, including failed starts. Answered means over five seconds with no detected voicemail. Sum counts before dividing. Zero attempts means no rate. SMS delivery rate = delivered / (delivered + failed).

[Read the compact AI rules](https://docs.nixflex.com/ai-rules.md#campaigns)

Read the saved schedule, progress and current wider-hours choice for one voice campaign.

Method: **GET** · Success: **200** · Scope: **Owning account**

**The important part**

* This read returns the same campaign fields as the list, without recipients.
* Wider-hours confirmation is checked against the current saved schedule.
* An unavailable result is an error, not an empty campaign or a false confirmation.

[Business guide](https://docs.nixflex.com/guides/business/voice-campaigns/check-results.md) · [Developer guide](https://docs.nixflex.com/guides/developer/campaigns/results-and-controls.md) · [Glossary](https://docs.nixflex.com/guides/glossary.md)

## Authentication

Send `Authorization: Bearer KEY_ID:KEY_SECRET` using the owning account's server-side credential. Owner, Admin and Member may read their account's campaign in the signed-in dashboard. The public endpoint uses the existing API-key authentication and account scope.

## Request fields

| Field | Type | Required | Limits and meaning |
| - | - | - | - |
| `id` (path) | string | Yes | The exact saved campaign ID, 1–200 characters. Invalid, missing, foreign and deleted IDs share the same 404. |

Do not send a request body. This endpoint has no pagination or recipient query fields.

## Response fields

`200 OK` returns the shape below. Nullable fields can be unknown or unset; do not turn null into zero or false.

| Field | Type | Meaning |
| - | - | - |
| `campaign` | object | The owned campaign. |
| `campaign.campaign_id` | string | Public campaign ID. |
| `campaign.agent_id` | string | Owning agent ID. |
| `campaign.name` | string or null | Saved campaign label. |
| `campaign.from_number` | string or null | International number with + and digits; no spaces. Pattern: `^\+[1-9][0-9]{6,14}$`. |
| `campaign.schedule_type` | string | Saved now or schedule mode. |
| `campaign.scheduled_date` | string or null | Saved scheduled date. |
| `campaign.window_start_minutes` | integer or null | Configured start minute. |
| `campaign.window_end_minutes` | integer or null | Configured end minute. |
| `campaign.window_days` | array or null | Saved value. |
| `campaign.timezone` | string or null | Saved campaign time zone. |
| `campaign.source` | string | Saved origin label. |
| `campaign.status` | string | Current state; for example scheduled, launching, running, done, failed or cancelled. Treat new states conservatively. |
| `campaign.total_count` | integer | Count. Minimum 0. |
| `campaign.started_at` | string or null | Saved timestamp, or null. Format: date-time. |
| `campaign.completed_at` | string or null | Saved timestamp, or null. Format: date-time. |
| `campaign.created_at` | string or null | Saved timestamp, or null. Format: date-time. |
| `campaign.updated_at` | string or null | Saved timestamp, or null. Format: date-time. |
| `campaign.allow_wider_hours` | boolean | True only with confirmation evidence for the current policy revision. |
| `campaign.prompt` | string or null | Default voice instructions. |
| `campaign.done_count` | integer | Count. Minimum 0. |
| `campaign.failed_count` | integer | Count. Minimum 0. |
| `campaign.voicemail_count` | integer | Count. Minimum 0. |

The response sends `Cache-Control: no-store`. Keep null values as null. `allow_wider_hours` is true only when the current saved hours and days have matching confirmation evidence. Missing or outdated evidence means false; a failed evidence read returns 503. Internal policy identifiers and account credentials are excluded.

## Example request

These examples use HTTP directly. The SDK/CLI/MCP clients provide the [campaign list](https://docs.nixflex.com/api-reference/voice-campaigns/get-campaigns.md); they do not add a dedicated detail method. Set `NIXFLEX_API_KEY` privately and `NXF_CAMPAIGN_ID` to an owned campaign. Raw HTTP base URL: `https://api.nixflex.com/v1`. Node and Python SDK base URL: `https://api.nixflex.com`. The SDK adds `/v1`.

```bash cURL theme={"dark"}
curl --request GET \
  --url "https://api.nixflex.com/v1/campaigns/$NXF_CAMPAIGN_ID" \
  --header "Authorization: Bearer $NIXFLEX_API_KEY"
```

```javascript Node (HTTP) theme={"dark"}
const base = 'https://api.nixflex.com'.replace(/\/$/, '');
const id = encodeURIComponent(process.env.NXF_CAMPAIGN_ID);
const response = await fetch(`${base}/v1/campaigns/${id}`, {
  headers: { Authorization: `Bearer ${process.env.NIXFLEX_API_KEY}` },
});
const result = await response.json();
if (!response.ok) throw new Error(result.error?.code ?? `HTTP ${response.status}`);
console.log(result.campaign);
```

```python Python (HTTP) theme={"dark"}
import json
import os
from urllib.parse import quote
from urllib.request import Request, urlopen

base = "https://api.nixflex.com".rstrip("/")
campaign_id = quote(os.environ["NXF_CAMPAIGN_ID"], safe="")
request = Request(
    f"{base}/v1/campaigns/{campaign_id}",
    headers={"Authorization": f"Bearer {os.environ['NIXFLEX_API_KEY']}"},
)
with urlopen(request, timeout=20) as response:
    result = json.load(response)
print(result["campaign"])
```

```powershell PowerShell (HTTP) theme={"dark"}
$base = 'https://api.nixflex.com'
$campaignId = [Uri]::EscapeDataString($env:NXF_CAMPAIGN_ID)
$result = Invoke-RestMethod -Method Get -Uri "$base/v1/campaigns/$campaignId" -Headers @{
    Authorization = "Bearer $env:NIXFLEX_API_KEY"
}
$result.campaign
```

## Example response

Illustrative `200 OK` response with all campaign fields. Counters describe saved progress and do not guarantee that every recipient was reached.

```json Response theme={"dark"}
{
  "campaign": {
    "campaign_id": "campaign_example",
    "agent_id": "agent_example",
    "name": "Appointment reminders",
    "prompt": null,
    "from_number": "+12025550123",
    "schedule_type": "schedule",
    "scheduled_date": "2026-11-20",
    "window_start_minutes": 540,
    "window_end_minutes": 1020,
    "window_days": [
      "mon",
      "tue",
      "wed",
      "thu",
      "fri"
    ],
    "timezone": "America/New_York",
    "source": "api",
    "status": "scheduled",
    "total_count": 10,
    "done_count": 0,
    "failed_count": 0,
    "voicemail_count": 0,
    "started_at": null,
    "completed_at": null,
    "created_at": "2026-11-12T00:00:00Z",
    "updated_at": "2026-11-12T00:00:00Z",
    "allow_wider_hours": false
  }
}
```

## Errors

Failures use the standard [error envelope](https://docs.nixflex.com/api-reference/errors.md#error-envelope). Preserve the response status and code.

| Status | Code | Meaning | What to do |
| - | - | - | - |
| 401 | [`unauthorized`](https://docs.nixflex.com/api-reference/errors#unauthorized) | The credential is missing or invalid. | Check the account and host. |
| 403 | [`permission_denied`](https://docs.nixflex.com/api-reference/errors#permission_denied) | The principal cannot access this account. | Check the account permission. |
| 404 | [`not_found`](https://docs.nixflex.com/api-reference/errors#not_found) | The ID is invalid, missing, foreign or deleted. | Check the owned ID; do not retry unchanged. |
| 429 | [`rate_limit_exceeded`](https://docs.nixflex.com/api-reference/errors#rate_limit_exceeded) | The account request limit was reached. | Respect `Retry-After`. |
| 503 | [`campaign_unavailable`](https://docs.nixflex.com/api-reference/errors#campaign_unavailable) | Campaign details or current confirmation evidence could not be checked. | Keep the previous view marked unavailable and retry the read with bounded backoff. |

## Retry and idempotency

This request is read-only. Retry transient connection or server errors with bounded backoff. Do not turn 503 into an empty campaign, a false wider-hours choice or successful deletion. A later read can return newer progress. Respect `Cache-Control: no-store`.

## Related endpoints

* [List voice campaigns](https://docs.nixflex.com/api-reference/voice-campaigns/get-campaigns.md)
* [Launch a voice campaign](https://docs.nixflex.com/api-reference/calls/batch-launch.md)
* [Delete a voice campaign](https://docs.nixflex.com/api-reference/voice-campaigns/delete.md)


## OpenAPI

````yaml api-reference/public.openapi.json GET /campaigns/{id}
openapi: 3.1.0
info:
  title: Nixflex public API
  version: 1.0.0
  description: >-
    Nixflex API reference for agents, calls, messaging, knowledge, organisations
    and integrations. Authenticate with the owning account and follow each
    operation’s permissions, response and retry contract.
servers:
  - url: https://api.nixflex.com/v1
security:
  - bearerAuth: []
paths:
  /campaigns/{id}:
    get:
      tags:
        - Voice campaigns
      summary: Get a voice campaign
      description: >-
        Read one owned voice campaign with the same fields as a campaign-list
        item. No recipients are included. Wider-hours confirmation uses current
        saved evidence; an evidence-read failure returns 503 rather than false.
        Missing, foreign, deleted and invalid IDs have the same 404. Responses
        use Cache-Control: no-store.
      operationId: getVoiceCampaign
      parameters:
        - name: id
          in: path
          required: true
          description: >-
            Exact owned campaign identifier. Invalid, missing, foreign and
            deleted IDs share a 404.
          schema:
            type: string
            minLength: 1
            maxLength: 200
      responses:
        '200':
          description: Owned campaign detail.
          content:
            application/json:
              schema:
                type: object
                required:
                  - campaign
                properties:
                  campaign:
                    type: object
                    properties:
                      campaign_id:
                        type: string
                        description: Public campaign ID.
                      agent_id:
                        type: string
                        description: Owning agent ID.
                      name:
                        type:
                          - string
                          - 'null'
                        description: Saved campaign label.
                      from_number:
                        type:
                          - string
                          - 'null'
                        description: International number with + and digits; no spaces.
                        pattern: ^\+[1-9][0-9]{6,14}$
                      schedule_type:
                        type: string
                        description: Saved now or schedule mode.
                      scheduled_date:
                        type:
                          - string
                          - 'null'
                        description: Saved scheduled date.
                      window_start_minutes:
                        type:
                          - integer
                          - 'null'
                        description: Configured start minute.
                      window_end_minutes:
                        type:
                          - integer
                          - 'null'
                        description: Configured end minute.
                      window_days:
                        type:
                          - array
                          - 'null'
                        items:
                          type: string
                          description: Weekday.
                        description: ''
                      timezone:
                        type:
                          - string
                          - 'null'
                        description: Saved campaign time zone.
                      source:
                        type: string
                        description: Saved origin label.
                      status:
                        type: string
                        description: >-
                          Current state; for example scheduled, launching,
                          running, done, failed or cancelled. Treat new states
                          conservatively.
                      total_count:
                        type: integer
                        description: Count.
                        minimum: 0
                      started_at:
                        type:
                          - string
                          - 'null'
                        description: Saved timestamp, or null.
                        format: date-time
                      completed_at:
                        type:
                          - string
                          - 'null'
                        description: Saved timestamp, or null.
                        format: date-time
                      created_at:
                        type:
                          - string
                          - 'null'
                        description: Saved timestamp, or null.
                        format: date-time
                      updated_at:
                        type:
                          - string
                          - 'null'
                        description: Saved timestamp, or null.
                        format: date-time
                      allow_wider_hours:
                        type: boolean
                        description: >-
                          True only with confirmation evidence for the current
                          policy revision.
                      prompt:
                        type:
                          - string
                          - 'null'
                        description: Default voice instructions.
                      done_count:
                        type: integer
                        description: Count.
                        minimum: 0
                      failed_count:
                        type: integer
                        description: Count.
                        minimum: 0
                      voicemail_count:
                        type: integer
                        description: Count.
                        minimum: 0
                    required:
                      - campaign_id
                      - agent_id
                      - name
                      - from_number
                      - schedule_type
                      - scheduled_date
                      - window_start_minutes
                      - window_end_minutes
                      - window_days
                      - timezone
                      - source
                      - status
                      - total_count
                      - started_at
                      - completed_at
                      - created_at
                      - updated_at
                      - allow_wider_hours
                      - prompt
                      - done_count
                      - failed_count
                      - voicemail_count
                    description: ''
                    additionalProperties: false
                additionalProperties: false
              examples:
                campaign:
                  value:
                    campaign:
                      campaign_id: campaign_example
                      agent_id: agent_example
                      name: Appointment reminders
                      prompt: null
                      from_number: '+12025550123'
                      schedule_type: schedule
                      scheduled_date: '2026-11-20'
                      window_start_minutes: 540
                      window_end_minutes: 1020
                      window_days:
                        - mon
                        - tue
                        - wed
                        - thu
                        - fri
                      timezone: America/New_York
                      source: api
                      status: scheduled
                      total_count: 10
                      done_count: 0
                      failed_count: 0
                      voicemail_count: 0
                      started_at: null
                      completed_at: null
                      created_at: '2026-11-12T00:00:00Z'
                      updated_at: '2026-11-12T00:00:00Z'
                      allow_wider_hours: false
          headers:
            Cache-Control:
              description: Do not store this response.
              schema:
                type: string
                const: no-store
        '401':
          description: 'unauthorized: The credential is missing or invalid.'
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: Machine-readable error code.
                      message:
                        type: string
                        description: Explanation.
                      doc_url:
                        type: string
                        description: Error reference link.
                      details:
                        type: object
                        properties: {}
                        description: >-
                          Optional context; inspect campaign_id, status, outcome
                          and safe_to_retry for uncertain writes.
                        additionalProperties: true
                    required:
                      - code
                      - message
                      - doc_url
                      - type
                    description: ''
                    additionalProperties: false
                required:
                  - error
                description: ''
                additionalProperties: false
        '403':
          description: >-
            permission_denied: The authenticated principal is not allowed to
            access this account.
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: object
                    required:
                      - type
                      - code
                      - message
                      - doc_url
                      - details
                    properties:
                      type:
                        type: string
                      code:
                        type: string
                        enum:
                          - permission_denied
                      message:
                        type: string
                      doc_url:
                        type: string
                        format: uri
                      details:
                        type: object
                        additionalProperties: true
                    additionalProperties: true
                additionalProperties: true
              examples:
                permission_denied:
                  value:
                    error:
                      type: permission_denied
                      code: permission_denied
                      message: You do not have permission to do this.
                      doc_url: https://docs.nixflex.com/errors/permission_denied
                      details: {}
        '404':
          description: 'not_found: Invalid, missing, foreign or deleted campaign.'
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: object
                    required:
                      - type
                      - code
                      - message
                      - doc_url
                      - details
                    properties:
                      type:
                        type: string
                      code:
                        type: string
                        enum:
                          - not_found
                      message:
                        type: string
                      doc_url:
                        type: string
                        format: uri
                      details:
                        type: object
                        additionalProperties: true
                    additionalProperties: true
                additionalProperties: true
              examples:
                not_found:
                  value:
                    error:
                      type: not_found
                      code: not_found
                      message: Campaign not found.
                      doc_url: https://docs.nixflex.com/errors/not_found
                      details: {}
        '429':
          description: 'rate_limit_exceeded: The account request limit was reached.'
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: Machine-readable error code.
                      message:
                        type: string
                        description: Explanation.
                      doc_url:
                        type: string
                        description: Error reference link.
                      details:
                        type: object
                        properties: {}
                        description: >-
                          Optional context; inspect campaign_id, status, outcome
                          and safe_to_retry for uncertain writes.
                        additionalProperties: true
                    required:
                      - code
                      - message
                      - doc_url
                      - type
                    description: ''
                    additionalProperties: false
                required:
                  - error
                description: ''
                additionalProperties: false
        '503':
          description: >-
            campaign_unavailable: Campaign details or current wider-hours
            evidence could not be read.
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: object
                    required:
                      - type
                      - code
                      - message
                      - doc_url
                      - details
                    properties:
                      type:
                        type: string
                      code:
                        type: string
                        enum:
                          - campaign_unavailable
                      message:
                        type: string
                      doc_url:
                        type: string
                        format: uri
                      details:
                        type: object
                        additionalProperties: true
                    additionalProperties: true
                additionalProperties: true
              examples:
                campaign_unavailable:
                  value:
                    error:
                      type: server_error
                      code: campaign_unavailable
                      message: Campaign details could not be checked. Please retry.
                      doc_url: https://docs.nixflex.com/errors/campaign_unavailable
                      details: {}
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        KEY_ID:KEY_SECRET from the owning account. Keep it server-side. A
        verified personal dashboard Bearer session may be used where the
        operation documents role-based access.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.