Unique Event ID does not match Event Variable Value

Hello,

my issue does not directly relate to Facebook. I’m using the unique event id feature for deduplicating events for pinterest.
The part with passing the variable to the sGTM and using it there for the serverside reuests does work fine.
My problem is on the web-gtm side: I trigger a pinterest tag at the “view_item” event using the “Unique Event ID” variable. In debug mode I can see that the pinterest tag does not use the value for “unique event id” which belongs to this event (the sgtm part does!), it uses the “unique event id” value from the event “window loaded” which happens later. I really have no idea why this happens. Any suggestions are welcome!
Lucas

  1. Make sure that the tag that sends data to the server and the tag with the web event are fired on the same triggers. Unique event id will be different if one tag uses e.g. DOM ready and the other Window loaded.

  2. Also unique event id will be different if you use tag sequencing in the tag.

Hi Alex,

Thanks for your answer. I am not using tag sequencing at this point. I may not have expressed myself clearly, because the sGTM does what it should and both tags are triggered by the same event (the correct ID arrives in the sGTM).

I have created screenshots that may make the problem easier to understand.

Both the Pinterest tag and the GA4 tag are triggered by the “view_item” event:

For the “view_item” event, the unique event ID variable ends with “443”:

In the triggered Pinterest tag, the value of the event ID ends with “830” (yes, correct variable is configured):

The correct value (…443) is also used in the GA4 tag:

The value that the Pinterest tag uses as the event ID comes from the “Window loaded” event that takes place later:


I have no idea why this is the case. The sGTM part seems to work correctly.

edit: Sorry for making several Posts. I was not allowed to add more images in one post. Furthermore my first two posts are still hidden (the forum has wrongly classified them as advertising) and the forums automatic unblocking feature does not work.

Your problem is that you are passing the event_id parameter also to google tag, you can see it here in the screenshot:

Accordingly, the event_id from the configuration tag is used, not from the event tag.

1 Like

Tank you for your help, this was exactly the issue. Now it’s working perfect fine!

1 Like