if you have the admin cookie in your browser, than you won’t be tracked. You need to delete that cookie first.
If you imported the contacts, than they won’t get tracked automatically, Mautic needs to make the connection. This is usually done by sending the first email out. Once they open/click emails, the contact is bound to an email address + computer (cookie) and you can see when they return.
@mikew , I just ran into this myself. Funny to read my answer and getting angry at myself.
In fact, my suggestion doesn’t work.
This is the issue I ran into (running 3.2.1 on this one)
1. User checks shopify page with Mautic tracking
tracking works perfectly, anonimous user is created, and tracked properly.
2. User chooses products, goes to the cart
tracking still works, contact is seen last in the cart.
3. User pays
tracking doesn’t register that, but it’s okay, shopify keeps its system closed.
4. Shopify Plugin submits the email data via API
new contact is created with NO tracking history, just an email address. Identified by Shopify Plugin.
this is still how it’s expected
5. Contact get’s a thank you mail with tracking image and a link
6. User opens email and clicks
here is the problem: even by opening on the same browser the Contact Nr. 2. will be continued to be tracked. Our Contact No.1. will be abadoned, and tracking won’t happen anymore, and previous tracking is also not merged together.
So we will have 2 profiles:
Contact No 1.: With pre-purchase info, anonymous
Contact No 2.: With Post-Purchase, identified
And both contacts would have the same Mautic Device Id.
I did reproduce this on multiple occasions.
I would love to know if this is normal behaviour.
The question is: will an anonymous contact merged into a known contact based on an email open?
when does the system merge an unknown contact into a known contact based on mautic device id?
If this is not happening, is that a bug or expected behaviour?
Device fingerprinting iirc doesn’t work as expected.
Collapsing a Cookie-based tracking anonymous contact into a known contact can only happen on link click if you append a parameter to your links in the email content that lands people on the site. The Mautic tracking pixel should pick up the HTML encoded email from the URL and automatically merge the activity history of the known contact and the anonymous contact.
I believe the second point of this bullet that you’re missing is to append your links back to the site with something like the following.
Hey @jordan_ryan , thank you so much for the answer.
To make sure I understand it right:
Someone visits shopify as an anonymous contact, creating a cookie.
This person purchases something, so I fire the tracking pixel containing the email address on the thank you page
The contact’s anonymous profile is now extended with the email = converted into a known contact?
@joeyk - Correct, the records are two-fold in the system until an identification event occurs, and the new anonymous contact gets identified, and they get merged to the identified contact.
I would say the cookie doesnt’ get created, but instead a contact gets created. You can actually see these contacts by going to Contacts and filtering for is:anonymous and you get your list of unidentified users and their behaviors.
I reality it’s not working like this. This is what happens:
Anonym contact visits 10 pages. Mautic leaves the cookie, an anonym contact is created. Lets say ID: 100. The tracking works even if IP is changed, all good.
The person decides to buy a product. He is tracked until the payment page. On the payment page, there is no tracking JS, Shopify doesn’t let us to place it there. So the trail stops at the payment page for ID 100.
Payment successful -
An API call is created, where email, name and purchased products are filled out. A new contact is created via API. We call it ID 200. This contact has no cookie placed anywhere, since he was created via server to server communication IN THE BACKGROUND.
Out person now passes the cart page, goes to the confirmation page. There is tracking script again. We can pass the email here to Mautic tracking, since the email is known to us now. So we add the email into the tracking code.
My expectation is, that Mautic realises, that I have ID 100, who’s cookie is on this computer and we are tracking this anonym contact for months, plus I have ID 200, created by API. And it seems, that based on ID 200’s email AND ID 100’s cookie info I shall merge them.
But this doesn’t happen. ID 100 will be ‘abandoned’, and ID 200 will be tracked in the future. So I will only have identified contacts AFTER they purchased something, and their visits from before the purchase will be ‘abandoned’.
Thank you for the idea.
Yes, it is publicly updateable.
I think the problem is, that first I created the contact with API, and just then identified an already existing contact. So Mautic is confused - and doesn’t merge the 2 contacts, but decides to follow only the second one.
If I am using the API to pass through an order, I am able to get the IP address in the payload. I can store this is a custom field, my question is "is there a way to merge the anonymous user based on the IP with the new user and his custom field IP ?
A work around is to have a hidden mautic form on the page that collects the order, before the data is sent into Mautic via api. The hidden form collects the email address during the order process and drops the cookie on the page.
Then if you match the email address coming in vai the API with the pre existing email addres inserted by the hidden form, the data should merge.
Are you doing this within Mautic or the API or some serverside scripting with SQL?
My Mautic is giving visitors new mautic and device IDs on every page load and when they fill out a form, they are added as a contact but none of their page visits are recorded because they are all considered separate.
Would you be willing to share the SQL? I have looked at the tables and figured out a few relations but I don’t want to pretend I know it all and miss something that is going to cause trouble elsewhere.