Vimeo OTT and Refersion don’t have an official integration, but we do have a solid workaround. With some setup and testing, you’ll be able to integrate using Zapier.

The steps below outline what’s worked in the past, though your specific setup may require additional tweaks.

Note: You will need to be on a Zapier plan that supports at least 1 Premium app in order to integrate Refersion and Vimeo OTT.

Note: These instructions are for sites that are hosted outside the Vimeo OTT platform and use subscribe links. For sites that use Vimeo’s hosted experience, you’ll need to get in touch with your Vimeo account manager first, and then connect with us.

Step 1: Tracking affiliate clicks

In order to track clicks when affiliates drive customers to your site, you first need to add a snippet of Javascript in the header (<head>) section of your site. In the snippet below, you’ll replace YOUR_PUB_KEY with the Public Key from your Refersion account.

You can find your public key in Refersion by navigating to Account > Settings > Refersion API:

<script>!function(e,n,t,i,o,c,s,a){e.TrackingSystemObject="r",(s=n.createElement(t)).async=1,s.src="https://cdn.refersion.com/refersion.js",s.onload=function(){r.pubKey="YOUR_PUB_KEY",r.settings.fp_off=!1;r.initializeXDLS().then(()=>{r.launchDefault()})},(a=n.getElementsByTagName(t)[0]).parentNode.insertBefore(s,a)}(window,document,"script");</script>

Now that we can track clicks on your main site, we’ll need to pass the tracking from there to the Vimeo site using another snippet of Javascript. This additional Javascript ensures that we can create the conversions for your affiliates within Refersion when customers leave your site and complete their purchase in the Vimeo checkout.

Please add the following Javascript code to the footer of your site right before the closing </body> tag to help get the tracking passed over:

<script>let links=document.querySelectorAll("a");function urlSearchParams(t){this.q=t,this.get=function(t){if(-1===this.q.indexOf("&")){let e=this.q.split("=");return e[0]===t?e[1]:null}{let e=this.q.split("&");for(let r=0;r<e.length;r++){let i=e[r].split("=");if(i[0]===t)return void 0===i[1]||decodeURIComponent(i[1])}}},this.has=function(t){if(-1===this.q.indexOf("&"))return this.q.split("=")[0]===t;{let e=this.q.split("&");for(let r=0;r<e.length;r++)if(e[r].split("=")[0]===t)return!0}}}function addTrackingToPurchaseLinks(t){let e=new urlSearchParams(window.location.search.substring(1));if(!e.has("rfsn"))return;let i=t.target,n=i.attributes,s=e.get("rfsn");if(!n.hasOwnProperty("data-track-conversions"))return;let a=i.href,o=-1===a.indexOf("?")?"?":"&",l=sessionStorage.getItem("cart_id"),c=new urlSearchParams(a.split("?").pop());if(!c.has("rfsn")&&!c.has("campaign")&&-1===a.indexOf("#")){const t={cart:l,id:localStorage.getItem("rfsn_v4_id"),url:window.location.href,aid:localStorage.getItem("rfsn_v4_aid"),cs:localStorage.getItem("rfsn_v4_cs")};r.sendCheckoutEvent(t.cart,t.id,t.url,t.aid,t.cs),i.href=a+o+"rfsn="+s+"&campaign="+l}}links.forEach(t=>{let e=t.getAttribute("href");null!==e&&-1!==e.indexOf("checkout")&&t.setAttribute("data-track-conversions","")}),sessionStorage.getItem("cart_id")||sessionStorage.setItem("cart_id",[...Array(22)].map(t=>(~~(36*Math.random())).toString(36)).join("")),document.addEventListener("click",addTrackingToPurchaseLinks);</script>

Once the code is in place, anytime a customer lands on your site and clicks a subscribe link, the following URL parameters will be added to the URL of the Vimeo OTT checkout page:

  • rfsn - Unique to Refersion; this is used to track the affiliate that referred the customer to your site (i.e. rfsn=12345678.a1b0).

  • campaign - A Unique ID that is used to connect the affiliate referral click to the subscription order later.

Note: If you already have additional UTM parameters on the links for other tracking purposes, these will be carried over as well.

Step 3: Set up your Zapier Template

Check out this Zapier template as your starting point. It is set up to listen for new and recurring subscription webhooks from Vimeo OTT and then send this subscription data into Refersion. Once the data is in Refersion, the subscription order will be credited to the affiliate who helped drive the sale.

There are a few things you'll need to configure, outlined below:

  1. In order to process your initial test data in Zapier, you’ll first need to add your Zapier webhook URL to Vimeo OTT. You can check out Vimeo’s video guide and written instructions for using their webhooks with Zapier here.

  2. Our Zapier template is mapped to specific topics, so you’ll want to set your filters to match (by default, Vimeo will send all webhook topics to Zapier).

    Here is a list of topics you may need to configure in your zap:
    - customer.product.created
    - customer.product.renewed
    - customer.product.free_trial_converted
    - customer.product.resumed

    Set the filter to: Only continue if: 1.Topic → (Text) Exactly Matches → customer.product created. When adding a new topic, choose "or" instead of "and". (Repeat this step for all 4 topics)

    See the image below.

With these two steps out of the way, you should be good to go, but if you run into trouble, chat with us from your Refersion dashboard or send us an email.

Did this answer your question?