Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google measurement protocol transactions not being recorded

I am issuing GET requests as defined in the Google Measurement Protocol from our server to record offline conversions.

The following test request (tracking id obfuscated)

https://www.google-analytics.com/debug/collect?v=1&tid=xx&cid=111300&t=transaction&ti=1500000&tr=100

validates against the /debug Endpoint (using Postman)

{
  "hitParsingResult": [ {
    "valid": true,
    "parserMessage": [ ],
    "hit": "/debug/collect?v=1\u0026tid=xxu0026cid=111300\u0026t=transaction\u0026ti=1500000\u0026tr=100"
  } ],
  "parserMessage": [ {
    "messageType": "INFO",
    "description": "Found 1 hit in the request."
  } ]
}

And shows up in the Sales Performance report in Google Analytics when submitted to the production endpoint using PostMan (i.e. without /debug/)

However I can't see any of the actual production data, submitted from the server in the Sales Performance report.

Any ideas?

like image 814
Matt Evans Avatar asked Mar 13 '17 07:03

Matt Evans


People also ask

Why is Google Analytics missing transactions?

Google Analytics may not correctly track all transactions on your website. For example, transactions are missed if users opt out of analytics tracking or go over GA's 500 hits-per-session tracking limit. Google Analytics can also record duplicate transactions if users return to or refresh an order confirmation page.

How long does it take for transactions to show in Google Analytics?

Many of your reports and explorations can take 24-48 hours to process data from your website or app.

How much transactions data in Google Analytics may not be accurate and it still would be OK?

In some guides/videos, you might learn that it's acceptable to have less than 5% of missing transactions (in other words, go for at least 95% accuracy).

What Cannot be tracked in Google Analytics?

You can't track Individual users Unfortunately, Google Analytics only allows to use a unique user ID and prohibits sending personal information, username or an IP address.


2 Answers

This is kind of tricky, yes the transaction is valid,but the debuger only check the syntaxis, but your Google Analytics configuration has not enabled that type of hit (t=transaction, That is only for Standart E-commerce). In my test account, I run that hit and this work. In your case, if your account is enhanced e-commerce is being filtered on the processing.

So here is a screeshot of you hit on my test view running on classic ecommerce. enter image description here

So you have 2 options to fix this, downgrade you e-commerce (not recommendable in all the cases)

Downgrade

If you do want to use that syntaxis, you have to uncheck the enhance e-commerce and that should work in your case. With your hit and with my configuration this works (a new account w/no filter and standard e-commerce enabled)

Attach information

The enhanced ecommerce was designed to be send attached with other hits (on event or pageview mainly).

For example, this hit is a no interaction event and it's valid for receive transaction and the purchase. Use no interaction events avoid fake sessions and allows to you import the data of the transaction without alter metrics as bounce rate. https://www.google-analytics.com/collect?v=1&t=event&ni=1&ec=Ecommerce&ea=Transaction&cid=2.2&tid=UA-xxxxx-1&ti=T12345&tr=35.43&pa=purchase

enter image descriptio[![enter image description here

like image 90
Kemen Paulos Plaza Avatar answered Jan 02 '23 04:01

Kemen Paulos Plaza


There is a data latency with Google analytics. Officially its 24 - 72 hours before data shows up in the standard reports.

From my own experience I can say depending upon how much data there is in your account you can see it as early as 12 - 24 hours.

If the debug end point says its a valid it you can assume its working fine.

like image 44
DaImTo Avatar answered Jan 02 '23 05:01

DaImTo