Solved

Shopify Integration losing user Activity after Purchasing

  • 26 September 2022
  • 4 replies
  • 96 views

Badge +1

After following the integration setup between Shopify and Heap, and adding the checkout snippet to checkout.liquid, I am facing an issue. Every user who has purchased on the site, seen with “done: Shopify Event, Purchased” has no data associated with their user.

It seems that the checkout events are dissociating the user from their previous ID.

These users are the most important, so would love to have this fixed. 

icon

Best answer by dlad 26 September 2022, 23:20

View original

4 replies

Userlevel 5
Badge +4

Hi @RoryHD - I’ve escalated this to our support team. 

Userlevel 4
Badge +2

Thanks Dave! I have the support ticket and might be able to offer some guidance here as well. @RoryHD -- can you share screenshots / examples of such users? If I understand right, the users you are referring to show purchase data from Shopify, but no other behavioral data like clicks and pageviews. 

If that’s the case, it’s likely that what we call “clientside users” are not being merged with “Shopify users” via Heap’s identity feature. When Shopify data is backfilled from Shopify into Heap, the only way it can be attributed to the correct pre-existing users in Heap is through identity or user property matching. In your case, that is Shopify Customer ID, which is assigned as the Heap identity of your users. In order for incoming Shopify data to be attributed to existing Heap users, those existing Heap users must be identified by Shopify customer ID via Heap’s identify() API. Note this can also be done retroactively.

For example, if I visited your site, clicked around, did not purchase, and was not identified, but later re-visited and made a purchase, I would have Shopify data under the Heap user with Shopify customer ID of ‘devon’. But my pageviews and clicks would still be under a separate, non-identified “anonymous” user. What needs to happen is that when I revisit your site, I am identified through the heap.identify() API as heap.identify(‘devon’). At that point, the clientside (clicks/pageviews) user will be merged with the Shopify events user, all under one user with identity ‘devon’. That user with have both behavioral events and Shopify events.

Badge +1

Hi @dlad, thanks for your response. Attached is a screenshot of some of these users. You can see that the only events listed are ones from the API - no on-site activity.

I believe your explanation of the issue is correct. Is this not something that the integration and “checkout.liquid” snippet should handle through the integration itself?

Is there more custom code that needs to be inserted?

If there is a specific fix, or point at which to identify the user that would fix the issue, please let me know.

 

Userlevel 4
Badge +2

Hi Rory, ideally, clientside identity should automatically be captured as Shopify customer Id, and the Shopify “integration users” and clientside users will be merged. I will follow up with you directly in a support ticket.

Reply