> ## Documentation Index
> Fetch the complete documentation index at: https://clickflare.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# TrafficForce as a Traffic Source

> Track TrafficForce campaigns in ClickFlare, pass site and channel data, and send conversions back to TrafficForce with its S2S postback.

![TrafficForce traffic source template](https://mintcdn.com/clickflare/0jaeWC_DJvLt2SMH/images/integrations/covers/templates/trafficforce.png?fit=max\&auto=format\&n=0jaeWC_DJvLt2SMH\&q=85\&s=0f9ef0de93ddeedd8b1a3eee0f572b25)

TrafficForce (Traffic Force) is a self-serve ad network selling display banners, popunders, native ads, pre-roll video and other formats on desktop and mobile, mostly bought on CPM. This guide sets up TrafficForce as a traffic source in ClickFlare. It covers passing TrafficForce's click data into your reports and sending conversions back to TrafficForce, so its conversion stats, ROI and auto-optimization work from the same data as yours.

You do everything from the **campaign editor**. The TrafficForce traffic source is created inline, without leaving the campaign.

## At a glance

| | |
| - | - |
| **Ad formats** | Display banners, popunders, native, pre-roll video, push and others |
| **Click ID macro** | `{CLICK_ID}`, required for S2S conversion tracking |
| **Conversion tracking** | S2S postback to `delivery.trafficforce.com/conv.php`, or TrafficForce's own pixel |
| **Payout passed back** | No. TrafficForce's postback takes only the click ID. Earnings per conversion are set in TrafficForce. |
| **Multiple events** | One conversion type per ad group |
| **Cost** | Not passed. The template has no cost row. Use the **CPC** cost model. |
| **Conversion API** | No |

## How it works

**1. TrafficForce sends the click**

A visitor clicks your ad. TrafficForce opens your ClickFlare campaign URL and fills in its macros: the click ID in `cid`, plus the site, channel, campaign, group, ad, keywords, country and language.

**2. ClickFlare stores the TrafficForce click ID**

ClickFlare saves the value of `cid` as the visit's **External ID** and redirects the visitor to your lander or offer.

**3. The conversion reaches ClickFlare**

Your affiliate network or store posts the conversion back to ClickFlare, matched on the ClickFlare click ID.

**4. ClickFlare posts it back to TrafficForce**

ClickFlare fires the TrafficForce postback, replacing `{external_id}` with the stored TrafficForce click ID. TrafficForce matches it to the original click and updates its conversion and ROI stats.

> [!NOTE]
>
> The mirror to keep straight: in the **campaign URL** you write *ClickFlare's* parameter (`cid`) and *TrafficForce's* macro (`{CLICK_ID}`). The template does this for you. In the **postback URL** you write *TrafficForce's* parameter (`click_id`) and *ClickFlare's* token (`{external_id}`).

## Before you start

* **Set up your own tracking domain.** Run the campaign and the postback on your own custom domain. Shared domains get flagged by networks and blocked by browsers. See [Custom Domains](https://clickflare.com/docs/en/settings/custom-domains.md).
* **Have an offer ready in ClickFlare**, and its affiliate network set up to post conversions back to ClickFlare. See [Creating an Offer](https://clickflare.com/docs/en/tracking/creating-an-offer-1.md) and [Adding an Affiliate Network](https://clickflare.com/docs/en/tracking/adding-an-affiliate-network.md).
* **Know your average payout.** TrafficForce does not read the payout from the postback. You enter it once, as **Earnings per conversion**, in TrafficForce's conversion settings.
* **Decide which conversion TrafficForce should receive.** TrafficForce's auto-optimization uses the conversions you send it. If your funnel has several steps (lead, then sale), pick the one that matters. See [Choosing the event to send](#choosing-the-event-to-send).

***

## Step 1 – Create the campaign and the TrafficForce traffic source

1. Go to **Campaigns** and click **New**.
2. In **Traffic Source**, open the dropdown and click **+ New Traffic Source**.
3. Type `trafficforce` in the search box and select the **TrafficForce** template.
4. Enter a **Name**, for example `TrafficForce`.
5. Leave **Cost currency** on **USD** unless your TrafficForce account is billed in another currency.

The template fills in the **Parameters** table for you:

| Name | TS Parameter | TS Token (TrafficForce macro) | ClickFlare Token | What it carries |
| - | - | - | - | - |
| externalId | `cid` | `{CLICK_ID}` | `{external_id}` | TrafficForce's click ID. Required for the postback. |
| Site ID | `site_id` | `{site_id}` | `{trackingField1}` | The ID of the site the ad ran on |
| Channel ID | `channel_id` | `{channel_id}` | `{trackingField2}` | The ID of the ad channel (the placement on the site) |
| Campaign ID | `campaign_id` | `{campaign_id}` | `{trackingField3}` | Your TrafficForce campaign ID |
| Group ID | `group_id` | `{group_id}` | `{trackingField4}` | Your TrafficForce ad group ID |
| Ad ID | `ad_id` | `{ad_id}` | `{trackingField5}` | The ad that was shown |
| Keywords | `keywords` | `{keywords}` | `{trackingField6}` | The keywords the ad was matched on |
| Country | `country` | `{v_country}` | `{trackingField7}` | The visitor's country |
| Language | `lang` | `{v_language}` | `{trackingField8}` | The visitor's language |
| Site Name | `site_name` | `{site_name}` | `{trackingField9}` | The name of the site the ad ran on |
| Channel Name | `channel_name` | `{channel_name}` | `{trackingField10}` | The name of the ad channel |

![The TrafficForce template's Parameters table in ClickFlare, with TrafficForce's macros pre-filled](https://mintcdn.com/clickflare/0jaeWC_DJvLt2SMH/images/integrations/templates/trafficforce/parameters.png?fit=max\&auto=format\&n=0jaeWC_DJvLt2SMH\&q=85\&s=f35f70d45da3b389a3851cc6ee6b102d)

Each tracking field becomes a column you can group reports by. `site_id` and `channel_id` are the ones you will use most: they tell you which sites and placements convert, so you can exclude or bid up channels in TrafficForce. The name rows (`site_name`, `channel_name`) make the same reports readable without looking IDs up.

Note the difference in case. The click ID macro is upper case, `{CLICK_ID}`, while the other TrafficForce macros are lower case. Type them exactly as shown.

> [!WARNING]
>
> Don't change or remove the `externalId` row. Without `cid={CLICK_ID}` in the campaign URL, ClickFlare has no TrafficForce click ID to send back, and TrafficForce cannot match any conversion.

### Adding more TrafficForce macros

TrafficForce offers more macros than the template uses. Useful ones to add with **Add Parameter**:

| Name | TS Parameter | TS Token | What it carries |
| - | - | - | - |
| Campaign Name | `campaign_name` | `{campaign_name}` | Your campaign's name |
| Group Name | `group_name` | `{group_name}` | Your ad group's name |
| Ad Name | `ad_name` | `{ad_name}` | The ad's title |
| Browser | `browser` | `{v_browser}` | The visitor's browser |
| OS | `os` | `{v_os}` | The visitor's operating system |
| Device | `device` | `{v_device}` | The visitor's device |
| Carrier | `carrier` | `{v_carrier}` | The visitor's mobile carrier |

Click **Add Parameter**, give the row a name and parameter, and enter the TrafficForce macro as the **TS Token**. ClickFlare assigns the next free tracking field. The template already uses ten tracking fields, so you have ten left.

## Step 2 – Set up the postback

The postback is what sends conversions to TrafficForce. It lives on the traffic source, so every campaign that uses this TrafficForce traffic source sends conversions the same way.

### TrafficForce's postback format

TrafficForce registers server-to-server conversions at one URL:

```text theme={null}
http://delivery.trafficforce.com/conv.php?click_id=<STORED_CLICK_ID>
```

`<STORED_CLICK_ID>` is the value TrafficForce put into `{CLICK_ID}` on the click. Your tracker stores it and sends it back. Nothing else goes in the URL: no payout, no account ID, no event name.

### Add it to the traffic source in ClickFlare

1. Back in the **New Traffic Source** form, scroll to **Passing conversion info to traffic source**.
2. Turn on **Traffic source postback URL**. The template's postback appears:

```text theme={null}
http://delivery.trafficforce.com/conv.php?click_id={external_id}
```

It already sends the click ID as ClickFlare's `{external_id}` token, in TrafficForce's `click_id` parameter. There are no placeholders to replace.

3. In the dropdown on the left, choose the ClickFlare event that should fire the postback. Keep **Conversions** to send every conversion. If your final action is a custom conversion (for example `purchase`), choose that instead.
4. Click **Save**. You are back in the campaign editor with the TrafficForce traffic source selected.

![The Traffic source postback URL switched on, showing the TrafficForce template's postback](https://mintcdn.com/clickflare/0jaeWC_DJvLt2SMH/images/integrations/templates/trafficforce/postback.png?fit=max\&auto=format\&n=0jaeWC_DJvLt2SMH\&q=85\&s=51d4a80f9eca0b42ea2e9859114fc7ad)

> [!WARNING]
>
> Don't add `&payout={payout}` or similar to the postback. TrafficForce's conversion URL only reads `click_id`. Revenue in TrafficForce's stats comes from the **Earnings per conversion** value you set in TrafficForce (Step 4), not from ClickFlare.

To learn what each postback token does, see [How to Configure a Traffic Source S2S Postback URL](https://clickflare.com/docs/en/tracking/how-to-configure-a-traffic-source-s2s-postback-url.md).

## Step 3 – Finish the campaign and copy its URL

1. Name the campaign.
2. Set the **Cost Model** to **CPC** and enter your cost per visit. The template doesn't pass cost. See [Cost](#cost).
3. Choose **Redirect** or **Direct** tracking. Redirect is the usual choice for TrafficForce's banner and popunder traffic.
4. Click **Next** and, on **Destination**, add your lander (optional) and your offer.
5. Save, open **Tracking**, select your own tracking domain and copy the **campaign URL**.

The campaign URL already contains every TrafficForce macro from the template, for example `cid={CLICK_ID}`, `site_id={site_id}` and `channel_id={channel_id}`.

If you use a lander, its call-to-action must link to the ClickFlare **click URL**, not to the offer directly. Otherwise the visit reaches the offer without a ClickFlare click ID, and the conversion cannot be traced back to TrafficForce.

See [Creating a Campaign in ClickFlare](https://clickflare.com/docs/en/campaigns/creating-a-campaign-in-click-flare.md).

## Step 4 – Create the campaign in TrafficForce

TrafficForce sets conversion tracking per ad group, not per account. You turn it on in the group's settings and describe the conversion there.

1. In TrafficForce, create a campaign and an ad group as usual: format, targeting, bid.
2. Paste the ClickFlare campaign URL as the ad's click URL.
3. In the ad group's settings, find the conversion section and turn on **Enable Conversion Tracking**. TrafficForce's help places these settings under **Ad Management → Manage Ads** (creating or editing the group) and **Ad Management → Conversions**. Newer layouts show it as a conversion postback section in the ad group setup step.
4. Fill in the conversion fields:

| Field | What to enter |
| - | - |
| **Action Name** | A name for the conversion, for example `Sale` |
| **Tracking Purpose** | The conversion goal |
| **Max spent per conversion** | The most you will pay for a conversion. TrafficForce uses it to judge which conversions count as successful. |
| **Earnings per conversion** | Your average payout. TrafficForce uses it to calculate ROI in its stats, because the postback does not carry payout. |
| **Tracking Period** | How many days after the click a conversion still counts |
| **Max conversions per click** | Leave on 1 unless your offer can convert several times per click |

5. Save the group and submit it.

You don't need TrafficForce's tracking code (**Get Tracking Code**). That is the pixel route, for advertisers without a tracker. With ClickFlare, conversions arrive through the S2S postback.

Paste the URL exactly as ClickFlare gives it. TrafficForce replaces each macro in braces when the ad is clicked.

## Step 5 – Test the integration

TrafficForce does not document a test conversion tool, so test with a click.

1. Open the ClickFlare campaign URL in a browser, replacing `{CLICK_ID}` with a test value, for example `cid=test123`.
2. In ClickFlare, open the campaign's report and check that the visit shows `test123` as its External ID.
3. Complete the offer, or post a test conversion to ClickFlare for that click.
4. Go to **Logs → Postback Status** and filter by the campaign. You should see a request to `delivery.trafficforce.com/conv.php?click_id=test123`.

A fake click ID proves ClickFlare builds and sends the postback correctly. It won't show in TrafficForce, because TrafficForce never issued it. Once the ad group gets real clicks, the first real conversion should appear in TrafficForce's stats, and its ROI should update.

Once conversions arrive reliably, you can turn on **Enable Auto-Optimization** in TrafficForce. It then favours the ad with the most conversions instead of the best CTR.

### TrafficForce's own postback ping

TrafficForce can also send a postback ping *to* your system when it registers a conversion, with tokens such as `{CAMPAIGN}`, `{GROUP}`, `{AD}`, `{PROFIT}`, `{SITE}` and `{CHANNEL}`. That is the opposite direction, for advertisers who track conversions in TrafficForce. With ClickFlare you don't need it. Leave it empty.

***

## Choosing the event to send

TrafficForce's postback has no event or goal parameter. Every postback it receives counts as a conversion of the ad group's **Action Name**. If your funnel has several steps, send TrafficForce only the one it should optimize on.

1. In ClickFlare, create a [custom conversion](https://clickflare.com/docs/en/settings/custom-conversions.md) for each step, for example `lead` and `purchase`.
2. On the TrafficForce traffic source, map the postback to the step TrafficForce should learn from, for example `purchase`.
3. In TrafficForce, set **Earnings per conversion** to the payout of that step.

Earlier steps still show in ClickFlare. They just don't reach TrafficForce.

> **Sending more than one event**
>
> You can click **+ Another postback URL** and map a second ClickFlare event to the same TrafficForce postback. TrafficForce then counts both as the same conversion, so raise **Max conversions per click** above 1, or it ignores the second one. Its conversion count and ROI then mix the two steps. Do this only if that is what you want.

> **Filtering which conversions are sent**
>
> To send a postback only for some conversions, for example only those above a certain payout, use **Event filter** under the postback to add conditions.

## Cost

The template does not pass cost. It has no Cost row, and TrafficForce does not document a cost macro for the click URL.

TrafficForce sells mostly on CPM. Set the campaign's **Cost Model** to **CPC** and enter your CPM bid divided by 1,000 as the cost value. For example, a 2.00 CPM bid becomes 0.002 per visit. For popunders this is close, because one impression is roughly one visit. For banners and native, where only a fraction of impressions are clicked, divide your TrafficForce spend by its clicks instead, and update the value as your CTR changes.

> [!NOTE]
>
> Don't use **Not Tracked** with this template. With no cost in the URL and no cost integration, ClickFlare records zero cost and every campaign looks profitable.

When the recorded spend differs from your TrafficForce spend, correct it with a [manual cost upload](https://clickflare.com/docs/en/settings/manual-cost-upload.md). See [Cost Models](https://clickflare.com/docs/en/core-platform-concepts/cost-models.md) and [How to Set Up Traffic Source Cost Tracking](https://clickflare.com/docs/en/tracking/how-to-setup-traffic-source-cost-tracking.md).

## Delayed revenue

If you run search arbitrage (RSOC or AFD) behind TrafficForce, the feed reports revenue hours or days after the click. ClickFlare can send a postback once that revenue arrives, but TrafficForce only receives the conversion, not the amount. See [Sending Delayed Revenue to Traffic Sources](https://clickflare.com/docs/en/advanced-tracking-configuration/how-to-send-delayed-revenue-to-traffic-sources.md).

***

## Troubleshooting

> **Conversions show in ClickFlare but not in TrafficForce**
>
> * **Traffic source postback URL** is off on the TrafficForce traffic source.
> * **Disable sending postbacks to traffic source** is on in the campaign.
> * **Enable Conversion Tracking** is off on the TrafficForce ad group.
> * The conversion happened after the ad group's **Tracking Period**.
> * The postback is mapped to a different event than the one the conversion logged. Check **Logs → Event Logs** to see which event was recorded.
> * Check **Logs → Postback Status**: a failed request shows the status code TrafficForce returned.

> **The postback goes out with an empty click\_id**
>
> * The ad's click URL in TrafficForce is missing `cid={CLICK_ID}`, or the macro was edited. It must be upper case, as in the template. Copy the URL from ClickFlare again.
> * The `externalId` row was edited or removed from the traffic source.

> **TrafficForce shows conversions but the wrong revenue**
>
> TrafficForce calculates revenue from **Earnings per conversion** on the ad group, not from ClickFlare. Update that value when your payout changes. ClickFlare's own reports always use the real payout.

> **Cost is zero in ClickFlare**
>
> The campaign's Cost Model is **Not Tracked**. The template passes no cost, so set the model to **CPC** with a cost per visit. See [Cost](#cost).

> **Site or channel columns are empty**
>
> The macros were not replaced, usually because the URL was edited or pasted somewhere TrafficForce doesn't process macros. Paste the campaign URL from ClickFlare unchanged. See [Traffic Source Tokens Arriving Empty](https://clickflare.com/docs/en/troubleshooting/tokens-arriving-empty.md).

For the general checklist, see [Conversions not showing](https://clickflare.com/docs/en/troubleshooting/conversions-not-showing.md).

***

**FREQUENTLY ASKED QUESTIONS**

> **Q1:** Can I use the same TrafficForce traffic source for all my TrafficForce campaigns?

**A1:** Yes. The postback is set once on the traffic source and every campaign using it sends conversions the same way. Conversion settings such as **Earnings per conversion** live on each TrafficForce ad group, so set them per group.

> **Q2:** Why is it `cid` in the campaign URL and `click_id` in the postback?

**A2:** They are two halves of the same value. ClickFlare reads TrafficForce's click ID from its own `cid` parameter. TrafficForce expects it back in its own `click_id` parameter. Change neither.

> **Q3:** Can ClickFlare send the payout to TrafficForce?

**A3:** No. TrafficForce's conversion URL only accepts the click ID. Enter your payout as **Earnings per conversion** in TrafficForce.

> **Q4:** Should I use Redirect or Direct tracking with TrafficForce?

**A4:** Redirect is the usual choice and works with every TrafficForce format. Use Direct only if TrafficForce must see your lander's domain as the destination. See [Direct Campaign Tracking](https://clickflare.com/docs/en/campaigns/direct-campaign-tracking.md).

> **Q5:** Do I need TrafficForce's conversion pixel as well?

**A5:** No. The pixel and the S2S postback do the same job. Use the postback, because it fires from ClickFlare's server and doesn't depend on cookies in the visitor's browser.

## Related

> **[Traffic source postbacks](https://clickflare.com/docs/en/tracking/how-to-configure-a-traffic-source-s2s-postback-url.md)**
>
> Every token you can use in a postback.

> **[Custom conversions](https://clickflare.com/docs/en/settings/custom-conversions.md)**
>
> Split leads and sales into separate events.

> **[Cost models](https://clickflare.com/docs/en/core-platform-concepts/cost-models.md)**
>
> How CPC, CPA and RevShare costs are calculated.

> **[Conversions not showing](https://clickflare.com/docs/en/troubleshooting/conversions-not-showing.md)**
>
> The general checklist when postbacks don't arrive.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.