Update Campaign
Launch, pause or finish a campaign, and change its budget, price cap, approval mode or quality rules.
curl --request PATCH \
--url https://api.aiclicks.io/api/v1/outreach/campaigns/5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d \
--header 'Authorization: Bearer ak_live_xxx' \
--header 'Content-Type: application/json' \
--data '{
"budget_cents": 750000,
"max_link_price_cents": 50000,
"criteria": { "excluded_domains": ["nordvpn.com", "expressvpn.com", "surfshark.com"] }
}'
import httpx, os
resp = httpx.patch(
"https://api.aiclicks.io/api/v1/outreach/campaigns/5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d",
headers={"Authorization": f"Bearer {os.environ['AICLICKS_API_KEY']}"},
json={"status": "stopped"},
)
resp.raise_for_status()
print(resp.json()["data"]["status"])
const resp = await fetch(
"https://api.aiclicks.io/api/v1/outreach/campaigns/5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d",
{
method: "PATCH",
headers: {
Authorization: `Bearer ${process.env.AICLICKS_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({ status: "stopped" }),
},
);
const { data } = await resp.json();
console.log(data.status);
{
"data": {
"id": "5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d",
"status": "launched",
"budget_cents": 750000,
"max_link_price_cents": 50000,
"criteria": {
"min_domain_rating": 40,
"min_organic_traffic": 5000,
"exclude_competitors": true,
"excluded_domains": ["nordvpn.com", "expressvpn.com", "surfshark.com"],
"brand_reference_url": "https://yourbrand.com/vpn"
},
"updated_at": "2026-12-04T10:01:12.004Z"
},
"generated_at": "2026-12-04T10:01:12.090Z"
}
{
"detail": "Illegal campaign status transition: finished -> launched"
}
Changes one or more fields of a campaign. Send only the fields you want to change. The response is the full campaign, in the same shape as Get Campaign. The example below shows only some fields.
Status moves:
| From | Allowed to |
|---|---|
planned | launched |
launched | stopped, finished |
stopped | launched |
finished | — |
When a campaign is stopped, AIclicks does not start new outreach. Opportunities that you already approved continue to placement. When a campaign is finished, AIclicks stops all open outreach. Opportunities that you approved and that are not live yet are released by the AIclicks team.
Path parameters
UUID of the campaign.
Body parameters
The new status. See the table above.
A new label.
The new planned total spend. It cannot be lower than spent_cents + reserved_cents.
The new price cap for one link. It applies to quotes that arrive after the change.
The new low-balance alert level.
all or over_cap.
Quality rules. The keys you send replace the old values. Keys you do not send stay the same. New domain rules apply to the sources you send after the change.
Errors
The status move is not allowed, or budget_cents is lower than the money already spent and reserved.
The campaign does not exist.
A value is out of range, for example a negative budget_cents or an unknown status.