Skip to main content

← All docs

CPA postback connector

One endpoint accepts conversions from any affiliate network. Each postback is matched to the partner via the click ID, then becomes a deal with value and commission. Supported out of the box: dr.cash, ClickBank, MaxBounty, Advidi, and a generic preset for anything else.

How it works

  1. Visitors click your /ref/<slug>link and the network substitutes the per-click ID (e.g. the tcr).
  2. The network fires a postback to the URL below when the lead or order converts.
  3. EdenClick matches the click ID, and creates a deal for the partner — idempotently, so repeated pings update the same deal.

Endpoint

GET/POST https://edenclick.pamanix.workers.dev/api/v1/postbacks?network=<preset>&...&ip=<your-ip>

Add network=clickbank,maxbounty,advidi, orgeneric. Omittingnetwork defaults to generic, which reads the same fields dr.cash sends. Include the click ID so the conversion is attributed to the right partner.

Network presets

NetworkClick IDStatusPayoutOrder / Offer
ClickBankcbfid / affidtransactionTypeamountreceipt / productTitle
MaxBountyaff_substatuspayoutorderId / offer
Advidiaff_substatuspayoutsubid / offer
Genericsub1 / aff_sub / clickid…statuspayout / payment / amountuuid / orderId / receipt…

Each preset reads the first non-empty value for its click ID, payout, order, and offer parameters, so your network's existing postback fields work without rewriting.

Status mapping

Wonapproved, accepted, sale, paid, billed, completed… — deal with value + commission
Lostrejected, cancelled, chargeback, refund, trash… — kept for the record
Lead Inhold / anything else — value 0

For CPA networks the payout is the affiliate commission, so commission = payout on approved conversions. ClickBank reports the merchant sale amount instead, so its commission is resolved from the attributed link or partner rate.