Solved

Started Checkout event not working anymore - Bold Commerce & Shopify

  • 24 September 2021
  • 5 replies
  • 387 views

Badge +2
  • Contributor I
  • 2 replies

I have a Shopify shop and use Bold Commerce app for the checkout.

During months, I was able to use the following code in Bold Commerce to trigger the ‘Started Checkout’ event in Klaviyo.

It suddenly stopped working in July. Since then, I’ve contacted Bold Commerce support and they investigated during weeks : there is no issue on their end.

If I test it myself, Klaviyo will tell me that I’m “active on the website” when I start checkout.

So it does triggers something but not this specific event.

Is this code wrong? How can I fix it?

<script async type="text/javascript" src="//static.klaviyo.com/onsite/js/klaviyo.js?company_id=??????"></script>

<script>
var _learnq = _learnq || [];

const items = [];
const itemNames = [];

_learnq.push(['identify', {
'$email': BOLD.order.customer.email
}]);

window.BOLD.order.line_items.forEach(function (item) {
itemNames.push(item.product_title);
items.push({
"SKU": item.sku,
"ProductName": item.product_title,
"Quantity": item.quantity,
"ItemPrice": item.price,
"RowTotal": item.total_price,
});
});

let klaviyoPayload = {
"$event_id": BOLD.order.public_order_id,
"$value": (BOLD.order.total / Math.pow(10, 2)).toFixed(2),
"ItemNames": itemNames,
"ResumeUrl": BOLD.order.resumable_url,
"Items": items
};

_learnq.push(['track', 'Started Checkout', klaviyoPayload]);

</script>

   

 

icon

Best answer by julie.accardo 25 September 2021, 17:23

View original

5 replies

Userlevel 7
Badge +58

Hi @lngr no problem glad I could be of some help! I think the best case here going forward would be to contact Klaviyo support since they are the ones that can go into your site and account and have access to take a deeper look. Keep us updated here as well if you can about what Bold Commerce support says too. 

Thanks!

Alex

Userlevel 5
Badge +34

Hi @lngr,

Thanks for reaching out to the Klaviyo Community!

I’ll let others using Bold Commerce chime in here but there are a few things come to mind:

  • I’m curious if there have been any recent changes to your Shopify theme as this can sometimes disrupt additional JS that gets added to a website.
  • It could be worth following the steps in Bold Commerce’s help guide to try to reintegrate your Bold Commerce Started Checkout events with Klaviyo to see if that resolves the issue.
  • Can you confirm that the Started Checkout metric that you’re referencing is the one with the gear icon next to it and not the Started Checkout metric with the Shopify logo next to it? The metric with the gear icon is the one that updates with Started Checkout activity through Bold Commerce. 
  • In doing some research, I’ve learned that Bold Commerce’s Cashier app has a feature where it can be “partially-enabled” (meaning that it can be enabled in some geographies and rely on Shopify checkout for other geographies). If that’s the case and you’re starting to see some more activity through the Shopify Started Checkout event and less activity through the Bold Commerce checkout, there could be extra setup that you need to complete by updating the “merchant scripts.” 

Since the script was built by Bold Commerce, it would be on them to help you further troubleshoot any technical issues with the script they’ve coded. 

I hope this helps!

Julie

Badge +2

Thanks @julie.accardo for your answer.

  • There was no change to our theme
  • I followed carefully the tutorial you’ve linked but it seems now outdated (last updated in 2018). It worked during months/years but not since July - https://gist.github.com/boldsupport/64a00464b46af660967d6ee3ded2ea1f
  • Yes I can confirm
  • We haven’t partially enabled it, it’s enabled 100% of the time, all our orders go through the Bold Cashier checkout

 

Userlevel 7
Badge +58

Hi @lngr,

I believe @julie.accardo is on the right track here and offered the right path. If BoldCommerce checkout stopped working, it’s not a Klaviyo-supported integration so we’re not going to be able to troubleshoot it or look into your custom Boldcommerce code in any more detail. However, I would definitely consider reaching out to support as they could also check for the possibility that there are multiple klaviyo.js snippets. Support could verify is if there are duplicate API keys present i.e. multiple onsite javascript snippets and if so, you’ll need those to be removed by support so that there are no issues on your site.

 

Keep us updated,

Alex

Badge +2

Thanks for the clarification @alex.hong - it’s really appreciated.

I’ve checked again, and from the Chrome console it doesn’t seem there are duplicate calls.

I’ve forwarded the thread to Bold Commerce, which I have been in contact since the issue started.

Maybe you wan to check our website here and test it yourself.

 

Reply