> ## 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.

# Codefuel (Perion) Integration Guide

> Integrating CodeFuel to ClickFlare

Thanks to ClickFlare's API integration with Codefuel, you'll be able to have conversions and revenue accurately pulled automatically into ClickFlare.

The revenue and conversions are pulled with a frequency of every hour for 3 days, from the moment that the conversion happens. So you're assured to always have the most up-to-date revenue

In this article, we'll go over the step-by-step process of setting up the API Integration with CodeFuel.

**What you'll need for the integration:**

* An active CodeFuel Account.
* An active ClickFlare Account.
* Your CodeFuel *Client ID and Client Secret.*

**Adding the Codefuel integration to ClickFlare**.

To add CodeFuel integration to your ClickFlare account, begin by accessing the **Integrations Menu,** found in the *left sidebar.*

<img src="https://mintcdn.com/clickflare/HWEFUWc8ESwPCjai/images/help-center/05-integrations/04-revenue-stream-integrations/07-codefuel-perion-integration-guide-01.png?fit=max&auto=format&n=HWEFUWc8ESwPCjai&q=85&s=bf27be72885d89b978de449b91c5f1db" alt="To add CodeFuel integration to your ClickFlare account, begin by accessing the Integrations Menu, found in the left…" width="246" height="344" data-path="images/help-center/05-integrations/04-revenue-stream-integrations/07-codefuel-perion-integration-guide-01.png" />

* Under *Revenue Stream*, click **Add Integration.**

<img src="https://mintcdn.com/clickflare/HWEFUWc8ESwPCjai/images/help-center/05-integrations/04-revenue-stream-integrations/07-codefuel-perion-integration-guide-02.png?fit=max&auto=format&n=HWEFUWc8ESwPCjai&q=85&s=6c2b4c7cdff3603916cc497ba6de7438" alt="Under Revenue Stream, click Add Integration" width="1792" height="171" data-path="images/help-center/05-integrations/04-revenue-stream-integrations/07-codefuel-perion-integration-guide-02.png" />

* Choose the CodeFuel template
* Give your new integration a N**ame**.

<Info>
  Note: Have your integrations' connection info ready before proceeding to connect it with ClickFlare.
</Info>

* Enter your **Client ID** and your **Client Secret**.
* Move on to choosing the **custom conversion** you want to attribute the conversion event to.

  <Tip>
    To learn how to add a custom conversion in ClickFlare, follow our article [here](/docs/en/settings/custom-conversions).
  </Tip>

<img src="https://mintcdn.com/clickflare/HWEFUWc8ESwPCjai/images/help-center/05-integrations/04-revenue-stream-integrations/07-codefuel-perion-integration-guide-03.png?fit=max&auto=format&n=HWEFUWc8ESwPCjai&q=85&s=dc2db88094b4d35b2b4b11bcbca52af0" alt="To learn how to add a custom conversion in ClickFlare, follow our article here" width="814" height="450" data-path="images/help-center/05-integrations/04-revenue-stream-integrations/07-codefuel-perion-integration-guide-03.png" />

<Info>
  Note: In order for the integration to work, you have to send the \{cf\_click\_id} to the "gclid" parameter (check offer URL example below). That's why you're not giving the option to choose a subid, like for other Feeds.
</Info>

* Lastly, click on **Save.**

  You’ll see the new integration appear under the Revenue Stream Integrations section.

**Offer URL template for CodeFuel:**

```
https://search.automotivepro.co/search?q=shoes&gd=AP1007384&gclid=cf_click_id&subid={cf_click_id}
```

If you want, you can also add the postback directly in the URL, as shown below

`https://www.searchoverus.com/search?q=shoes&gd=AP1007384&pb=https%3A%2F%2Fwww.flarequick.com%3Fclick_id%3D%7Bcf_click_id%7D%26ct%3Dclick`

\*It's advisable to encode the postback as shown above.

**Postback template for CodeFuel**

Alternatively, you can ask your account manager to implement it for you. In case you opt for this solution, share with them the following postback:

`https://www.your_tracking_domain.com/cf/cv?click_id=subid&ct=click`
