# API reference

> Every Ballast endpoint with its parameters, permissions and a curl example, plus signed webhooks for replies, bounces and wins. Keys come from Settings.

Canonical: https://ballast.to/docs/api
Last updated: 2026-10-25

Developers

Ballast is cold email and email outreach software with every feature on every plan. Connect unlimited mailboxes, send sequences that ramp up slowly and pause themselves when bounces climb, and answer every reply from one inbox, priced by the emails you send.

The REST API has 182 endpoints in 25 areas, the same operations as the dashboard. Each one is also a tool for your AI through [MCP](https://ballast.to/docs/mcp), or automated via the official [n8n community node](https://ballast.to/docs/integrations#n8n). The OpenAPI spec is at `/api/v1/spec.json` for Postman or code generators.

## Authentication

Create a key in Settings, API keys. It belongs to one workspace and acts with the role of the person who created it, so a member's key can't do what only admins can. Send it as a bearer token. Each key gets 600 requests a minute.

```
curl https://ballast.to/api/v1/me \
  -H "Authorization: Bearer $BALLAST_API_KEY"
```

### Errors

Errors come back as JSON with an HTTP status, a `code` and a `message` written for people. Invalid input lists each problem under `data.issues`. 401: missing or revoked key. 402: the workspace needs an active plan. 403: your role can't do this. 429: slow down.

## Endpoints

Each area has its own page with every endpoint, its parameters, what it returns, who can call it and a curl example.

- [Workspace Who you are, the workspace and its sending settings. 5](https://ballast.to/docs/api/workspace)
- [Analytics The Overview dashboard: sends, replies, bounces and sentiment. 1](https://ballast.to/docs/api/analytics)
- [Campaigns Sequences, templates, steps and variants, leads, schedule, launch and pause. 33](https://ballast.to/docs/api/campaigns)
- [Leads Create, import, update, verify and mark leads won. 22](https://ballast.to/docs/api/leads)
- [Inbox vendors Import mailboxes bought from Zapmail, InboxKit, Mailforge, Infraforge or Primeforge. 8](https://ballast.to/docs/api/inbox-vendors)
- [Lead sources Pull from Apollo, Instantly, Smartlead or Lemlist with your key, or take rows from Clay. 5](https://ballast.to/docs/api/lead-sources)
- [Lead finder Find local businesses on the map and the addresses their websites publish. 13](https://ballast.to/docs/api/lead-finder)
- [Lists Group leads to add them to campaigns together. 4](https://ballast.to/docs/api/lists)
- [Labels Reply labels and the triggers they run. 6](https://ballast.to/docs/api/labels)
- [Suppressions Addresses and domains that are never emailed. 3](https://ballast.to/docs/api/suppressions)
- [Unibox Reply threads from every mailbox, labels and answers. 15](https://ballast.to/docs/api/unibox)
- [Automations A trigger and the steps it runs: actions, waits and conditions, with their run history. 11](https://ballast.to/docs/api/automations)
- [Notifications Your bell: what happened that needs a look, and what you choose to hear about. 5](https://ballast.to/docs/api/notifications)
- [Mailboxes Connect, test and tune the mailboxes you send from. 10](https://ballast.to/docs/api/mailboxes)
- [Warmup Warmup per mailbox and its inbox placement. 3](https://ballast.to/docs/api/warmup)
- [Placement tests Send an email to test inboxes at each provider and see where it lands. 4](https://ballast.to/docs/api/placement-tests)
- [Deliverability Network The IPs your SMTP and IMAP mailboxes log in through. 4](https://ballast.to/docs/api/deliverability-network)
- [Domains Sending domains and their nightly DNS and blacklist report. 4](https://ballast.to/docs/api/domains)
- [Link domain The domain your unsubscribe and tracking links use. 6](https://ballast.to/docs/api/link-domain)
- [Integrations Your verifier and your own AI key. 7](https://ballast.to/docs/api/integrations)
- [Webhook endpoints Where Ballast sends events, and their delivery log. 7](https://ballast.to/docs/api/webhook-endpoints)
- [Offer profile What you sell, used by Write with AI. 3](https://ballast.to/docs/api/offer-profile)
- [Billing Plan, usage and limits. 1](https://ballast.to/docs/api/billing)
- [Domain checker The free SPF, DKIM, DMARC and blacklist check. 1](https://ballast.to/docs/api/domain-checker)
- [API keys Keys for this workspace. 1](https://ballast.to/docs/api/api-keys)

## Webhooks

Add endpoints in Settings, Webhooks, or with `POST /webhooks`. Ballast POSTs JSON for each event you pick. Answer with any 2xx within 10 seconds. Anything else is retried 8 more times with growing gaps, for about two hours; redirects are not followed. Every delivery has an `id` shared by all your endpoints, so you can ignore one you've already handled.

| Event | When |
| --- | --- |
| lead.replied | A lead answered a campaign email (out-of-office and auto-replies excluded). |
| lead.labeled | A reply got a label, from AI, a rule, a person or the API. |
| lead.bounced | An email to a lead bounced hard. |
| lead.unsubscribed | A lead unsubscribed, by link, one-click header or reply. |
| lead.complained | A lead's email provider reported a campaign email as spam (feedback loop report; Gmail doesn't send these). |
| lead.won | A lead was marked won. |
| campaign.paused | A campaign stopped sending: paused by someone, a label, a breaker or its end date. |

### Payload

Lead events carry the lead and its campaign; the rest depends on the event: `reply`, `label`, `bounce` (its `kind` is `dead` for an address that no longer exists, `blocked` for a 5.7.x refusal of the sender), `value` for a win, `reason` for a paused campaign.

lead.replied

```
{
  "id": "0199f2b4-6c1e-7a51-9d8e-3f4b2c1a0e77",
  "type": "lead.replied",
  "created_at": "2026-10-17T09:14:03.120Z",
  "workspace_id": "0199a1b2-...",
  "data": {
    "lead": {
      "id": "0199...",
      "email": "jane@example.com",
      "first_name": "Jane",
      "last_name": "Doe",
      "company": "Example Inc",
      "title": "Head of Sales",
      "status": "replied",
      "custom": {}
    },
    "campaign": {
      "id": "0199...",
      "name": "Q4 founders",
      "status": "running"
    },
    "reply": {
      "thread_id": "0199...",
      "mailbox": "you@yourdomain.com",
      "subject": "Re: Quick question",
      "text": "Sounds interesting, what does it cost?",
      "received_at": "2026-10-17T09:13:58.000Z"
    }
  }
}
```

### Check the signature

Headers: `Ballast-Event`, `Ballast-Delivery` and `Ballast-Signature: t=<unix seconds>,v1=<hex>`, an HMAC-SHA256 of the timestamp, a dot and the raw body, keyed with the endpoint's secret (`whsec_...`). Refuse signatures older than 5 minutes.

Node.js

```
import { createHmac, timingSafeEqual } from "node:crypto";

// header = the Ballast-Signature request header, rawBody = the body exactly as received
export function verifyBallast(secret, rawBody, header) {
  const parts = Object.fromEntries(header.split(",").map((p) => p.split("=")));
  const t = Number(parts.t);
  if (!t || !parts.v1 || Math.abs(Date.now() / 1000 - t) > 300) return false;
  const expected = createHmac("sha256", secret).update(`${t}.${rawBody}`).digest("hex");
  return expected.length === parts.v1.length && timingSafeEqual(Buffer.from(expected), Buffer.from(parts.v1));
}
```
