Track Campaign Source on Google Analytics

DOKU Checkout now supports the ability to track campaign sources through Google Analytics (GA). This feature allows merchants to attribute transactions to specific marketing campaigns by passing UTM.

By leveraging this feature, you can:

  • Identify which campaigns drive conversions

  • Improve marketing strategy based on performance data

  • Track customer behavior through your Google Analytics account


How it Works ?

When generating a checkout order, you can pass Google Analytics UTM parameters in the request. These parameters will be stored and sent during the transaction process, enabling you to track attribution data in your analytics tools.

Request sample :

"additional_info": {
        "google_config": {
            "campaign_name": "test_name_2",
            "campaign_source": "test_source_2",
            "campaign_medium": "test_medium_2",
            "debug_mode": true
        },
    }
Body Paramater
Type
Mandatory
Description

google_config.campaign_name

String

Optional

The name of the marketing campaign (e.g., "ramadhan_sale"). Used to group campaign results.

google_config.campaign_source

String

Optional

The source of the traffic (e.g., "google", "instagram"). Identifies where the user came from.

google_config.campaign_medium

String

Optional

The medium used in the campaign (e.g., "cpc", "email", "referral").

google_config.debug_mode

Boolean

Optional

Set to true to enable debug mode, which will log campaign tracking behavior for troubleshooting purposes.

Last updated

Was this helpful?