If you've got a custom script or redirection method for your affiliate links, you'll want to make sure to add support for query parameter pass-through yourself.
You'll also probably need to contact our Support team in case our sitemap scan can't pick up your affiliate links. This usually happens if you have a non-standard redirect method, such as client-side redirects using window.location.
Luckily, compatibility pretty easy to set up, but it does require a little custom code, sometimes from both sides.
Here are the main scenarios you'll need to handle:
- Scenario 1: Pass-through external parameters to the cloaked link
- Scenario 2: Handle Partnerize links (if you are using Partnerize)
- Scenario 3: Client-side redirects and custom cloaking scripts
Scenario 1: Pass-through external parameters to the cloaked link
In short, you'll want to pass-through any query parameters Affilimate adds to your cloaked link down to the underlying affiliate link.
You'll need to correctly append the query parameter at the end, and be aware of any encoding considerations depending on the format of the link itself.
For example, let's assume your custom cloaked affiliate link looks something like this:
And that this cloaks an affiliate link which supports Smart Labels, for example an Impact link:
Affilimate will append the correctly formatted query parameter to your cloaked link on the landing page itself.
At that point, it's your link cloakers responsibility to forward that to the underlying link before redirecting the user.
For example, we'll modify your cloaked link into, e.g.:
You then need to take that extra parameter (subId3) and its value (your-page-slug_amcid-02khsbfds983bf8), and pass it through to the link you redirect the user to:
The SubId name and value is different for every network, so be sure not to hardcode them. Contact Support if you prefer to whitelist specific query parameter names, and we'll provide you with a current list.
In short: Take any extra query parameters that we add to your on-page affiliate links, and append them to your affiliate link before sending the user along. This behavior applies to all affiliate links where we support dynamic SubIDs ("Smart Labels") with one exception.
Scenario 2: Handle Partnerize links (if necessary)
Partnerize appends SubIDs as part of the path of the link, instead of a query parameter.
In this scenario, Affilimate will append the query parameter called
pubref to your cloaked link. From there, you'll need to modify the underlying link to contain this pubref as part of the path.
For example, Affilimate will add a query parameter like this:
And you'll need to modify the Partnerize link you redirect the user to so it includes, e.g.
/pubref:your-page-slug_amcid-02khsbfds983bf8/ right after the camref in the URL. So for example, turning this:
Based on whatever value is being sent as the
Scenario 3: Client-side redirects and custom cloaking scripts
If your redirects from your cloaked links to the affiliate link do not use a standard 3XX response code, please contact Support so we can work together on detection of your custom cloaked links or script.
For both of these networks, we recommend generating the links by hand for better control and tracking.