Setting Up Affiliate Tracking with Salesforce Commerce Cloud
  • 13 Sep 2024
  • Dark
    Light
  • PDF

Setting Up Affiliate Tracking with Salesforce Commerce Cloud

  • Dark
    Light
  • PDF

Article summary

GRIN lets you generate custom links for your Influencers, called affiliate links, to share with their audience and refer them to your products. GRIN also lets you track conversions on affiliate links, which means we can track when an affiliate link is used to make purchases in your store and attribute these purchases to the associated Influencer. This is great for tracking your ROI and which of your Influencers are the most successful.

To track affiliate link conversions in your Commerce Cloud site, you first need to set up the affiliate integration.

NOTE
We highly recommend a developer or integration partner on your team completes the affiliate integration process because it requires prior developer experience. If you need further technical support, please contact your CSM representative.

What You'll Need

  • The GRIN cartridge already installed in your Commerce Cloud environment.
  • Your brand you want to integrate with already set up in GRIN.

Code Changes

  1. Load the templates/include/grinFooter.isml template from the int_grin cartridge.
  2. Include the template in the footer of every page.
    • For SFRA-based environments, the template is located at:
      templates/default/components/footer/pageFooter.isml
< iscomment > GRIN SDK</ iscomment > 
< isinclude template = "/include/grinFooter" />
  1. Load the templates/tracking/grinConversionTracking.isml template from the int_grin cartridge.
  2. Include the template in the confirmation page after a successful checkout. 
    • For SFRA-based environments, the template is located at templates/default/checkout/confirmation/confirmation.isml
<iscomment>GRIN conversion tracking</iscomment>
<isinclude template="tracking/grinConversionTracking" />

You should now have both the JavaScript SDK library and conversion tracking script included. Your integration is now complete and ready to be tested.

Enabling the Integration

You can enable the SDK and conversion scripts by changing the GRIN configurations in the Business Manager. This lets you choose when you want to track affiliate conversions. To enable the integration:

  1. Go to your Business Manager.
  2. Navigate to Merchant Tools > Site Preferences > Custom Preferences.
  3. Click on GRIN Configuration.
  4. Select Yes for Enable GRIN Conversion Tracking.
  5. Enter the URL for the GRIN Conversion Tracking SDK URL.

4407795554711conversion-tracking.png


Congratulations! You're now set up to track affiliate link conversions in GRIN.


Was this article helpful?