Skip to main content
POST
Create a campaign

Authorizations

Authorization
string
header
required

Workspace API key, e.g. sa_live_…. Scopes: read / write / track / *.

Body

application/json
name
string
required
Required range: x >= 1
attribution_model
enum<string>
default:last_click
Available options:
last_click,
first_click
status
enum<string>
default:active
Available options:
active,
paused
join_mode
enum<string>

Who can join. anyone makes a membership active right away; approve means you approve each request; invite hides the campaign from affiliates outside it, who can't join or ask. You add people yourself, or auto_enrol adds them, and they're active. The default campaign can't be invite only. Wins over auto_approve when both are sent.

Available options:
anyone,
approve,
invite
auto_approve
boolean

Who can join. true lets anyone join; false means you approve each new affiliate. It decides signups while this is the default campaign, which is where new signups land, and on any campaign it decides whether an affiliate added automatically (auto_enrol) is active right away or waits for your approval. Omit to leave it unset (anyone).

auto_enrol
boolean

Add every new affiliate to this campaign automatically, on top of their main campaign. Turning it off removes no one.

enrol_existing
boolean
default:false

With auto_enrol, also add your current affiliates now.

make_default
boolean
default:false

Make this the default campaign, where new signups land. Your first campaign always becomes the default.

destination_url
string

Where referral links land (https). The dashboard requires this before a campaign can go live - API-created campaigns without it produce links with no landing page.

ref_param
string

Referral-link query parameter (e.g. via, ref, aff).

Response

Created campaign

object
string
Example:

"campaign"

data
object