I'm trying to understand the lastVisit field of the CustomerJourney for an order in the GraphQL API. For each order we can get the CustomerJourney preceding that order which includes following fields:
What I would expect here is that the firstVisit always matches the first moment from moments list, while the lastVisit always matches the latest moment from the moments list.
My main question is this: I noticed that if lastVisit is not empty, then the latest moment in the moments field matches the lastVisit, but sometimes the moments list is not empty, but the lastVisit field is. Does anyone know why this happens? Is this some bug or does it happen for specific cases?
Background problem: I would like to find the UTM tags in the last link that led to an order. The obvious thing was to check the lastVisit field and take the UTM tags from there, but than I noticed that this field is sometimes missing, even though there are some moments with UTM tags linked to that same order.
Solved! Go to the solution