mbaersch / request-repeater

change and forward incoming requests to a new endpoint (Custom Tag Template for Server-Side Google Tag Manager)
Apache License 2.0
2 stars 0 forks source link

Error: "Body omitted because it contains binary data" #1

Open AlanBoydell opened 2 months ago

AlanBoydell commented 2 months ago

Using the template, I expect to see en=myCustomEventName in the Request Body, but instead I see the following message: "Body omitted because it contains binary data".

However the event does indeed show up in the report at the endpoint.

image

Here is the configuration of my tag:

image

For the original GA4 tag, the "en=" variable does indeed appear in the request body.

PS: Thanks and congrats on this amazing tag. It is going to be extremely useful to me. I can't believe it doesn't exist by default.

mbaersch commented 2 months ago

Hi,

as far as I can see, everything works as expected? Request body inspection in the preview is indeed not very helpful but your request contained the parameter inside the body (at least once) and the template obviously changed the value when it arrived correctly at the endpoint (?)

I think inside Tag Assistant, you will only see a body if it is in JSON format and everything else leads to this message... But I am not very sure about that as Google sometimes builds strange stuff.

If you want to see the new value as a get parameter, the incoming request should already contain it (with a different value for example).