Targets and Conversions Guide


Targets Overview

What is a Target?

A Target is a destination URL where your traffic will be redirected after passing through campaign flows and filters. Each target represents a final landing page, offer, or another campaign in your traffic distribution system.

Targets are the endpoints in your traffic flow:

Key Features


Creating and Managing Targets

Creating a New Target

  1. Navigate to Targets page from the main menu
  2. Click the Add Target button
  3. Fill in the target details:
    • Name: Descriptive name for the target (e.g., "Offer A - Desktop")
    • Target Type: Choose between:
      • URL: External destination URL
      • Campaign: Redirect to another campaign (campaign chaining)
    • URL (for URL type): The destination URL
    • Campaign (for campaign type): Select the campaign to redirect to
    • Redirect Type: How the redirect will be executed (see Redirect Types)
    • Description (optional): Notes about this target

Target List Features

The Targets page provides:

Editing Targets

  1. Click on a target row to open the detail page
  2. Click the Edit button
  3. Modify the target details
  4. Click Save to apply changes

Deleting Targets

  1. From the Targets list, click the delete icon (trash can) next to the target
  2. Confirm the deletion
  3. Note: Targets assigned to active flows should be reassigned before deletion

Target URL Macros

Target URLs support dynamic macros (placeholders) that are automatically replaced with actual values when traffic is redirected.

Available Macros

Macro Description Example Value
{click_id} Unique click identifier 86f72615f9f2c70d6d0
{campaign_id} Campaign ID 123
{flow_id} Flow ID 456
{target_id} Target ID 789
{country} Visitor's country code (ISO 2-letter) US
{device} Device type desktop, mobile, tablet
{os} Operating system Windows, iOS, Android
{browser} Browser name Chrome, Safari, Firefox
{language} Browser language en, es, fr
{ip} Visitor's IP address 192.168.1.1
{timestamp} Current Unix timestamp 1701234567890
{random} Random number (0-999999) 456789
{date} Current date (YYYY-MM-DD) 2025-12-11
{time} Current time (HH:MM:SS) 14:30:45

Using Macros in Target URLs

Example 1: Basic tracking

https://example.com/offer?click={click_id}&country={country}

Result:

https://example.com/offer?click=86f72615f9f2c70d6d0&country=US

Example 2: Advanced tracking

https://partner.com/track?cid={campaign_id}&clid={click_id}&device={device}&os={os}×tamp={timestamp}

Result:

https://partner.com/track?cid=123&clid=86f72615f9f2c70d6d0&device=mobile&os=iOS×tamp=1701234567890

Example 3: Custom parameters

https://offers.com/page?subid={click_id}&geo={country}&ua={device}&source=tds

Result:

https://offers.com/page?subid=86f72615f9f2c70d6d0&geo=FR&ua=desktop&source=tds

Important Notes


Redirect Types Explained

Simple TDS supports multiple redirect methods to accommodate different use cases and bypass various tracking restrictions.

1. HTTP 302 Redirect (Default)

Type: http

Description: Standard server-side HTTP redirect using 302 status code.

Pros:

Cons:

Best for: General use, most offers, fast redirects

Example Response:

HTTP/1.1 302 Found
Location: https://example.com/offer?click_id=123

2. Meta Refresh Redirect

Type: meta

Description: HTML page with meta refresh tag that redirects after page load.

Pros:

Cons:

Best for: Offers requiring referrer tracking, bypassing certain restrictions

Example HTML:

<!DOCTYPE html>
<html>
<head>
    <meta http-equiv="refresh" content="0;url=https://example.com/offer?click_id=123">
</head>
<body>Redirecting...</body>
</html>

3. JavaScript Redirect

Type: js

Description: JavaScript-based redirect using window.location.

Pros:

Cons:

Best for: Modern browsers, tracking-intensive campaigns

Example HTML:

<!DOCTYPE html>
<html>
<head>
    <script>
        window.location.href = 'https://example.com/offer?click_id=123';
    </script>
</head>
<body>Redirecting...</body>
</html>

4. Blank Referrer Redirect

Type: blank_referrer

Description: Opens target in a new window/tab with blank referrer, then closes original.

Pros:

Cons:

Best for: Offers that reject referrers, privacy-focused redirects

5. cURL Redirect

Type: curl

Description: Fetches the target page server-side and displays it directly.

Pros:

Cons:

Best for: Advanced use cases, content proxying

6. Double Meta Redirect

Type: double_meta

Description: Two-stage meta refresh redirect for maximum referrer manipulation.

Pros:

Cons:

Best for: Highly restrictive offers, advanced tracking requirements

7. Form Submit Redirect

Type: form_submit

Description: Uses an auto-submitted HTML form to redirect.

Pros:

Cons:

Best for: Offers requiring POST data, special tracking scenarios

8. iFrame Redirect

Type: iframe

Description: Displays target page inside an iframe.

Pros:

Cons:

Best for: Content display, pages that allow iframe embedding


Target Weight Distribution

When multiple targets are assigned to a single flow, the system uses weight-based distribution to split traffic proportionally.

How Weights Work

Weights are relative numbers that determine the percentage of traffic each target receives. The system calculates the percentage based on the total weight.

Formula:

Target Percentage = (Target Weight / Total Weight) Γ— 100

Weight Examples

Example 1: Equal Distribution

Target Weight Traffic %
Target A 100 33.3%
Target B 100 33.3%
Target C 100 33.3%
Total 300 100%

Example 2: Weighted Distribution

Target Weight Traffic %
Target A 50 25%
Target B 100 50%
Target C 50 25%
Total 200 100%

Example 3: Custom Distribution

Target Weight Traffic %
Target A (Best Performer) 70 70%
Target B (Testing) 20 20%
Target C (Backup) 10 10%
Total 100 100%

Best Practices

  1. Start with equal weights (100 each) and adjust based on performance
  2. Use round numbers for easier calculation (10, 50, 100)
  3. Test new targets with low weights (10-20) before scaling up
  4. Monitor conversions and adjust weights to maximize ROI
  5. Set backup targets with low weights (5-10) for fallback

Weight Selection Algorithm

The system uses weighted random selection:

  1. Calculates cumulative weight ranges for each target
  2. Generates a random number between 0 and total weight
  3. Selects the target whose range contains the random number
  4. Only active targets participate in selection

Assigning Targets to Flows

Targets are assigned to flows through the Flow Detail page. Each assignment creates a FlowTarget relationship with a weight value.

Steps to Assign Targets

  1. Navigate to Campaigns and select your campaign
  2. Click on a Flow to open the Flow Detail page
  3. Scroll to the Targets section
  4. Click Add Target or Assign Target
  5. Select a target from the dropdown
  6. Set the Weight value (default: 100)
  7. Click Save

Managing Flow-Target Assignments

Exit Flow Targets

Flows can be marked as Exit Flow. These are special flows used when no regular flow matches the visitor's filters:

Note: Every active campaign must have at least one Exit flow with targets to handle unmatched traffic.


Conversions Overview

What is a Conversion?

A Conversion occurs when a visitor who clicked through your TDS completes a desired action on the target page, such as:

Conversion Data Structure

Each conversion record includes:


Conversion Tracking Methods

Simple TDS supports three methods for tracking conversions. All methods are accessed via the /c/ endpoints (not /api/).

Method 1: Postback URL (Server-to-Server)

Best for: CPA networks, affiliate platforms, automated tracking

Endpoint: GET /c/postback

URL Format:

https://yourdomain.com/c/postback?click_id={click_id}&conversion_type={conversion_type}&conversion_value={conversion_value}&external_id={external_id}

Parameters:

Parameter Required Description Example
click_id Yes* Unique click identifier 86f72615f9f2c70d6d0
campaign_id Yes* Campaign ID (if click_id not available) 123
conversion_type No Type/category of conversion lead, sale, registration
conversion_value No Monetary or custom value 100.50
external_id No Partner's transaction/order ID order_12345

*Either click_id or campaign_id must be provided.

Example Usage:

https://yourdomain.com/c/postback?click_id=86f72615f9f2c70d6d0&conversion_type=sale&conversion_value=49.99&external_id=order_12345

Response:

{
  "success": true,
  "conversion_id": 456
}

Setup Instructions:

  1. Go to Conversions page
  2. Select your campaign
  3. Copy the Postback URL from the Postback tab
  4. Replace placeholders with your partner's macros:
    • Replace {click_id} with partner's click ID macro
    • Replace {conversion_type} with fixed value or partner's macro
    • Replace {conversion_value} with partner's payout macro
    • Replace {external_id} with partner's transaction ID macro
  5. Add the URL to your partner's postback settings

Partner Macro Example (Generic):

https://yourdomain.com/c/postback?click_id=[CLICK_ID]&conversion_type=lead&conversion_value=[PAYOUT]&external_id=[TRANSACTION_ID]

Method 2: Pixel Tracking (Image Tag)

Best for: Thank you pages, confirmation pages, client-side tracking

Endpoint: GET /c/pixel.gif

HTML Code:

<img src="https://yourdomain.com/c/pixel.gif?click_id={click_id}&conversion_type={conversion_type}&conversion_value={conversion_value}&external_id={external_id}" width="1" height="1" style="display:none" />

Parameters: Same as Postback URL

Example Usage:

<!-- Basic pixel -->
<img src="https://yourdomain.com/c/pixel.gif?click_id=86f72615f9f2c70d6d0&conversion_type=lead" width="1" height="1" style="display:none" />

<!-- With value -->
<img src="https://yourdomain.com/c/pixel.gif?click_id=86f72615f9f2c70d6d0&conversion_type=sale&conversion_value=99.99" width="1" height="1" style="display:none" />

Setup Instructions:

  1. Go to Conversions page
  2. Select your campaign
  3. Copy the Pixel Code from the Pixel tab
  4. Replace {click_id} with actual click_id value or JavaScript variable
  5. Paste the code on your thank you/confirmation page (before </body> tag)

Dynamic Pixel with JavaScript:

<script>
(function() {
    // Extract click_id from URL
    const urlParams = new URLSearchParams(window.location.search);
    const click_id = urlParams.get('click_id');

    // Create and insert pixel
    if (click_id) {
        let img = new Image();
        img.src = "https://yourdomain.com/c/pixel.gif?click_id=" + click_id + "&conversion_type=lead&conversion_value=50";
        document.body.appendChild(img);
    }
})();
</script>

Method 3: JavaScript Tracking

Best for: SPAs, dynamic pages, advanced tracking scenarios

Endpoint: GET /c/postback (via fetch/AJAX)

JavaScript Code:

<script>
(function() {
    // Extract click_id from URL
    const urlParams = new URLSearchParams(window.location.search);
    const click_id = urlParams.get('click_id');

    // Send conversion via fetch
    if (click_id) {
        const url = "https://yourdomain.com/c/postback?click_id=" + click_id + "&conversion_type=lead&conversion_value=50&external_id=order123";
        fetch(url, {method: 'GET'})
            .then(response => response.json())
            .then(data => console.log('Conversion tracked:', data))
            .catch(error => console.error('Tracking error:', error));
    }
})();
</script>

Setup Instructions:

  1. Go to Conversions page
  2. Select your campaign
  3. Copy code from the JavaScript Pixel tab
  4. Replace placeholders with actual values or JavaScript variables
  5. Paste the code on your conversion page

S2S Upstream Postback (Traffic Source Relay)

When traffic arrives from a paid source (RTB Panda, ClickBaza, etc.), the source includes their own click ID in the URL. When a conversion is recorded in TDS, the S2S Postback URL setting on the campaign automatically relays the conversion event back to the traffic source.

This is configured per campaign in Campaign Settings β†’ S2S Postback URL. See the Campaign Management Guide for full configuration details.

Quick Macro Reference

MacroDescription
{clickid}Traffic source click ID (from ?clickid= in original traffic URL)
{payout}Conversion value passed by the offer
{status}Conversion type (confirmed, lead, sale…)
{tds_click_id}TDS internal click UUID

Any query parameter from the original traffic URL is available as a macro using its exact name in curly braces.


Conversion Types and Values

Conversion Types

Conversion types categorize different conversion events. Common types:

Setting Conversion Type:

?conversion_type=lead
?conversion_type=sale
?conversion_type=custom_event_name

Conversion Values

Conversion value is a numeric field for tracking monetary value or custom metrics.

Examples:

Setting Conversion Value:

?conversion_value=49.99
?conversion_value=100

External ID

External ID links your conversion to a partner's transaction, order, or lead ID.

Use cases:

Setting External ID:

?external_id=order_12345
?external_id=txn_abc123
?external_id=lead_98765

Viewing Conversion Data

Conversions Page

The Conversions page provides tools for generating tracking codes:

  1. Navigate to Conversions from the main menu
  2. Select Campaign: Choose which campaign to generate tracking for
  3. View Tabs:
    • Postback: Server-to-server URL
    • Pixel: HTML image tag code
    • JavaScript Pixel: JS-based tracking code
    • Instructions: Detailed setup guide
  4. Copy Code: Click copy icon to copy tracking code
  5. Customize: Replace placeholders with actual values

Statistics Page

View conversion data on the Statistics page:

  1. Navigate to Statistics
  2. Select date range
  3. View conversion metrics:
    • Conversions Count: Total number of conversions
    • Conversion Value: Sum of all conversion values
    • Conversion Rate: (Conversions / Clicks) Γ— 100%
    • EPC (Earnings Per Click): Total Value / Total Clicks
  4. Filter by:
    • Campaign
    • Flow
    • Target
    • Date range
    • Country, device, etc.

Analytics Features


Best Practices

Target Management

  1. Use descriptive names: "US Desktop - Offer A" instead of "Target 1"
  2. Test redirect types: Different offers work better with different methods
  3. Monitor performance: Regularly check which targets convert best
  4. Update inactive targets: Disable or delete targets that no longer work
  5. Use URL macros: Always include {click_id} for conversion tracking

Conversion Tracking

  1. Always pass click_id: Essential for accurate attribution
  2. Use postback when possible: More reliable than pixels
  3. Test tracking: Verify conversions are recorded correctly
  4. Include external_id: Helps with reconciliation and fraud detection
  5. Set conversion types: Makes reporting and analysis easier
  6. Monitor data quality: Check for duplicate or invalid conversions

Traffic Optimization

  1. Start with equal weights: Then optimize based on data
  2. A/B test targets: Compare performance with different weights
  3. Use exit flows: Monetize all traffic, even unmatched
  4. Track by conversion value: Not just conversion count
  5. Adjust regularly: Optimize based on recent performance

Troubleshooting

Target Issues

Problem: Target URL not working

Problem: Macros not replaced

Problem: Redirect not happening

Conversion Tracking Issues

Problem: Conversions not recorded

Problem: Duplicate conversions

Problem: Missing conversion data


Summary

For more information, see: