darkcore docs
PWAIntegrations

Keitaro integration: create a Traffic Source for darkcore

Create a darkcore source in Keitaro, pass click_id in the Campaign URL, and return the conversion for the matching click_id.

In Keitaro, create a Traffic Source named darkcore.

Follow these steps

1. Create the darkcore Traffic Source in Keitaro

  1. In Keitaro, open Traffic Sources → Create.
  2. Do not choose a Facebook, TikTok, or other ad-network template. Create a custom source called darkcore.
  3. In Parameters, fill in more than External ID. Add the full darkcore mapping:
Keitaro nameParameterPlaceholder
External IDexternal_id{click_id}
Sub Id 1sub1{sub1}
Sub Id 2sub2{sub2}
Sub Id 3sub3{sub3}
Sub Id 4sub4{sub4}
Sub Id 5sub5{sub5}
Sub Id 6sub6{sub6}

If you use more subs, fill sub7–sub10 by the same rule. darkcore supports all ten.

  1. In S2S postback, enter darkcore's postback receiver URL:
https://edge.darkcorepwa.com/p?click_id={external_id}&status={status}&payout={revenue}&transaction_id={tid}
  1. In “Only with statuses”, select the statuses darkcore should receive, usually lead and sale. If your workspace has other conversion types, add their matching aliases first.
  2. Save the source.

2. Create a Campaign in Keitaro

  1. Open Campaigns → Create.
  2. Select the darkcore source you created in Source.
  3. Add your affiliate offers and distribution rules to the Campaign.
  4. Save the Campaign and copy its Campaign URL.

The copied URL must contain every parameter from the source:

https://YOUR_KEITARO_DOMAIN/YOUR_CAMPAIGN?external_id={click_id}&sub1={sub1}&sub2={sub2}&sub3={sub3}&sub4={sub4}&sub5={sub5}&sub6={sub6}

If external_id or a required sub is absent, return to the Traffic Source and click Update parameters in attached campaigns. Without external_id, Keitaro cannot return a conversion; without sub, Keitaro loses traffic context.

3. Add the Keitaro Campaign as an offer in the darkcore stream

In Stream → Tracking links, create a link to the Campaign URL from step 2. Keep {click_id} in the URL as a darkcore macro:

https://YOUR_KEITARO_DOMAIN/YOUR_CAMPAIGN?external_id={click_id}&sub1={sub1}&sub2={sub2}&sub3={sub3}&sub4={sub4}&sub5={sub5}&sub6={sub6}

Now the stream rule takes traffic to a PWA or Direct Link, and its tracking link takes traffic to Keitaro.

One default offer for all Keitaro Campaigns

Create one universal offer and pass the Campaign ID in sub1.

  1. In Offers → Create, add an offer such as Keitaro universal.
  2. In its URL, insert your Keitaro domain and darkcore macros:
https://YOUR_KEITARO_DOMAIN/{sub1}?external_id={click_id}&sub1={sub1}&sub2={sub2}&sub3={sub3}&sub4={sub4}&sub5={sub5}&sub6={sub6}
  1. In Stream → Traffic distribution → Tracking links, create a tracking link without filters, select this offer, and put it last. It becomes the default offer for all traffic not caught by earlier rules.
  2. When launching, put only the required Keitaro Campaign ID or alias in the stream link's sub1:
https://YOUR_STREAM_DOMAIN/?sub1=123

In this example, darkcore sends traffic to https://YOUR_KEITARO_DOMAIN/123.

The universal offer reserves sub1 for the Keitaro Campaign ID or alias. Do not pass an ad-set ID, creative ID, or another value there. Use sub2–sub10 for those.

Before saving, open a real Keitaro Campaign URL and check its form. Replace with {sub1} only the part of the URL that actually contains the Campaign ID or alias. Do not put a full URL into sub1.

Make one test click

  1. Open the exact stream URL that will be used in ads, for example https://YOUR_STREAM_DOMAIN/?sub1=123.
  2. After the PWA or Direct Link, the browser should open https://keitaro.example/123, and its URL must no longer contain {click_id} or {sub1} in braces.
  3. In Keitaro → Logs → Clicks, open that click and compare:
    • External ID equals the click_id for this click in darkcore;
    • Sub Id 1 equals 123;
    • other Sub Ids contain the values passed into the stream.
  4. Send a test conversion in Keitaro. darkcore must show a conversion for the same click_id.

What to fix after the test

What you seeWhat to do
A Keitaro 404 or another error opens instead of the intended CampaignThe stream URL does not have sub1=CAMPAIGN_ID, or the ID in sub1 does not match Keitaro's Campaign URL.
No click in KeitaroConfirm that the default offer is selected in the stream tracking link and that another rule above does not override it.
External ID is emptyThe source must have external_id = {click_id}. After changing it, click Update parameters in attached campaigns.
Sub Id 1 is emptyThe source must have sub1 = {sub1}, and the stream URL must include ?sub1=CAMPAIGN_ID.
A conversion appears in Keitaro but not darkcoreCheck the S2S URL in the source: it must contain click_id={external_id}.
darkcore rejects a conversionIn the source's Only with statuses, keep statuses that match darkcore aliases, such as lead and sale.

On this page