Skip to main content
n8n and ClickFlare Integration n8n is a workflow automation tool you can use in the cloud or host on your own server. A workflow is a chain of nodes: a trigger node starts it and the nodes after it read, change and send data. Two core nodes connect n8n to ClickFlare: the Webhook node, which receives requests, and the HTTP Request node, which calls any URL or API. The connection works in both directions:
  • ClickFlare → n8n. ClickFlare’s Custom Webhook sends an event (a conversion, a purchase, a click) to an n8n Webhook node. The workflow stores it, enriches it or passes it on.
  • n8n → ClickFlare. An HTTP Request node posts a conversion to ClickFlare’s postback endpoint as JSON, so any app or webhook n8n receives can report conversions. The same node calls the ClickFlare REST API, so one workflow can catch an event, check a report and act on it.
Because n8n can run on your own infrastructure, it’s a good fit when you want conversion data to stay on servers you control.

At a glance

To set up n8n with ClickFlare:
  1. Add a Webhook node.
  2. Map the event in ClickFlare.
  3. Test, then publish.
  4. Post conversions to ClickFlare.
  5. Call the ClickFlare API.

How the data flows


What you’ll need

  • A ClickFlare account with your own tracking domain for postbacks. See Tracking domains.
  • An n8n instance, cloud or self-hosted. A self-hosted instance must be reachable from the internet over HTTPS for ClickFlare to call it.
  • For n8n → ClickFlare: the click ID stored somewhere the trigger can return it.
  • For API calls: an API key from Settings → API Keys.

Send ClickFlare events to n8n

1

Add a Webhook node

Create a workflow and add a Webhook node as the trigger. Set:
  • HTTP Method: POST, to match the ClickFlare mapping. GET works too if you send values in the URL only.
  • Path: n8n fills in a random path. You can replace it with something readable, such as clickflare-conversions.
  • Authentication: Header auth is a good choice. Create a credential with a header name and a secret value. You’ll add the same header in ClickFlare.
  • Respond: Immediately is enough. ClickFlare only needs to know the request arrived.
2

Add a Webhooks integration in ClickFlare

Go to Integrations, click Conversion API → New integration and choose Webhooks. Pick the Workspace and give it a Name.
3

Map the event

Under Event Type Mapping, pick the ClickFlare Event, set Request Method to POST and paste the n8n URL as the Webhook URL. Add the values you need with macros, in the URL or the body, for example:
Open Advanced configuration and add the header you set on the Webhook node. To send only some events, click Add Conditions. Click Next, then Save.A ClickFlare Webhooks integration for n8n: the Sale event, POST, the n8n webhook URL and a JSON body with click_id, payout and campaign macros and an auth header under Advanced configuration
4

Test with the test URL

n8n shows two URLs at the top of the Webhook node: Test URL and Production URL. For a first test, put the test URL in ClickFlare, click Listen for Test Event in n8n and fire an event. The data appears in the node, and you can build the rest of the workflow from it. Values sent in the URL arrive under query, values sent in the body under body.
5

Publish and switch to the production URL

n8n registers the production URL only when you publish the workflow. Publish it, then replace the test URL in ClickFlare with the Production URL. Production runs don’t show data in the editor: open the workflow’s Executions tab to see them.
The test URL only works while n8n is listening for a test event. If ClickFlare still points at it after you publish, events are lost.
Other Webhook node options worth knowing: IP(s) Allowlist limits who can call the URL, and Ignore Bots drops link previewers and crawlers. The maximum payload is 16MB. Self-hosted instances can change it with N8N_PAYLOAD_SIZE_MAX.

Report conversions from n8n to ClickFlare

ClickFlare accepts conversions as a JSON POST on the same endpoint as its postback:
The body keys are cf_click_id (required), payout, ct, txid and param1 to param20. ct must match a custom conversion created under Settings → Custom Conversions. See Custom conversions.
1

Set up the trigger

Use an app trigger node, or a Webhook node if the platform sends its own webhooks, as in the Hotmart and PartnerStack guides. The click ID must be in the data: pass {cf_click_id} in the offer or lander URL and have the platform store it.
2

Add an HTTP Request node

Set:Then write the body with expressions that point at the trigger’s fields:
This example maps a PartnerStack reward. n8n reads nested fields and does the math inline, so a platform’s own payload needs no extra nodes.
3

Skip events you don't want

Put an If or Filter node before the HTTP Request node, for example to skip test events or statuses you don’t track.
4

Test the node

Run the node with a real click ID from a recent ClickFlare click. The conversion should appear on that campaign and in Logs → Event Logs.
Need several conversions on the same click kept apart? Send a unique txid in the body, as in the example above: a different txid adds a conversion, the same txid replaces the earlier one. A GET to /cf/cv with click_id, payout, ct and txid under Send Query Parameters works too. See Postback parameters.

Call the ClickFlare API from n8n

1

Create a Header Auth credential

In an HTTP Request node, set Authentication to Generic Credential Type, then Header Auth. Create a credential with Name api-key and Value your key from Settings → API Keys. n8n adds the header to every request that uses the credential. See API overview.
2

Import the request

The HTTP Request node can import a curl command. Click Import cURL and paste:
Then remove the pasted header and select the Header Auth credential instead, so the key isn’t stored in the node.
3

Pull a report

For report data, POST to https://public-api.clickflare.io/api/report with a JSON body:
Every breakdown in groupBy must also be in metrics. conversionTimestamp (visit or postback) and currency are optional. For long reports, turn on the node’s Pagination option and raise page until no rows come back.
Example: ROI alert. A Schedule Trigger runs every hour, the HTTP Request node pulls today’s campaign report, a Filter node keeps campaigns with roi below your floor and a Slack or email node sends the list. A request without the api-key header returns 401.
An API key has the same rights as your account. Keep it in a credential, not in node parameters, so it doesn’t end up in exported workflows.

Verify the setup

1

ClickFlare → n8n

Fire an event and open Executions. The run should show the click ID and payout as real values, not the macro text.
2

n8n → ClickFlare

Run the HTTP Request node with a recent click ID. The conversion should appear under the right custom conversion with the right payout.

Troubleshooting

  • ClickFlare points at the test URL. Use the production URL after you publish.
  • The workflow isn’t published, so the production URL isn’t registered.
  • The header in ClickFlare’s Advanced configuration doesn’t match the Webhook node’s Header Auth credential. n8n rejects the request.
  • An IP allowlist on the node blocks ClickFlare.
  • A self-hosted instance isn’t reachable from the internet, or has no valid HTTPS certificate.
  • The expression for cf_click_id returns nothing. Check the path in the input panel: webhook data sits under body.
  • ct doesn’t match a custom conversion exactly.
  • The URL isn’t your tracking domain with /cf/cv.
See Troubleshooting S2S postbacks.
The api-key header is missing or wrong. Check the credential’s name and value, and that the node uses it.

FAQ

Yes, both ways. ClickFlare’s Custom Webhook sends events to an n8n Webhook node, and the HTTP Request node posts conversions to /cf/cv or calls the ClickFlare REST API.
The Production URL, after you publish the workflow. Use the test URL only while you build.
Yes. Set up the webhook on the campaign itself, or use one workflow and a Switch node on the campaign ID you send in a macro. See Custom Webhook.
The MCP server is meant for AI assistants. For fixed automations, the REST API is the simpler route. See ClickFlare MCP.

Custom Webhook

Send any event out

API overview

Keys and endpoints

Zapier

The same with Zapier