S2S / ClickID Tracking

    Cookieless tracking via unique ClickIDs and server-side postbacks — ideal for mobile, apps and maximum tracking reliability.

    ClickID tracking: How it works

    With ClickID tracking, QUALITYCLICK generates a unique ClickID for each click and appends it to the outgoing link. This ID replaces cookie-based attribution and enables cookieless tracking.

    The flow

    1
    Click
    Partner link with ClickID
    2
    Shop
    Store ClickID
    3
    Order
    Customer purchases
    4
    Tracking pixel
    Send back ClickID

    Step 1: Set up click targets with ClickID

    All links under Creatives → Click Targets must contain the ClickID as a URL parameter. Use the placeholder <% CLICKID %>:

    Click target with ClickID
    https://www.your-shop.com/landing?qc_clickid=<% CLICKID %>

    Optionally, you can also include the PartnerID:

    Click target with ClickID and PartnerID
    https://www.your-shop.com/landing?qc_clickid=<% CLICKID %>&qc_pid=<% PID %>

    On click, QUALITYCLICK generates a unique ClickID via the go.cgi and redirects the visitor to your shop. The ClickID is a string of letters, digits and special characters, not a purely numeric sequence. Its length is variable, so provide a field with 255 characters in your shop. Store the ClickID unchanged and pass it URL-encoded to the tracking pixel.

    💡Tip
    The parameter name qc_clickid is a recommendation — you can choose any parameter name (e.g. clickid, affiliate_click etc.). What matters is that your shop correctly receives and stores the value.

    Step 2: Store the ClickID in your shop

    Your shop must read the ClickID from the URL parameter and retain it until the order confirmation. Two options:

    • Session cookie: Store the value in your own cookie or server session
    • URL parameter: Carry the value from page to page as a URL parameter

    Step 3: Pass the ClickID to the tracking pixel

    On the order confirmation page, pass the stored ClickID to the tracking pixel:

    Tracking pixel with ClickID
    https://partner.your-site.com/get_trans.cgi
      ?cpid=1
      &tid=ORD-2026-001
      &clickid=STORED_CLICKID
      &produkt=Sale
      &umsatz=95.50

    Replace STORED_CLICKID with the URL-encoded ClickID from your shop.

    QUALITYCLICK automatically resolves the information from the original click via the ClickID: PartnerID, SubID and CreativeID. This way, the transaction is attributed to the correct partner - without a cookie.

    ⚠️Warning
    If you additionally pass the parameter pid (value from 2), the ClickID is not evaluated and the transaction is attributed to this partner. Without pid, the values from the ClickID take precedence over additionally passed subid and wmid. Only pass parameters you can actually populate with values — when in doubt, leave them out.

    Server-to-Server Tracking (S2S)

    With server-to-server tracking, the get_trans.cgi is not called from the customer's browser (client-side), but from your web server (server-side). The call is technically identical — the same URL with the same parameters. For S2S calls, the IP address, country and browser identifier of your server are stored with the transaction, not those of the customer.

    Advantages of S2S

    • Works even when the customer has disabled JavaScript or images
    • Independent of browser restrictions (ad blockers, cookie blocking)
    • Higher reliability with slow connections or when customers leave the page prematurely

    Recommended strategy: Pixel + S2S as fallback

    We recommend using both methods in parallel:

    1. Client-side pixel (JavaScript or image) on the order confirmation page — captures the transaction instantly in real-time
    2. Server-side S2S call a few seconds later — as a safeguard for cases where the client-side call fails

    If the program's duplicate handling is set to "Filter double transaction IDs" (System → Program management → Edit program), QUALITYCLICK detects duplicates based on the TransactionID (tid) and only creates the transaction once. Parallel operation is only possible without an active auth token (see Securing with an auth token).

    PHP example: S2S call with cURL

    PHP: Server-to-Server call
    <?php
    // S2S postback to QUALITYCLICK after order completion
    $params = [
        'cpid'     => 1,                              // Program ID
        'tid'      => 'ORD-2026-001',                  // Your order number (unique)
        'clickid'  => $_SESSION['qc_clickid'] ?? '',   // Stored ClickID
        'produkt'  => 'Sale',                          // Commission product (exact spelling)
        'umsatz'   => 95.50,                           // Net revenue excl. VAT/shipping
    ];
    $url = 'https://partner.your-site.com/get_trans.cgi?' . http_build_query($params);
    
    // Call with short timeout
    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    curl_setopt($ch, CURLOPT_TIMEOUT, 5);
    curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 3);
    $response = curl_exec($ch);
    curl_close($ch);
    ?>

    cURL example (command line)

    cURL: Server-to-Server call
    curl -s "https://partner.your-site.com/get_trans.cgi?\
    cpid=1&\
    tid=ORD-2026-001&\
    clickid=STORED_CLICKID&\
    produkt=Sale&\
    umsatz=95.50"
    💡Tip
    Set a short timeout (3–5 seconds) for the S2S call so that order processing in your shop is not blocked. After a timeout, check the transaction log to see whether the transaction has arrived; the client-side pixel serves as an additional safeguard.

    Securing with an auth token

    To ensure that only your server can report transactions, you can define an auth token for a partner program. Calls to get_trans.cgi without a valid token are then rejected. The feature is enabled by the QUALITYCLICK team (info@qualityclick.com). The auth token is not available for programs with anchor tracking.

    Once the feature is enabled, you define the token yourself:

    1. Go to System → Tracking Codes and select the partner program
    2. Define a token of at least 16 letters and digits and activate it
    3. Append the token to every call as the parameter auth_token
    S2S call with auth token
    https://partner.your-site.com/get_trans.cgi
      ?cpid=1
      &tid=ORD-2026-001
      &clickid=STORED_CLICKID
      &produkt=Sale
      &umsatz=95.50
      &js=1
      &auth_token=YOUR_TOKEN

    With js=1, the response contains a line of text from which your server can tell whether the transaction was accepted or rejected.

    ⚠️Warning
    The auth token is intended exclusively for server-to-server calls and must never be visible in the browser. Do not include it in a pixel on the order confirmation page or in any other code that is executed in the browser: there it would appear in the source code and anyone could use it to report transactions. Once the token is active, it applies to all calls of the program. In that case, report transactions exclusively server-side.

    Additional parameters

    nocheck — Allow cross-selling

    If cross-selling is disabled for a program, transactions are only created for the commission products the partner has promoted. With the parameter nocheck=1, this check is skipped for the individual call.

    Pixel with nocheck
    https://partner.your-site.com/get_trans.cgi
      ?cpid=1&tid=ORD-2026-001&clickid=STORED_CLICKID&nocheck=1

    The parameter only takes effect if cross-selling is disabled for the program. It is set up by the QUALITYCLICK team (info@qualityclick.com).

    Testing the tracking

    After setup, you should test thoroughly:

    1. Click a creative of the test partner (PartnerID 2)
    2. Check whether the ClickID arrives correctly in the URL parameter
    3. Complete a test order
    4. Check under Transactions → Edit whether the transaction was created with the correct PartnerID
    5. Check under Transactions → Log whether the call appears in the logs

    If the transaction does not appear, check the transaction log: transactions discarded due to missing partner attribution show a dash "-" in the "Saved" column. For transactions rejected for other reasons, the column remains empty. If your call does not appear in the log at all, contact the QUALITYCLICK team.

    Still have questions?
    Our team helps you with the integration – personally and competently.