Hey Everyone,
I recently set up Amplitude to capture Shopify store event data, and I am seeing a bit of unexpected behavior. While Amplitude does seem to be capturing all events on our website, I’m having a bit of an issue piecing together the full user journey for customers who go completely through the funnel and make a purchase on the site.
Problem: For purchasing customers, the event stream is getting broken apart as coming from two different users which I’ll refer to as the pre-checkout user and checkout user.
Pre-Checkout User
This stream has the most events and captures all the website browsing type events (page view, product clicked, product details viewed, product added, etc.). This user has a device_id in the form of an alphanumeric string (ie. jHdTf2LNvsXrKDkwnq2Yto) in addition to information about the device type, and properly allocates a amplitude_id, session_id as well as everything else I would expect. The user_id is also generally null because the customer hasn’t signed into their account or created one yet.
Checkout User
The weird behavior comes when that same pre-checkout user starts their checkout process as the checkout started, purchase item, and order created events all get logged to a new user (different device_id, amplitude_id). The device_id is now in the form of a UUID (ie. 31518f28-9d40-59be-aa34-a1e5633f0f01) with no information in regards to the device type, platform, etc. From my understanding of the docs, it seems that the amplitude_id is generated based off the device_id and user_id. Since the device_id is now different it makes sense that the amplitude_id would be different, but I am trying to understand why the device_id is all of a sudden different.
Some other points to note for the checkout user:
- user_id now has a value — email (this is expected)
- session_id = -1 (unexpected)
Curious if anyone in the community has run into this problem before when setting Amplitude up on their Shopify store? To me, it seems like something may be happening with the cookie that is stored on the user’s device to recognize their device_id? My hypothesis is that when the customer starts a checkout that checkout process is happening in some other window/browser that is not aware of the original cookie. Is there any further setup I should be doing to ensure the appropriate device_id from the pre-checkout user gets passed into the checkout user?
Thanks in advance, and excited to join the community!
Sean
Best answer by Denis Holmes
View original