I have a custom metric in Google Analytics. I'm inserting it using Google Analytics Measurement Protocol.
When I make a request to Google Analytics, is there a way to replace the existing value of the metric instead of adding new value to it?
Let's say that the current value of that metric is cm1=100
. When I send the value 500
via Measurement protocol, I want cm1
to equal 500
, not 500+100=600
. How do I do that?
I'm currently using this kind of URL to insert custom metrics:
https://www.google-analytics.com/collect?v=1&ni=1&tid={tracking_id}&cid={cid}&t=event&ec={category}&ea={action}&el={label}&cm1=500