Create Add to Cart event for Sendlane

Using Reclaim Add to Cart Feature

This feature can identify abandoned cart contents for both unknown, non-logged in users (Resolve contacts) and known, non-logged in customers (emails in your Resolve suppression list). 

If you use this feature, we will send all of those Add to Cart events to you. 

To use this feature, you must first ensure that you’re using the most recent version of our script on your website. You can find your script in your  account under Code Script > View Script

This feature works for any e-commerce website. Click here for a link to all our tutorials on how to add the script to your site, in case you need a refresher.

ON YOUR WEBSITE:

1. Add the following script to the on-click event for adding an item to your cart, such as an “Add to Cart” button:

geq.addToCart(item);

**This feature works for any e-commerce platform, but we have specific examples for Sendlane**

IN SENDLANE

Follow Sendlane’s documentation to add their Add to Cart snippet. This endpoint allows you to send Added to Cart events as part of the Custom Integration. We’ve included the generic code for buttons below.

Remember: The name of the button should match what is in quotes below ("AddToCart") to fire properly. So, if your button isn’t “AddToCart”, you’ll need to update that in the script provided below.

Generic code for buttons defined by a button ID:

<script type="text/javascript">
document.getElementById("AddToCart").addEventListener('click',function (){
geq.addToCart(item)
});</script>

Generic code for button defined by a class notation:

<script type="text/javascript">
document.getElementsByClassName("AddToCart").addEventListener('click',function (){
geq.addToCart(item)
});</script>

IN SENDLANE: SET UP YOUR FLOW(S)

Once your existing snippet is modified/edited to include our script, you will see our additional unique identifier.

Additionally, you can see these events successfully passing through in your Retention.com account when you see the Added to Cart option populate under Event Details. This is an easy way to confirm that our events have been successfully implemented:

Contact us at support[at]retention.com and request that we enable Add to Cart events for your account. If you’re working with our onboarding team, this will already be enabled.