Skip to main content
Languages: every operation supports cURL, Node.js (TypeScript), Python, Go, Ruby, and PHP. The first 15 operations on this page show all six languages; the remaining 72 show cURL and TypeScript — the two most-used.

Campaigns API

Bulk campaign creation, scheduling, and analytics Base path: /api/v1/campaigns Endpoint count: 87

title: “Worked request and response samples” description: “Worked samples for the most-used campaign operations: create a campaign, test its timing, and launch it. Each sample shows the request, the success envelope, and the error envelope to expect.”

Worked request and response samples

Copy a request body as written, substitute your own ids, and compare the response envelope. Errors follow Devotel Orbit’s { error, meta } envelope, shown once below under Error envelope.
Auto-winner governance. POST /campaigns/{id}/variants accepts three optional knobs that gate the automatic winner-promotion scheduler: ab_auto_promote (boolean | null — false keeps every promotion behind the manual POST /campaigns/{id}/ab-select-winner call, null resets to the default true), ab_min_sample_size (integer | null — deliveries the leading variant must reach before an automatic verdict, 10–1,000,000, null resets to the default 30), and ab_confidence_threshold (number | null — Bayesian posterior confidence required to promote, 0.500–0.999, null resets to the default 0.950). GET /campaigns/{id}/ab-results echoes those settings together with a live auto_winner_progress snapshot — the gate values the evaluator currently applies, the current leader, and whether it would already lock — so a dashboard can render real progress toward an automatic verdict. See the A/B testing guide.
Cross-channel governance in one call. GET /campaigns/{id}/governance-summary aggregates the four governance primitives a campaign’s settings panel previously issued four separate calls for: the A/B(n) experiment config plus auto-winner governance, the control hold-out cohort, the resolved quiet-hours window (with campaign / org_default / platform_default source attribution), and the effective frequency-cap rules — global rules folded in alongside channel-scoped rules, each labelled applies: true|false so the dashboard can place the badge without re-admitting the org-wide caps list client-side. Use this ONE round-trip when you render the “rules in effect” card; the individual sources stay available if you only want one.

Create a campaign

POST /api/v1/campaigns/
Request

Check for overlapping schedules

POST /api/v1/campaigns/check-schedule-conflicts
Request

Launch the campaign

POST /api/v1/campaigns/{id}/send

Error envelope

422

List campaigns

GET /api/v1/campaigns
Retrieve campaigns with cursor-based pagination. Filter by status; supported values are draft, pending_approval, scheduled, running, sending, aborting, completed, partially_failed, paused, cancelled, and failed.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get a campaign

GET /api/v1/campaigns/{id}
Fetch a single campaign by ID, including its audience definition, message template, scheduling fields, lifecycle counters, and current status. Use it to render a detail view or to confirm a campaign’s state before updating or launching it.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get A/B test results

GET /api/v1/campaigns/{id}/ab-results
Return the per-variant metrics and the winner rollup for a campaign-level A/B test: recipients assigned, delivery and engagement counts per variant, the winning-variant flag, and the auto-promote progress when bandit/auto-winner governance is enabled. Campaigns with no A/B test return ab_test_enabled: false with an empty variants array.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get a contact’s A/B split assignment

GET /api/v1/campaigns/{id}/ab-split/{nodeId}/assignment
Look up which variant a given contact was assigned to at an in-journey A/B split node — the DSAR-grade lookup endpoint for A/B assignment provenance. Pass the contact_id as a query parameter; a contact that never traversed the split returns 404.
string
required
string
required
string
required
Contact to look up.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get in-journey A/B split results

GET /api/v1/campaigns/{id}/ab-split/{nodeId}/results
Return the per-variant rollup for one in-journey A/B split node: contacts assigned, conversions, conversion value in cents, and conversion rate per variant. Every configured variant appears in the rollup — a variant with zero conversions reports conversion_count: 0 so the node’s row stripes line up with the configured weights.
string
required
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List attribution-funnel

GET /api/v1/campaigns/{id}/attribution-funnel
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List cost

GET /api/v1/campaigns/{id}/cost
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List drip-analytics

GET /api/v1/campaigns/{id}/drip-analytics
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List export

GET /api/v1/campaigns/{id}/export
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List governance-summary

GET /api/v1/campaigns/{id}/governance-summary
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get campaign holdout lift

GET /api/v1/campaigns/{id}/holdout-lift
Read the campaign-wide incrementality report for a blast campaign with a configured campaign_holdout_percent control cohort: treatment and control rates, absolute and relative lift, Wald confidence interval, z-score, and significance flag. Recomputed on every read, so you can monitor lift while the campaign is still running. Returns has_holdout: false when no control cohort is configured.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get journey message delivery analytics

GET /api/v1/campaigns/{id}/journey-analytics
Read per-node message delivery stats for a journey campaign: each node in the journey definition with total, delivered, failed, delivery_rate, and the node channel/label. The response also echoes the holdout-group breakdown when the journey configured one. Use it for the journey-detail delivery view; use GET journey/node-analytics for the contact-level entered/completed/dropped funnel instead.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get the journey conversion goal

GET /api/v1/campaigns/{id}/journey/goal
Fetch the conversion-goal definition for a journey campaign: the event type that counts as converting, the optional event-filter predicate, the attribution window in hours, and its description. Returns 404 when the campaign has no goal defined. Use it to render the journey-detail goal panel or before setting a goal with PUT.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get journey goal analytics

GET /api/v1/campaigns/{id}/journey/goal/analytics
Read the goal-conversion rollup for a journey campaign: distinct enrolled contacts, converted contacts within the goal’s attribution window, conversion rate, total conversion value, and the per-step contribution ranked by which node the contact saw last before converting. The goal definition must already exist (404 otherwise). Conversion window 0 means unbounded (legacy) attribution.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get journey holdout lift

GET /api/v1/campaigns/{id}/journey/holdout-lift
Read the treatment-vs-holdout lift report for a journey campaign that carves a holdout_pct control group: treatment arm counts, holdout arm counts, and the absolute/relative lift of conversion above the do-nothing baseline. Lift fields are null while holdout conversion is tracked as counts only; returns has_holdout: false when the journey has no holdout configured.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get journey node funnel analytics

GET /api/v1/campaigns/{id}/journey/node-analytics
Read the contact-level funnel per journey node: distinct contacts entered, completed end-to-end, dropped out, currently parked at that node, and per-node conversion rate. This powers the journey-builder per-node overlay; contrast with GET journey-analytics, which reports per-node message delivery counts. Nodes with no contact activity yet are zero-filled.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get conversion channel pathing

GET /api/v1/campaigns/{id}/journey/pathing
Rank the top-N channel sequences that led converting contacts on this journey to the goal: rebuilds each contact’s ordered touch sequence from messages and rolls the sequences up (Klaviyo path-to-conversion parity). Supports model=last_touch|linear|time_decay, top (1-100, default 10), and half_life_hours (time_decay only, default 168). Bounded reads return a truncated flag when the caps cut heavy-campaign history.
string
required
Resource identifier
string (enum: last_touch|linear|time_decay)
integer
integer
Half-life for the time_decay attribution model
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List a campaign’s recipients

GET /api/v1/campaigns/{id}/recipients
Return one campaign’s recipient rows, cursor-paginated (query limit up to 200, opaque cursor from the prior page), with per-recipient delivery state for the detail drawer. The pagination block carries the authoritative total_count and failed_count aggregates (computed over the full recipient set, not the loaded page) so an analytics tab can render ‘X of N’ and size a resend-to-failed confirm dialog correctly. Read-only; campaigns:read scope.
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Return on ad spend for one campaign

GET /api/v1/campaigns/{id}/roas
Attribute one campaign’s journey-goal conversion revenue across the sibling campaigns that touched each converting contact, and pair the attributed revenue with this campaign’s send cost (SUM of message prices). Query knobs: model (last_touch | linear | time_decay, default last_touch), window_hours (0 = unbounded look-back, up to 8760h, default 168), and half_life_hours (time_decay model, default 168). Mixed-currency conversions are blended into the campaign’s send currency via the billing FX seam; revenue with no FX rate is surfaced as unconvertible, never silently dropped. Read-only; campaigns:read scope.
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

ROAS broken down by template or message

GET /api/v1/campaigns/{id}/roas/touchpoints
Attribute one campaign’s conversion revenue by touchpoint — template (default) or individual message — so a marketer can see which creative actually drove purchases, not just which campaign. Accepts the same model, window_hours, and half_life_hours knobs as GET /campaigns//roas plus granularity (template | message). Each touchpoint’s attributed revenue is paired with that touchpoint’s own send cost over the converting cohort, so numerator and denominator stay scoped consistently. Read-only; campaigns:read scope.
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

ROI attribution per channel for one campaign

GET /api/v1/campaigns/{id}/roi-attribution
Answer ‘which CHANNEL carried this campaign’: per-channel sent, delivered, conversions, revenue, and spend, folded into cost-per-acquisition and ROAS with one row per channel plus an all-channel totals row. Delivery uses the same channel-aware filter the analytics surfaces use, so this report’s delivery rate can never drift from the rest of the dashboard. Query window_hours bounds the look-back (0 = unbounded, up to 8760h). Read-only; campaigns:read scope.
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get send-time experiment lift report

GET /api/v1/campaigns/{id}/send-time-experiment/results
Returns per-window conversion lift vs control, statistical significance testing, recommended winning window, and full analytics for the send-time A/B experiment.
string
required
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get smart-send holdout lift

GET /api/v1/campaigns/{id}/smart-send-holdout-lift
Measure the incremental effect of per-contact smart-send time optimization: a deterministic held-out slice of the recipient-optimal audience is scored against the optimized arm with a Wald confidence interval and significance test. Distinct from GET /:id/holdout-lift, which measures sending-vs-not-sending. Returns configured: false when the campaign is not recipient-optimal or never opted into a holdout.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get campaign delivery stats

GET /api/v1/campaigns/{id}/stats
Read the aggregate delivery counters for one campaign: sent, delivered, failed, read totals plus the recipient count and computed delivery/read rates. Use it for the campaign-detail KPI strip; use the per-step analytics endpoints for drip/journey campaigns instead of building funnels off this flat aggregate.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List drip campaign steps

GET /api/v1/campaigns/{id}/steps
Read the ordered step definitions of a drip campaign: channel, template, subject, delay in minutes, and optional entry conditions per step. Use it to render the drip editor or to diff a planned step update before replacing the sequence with POST /:id/steps.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get voice cost rollup

GET /api/v1/campaigns/{id}/voice-cost-rollup
Roll up the settled per-call charges for an outbound voice broadcast campaign: total cost in cents, the count of settled calls that contributed, and the average cost per settled call. Voice-only — SMS/email and other channel costs flow through the aggregate GET /:id/stats endpoint instead.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List pending campaign approvals

GET /api/v1/campaigns/approvals/pending
List campaign launch requests waiting for supervisor decision, oldest first. Owner, admin, or super-admin only. Supports an optional campaign_id filter and a page-size limit (default 50, capped) so the queue view can poll a bounded slice.
integer
string
Optional single-campaign filter.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get campaign approval policy

GET /api/v1/campaigns/approvals/settings
Read the org-wide supervisor-approval policy: whether approvals are required by default and the minimum audience size that forces a launch through the approval queue. Any authenticated caller may read it so they know whether their next launch will be gated.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get the campaign audience cap

GET /api/v1/campaigns/audience-cap/settings
Read the org-wide campaign audience cap: the override flag, the configured maximum audience size, and the platform floor/ceiling bounds so callers can validate an update without hardcoding the limits. Any authenticated caller may read it.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List CRM audience containers

GET /api/v1/campaigns/audience-sources/{provider}/containers
List the audience containers available on a connected CRM provider — HubSpot static lists, Salesforce reports and list views, or Pipedrive person filters — so the campaign-create wizard can populate the audience-source dropdown. Returns ok=false plus an empty array when the provider connection is missing or stale.
string (enum: hubspot|salesforce|pipedrive)
required
CRM provider whose containers to list.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List connected CRM audience providers

GET /api/v1/campaigns/audience-sources/providers
List the CRM providers (HubSpot, Salesforce, Pipedrive) the org has an active Nango connection for, with a connected flag per provider. The campaign-create wizard uses this to enable CRM-sourced audience options (static lists, reports, person filters) in the audience picker.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get the deliverability seed-lab report

GET /api/v1/campaigns/deliverability-seed-lab
Read the measured counterpart to the predicted deliverability lab: for every registered test handset, aggregate the tenant’s own terminal delivery receipts to that destination — delivery rate, latency, inbound-reply corroboration, and the observed operator per MCCMNC. Pass ?window=7d|30d|90d (default 30d) to pick the lookback window.
string (enum: 7d|30d|90d)
Historical lookback window. Defaults to 30d.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get the Outbound Studio hub summary

GET /api/v1/campaigns/outbound-hub
Fetch the three campaign slices the Outbound Studio hub renders in one batched round-trip — in-flight, needs-attention, and recently-sent campaigns — collapsing the prior three parallel list calls. Any slice can come back empty; the endpoint deliberately degrades to empty slices instead of an error so the hub page stays usable on a database availability event.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Run a campaign compliance preflight

GET /api/v1/campaigns/preflight
Check tenant sending-compliance readiness for a channel (default sms): desktop advisory used by the campaign-create wizard to warn early when no usable dedicated sending number is attached or a country profile is missing, so a launch does not 422 every recipient at send time. Unknown channel values fall back to sms. The send-time gate remains authoritative; this is an early-warning read.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get the default quiet-hours window

GET /api/v1/campaigns/quiet-hours/settings
Read the org-wide default quiet-hours window that drip and journey campaigns fall back to when a campaign row carries no explicit window: enabled flag, configured start/end hours (recipient-local 24h clock), and the platform default hours. Any authenticated caller may read; updating requires owner or admin.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get bulk campaign ROI summary

GET /api/v1/campaigns/roi-summary
Fetch direct-attribution cost / revenue / conversion / ROI figures for up to 200 campaign ids in one round-trip, so report exports and bulk ROI views do not fan out the per-campaign multi-touch attribution engine. Pass a comma-separated list of campaign ids; each id maps to a spend_cents / revenue_cents / conversions / roas / roi_pct entry (roas/roi_pct null when spend is zero).
string
Comma-separated campaign ids — at most 200 ids are resolved; extras are ignored.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get aggregate campaign stats

GET /api/v1/campaigns/stats
Read tenant-wide campaign aggregate counters: total campaign count and a breakdown by lifecycle status, aggregated over the same subset the campaigns list shows. Forward the same channel/type/search/date filters the list uses so status-tab badges in the dashboard match the filtered subset instead of overstating the tenant totals.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

List journey templates

GET /api/v1/campaigns/templates
List the prebuilt journey-template catalog (onboarding / engagement / winback / transactional / feedback) with id, name, description, category, and channel summary per template. Optional ?category= filter; used by the journey-template picker to deep-link ‘Try the Welcome Series in 1 click’ style starters straight from onboarding.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Get a journey template

GET /api/v1/campaigns/templates/{templateId}
Fetch a single prebuilt journey template from the CXG-011 catalog, including its full node + edge graph, category, and default channel. Use it to render a template preview before cloning the template into a draft journey campaign via its instantiate endpoint.
string
required
Catalog template id, e.g. ‘welcome-series’.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Create a campaign

POST /api/v1/campaigns
Create a marketing campaign (blast, drip, or journey) targeting an all-contacts / list / segment / CSV / hand-picked-contacts (manual) audience. The campaign is created as a draft until POST /campaigns//send. message_template is optional at creation but mandatory at send-time. For drip campaigns, the steps array defines the sequence; smart_send spreads delivery across 24h using best-time-to-send predictions.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
string
string (enum: blast|drip|journey|ad)
string (enum: sms|mms|whatsapp|email|rcs|viber|…)
required
string (enum: all|list|segment|csv|manual)
string
string
object
string
integer
object
Recurrence config. Accepts either canonical keys (type, end_type, end_date, end_count, days, date, cron) or UI-prefixed keys (recurrence_type, recurrence_end_type, recurrence_end_date, etc.). When end_type === ‘on_date’ the end_date MUST be in the future; past dates are rejected with HTTP 400.
boolean
object[]
boolean

Select the A/B test winner

POST /api/v1/campaigns/{id}/ab-select-winner
Manually declare the winning variant of a campaign-level A/B test, overriding any auto-winner rule. Every contact still in the holdout group then receives the winner’s content. The variant_id must belong to the campaign’s configured variant set (POST /campaigns//variants).
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required

Record an in-journey A/B split conversion

POST /api/v1/campaigns/{id}/ab-split/{nodeId}/conversion
Record a goal-reached event for a contact that traversed an in-journey A/B split node, attributing the conversion to the variant the contact was assigned to. Optional value_cents folds into the split’s revenue rollup. A contact with no assignment 404s rather than writing an orphan row. This endpoint is not idempotent — a contact can convert more than once; de-duplicate at the caller if single-fire semantics are required.
string
required
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
string
integer
object

Abort a running campaign

POST /api/v1/campaigns/{id}/abort
Stop a running campaign immediately: drain its queued sends and flip it through aborting to paused. Unlike /pause (which leaves queued jobs in place for a later resume) aborting is a hard stop for everything not yet sent, and unlike /cancel the campaign is not terminal — requeue or resume it afterwards if needed.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Approve a pending campaign launch

POST /api/v1/campaigns/{id}/approve
Approve a campaign that is queued for launch approval and dispatch it immediately. Owner or admin role only. When the tenant requires campaign launch approval, an operator’s send flips the campaign to pending_approval and queues it for a supervisor; this endpoint is the supervisor decision. If dispatch fails (insufficient credits, fraud guard, provider outage) the approval stays pending and the campaign rolls back to pending_approval, so the queue stays consistent.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Create cancel

POST /api/v1/campaigns/{id}/cancel
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Create clone

POST /api/v1/campaigns/{id}/clone
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Preview a campaign launch (dry run)

POST /api/v1/campaigns/{id}/dry-run
Returns a read-only snapshot of what would happen if the campaign launched right now — resolved audience size with the suppressed / opted-out / unreachable / held-out / deliverable breakdown, projected cost against the wallet balance (from the same pricing lane the send path bills on), a quiet-hours skip estimate, the channel-fallback waterfall with provider readiness, personalization coverage, non-blocking warnings, and a ready_to_launch verdict. It never mutates state, never touches the wallet, and never enqueues a job — safe to call on every keystroke of the launch wizard. No request body fields are read.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Create enroll-contact

POST /api/v1/campaigns/{id}/enroll-contact
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Create enroll-segment

POST /api/v1/campaigns/{id}/enroll-segment
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Create execute-drip-step

POST /api/v1/campaigns/{id}/execute-drip-step
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Create generate-variants

POST /api/v1/campaigns/{id}/generate-variants
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Record a journey goal conversion

POST /api/v1/campaigns/{id}/journey/goal/conversion
Record a goal-reached event for a contact on a journey campaign that has a defined goal (define it first with PUT /journey/goal). First conversion per (campaign, contact) wins; replays are deduped server-side and return deduped: true, keeping the conversion rate bounded by 100%. When last_node_id is omitted, the most-recent journey node seen by the contact is looked up server-side so per-step contribution analytics still work for generic event-bus callers.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
string
Last journey node the contact saw; attributed server-side when omitted
number
Revenue value of the conversion in integer cents
object
Free-form conversion context

Optimize a campaign with AI suggestions

POST /api/v1/campaigns/{id}/optimize
Generate optimization suggestions for a campaign: a recommended send time, message variants, and a confidence-weighted rationale. The response discloses how the suggestions were produced (LLM vs deterministic heuristic fallback), token cost when the LLM ran, and per-variant SMS-segment billing impact alongside each suggestion. Reach for this before launch or while iterating on draft copy.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Pause a running campaign

POST /api/v1/campaigns/{id}/pause
Pauses a running campaign while keeping already-queued send jobs in place: a later POST /:id/resume continues from where it stopped. Contrast with /abort (drains the queue — hard stop) and /cancel (terminal; reopenable only within 60 days via /reopen). Use pause for operator traffic control such as throttling volume during an incident review.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Preview smart-send per-contact schedule

POST /api/v1/campaigns/{id}/preview-smart-send
Preview the per-contact optimal send times smart-send would compute from engagement profiles, before launching the campaign: a scheduled_at per sampled contact, a 24-hour UTC distribution histogram, and profile/fallback counts so operators can verify the spread. When the campaign declared more than one channel, a next_best_channel recommendation block is included. Pass ?limit= (default 500, max 5000) to control the sample size.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Reject a campaign pending supervisor approval

POST /api/v1/campaigns/{id}/reject
Supervisor-side decision for the launch gate: flip the campaign back to draft and record the pending approval row as rejected with an optional free-text reason (≤1 KB) in the JSON body. The operator may then edit and resubmit. Only callable by an owner/admin; 404 when no pending approval row exists for this campaign and 409 when the campaign’s status has already moved on. Audit-logged; campaigns:write scope.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Reopen a cancelled campaign

POST /api/v1/campaigns/{id}/reopen
Flip a cancelled campaign back to draft within its 60-day reopen window: zero the runtime counters, clear the lifecycle clock, and snapshot the prior run under metadata.previous_runs so statistics restart cleanly while history is preserved. Past the window the route returns 409 REOPEN_WINDOW_EXPIRED and the campaign must be cloned instead. Audit-logged; campaigns:write scope.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Re-queue a campaign’s failed sends

POST /api/v1/campaigns/{id}/resend-failed
Re-send every failed message in the campaign’s recipient set through the outbound sender, then refresh campaign stats. Pair with the authoritative failed_count returned by GET /campaigns//recipients so a confirmation dialog can name the exact affected count before retrying. Running this during an active send creates duplicate deliveries for recipients whose original message succeeded — reserve it for completed or halted batches. Audit-logged; campaigns:write scope.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Resume a paused campaign

POST /api/v1/campaigns/{id}/resume
Resume a paused campaign — restart delivery from where the run paused. For journey campaigns, paused enrollments pick up at their paused nodes; for blasts, the paused send batch re-enters the queue. Internal schedulers may request synchronous execution via the X-Internal-Bulk-Send header so BullMQ retries on failure. Audit-logged; campaigns:write scope.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Resume a journey enrollment from a node

POST /api/v1/campaigns/{id}/resume-journey
Advance one contact’s journey enrollment from a named node. The JSON body carries contact_id, recipient_address, next_node_id, and a stringified journey_definition (validated at the boundary before execution; optional enrollment_id improves terminal-state detection). Called by the scheduling infrastructure when a wait node’s timer fires; a non-2xx response signals the scheduler to back off and retry rather than clear the resume state. Operator callers may also use it to un-stick a contact manually.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Launch a campaign to its audience

POST /api/v1/campaigns/{id}/send
Begin delivering the campaign to its resolved audience. Pre-launch gates run before anything is queued: audience size against the org’s cap (400 AUDIENCE_TOO_LARGE), wallet balance against the estimated cost (402), and the supervisor-approval gate for gated orgs — which parks the launch in pending_approval instead of dispatching. The JSON body may carry launch-time overrides (e.g. recipient_limit to cap the blast to the first N recipients). 400/402/422 on gate failures; 202 once the batch is queued.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Preview send-time experiment cohort plan

POST /api/v1/campaigns/{id}/send-time-experiment/preview
Returns the deterministic cohort assignment for each send window in a send-time A/B test, including control arm size, recipient distribution, and next fire times.
string
required
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Replace drip campaign steps

POST /api/v1/campaigns/{id}/steps
Replace the full drip step sequence of a campaign (1–50 steps). Each step takes a channel, template body, delay in minutes (or a delay_unit discriminator the server normalizes to minutes), and an optional gate on the previous step’s outcome. Auto-converts the campaign to type drip when it is not already one.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
object[]
required

Set A/B variants and governance

POST /api/v1/campaigns/{id}/variants
Full-replace the A/B variant set (2–4 variants) of a campaign and/or update its experiment governance: winner metric, holdout percent, bandit toggle, and the auto-promote sample-size/confidence thresholds. Because variants is optional, a governance-only call updates just those columns without redistributing traffic evenly across variant rows.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
object[]
string (enum: delivered|opened|clicked|replied)
integer
boolean
any
any
any

Prefill an AI brief from a quick prompt

POST /api/v1/campaigns/ai-brief/prefill
Resolve the contextual seed behind one Outbound Studio Quick Prompt card (resend-failed, winning-variant, reengage-inactive): a contacts sample, a pre-filled brief body, the source campaign reference, and an audience-size hint. Read-only and never calls the LLM — the downstream POST /campaigns/from-brief still generates the actual draft.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string (enum: resend-failed|resend-non-deliverers|winning-variant|reengage-inactive)
required
Quick Prompt id; the legacy resend-non-deliverers alias is still accepted.

Suggest campaign copy with AI

POST /api/v1/campaigns/ai-brief/suggest
Cold-start the campaign create wizard with three alternative subject lines, body copies, and CTA labels generated from the org’s product catalog plus its last-30d best-performing campaigns. All body fields are optional — it runs with no operator input. Returns 503 when no LLM provider is configured so the caller can fall back to manual copy.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string (enum: sms|mms|whatsapp|email|rcs|viber|…)
Optional channel hint driving per-channel length caps and tone.
string
string
Optional free-text steer (e.g. ‘holiday sale’).

Preview a CRM or CDP account audience

POST /api/v1/campaigns/audience-sources/preview
Resolve a CRM-backed audience source (HubSpot list, Salesforce report/list view, Pipedrive person filter) or a CDP account group right now and return the recipient count plus a ≤25-row contact sample for the wizard preview card. Native Orbit audiences (segments, lists, CSV, manual rosters) are rejected here — use POST /campaigns/audience/preview for those instead.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
Audience source type — a CRM-backed type (hubspot_list, salesforce_report, salesforce_list_view, pipedrive_filter) or cdp_account. orbit_segment is rejected.
string
Provider container reference (list/report/filter id, or the CDP account group_id). Required unless type is orbit_segment.
string (enum: Contact|Lead)
Salesforce object to resolve (Contact or Lead).

Preview a native campaign audience

POST /api/v1/campaigns/audience/preview
Estimate the audience for the campaign wizard before create: gross matching count, a ≤10-row contact sample, and when channel is supplied a net reachability projection that subtracts suppression-list entries and channel opt-outs (frequency-cap shaving is an advisory estimate only). Results are cached for 5 minutes on a hash of the criteria so the wizard can re-render without re-evaluating.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string (enum: all|list|segment|csv|manual)
Audience strategy. Defaults to all.
string
Id of the list or segment when audience_type is list or segment.
string[]
Raw recipients when audience_type is csv.
string[]
Hand-picked contact ids when audience_type is manual.
string
Optional channel — when supplied the response also carries the net reachability projection (suppression + opt-outs + advisory frequency-cap estimate).

Check schedule conflicts for an audience

POST /api/v1/campaigns/check-schedule-conflicts
Advisory pre-flight check for the wizard step that picks scheduled_at: list already-scheduled, running, or paused campaigns that target the same channel and an overlapping audience inside a ±window_hours band (default 72h, max 720h). Read-only — the response never blocks create/update and an empty conflicts array means no fatigue risk.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
Candidate send time to check.
string (enum: all|list|segment|csv|manual)
Audience strategy. Defaults to all.
string
List or segment id when the audience type needs one.
string
required
Campaign channel to check.
integer
Lookaround band in hours (default 72, max 720).
string
Campaign to ignore — pass its id when editing so it does not conflict with itself.

Plan a cross-campaign send schedule

POST /api/v1/campaigns/cross-schedule/preview
Arbitrate a shared hourly frequency-cap budget across up to 100 campaigns: given a spread window, a global cap per hour, and an optional quiet-hour window it returns a per-campaign plan (recommended scheduled_at plus per-slot send counts). Read-only — apply the recommended times through the existing schedule path on each campaign.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
Spread-window start (must not be in the past).
string
required
Spread-window end (must be after window_start).
integer
required
Shared hourly send cap arbitrated across the campaigns.
integer
Optional slot granularity in minutes (1-1440).
object
Optional quiet-hour window excluded from eligible slots.
object[]
required
Campaign ids with optional explicit volume, priority, and pace factor.

Score draft campaign content for deliverability (pre-flight)

POST /api/v1/campaigns/deliverability-lab
Score a draft campaign before you send it. Pass the draft message content and channel in the request body (no saved campaign needed) and get back the content issues that could hurt deliverability — spam-trigger words and risky links — plus a predicted delivery rate for each destination carrier, based on your own historical delivery results. This check is read-only: it never sends your campaign, charges your wallet, or changes anything in your account.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string (enum: sms|mms|whatsapp|email|rcs|viber|…)
required
Campaign channel the draft content targets.
string
Draft message body to score. Defaults to empty string.
string
Email-only subject line.
string (enum: 7d|30d|90d)
Historical lookback window for the carrier delivery baseline. Defaults to 30d.

Register a seed-lab test recipient

POST /api/v1/campaigns/deliverability-seed-lab/recipients
Register one of your own test handsets on the deliverability seed-lab roster (SMS/MMS/RCS). Orbit then scores the actual delivery rate and latency of your real sends to that handset. Returns 409 when the handset is already registered and 422 when the roster is full.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
Handset number, validated and normalized to E.164.
string
required
Friendly label (device, SIM, or tester name).
string (enum: sms|mms|rcs)
Handset channel this recipient tests. Defaults to sms.
string
Expected destination MCCMNC (5-6 digits), when known.
string
Expected operator label.
string
Expected ISO 3166-1 alpha-2 country code.

Generate a campaign draft from a brief

POST /api/v1/campaigns/from-brief
Generate a complete campaign draft from a natural-language brief (8-4000 chars): name, goal, audience rationale, per-channel copy for SMS/RCS/WhatsApp/email/push, a recommended send time, a fallback channel chain, an optional A/B test, and operator warnings. Returns a structured payload only — no campaign is persisted; commit the reviewed draft via POST /campaigns.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
Natural-language campaign brief (8-4000 chars).

Enroll new segment members (internal)

POST /api/v1/campaigns/internal/segment-entry
Internal-only enrollment dispatch POSTed by the segment-refresh worker after a membership tick: resolves running journey campaigns whose trigger is configured on the given segment and enrolls each newly-added contact into them through the same journey-entry path the CDP event router uses. Returns the count of contacts enrolled.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
string[]

Unenroll departed segment members (internal)

POST /api/v1/campaigns/internal/segment-exit
Internal-only exit dispatch POSTed by the segment-refresh worker after a membership tick: un-enrolls contacts that have left the given segment from the journey campaigns whose segment trigger matches, so removed members stop progressing through the journey instead of receiving the remaining steps.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
string[]

Generate a journey draft from a prompt

POST /api/v1/campaigns/journey/from-prompt
Generate a structured draft journey graph from a plain-English intent: an LLM-assisted builder for non-technical operators that returns validated nodes + edges the journey canvas renders unchanged. The draft is NOT persisted — review it, then commit via POST /campaigns. Also returns an ephemeral activation simulation (channel projection, cost preview) when simulation succeeds.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
string (enum: sms|rcs|whatsapp|email|push|voice)[]
Restrict send nodes to channels the tenant has connected; defaults to the standard six-channel set.
string

Simulate a journey graph

POST /api/v1/campaigns/journeys/simulate
Preview a journey graph BEFORE a campaign row exists: given draft nodes/edges and an estimated entry-cohort size, project per-node arrivals, per-channel projected sends and optional cost, terminal outcomes, dead steps, plus optional what-if scenarios that re-run the projection with different entry sizes or branch pass-rates. Read-only — never enrolls a contact, queues a job, or touches the wallet.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
object[]
required
object[]
required
number
required
Estimated entry-cohort size to project against.
object
object[]

Preview campaign cost

POST /api/v1/campaigns/preview-cost
Estimate launch cost for the campaign-create wizard’s review step: the live per-recipient unit price (org override, per-country wholesale rate, or sub-type lane) multiplied by estimated_recipients, plus the platform fallback flag so the screen can show whether an exact or fallback rate was used. Prices through the same billing resolver the send path charges the wallet with, so the preview matches the actual deduction at send time.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string (enum: sms|mms|whatsapp|email|rcs|viber|…)
required
integer
required
string
ISO country code to price for; defaults to the global rate.
string
Pricing sub-type lane (e.g. whatsapp marketing vs utility).

Instantiate a journey template

POST /api/v1/campaigns/templates/{templateId}/instantiate
Clone a prebuilt journey template from the catalog into a new draft campaign (type=‘journey’) in the caller’s tenant. The template’s node + edge graph is serialised onto the campaign so the journey builder re-opens it verbatim; all body fields are optional overrides (name, description, channel, audience). Returns 201 with the created campaign — continue in the journey builder, then launch via POST /campaigns/:id/send.
string
required
Catalog template id, e.g. ‘welcome-series’.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
Campaign display name — defaults to the template’s name.
string
Optional campaign description — defaults to the template’s.
string (enum: sms|mms|whatsapp|email|rcs|viber|…)
Override of the inferred default channel (list filtering + billing reporting); per-node channels in the graph are not mutated.
string (enum: all|list|segment|csv|manual)
Audience strategy override; ‘manual’ is the picker-approved hand-picked roster.
string
Identifier of the chosen list/segment when audience_type is set.

Translate template copy into locales

POST /api/v1/campaigns/templates/translate
Generate one LLM-translated variant per requested BCP-47 locale from a source body (+ optional subject). placeholders, URLs, and phone numbers are copied verbatim; an optional channel hint enforces per-channel length caps (SMS ≤160, push ≤120). Returns a directly-usable LocaleVariantSet — nothing is persisted; the send pipeline later picks each recipient’s variant by their stored language. Review the variants in the composer and commit them via the regular template/campaign write endpoints.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
Source template body to translate.
string
Optional source subject line (email).
string
BCP-47 locale the source is written in; echoed back as the default variant.
string[]
required
BCP-47 target locales, e.g. [‘fr’, ‘pt-BR’].
string (enum: sms|rcs|whatsapp|email|push|voice)
Channel hint enforcing per-channel length norms.
string
Brand tone hint, e.g. ‘formal’ or ‘friendly’.

Update a campaign

PUT /api/v1/campaigns/{id}
Update an existing campaign’s name, message template, audience, schedule, or channel settings. Only campaigns still in draft, scheduled, or paused accept edits — a running or terminal campaign must be paused first. Send only the fields you are changing.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
string
string (enum: blast|drip|journey|ad)
string (enum: sms|mms|whatsapp|email|rcs|viber|…)
string (enum: all|list|segment|csv|manual)
string
string
object
string
integer
boolean
boolean

Set the journey conversion goal

PUT /api/v1/campaigns/{id}/journey/goal
Create or replace the conversion goal for a journey campaign (idempotent upsert). goal_event_type is the event that counts as a conversion (e.g. purchase.completed). conversion_window_hours bounds attribution from first enrollment (0 disables the window; default 168). Only goal-reached events recorded after this can drive the analytics and lift surfaces.
string
required
Resource identifier
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
string
required
Event type that counts as a conversion
object
Optional attribute predicate on the event
number
Attribution window from first enrollment; 0 disables it (unbounded attribution)
string

Update campaign approval policy

PUT /api/v1/campaigns/approvals/settings
Set the org-wide supervisor-approval policy (owner/admin only): flip the require-approval default and/or the audience-size threshold above which every launch is queued for approval. The write patches only the approvals block on the org settings, so sibling settings keys are preserved.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
boolean
required
any
Audience-size threshold above which launches require approval; null clears the threshold.

Update the campaign audience cap

PUT /api/v1/campaigns/audience-cap/settings
Set the org-wide campaign audience cap (owner/admin only): enable the override and pick a maximum audience size inside the platform floor/ceiling band returned by GET. The write touches only the two audience-cap keys, so the sibling approval-policy keys survive. The send path clamps out-of-range sizes back into the band.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
boolean
required
any
Required (and rejected with 422 when absent) when the override is enabled.

Update the default quiet-hours window

PUT /api/v1/campaigns/quiet-hours/settings
Owner/admin: set or clear the org-wide default quiet-hours fallback window for drip and journey sends. When disabled the platform default applies. When enabled, both start_hour and end_hour are REQUIRED and must be recipient-local 24h hours in [0, 23]. This fallback can only narrow the window — the platform TCPA dialing-window guard still applies at send time.
string
Stripe-style idempotency token. Pass a stable, client-generated value (1-255 chars) to dedupe retries on transient timeouts. The same key+credential+path replays the original response for 24h on 2xx (5min on 4xx, 30s on 5xx). Returns 409 if a concurrent request with the same key is already in flight; replayed responses include the Idempotency-Replay: true response header.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.
boolean
required
integer
integer

Delete a campaign

DELETE /api/v1/campaigns/{id}
Permanently delete a campaign. Only draft, cancelled, or completed campaigns can be deleted — abort a running campaign first (POST /campaigns//abort). Deletion also removes the campaign’s variant set; sends that already went out are unaffected.
string
required
Resource identifier
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.

Remove a seed-lab test recipient

DELETE /api/v1/campaigns/deliverability-seed-lab/recipients/{recipientId}
Remove one handset from the deliverability seed-lab roster by recipient id, with the row-locked reducer so concurrent updates cannot drop or duplicate entries. Returns the post-removal roster, or 404 when the id is not on the roster.
string
required
Seed-lab recipient id.
string (enum: true|false)
Sandbox opt-in for Clerk-session-authenticated requests. Set to true to route the call through the test-mode pipeline: no real provider delivery, no credits deducted, response meta.test_mode: true. Ignored for live API keys (dv_live_sk_*) — server-to-server clients must use a test-prefixed key (dv_test_sk_*) to exercise sandbox. Test-prefixed keys unconditionally enable sandbox regardless of this header.