artemklevtsov / RGA

A Google Analytics API client for R
http://cran.r-project.org/package=RGA
32 stars 13 forks source link

get_realtime and filter ORGANIC #60

Closed MarekLu closed 4 years ago

MarekLu commented 5 years ago

I found an issue in get_realtime function. I need to filter rt:medium ORGANIC results only:

d <- get_realtime(
  profileId = gaid,
  metrics = "rt:pageviews",
  dimensions = "rt:pageTitle",
  filters = "rt:medium==ORGANIC")

It ends with an erorr:

Error: Client error: (400) Bad Request
Invalid parameter: Invalid value 'rt:medium==,GANIC' for filters parameter.

Is there any way how to use ORGANIC (it must be in uppercase) in RGA?

MarekLu commented 5 years ago

There's a working workaround:

rt:medium=~[O]RGANIC

artemklevtsov commented 4 years ago

No related with RGA code.