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

# Create a campaign

> Create a campaign that calls the contacts in a contact view.

<Note>
  This endpoint is for the VIP plan only. Other plans get a `403`. See [Plan access](/api-reference/introduction#plan-access).
</Note>

A campaign calls everyone in a contact view, with one voice agent, inside the days and hours you set. It is a draft until you set it live. When it goes live, it adds the contacts in the view right away, and keeps the list in step with the view after that.

Before each call, the dialer checks DND and opt-outs. It never calls a contact with DND on.

<ParamField body="workspaceId" type="string">
  The workspace. Required for an account key. A workspace key uses its own workspace.
</ParamField>

<ParamField body="name" type="string" required>
  The campaign name, up to 200 characters.
</ParamField>

<ParamField body="voiceAgentId" type="string" required>
  The voice agent that places the calls. It must be in the same workspace.
</ParamField>

<ParamField body="savedViewId" type="string" required>
  The contact view that decides who gets called. It must be in the same workspace. Create views with the contact views endpoints.
</ParamField>

<ParamField body="dailyCapTalkMinutes" type="integer" required>
  Talk minutes the campaign may use each day. When it reaches this, its status becomes `capped` until the next calling day.
</ParamField>

<ParamField body="maxFollowUps" type="integer" default="0">
  Calls after the first one. `0` means call each contact once.
</ParamField>

<ParamField body="callingDays" type="integer[]" required>
  Days the campaign calls on. `1` is Monday and `7` is Sunday.
</ParamField>

<ParamField body="callingHoursStart" type="string" required>
  When calling starts each day, like `09:00`. On the quarter hour, and not before 9am.
</ParamField>

<ParamField body="callingHoursEnd" type="string" required>
  When calling stops each day, like `17:00`. On the quarter hour, after the start, and not after 8pm.
</ParamField>

<ParamField body="callingTimezone" type="string">
  A timezone for every contact, like `America/New_York`. Leave it out or send `null` to use each contact's own timezone. A zone that names no place, like `UTC`, `GMT` or a fixed offset, gets a `400`.
</ParamField>

<ParamField body="status" type="string" default="draft">
  `draft` or `live`. A live campaign starts calling at once. A locked workspace cannot add a campaign.
</ParamField>

## Errors

| Status | When |
| - | - |
| `400` | A field is missing or not valid. |
| `402` | The account has no plan, or its subscription is not active. |
| `403` | Your plan is not VIP, or the workspace is locked. |
| `404` | The workspace does not exist, or your API key cannot reach it. |

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST "https://api.nedzo.ai/v1/campaigns" \
      -H "Authorization: Bearer YOUR_API_KEY" \
      -H "Content-Type: application/json" \
      -d '{
        "workspaceId": "789e4567-e89b-12d3-a456-426614174000",
        "name": "September promo",
        "voiceAgentId": "aaa11111-bbbb-2222-cccc-333344445555",
        "savedViewId": "bbb11111-bbbb-2222-cccc-333344445555",
        "dailyCapTalkMinutes": 120,
        "maxFollowUps": 2,
        "callingDays": [1, 2, 3, 4, 5],
        "callingHoursStart": "09:00",
        "callingHoursEnd": "17:00"
      }'
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "workspaceId": "789e4567-e89b-12d3-a456-426614174000",
    "name": "September promo",
    "voiceAgentId": "aaa11111-bbbb-2222-cccc-333344445555",
    "savedViewId": "bbb11111-bbbb-2222-cccc-333344445555",
    "dailyCapTalkMinutes": 120,
    "maxFollowUps": 2,
    "callingDays": [1, 2, 3, 4, 5],
    "callingHoursStart": "09:00:00",
    "callingHoursEnd": "17:00:00",
    "callingTimezone": null,
    "status": "draft",
    "createdAt": "2026-10-11T12:00:00Z",
    "updatedAt": "2026-10-11T12:00:00Z"
  }
  ```
</ResponseExample>


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