-
Session Conversion Rate and Conversion Name with Spaces
So I’m scratching my head a bit on this one. I’ve been smoothly sailing along getting
sessionConversionRate
for a variety of conversions using GA4 Data API. It’s all smooth sailing as long as the request metric looks likesessionConversionRate:conversionName
.
Now I have a customer (unfortunately I don’t have direct access to their GA4 account) who has named their conversions likeconversion with space
. So, naturally, I fire off a request for the metricsessionConversionRate:conversion with space
… and, boom, error:Metric names must only contain letters, numbers, or _. Received a metric name = session_conversion_rate[conversion with space]
No worries, I thought, I’ll just replace the space with underscore. Problem solved, right? Wrong. I try that and end up with another error message:
Did you mean sessionConversionRate:conversion with space? Field sessionConversionRate:conversion_with_space is not a valid metric. For a list of valid dimensions and metrics, see https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema
So, here I am, ringing the bell for help. Is there a magic trick or workaround I’m missing here?
Log in to reply.