Upfluence’s Agnostic Sales Tracking (AST) system allows you to track sales generated by your affiliate campaigns on a variety of websites, even if you're not using one of our native integrated platforms like Amazon, Shopify, WooCommerce, BigCommerce, or Magento.
This type of set up is commonly used when:
1️⃣ You’re a Shopify user who needs to track sales but don’t want to offer a discount. (Check this special guide)
2️⃣ You’re using WooCommerce, BigCommerce or Magento integration to generate discount codes, but also want to generate affiliate links for your creators. (See integration capabilities).
3️⃣ You’re not using one of the supported integrations (Amazon, Shopify, WooCommerce, BigCommerce, or Magento) but still want to track influencer sales with Upfluence.
Important Notes:
Affiliate links generated with AST do not automatically apply discounts.
Shopify native integration enables you to generate discount codes and affiliate links, while you could choose to use AST to make affiliate links with NO discount.
WooCommerce, BigCommerce, or Magento native integration enables you to generate discount codes only. If you also need to create affiliate links, you can use the AST integration. You can also customize the AST affiliate links by adding UTM parameters during the creation process.
Installation Steps:
In order for Upfluence to capture your orders, you must install our tracking scripts on your website. Our tracking is quite simple, it is installed the same way as Google Analytics.
To install, you must complete the following steps:
Include a JavaScript code snippet on every page on your site so that we can track your affiliate visits.
Report each order to us either on your “Thank you” page using JavaScript
Note: We highly recommend someone on your team with experience in HTML completes this setup. This setup requires scripts to be pasted into specific sections of your website’s HTML to work correctly. If you have any questions, please contact Upfluence support.
1. Generate your personal script link
From your integrations settings, scroll down until you see the tracking script section. Then, click on the “Generate script” button, this will open a dedicated modal
Enter the website on which the script will be installed. This will identify the site when you generate affiliate links later on. Press " Generate script” to create your own script.
Once done, we will provide you with two scripts that must be installed in two different places on your website.
Note: We advise you to copy these scripts in a notepad in the meantime because you will have to modify some values to match your website payload.
2. Installation
These two steps are mandatory to track sales:
IMPORTANT: If your “Thank you” page is under a subdomain which is not the same as your global website (i.e. www.mywebsite.com and www.checkout.mywebsite.com), you must add a specific configuration step described below.
Please, refer to this installation guide: (Optional) Additional step for subdomains
1️⃣ Tracking Visits
Copy the first script and paste it into the <head>
section of every page on your site. Some content management systems (CMS) may have a dedicated section for adding code to all pages.
2️⃣ Track orders
In order to track purchases, you need to also install the script on your “Thank you” or order confirmation page. This would be the page that all customers are directed to after completing their order. This code is responsible for sending the order data to Upfluence.
a. Update the script payload
We recommend that you get help from a member of your technical team if needed.
Take the second generated script and update the payload to make sure it matches your website's payload, especially the one that corresponds to the order validation page.
When adding this code to your website you must dynamically insert the customer's transaction information from the respective order within the code snippet. As an example, “foo@bar.com" would be replaced with a real customer's email (e.g '{customerEmailAddress}' in the example below)
Below, we've provided a sample code snippet with dummy data that you can use as guide. Please use the one generated in Upfluence.
Not all data is required, but all is recommended. A description of each field is available at the end of this article.
Default Payload |
<script>_upf.push([ [ "order, { order_id: 1, // required order_name: "#1", // required amount: 105.45, // required currency: "USD", // required, items: [{name: 'product', amount: 105.45, currency: 'USD'}], customer: { customer_id: 1234, first_name: "foo", last_name: "bar", email: "foo@bar.com", }, } ])</script> |
Example script modified for Squarespace |
<script> _upf.push( ['order',{ 'order_id': {orderId}, // required 'order_name': '{orderId}', // required 'amount': {orderSubtotal}, // required 'currency': 'EUR', // required customer: { email: '{customerEmailAddress}', } }]);</script> |
b. Install the order tracking script
Once the values have been replaced, please insert the following code and replace the values into the <body> section of your order confirmation / thank you page.
Once done, you're ready to send affiliate links to influencers and track sales in Upfluence!
NOTE: We highly recommend doing a test order with an affiliate link to make sure everything's has been properly configured before sending the links to influencers.
3. (Optional) Additional step for subdomains
This part is optional and only concerns users that have a specific configuration.
If your “Thank you” page is under a subdomain or another domain which is not the same as your global website (i.e., www.mywebsite.com and www.checkout.mywebsite.com), you must add a property to update the URL with the visitor UUID.
To do so, to make sure the visitor UUID (user identification) is persisted until the end of the checkout process, you need to make sure to forward it to the checkout page which is on your subdomain:
Step 1: Identify Links Targeting the Payment Page
First, identify all the <a>
tags that target your payment page. For example, if your payment page URL is https://my-website.com/payment
, look for links in your HTML like.
<a href="https://my-website.com/payment">Pay Now</a>
Step 2: Add the Data Attribute
For each link targeting the payment page, add the data-upfluence-tracking="forward"
attribute. This attribute will help in tracking the visitors.
Here’s how to modify the link:
Original link:
<a href="https://my-website.com/payment">Pay Now</a>
Updated link:
<a href="https://my-website.com/payment" data-upfluence-tracking="forward">Pay Now</a>
Step 3: Test the Changes
Make sure to test it using an affiliate link and confirm you are properly tracking and attributing orders to creators. Refer to How to test your AST tracking setup.
Variable Descriptions
Transaction Data
A transaction represents the entire order that occurred, and contains the following values:
Value | Type | Required | Description |
order_id | Number | Yes | Unique shopping cart order ID or transaction number used to reference the purchase that you're reporting. |
order_name | String | Yes | Can be the same value than order_id |
amount | Number | Yes | Total amount the customer was charged for the order. |
items | Number | No | Total number of items included in the order |
currency | String | Yes | The three letter currency code of the order totals that you are reporting. Example: USD, CAD, GBP. |
Customer Data
A customer represents the individual customer who purchased, and contains the following values:
Value | Type | Required | Description |
first_name | String | No | Customer first name |
last_name | String | No | Customer last name |
customer_id | Number | No | Customer ID |
String | No | Custom email address |
Frequently Asked Questions
1. Can I use GTM to inject the Upfluence Script?
Yes, you can use GTM (Google Tag Manager) to inject the Upfluence Script. However, if GTM does not inject the script in the correct place, it may fail to work as intended.
2. Regarding tracking of UTM, are there any cookies' exemptions? Are we able to track sales even if the visitor didn't accept the cookies?
Upfluence's Agnostic Sales Tracking (AST) operates with multiple tracking systems to make sure we are not missing conversions:
Cookies
Fingerprinting: This allows for tracking in scenarios where a visitor may not accept cookies.
Local storage: if nor cookies or fingerprinting are possible, we are using local storage to keep track of users conversions.
IMPORTANT: If your “Thank you” page is under a subdomain which is not the same as your global website (i.e., www.mywebsite.com and www.checkout.mywebsite.com), you must add a specific configuration step described below. If this is not done, the “Local storage” tracking won't be possible. Please, refer to this installation guide: (Optional) Additional step for subdomains
These three tracking systems in parallels allow us to make sure we will always track conversions, no matter the browser or the device.
3. If there is a guest checkout option (enter email first), can AST still work for me?
Yes, AST (Agnostic Sales Tracking) can still work for you under the condition that you have the ability to paste the tracking script both on the checkout page (to track the orders) and across the whole website (to identify the user).
This setup ensures that AST can effectively track and attribute sales to the correct influencers.
4. If I want to use AST, but before the credit card is charged there is a 7-day trial, would there be a “pending” or “pause” on the conversion in the performance tab?
Conversions will be marked as paid because Upfluence does not have access to your backend to see trial periods or pending charges.
However, you have the option to manually reject individual conversions (sales) if necessary, such as during a trial period before the credit card is charged.
5. I’m inquiring about the feasibility of appending my own UTM parameters to the generated affiliate links (AST) to monitor details like the influencer's team affiliation and the sales channel. Is this technically achievable?
Yes, it is technically achievable. When setting up a tracking plan for AST (Agnostic Sales Tracking), you have the option to activate UTM parameters and customize them to your needs for source, medium, and campaign attribution.