Here is how to integrate VoyageSMS code with your Squarespace E-commerce
Tracking Code
If you use Squarespace, please follow these instructions for the tracking code:
- From your Squarespace home menu go to Settings > Advanced > Code Injection.
- In the Headers section, paste the code snippet (shown below) in the text area.
Important: Replace 'Client_ID' in the code below with the Client ID found in your Voyage dashboard under Settings—>Company—>Client ID
<script type="text/javascript">
/* <![CDATA[ */
(function(){if(window.voyage)return;window.voyage={q:[]};var fns=['init','event','track'];
for(var i=0;i<fns.length;i++){(function(fn){window.voyage[fn]=function(){
this.q.push([fn,arguments]);}})(fns[i])}})();voyage.init('Client_ID', { popup: true });
/* ]]> */
</script>
<script async src="https://assets.voyagetext.com/voyage.production.js"></script>
Purchase Pixel
To add the purchase pixel, please follow these instructions:
- From your Squarespace home menu go to Settings > Advanced > Code Injection.
- Scroll down and in the Order Confirmation page text area, copy and and paste the code below exactly.
<script type="text/javascript">
voyage.track('Purchase', { amountDollars: "{orderGrandTotal}" });
</script>
For additional assistance, you can reach out to our service team, or reference Squarespace's documentation here.
Tip: To capture and use Squarespace events for drip campaigns, you'll need to create custom events and add those to your "add to cart" and "checkout" flows in Voyage.