Solved

Abandoned cart flow: cart empty in the website after clicking on the button "return to your cart' in the email

  • 22 January 2021
  • 23 replies
  • 1712 views

Badge +2

Dear All, 

I created my 1st flow: Abandoned cart 

Trigger: When someone checkout started 

Filters: Place order zero times since starting this flow 

 

The abandoned card/references of the product/pictures appear well in the email but when we click on the button ‘return to your cart’ the cart seems empty on the website. The client is not able to find again his cart with the products and quantities.

I checked the settings and I correctly used in the button: {{ event.extra.checkout_url }}

 

Do you have any idea?

thank you so much

icon

Best answer by David To 3 May 2021, 00:59

View original

23 replies

Userlevel 3
Badge +10

Hey @CDJ08 !

Do you have a Shopify integration? If so, try :

{{ event.extra.responsive_checkout_url }}

This should re-load the cart contents regardless of what device a user opens the link on!

Badge +2

Hi @ksanfelipe 

I have a magento Integration, 
I will check 

thank you very much

Userlevel 3
Badge +10

Hi @CDJ08

That tag will only work for Shopify integrations. Do you use Magento or Magento 2?

Userlevel 3
Badge +10

To follow up:

If using Magento, the tag {{ event.extra.checkout_url }} should work. 

If using Magento 2, you’ll want to use {{ organization.url }}reclaim/checkout/cart?quote_id={{ event.Extra.QuoteID }}

If you are having issues with either one of these, any screenshots of the actual implementation would be helpful!

 

 

Badge +2

To follow up:

If using Magento, the tag {{ event.extra.checkout_url }} should work. 

If using Magento 2, you’ll want to use {{ organization.url }}reclaim/checkout/cart?quote_id={{ event.Extra.QuoteID }}

If you are having issues with either one of these, any screenshots of the actual implementation would be helpful!

 

 

I am having the exact same issue with Bigcommerce - any ideas?

Userlevel 3
Badge +10

Hi @WonderWho,

BigCommerce doesn’t pass us any kind of responsive link or cart token in the “Checkout Started” event, so we cannot rebuild a cart for that integration. If you’re interested, however, Arctic Leaf created an app that will allow you to regenerate a person’s cart with BigCommerce! For info:  https://www.bigcommerce.com/apps/klaviyo-cart-rebuilder-by-arctic-leaf/

Userlevel 3
Badge +4

@ksanfelipe thank you for sharing the information. It is extremely helpful. 

Badge +2

Hi @WonderWho,

BigCommerce doesn’t pass us any kind of responsive link or cart token in the “Checkout Started” event, so we cannot rebuild a cart for that integration. If you’re interested, however, Arctic Leaf created an app that will allow you to regenerate a person’s cart with BigCommerce! For info:  https://www.bigcommerce.com/apps/klaviyo-cart-rebuilder-by-arctic-leaf/

Thank you SO very much!!

Badge +1

Hi everybody! The same happens to my. I have klaviyo integrated with woocomerce…

 

please your help

best regards

Userlevel 7
Badge +60

Hello @Leon.andaur,

Are you using {{ organization.url }}cart?wck_rebuild_cart={{ event.extra.CartRebuildKey }} as the button’s Link URL? Using this specific link for your button’s Link URL should rebuild your recipient’s cart for WooCommerce as highlighted in the Rebuilding Carts from an Abandoned Cart Flow section of the How to Integrate with WooCommerce article. 

Hope this helps!

-David

Badge +1

Hello @Leon.andaur,

Are you using {{ organization.url }}cart?wck_rebuild_cart={{ event.extra.CartRebuildKey }} as the button’s Link URL? Using this specific link for your button’s Link URL should rebuild your recipient’s cart for WooCommerce as highlighted in the Rebuilding Carts from an Abandoned Cart Flow section of the How to Integrate with WooCommerce article. 

Hope this helps!

-David

Thanks for this , it worked! everything worked fine, however you missed a ‘/’ before the cart. Once this is fixed it works great. code should be:

{{ organization.url }}/cart?wck_rebuild_cart={{ event.extra.CartRebuildKey }}

 

hope this works for you all :)

Badge +2

i am facing same issue with my email template, ehwn i click on the button to return to my cart its showing me empty cart (your cart having no items) 
only if i login in the same window then only it will redirect me to the cart page.
i want to go to my cart page without login, i am using this url in email template button to return to my cart
{{ organization.url }}reclaim/checkout/cart?quote_id={{ event.Extra.QuoteID }}

Userlevel 7
Badge +60

Hello @Vertara,

Do you happen to be using Magento 2 with Klaviyo? If so, then that dynamic syntax you’ve highlighted should still function similarly to the default cart rebuild link of {{ organization.url|trim_slash }}/reclaim/checkout/cart?quote_id={{ event.Extra.QuoteID }} provided within Klaviyo’s default, pre-build abandoned cart flow for Magento 2. 

Users who click on this link typically would not need to be logged into their account to access their cart. Furthermore, since this is a cart rebuilt key, the recipient should also be able to rebuild their cart should they be using a different device, such as their phone and clicking on the link to be returned back to their cart.

I hope this helps!

David

Badge +2

I have added the same link to my cart button {{ organization.url|trim_slash }}/reclaim/checkout/cart?quote_id={{ event.Extra.QuoteID }}
still i am getting and empty cart page 
can you please suggest the solution

Userlevel 7
Badge +60

Hey @Vertara,

I would recommend checking to see if the users you are previewing as has already completed their order. Klaviyo’s email preview tool allows you to preview as any user who has recorded an event that triggers your flow; in this case, a Started Checkout event. This would also include customers who may have triggered the Started Checkout metric and then completed their order. When previewing as a customer who has completed their order, since the cart attempting to be rebuilt has been emptied, it would be expected that through previewing you would be seeing an empty cart page. 

Similarly, if a customer has made updates or changes to their cart, including emptying their cart; the cart button to rebuild their cart would direct users to their new updated cart as opposed to matching the metadata shared from the Started Checkout event. 

Lastly, I would recommend previewing as a customer who recently trigged the Started Checkout event. Depending on how you have set up your Magento 2 backend settings, this cart for each of your customers do have an expiration. When a user’s cart does expire, it would show the cart is empty when attempting to return and rebuild it through that dynamic link. 

David

Userlevel 4
Badge +9

Hi @WonderWho,

BigCommerce doesn’t pass us any kind of responsive link or cart token in the “Checkout Started” event, so we cannot rebuild a cart for that integration. If you’re interested, however, Arctic Leaf created an app that will allow you to regenerate a person’s cart with BigCommerce! For info:  https://www.bigcommerce.com/apps/klaviyo-cart-rebuilder-by-arctic-leaf/

This seemed to work for me for like, a day… now I get empty cart errors again. Any tips or insight? It looked like such a great fix.

Userlevel 7
Badge +60

Hello @wernstrom,

I would recommend taking a look at my comment above as it would often still apply to most cart rebuild services including both Shopify, WooCommerce, and Magento. 

Since it sounds like you are also using a third party service to rebuild your cart, I would also suggest reaching out to this third party provider for more details in terms of how their cart rebuild service functions and how it interacts with Klaviyo. Because this third party tool has a connection that is not build by Klaviyo, the developers of Arctic Leaf would be the best resource to reach out to for more details on how they have built the connection to interact with Klaviyo. 

If you need, I’ve also included the Arctic Leaf integration documentation to Klaviyo below:

Have a great day!

David

Userlevel 4
Badge +9

Thanks @david.to , I checked by adding items myself to the cart on one device, then checking on another, but good point. It’s a pity BigCommerce don’t pass this info through to Klaviyo.

Userlevel 5
Badge +18

Hello @Vertara,

Do you happen to be using Magento 2 with Klaviyo? If so, then that dynamic syntax you’ve highlighted should still function similarly to the default cart rebuild link of {{ organization.url|trim_slash }}/reclaim/checkout/cart?quote_id={{ event.Extra.QuoteID }} provided within Klaviyo’s default, pre-build abandoned cart flow for Magento 2. 

Users who click on this link typically would not need to be logged into their account to access their cart. Furthermore, since this is a cart rebuilt key, the recipient should also be able to rebuild their cart should they be using a different device, such as their phone and clicking on the link to be returned back to their cart.

I hope this helps!

David

 

Hi @Vertara

I’m not sure if you ever solved this, but I ran into the same problem and found that the dynamic syntax above is wrong.

At the very end for “quote_id”, the dynamic syntax should be {{ event.QuoteID }} since the QuoteID is not in the “Extra” array.

So, the full link rebuild is:

{{ organization.url|trim_slash }}/reclaim/checkout/cart?quote_id={{ event.QuoteID }}

 

Hope that helps! (Now I just have to figure out how to link to individual products since the product URL is not passed in.)

Userlevel 7
Badge +60

Hi all, 

 

Would also love to hear if this was solved for you, @Vertara! @DavidSandel makes an astute observation here. Thanks for jumping in to lend a helping hand!

 

Magento data is so custom that depending on how the event and metadata are shared/synced to Klaviyo, the default code structure may be different from user to user. I would encourage you @Vertara to investigate your event data as David did in his screenshot, to see if your checkout data is the same as the original code. If it is different, instead of using,

 event.extra.QuiteID

You may need to use the alternative code you find.

 

Thanks for jumping in @DavidSandel, love to see the Community interacting in this way! 

-Taylor 

Badge +1

Hello @Vertara,

Do you happen to be using Magento 2 with Klaviyo? If so, then that dynamic syntax you’ve highlighted should still function similarly to the default cart rebuild link of {{ organization.url|trim_slash }}/reclaim/checkout/cart?quote_id={{ event.Extra.QuoteID }} provided within Klaviyo’s default, pre-build abandoned cart flow for Magento 2. 

Users who click on this link typically would not need to be logged into their account to access their cart. Furthermore, since this is a cart rebuilt key, the recipient should also be able to rebuild their cart should they be using a different device, such as their phone and clicking on the link to be returned back to their cart.

I hope this helps!

David

Hi David,

I seem to be doing everything you suggested but still have an empty cart.

This is the url I am using {{ organization.url }}cart?wck_rebuild_cart={{ event.extra.CartRebuildKey }}

It is taking me back to the cart but it’s always empty

Any ideas why this might be?

Thanks

Ric

Userlevel 7
Badge +60

​​​​@ricbrooks

 

Did you make sure to check @David To’s other suggestion he mentioned above? 

Hey @Vertara,

I would recommend checking to see if the users you are previewing as has already completed their order. Klaviyo’s email preview tool allows you to preview as any user who has recorded an event that triggers your flow; in this case, a Started Checkout event. This would also include customers who may have triggered the Started Checkout metric and then completed their order. When previewing as a customer who has completed their order, since the cart attempting to be rebuilt has been emptied, it would be expected that through previewing you would be seeing an empty cart page. 

Similarly, if a customer has made updates or changes to their cart, including emptying their cart; the cart button to rebuild their cart would direct users to their new updated cart as opposed to matching the metadata shared from the Started Checkout event. 

Lastly, I would recommend previewing as a customer who recently trigged the Started Checkout event. Depending on how you have set up your Magento 2 backend settings, this cart for each of your customers do have an expiration. When a user’s cart does expire, it would show the cart is empty when attempting to return and rebuild it through that dynamic link. 

David

 

Hope this helps! Want to get this working for ya!

-Taylor 

Hello - I’m using WooCommerce and used the code found above for the Return to Cart link… but it’s still linking to an empty cart. Is there a new fix? 

Reply