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

# Building a campaign

> Set up the agent, recipient list, retry rules, call window, and launch or schedule.

Open **Call campaigns → New campaign** to start the builder. It has two parts: a form on the
left, and a live review of your recipient list on the right - nothing gets queued until every
issue in the review list is resolved.

## 1. Campaign & agent

Give the campaign a name, choose the agent to run it, and choose one or more phone numbers to
call from. With more than one from-number, calls are spread across them.

## 2. Calling list

### Set the default country code

Pick a country **first** - it's required, and the calling-list upload stays disabled until you
do. Vocily uses it to read any phone number in your file that isn't already written with a `+`
country code, so a plain `9876543210` is understood correctly.

### Get a recipient list

Either **download the template** for the selected agent, or upload a CSV you already have.

The template's phone column is named `callee_number`. If you're using your own file instead, name
its phone column one of: `callee_number`, `to_number`, `phone`, `phone_number`, or `mobile` -
matching is not case-sensitive and ignores spaces or punctuation, so `Phone Number` and
`phone-number` both work. A file with none of these is rejected with the list of accepted names.

### Map variables

If the agent personalizes calls - using the caller's name, an order number, or anything else set
up in [Variables](/building-agents/variables) - the builder lists every variable the agent
declares and asks you to map each one to a column in your file. A campaign can't launch until
every variable has a column.

The phone number itself needs no mapping: it always fills the agent's `callee_number` variable
automatically, shown as a locked row at the top of the mapping list.

<Tip>
  Running a plain, name-less campaign against an agent that still asks for a name? Delete that
  variable from the agent's configuration first - see [Variables](/building-agents/variables) -
  and the campaign will stop requiring it.
</Tip>

### Resolve duplicates and invalid numbers

The review list on the right filters your file into **All**, **Duplicates**, **Invalid**, and
**Removed**. Resolve everything with one click - "Remove duplicates, keep first" or "Remove
invalid" - or fix an invalid number inline and it re-validates on the spot. Re-uploading a file
resets these choices. A campaign can't launch while any row still needs review.

## 3. Retry rules (optional)

Turn on retries to automatically re-attempt a recipient who doesn't answer. Configure:

* Which outcomes retry - no answer, voicemail, busy, or failed.
* The maximum number of retries (up to 5).
* How long to wait before each retry attempt.

## 4. Call time window (optional)

Restrict dialing to a time window - a timezone, start and end hour, and which days of the week
are allowed. If the window closes while the campaign is still running, choose what happens next:

* **Pause** (default) - dialing waits and picks back up automatically when the window reopens.
* **Stop** - the campaign stops outright; you restart it manually.

## Getting results into your own system

A campaign has no webhook setting of its own. To have your system react to outcomes as they happen
rather than checking back in Vocily, set up a **webhook on the agent** (Agents → your agent →
**Settings → Webhooks**) and subscribe to the call events you care about - `call.ended` for the
outcome, `call.analysis.completed` once analysis is ready.

Every event carries `origin: "batch"` and the `batch_id`, so you can tell campaign calls from
ordinary ones and group them by campaign. One endpoint covers every campaign this agent runs, and
deliveries are signed, retried on failure, and visible in **Observe → Logs**.

## Parallel calls

The commit area at the bottom of the review list shows how many recipients are ready and an
editable **Parallel calls** number - how many calls this campaign can have going at once, capped
by your plan's calling capacity. Lowering it stretches out the campaign; an Owner or Admin can
raise the plan-wide cap from **Settings**. This number controls how many lines the campaign can
use at once - it does not change how fast Vocily dials down the list, which is paced
automatically.

Once the campaign finishes you'll see its **actual** cost on the campaign page, metered from the
calls that really happened. Vocily deliberately shows no up-front cost estimate: a useful one
would have to know how many people answer and how long they talk, and guessing that to the cent
would be a number you couldn't plan against.

## Launch or schedule

**Create & launch** starts dialing immediately. **Create & schedule** starts it at a future time
you choose, in a timezone you pick - a time in the past is rejected. Either way, you'll confirm
the recipient count and calling numbers before anything is queued.

## What's next

* [Manage a running campaign](/call-campaigns/managing-a-campaign) - pause, stop, watch progress,
  and export results.
