Home › Forums › Stripe Payments Plugin › ShareASale integration for Stripe Payments Plugin?
- This topic has 1 reply, 2 voices, and was last updated 3 years, 4 months ago by Admin.
-
AuthorPosts
-
June 8, 2021 at 6:25 am #4031zizzleParticipant
Hello,
We are looking for the best simple way to create an affiliate referral rewards system to pay people a commission for referring new customers who purchase items on our site. It would be great if you considered adding an affiliate add-on in the future, but for now it looks like ShareASale might be a good option for us. To get their tracking code to work they offer some code which needs to be installed in the checkout page (unique per each checkout) and also a header code which is easy enough to do. Please take a look at their instructions below and let us know how we can integrate the various variable values they provide like ?tracking={{Order ID}} and &amount={{Order Subtotal}} where we can provide these values into the code from the Stripe Payments Plugin on checkout result page… I think this would be most useful for those using your plugin to help boost their product sales using the ShareASale affiliate program for merchants.
See ShareASale instructions below:
==================================Developer Install Directions:
ShareASale’s tracking involves two “tags” or “pixels” which are snippets of code installed specifically on the checkout “thank-you” receipt page and in the header of every other site page. The first tag is for tracking conversions (i.e. sales) and the second for assisting with Affiliate click attribution accuracy in certain browsers.
Conversion Tracking Installation InstructionsThe ShareaASale tracking pixel code should be placed in the HTML </body> of your “thank you” page, which is also commonly referred to as the order confirmation or receipt page. This page is on your website and typically summarizes a completed purchase.
It is important that this thank you page where the ShareASale tracking pixel code belongs can only be reached once by completing a valid sale on your website. Be sure that the thank you page will not display the ShareASale tracking pixel code when revisited or refreshed again. Finally, check the ShareASale pixel code will not be displayed on any other shopping cart pages that might use the same template, like order status, order history, order e-mail confirmation, invoice history, etc.
Required.
Before copying the code below, be sure your developer replaces the {{placeholder}} values with variables or macros from your particular cart so they’re correctly populated per the definitions. Each ¶meter={{placeholder}} is designed to capture a different aspect of the customer’s sale and journey.
<img src="https://www.shareasale.com/sale.cfm?tracking={{Order ID}}&amount={{Order Subtotal}}&merchantID=xxxxxx&transtype=sale" width="1" height="1"> <script src="https://www.dwin1.com/19038.js" type="text/javascript" defer="defer"></script>
?tracking={{Order ID}}
The tracking parameter receives a unique record locator, typically the customer’s order number. It should be used to cross-reference sales in your system with ShareASale so you can review Affiliate referrals and make any necessary reconciliations.
&amount={{Order Subtotal}}
The amount parameter receives a numerical amount formatted to two decimal places (XX.XX). This value should be the order subtotal after discounts but before any taxes or shipping are added.
An additional tracking “master” tag covered below checks for a landing page URL parameter named sscid=, and stores it as a first-party cookie (under your domain, not just ShareASale’s). This helps with tracking accuracy under certain browsers that disallow access to third-party cookies (accessing shareasale.com cookies from the Merchant’s example.com domain). You might hear this method referred to as “cookieless” tracking on other Affiliate networks.
When the order confirmation “thank-you” receipt page is being displayed, the master tag will retrieve the value of this cookie and append it to your tracking pixel automatically. This will effectively “replay” the tracking pixel, with the additional parameters appended if the original “third-party” cookie could not be retrieved. You’ll notice that the “master tag” is the same script tag included below your tracking pixel. This tag should be present on every page of your website.
<script src="https://www.dwin1.com/19038.js" type="text/javascript" defer="defer"></script>
Find the file, template, or section of your cart admin that allows you to place code that will be included on every page of the site.
The best place is the HTML <head></head> section, if possible.
Just install it once, not multiple times(i.e.not the header and footer by mistake).
If you’re editing a common global file for your site, make sure you’re editing the right one for your theme. Often carts can have multiple themes / skins, and if you change you will need to re – integrate the master tag on that new theme too.
Install the copied pixel code with all {{placeholder}}s substituted onto your website’s aforementioned thank you page.
Optional
You can add the following optional parameters to your ShareASale tracking pixel code, usually before the URL’s closing quotation mark. Each of these expands your ShareASale tracking in case you want to use ShareASale features powered by the data they receive.
Product Level Tracking
Product level tracking can be configured using the &skulist=, &pricelist=, and &quantitylist= parameters below. All three parameters must be passed together and their {{placeholder}} values must be URL-encoded.
&skulist={{Sku 1,Sku 2}}
The skulist parameter receives a comma-delimited list of the SKUs of each purchased line-item in the cart.
&pricelist={{Price 1,Price 2}}
The pricelist parameter receives a comma-delimited list of the prices of each line-item in the cart, in the same respective order as the SKUs.
Discounts should not be reported as line items as they are not commissioned. &Pricelist= parameter values should reflect each item’s price after discounts but before any taxes or shipping are added. All pricelist values multiplied by their respective quantitylist values and summed should equal the amount parameter?s value.
&quantitylist={{Quantity 1,Quantity 2}}
The quantitylist parameter receives a comma-delimited list of the quantities of each line-item in the cart, in the same respective order as the SKUs.
Coupon Code Tracking
Coupon code tracking can be configured using the &couponcode= parameter. Its {{placeholder}} value should be URL-encoded.
&couponcode={{Coupon 1,Coupon 2}}
The couponcode parameter receives a comma-delimited list of the coupon, promo, and/or discount codes used in the order.
Customer Status Tracking
Customer status tracking can be configured using the &newcustomer= parameter. Its {{placeholder}} value should be binary or null (1, 0, or blank/empty). &newcustomer={{customer type}} The newcustomer parameter receives a 1, 0, or is left blank depending on whether the customer is new, old, or unknown (e.g. guest checkout) type.
The newcustomer parameter should be set based on a common value such as the customer’s email address, login status, previous order count, matching past payment method, etc. and toggled based on whether a previous transaction has occurred with that same value.
Currency Conversion
Currency tracking and automatic conversion can be configured using the ¤cy= parameter. Its {{placeholder}} value should be the ISO-4217 code for the currency used in the order. For conversions, we use an average of midpoint daily rates and update that rate once per day.
Below is the full supported list of possible {{placeholder}} values:
USD United States dollar
CAD Canadian dollar
EUR Euro
MXN Mexican peso
IDR Indonesian rupiah
GBP Pound sterling
NZD New Zealand dollar
AUD Australian dollar
SGD Singapore dollar
HKD Hong Kong dollar
CHF Swiss franc
RUB Russian ruble
JPY Japanese yen
CNY Chinese yuan
BRL Brazilian real
INR Indian rupee
NOK Norwegian krone
AED United Arab Emirates dirham
THB Thai baht
June 9, 2021 at 1:47 am #4033AdminKeymasterThis is not an advertised feature of our plugin. It will need to be handled as a custom development job. You can use the contact form of our site to get in touch about a custom development work done for your site.
-
AuthorPosts
- You must be logged in to reply to this topic.