Send Sources
Send up to 500 URLs to a campaign. Each accepted URL becomes an outreach opportunity, whether AIclicks found it or your own team did.
curl --request POST \
--url https://api.aiclicks.io/api/v1/outreach/campaigns/5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d/sources \
--header 'Authorization: Bearer ak_live_xxx' \
--header 'Content-Type: application/json' \
--header 'Idempotency-Key: send-to-outreach-batch-0412' \
--data '{
"sources": [
{
"url": "https://www.techradar.com/vpn/best-vpn",
"external_id": "opp_99121",
"target_url": "https://yourbrand.com/vpn",
"anchor_text": "Your Brand VPN"
},
{
"url": "https://www.tomsguide.com/best-picks/best-vpn",
"external_id": "opp_99122",
"origin": "partner",
"notes": "Editor replied in October. Open to a paid update of the streaming section.",
"contact_email": "editor@example.com",
"quoted_price_cents": 45000
},
{
"url": "https://nordvpn.com/blog/best-vpn-for-streaming/",
"external_id": "opp_99123"
}
]
}'
import httpx, os
resp = httpx.post(
"https://api.aiclicks.io/api/v1/outreach/campaigns/5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d/sources",
headers={
"Authorization": f"Bearer {os.environ['AICLICKS_API_KEY']}",
"Idempotency-Key": "send-to-outreach-batch-0412",
},
json={
"sources": [
{
"url": "https://www.techradar.com/vpn/best-vpn",
"external_id": "opp_99121",
"target_url": "https://yourbrand.com/vpn",
"anchor_text": "Your Brand VPN",
},
{
"url": "https://www.tomsguide.com/best-picks/best-vpn",
"external_id": "opp_99122",
"origin": "partner",
"notes": "Editor replied in October. Open to a paid update of the streaming section.",
"contact_email": "editor@example.com",
"quoted_price_cents": 45000,
},
]
},
)
resp.raise_for_status()
result = resp.json()["data"]
for item in result["accepted"]:
print("accepted", item["url"], item["opportunity_id"])
for item in result["rejected"]:
print("not accepted", item["url"], item["reason"])
const resp = await fetch(
"https://api.aiclicks.io/api/v1/outreach/campaigns/5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d/sources",
{
method: "POST",
headers: {
Authorization: `Bearer ${process.env.AICLICKS_API_KEY}`,
"Content-Type": "application/json",
"Idempotency-Key": "send-to-outreach-batch-0412",
},
body: JSON.stringify({
sources: [
{
url: "https://www.techradar.com/vpn/best-vpn",
external_id: "opp_99121",
target_url: "https://yourbrand.com/vpn",
anchor_text: "Your Brand VPN",
},
],
}),
},
);
const { data } = await resp.json();
console.log(data.accepted.length, "accepted,", data.rejected.length, "not accepted");
{
"data": {
"campaign_id": "5e7a1c2d-8b4f-4a6e-9d3c-1f2e3a4b5c6d",
"accepted": [
{
"url": "https://www.techradar.com/vpn/best-vpn",
"external_id": "opp_99121",
"opportunity_id": "0b9c8d7e-6f5a-4b3c-8d2e-1a0b9c8d7e6f",
"status": "processing"
},
{
"url": "https://www.tomsguide.com/best-picks/best-vpn",
"external_id": "opp_99122",
"opportunity_id": "1c0d9e8f-7a6b-4c5d-9e3f-2b1c0d9e8f7a",
"status": "processing"
}
],
"rejected": [
{
"url": "https://nordvpn.com/blog/best-vpn-for-streaming/",
"external_id": "opp_99123",
"reason": "competitor_domain",
"detail": "nordvpn.com is a tracked competitor of this domain."
}
]
},
"generated_at": "2026-12-04T10:15:03.771Z"
}
{
"detail": "Campaign is finished and does not accept new sources."
}
{
"detail": [
{
"type": "too_long",
"loc": ["body", "sources"],
"msg": "List should have at most 500 items after validation, not 501"
}
]
}
Sends a list of pages to a campaign for outreach. This is the endpoint behind a "Send to outreach" button in your product.
Each URL becomes one opportunity. You can send:
- Pages that AIclicks found — for example, the sources from the Get Mentioned recommendations or from
GET /api/v1/citations. These pages are already cited by AI assistants for the prompts of the client. - Opportunities that your own team found — any page from your own research, your own tool or your current vendor. Set
origin: "partner"and add what you already know, such as a contact or a price you were quoted. AIclicks runs the same quality checks, contacts the publisher and treats the page exactly like its own finds.
The call returns at once. Each accepted URL starts as processing, and you get an opportunity.created event for it. When you send quoted_price_cents, it becomes the estimated_price_cents of the opportunity.
Sending sources is free. Money is reserved only when you approve an opportunity, and spent only when its link is live.
Path parameters
UUID of the campaign. Use one campaign per client.
Authorizations
Optional unique string. A repeat request with the same key within 24 hours returns the first result. AIclicks also removes duplicates by URL: a URL that is already open in the campaign is returned in rejected with reason: "duplicate".
Body parameters
1 to 500 sources. Each source is an object with the fields below.
The page where the client should be mentioned. Absolute http or https URL, max 2,048 characters.
Your own ID for this opportunity. AIclicks returns it on the opportunity and on every webhook event.
aiclicks (default) when the page came from AIclicks data, or partner when your team found it.
The client page that the new link must point to. Defaults to criteria.brand_reference_url of the campaign.
The anchor text you prefer. The publisher can change it. AIclicks reports the final anchor in placement.anchor_text.
Free text for the AIclicks outreach team, max 2,000 characters. For example, the history of an earlier contact. It is stored as the first entry of the opportunity history.
A publisher contact that you already know. AIclicks contacts this person first.
A price that the publisher already quoted to you. AIclicks uses it as the ceiling for the negotiation.
A price cap for this one page. It overrides max_link_price_cents of the campaign.
Response
The sources that became opportunities. Each item has url, external_id, opportunity_id and status (processing).
The sources that did not become opportunities. Each item has url, external_id, reason and detail. reason is one of:
duplicate— the URL is already open in this campaign.previously_declined— you declined this URL in this campaign before.competitor_domain— the page is on the site of a tracked competitor.excluded_domain— the domain, or a parent domain, is incriteria.excluded_domains.below_min_domain_rating— the domain rating is known and belowcriteria.min_domain_rating.invalid_url— the value is not an absolutehttporhttpsURL.
Checks that need a person, such as traffic and competitor content, run after the call. A page that fails them becomes declined later, with a decline_reason.
Errors
The campaign is finished.
The campaign does not exist.
The list is empty or has more than 500 sources, or a field has the wrong type or length. The loc field shows where. A URL that is not valid does not fail the call: it comes back in rejected with reason: "invalid_url".