I have set up AWIN Server Tag (Stape).
In AWIN I get a “critical issue”, but I don’t understand the problem.
How can I set the Server-to-Server cookie, AWIN wants?
It says: Issues with the Server-to-Server Cookie The first-party cookie for Server-to-Server tracking could not be found. If this transaction came via an affiliate link, please make sure that the Server-to-Server cookie is set. (Ignore this if the transaction didn’t come via an affiliate link.)
I can see there is a outgoing request to set a cookie with {server_container_url} instead of a value.
Could that be connected to this topic and could that be a problem?
When you check this do you have the ‘awc’ parameter in the url? In other words do you have an awin click id that should be set in the cookie?
Have you checked if you have an awin_awc cookie?
The server tag sets the ‘awin_awc’ cookie when triggered in page view mode and there is an ‘awc’ query in the page_location or page_referrer parameter.
So there may be a problem in your case:
a) no hit is coming to the server or the tag is not triggered in page view format when the url has awc parameter.
b) you are not using a first party subdomain and the cookie cannot be set because of this.
Somehow I could fix it by updating the old cHTML tags of the web container (now using the EdinCuturic tag templates as explained here: https://www.youtube.com/watch?v=YBVx8CX_fmQ)
So it seems like the problem was coming from the server tag, but the server tag was not getting the awin_awc value. Although I don’t know what the problem was.
You probably only have a cookie being sent with the web event, so you definitely need to sort this out and make sure the ‘awin_awc’ cookie is set (the web tag sets a different cookie).
Are you using a first party subdomain for sGTM?
Everything looks normal from your screenshots. There should be no outgoing requests in the page_view work format, it just sets the cookie if there is awc in the url.
Can you check the outgoing hit on the conversion event?
We are using Usercentrics for our CMP. The variable {{Usercentrics - Variable - AWIN}} is by default false - once consent is provided, it changes to true. Usercentrics pushes a datalayer event called consent_status once the user provides/denies consent. We have set up our own subdomain for our sGTM tracking and connected this one to the stape container.
AWIN reports frequently the following critical issues:
No Affiliate Click or Missing MasterTag
The first-party cookie could not be found. If this transaction came via an affiliate link, then please make sure the MasterTag is correctly installed on all landing pages of your website. (Ignore this if the transaction didn’t come via an affiliate link. If you’re seeing this message because you’re using a third-party tracking platform, please consider upgrading your tracking in line with the Awin Gold Standard.)
Issues with the Server-to-Server Cookie
The first-party cookie for Server-to-Server tracking could not be found. If this transaction came via an affiliate link, please make sure that the Server-to-Server cookie is set. (Ignore this if the transaction didn’t come via an affiliate link.)
AWIN reports frequently the following critical issues:
Both of these warnings seem to indicate that there was no awin click ID in the transactions. This is generally normal, as not every conversion is likely to be made after clicking on awin ads.
As far as I remember, Awin has an option in its interface to get a link with a test click ID. You can run a preview of your containers, make purchases when clicking with the test click ID, and make sure that everything is being transferred correctly.
It is difficult to determine from the screenshots whether everything is configured correctly, as it is not known what is in your variables, how the triggers work, etc. However, I do not see any obvious problems.
The only reason why the click ID may not be transferred is if sGTM is not running in first-party context. That is, your sGTM subdomain is sgtm.example.de, but events are sent from example.com. However, you have indicated that you have connected the subdomain and are using it in your tracking.
@Alex : thanks for your input! is there anything special that we need to setup to have this first-party context or is it enough to have the tracking server reachable at the subdomain?
We got it working now. To put it simply, the problem was that server side tracking “couldn’t keep up” with determining and setting the appropriate channel information.
This particularly affected new visits or visits for which no server side cookie had yet been set, but also all visits with an existing server side cookie if the new entry resulted in a change of channel assignment - e.g. first entry via SEA, further entries via Direct, then later again via AWIN or in any other order…
To be honest, I can’t understand how this is supposed to work with other advertisers. On the one hand, server-side tracking is so fast that the hit has already been fired long before any data is exchanged with the client. On the other hand, the writing process of the cookie with the channel value is extremely delayed - we are talking about at least three to six seconds!
I decided on a solution based on the supposedly faster initial channel assignment on the client side. In principle, this now works in such a way that the client container makes the channel assignment for AWIN BEFORE sending the GA4 base tag to the server container and then sends it along as the “awin_channel” event parameter. The server container now takes this value directly from the event data of the incoming event and uses it DIRECTLY for the AWIN tracking hit.
To make this work, we changed the trigger for the client-side “Last Click Identifier” so that it is fired before the GA4 base tag. Unfortunately, selecting the same “Consent Initialization” level and setting the priority to 9 did not work straight away. That’s why we also set the GA4 Base Tag to fire the identifier immediately beforehand.
What you are describing sounds like a configuration issue in your GTM containers. I would strongly recommend contacting a tracking specialist who can check everything and configure it correctly.
Especially this part, it shouldn’t be like that:
On the other hand, the writing process of the cookie with the channel value is extremely delayed - we are talking about at least three to six seconds!