GarouDan GarouDan - 1 year ago 85
PHP Question

Real time visitors from Google Analytics. How to get it?

Is there any way using gapi (preferable) to retrieve the real time visitors from Google Analytics?

I tried to pass a date range like:

begin: 2012-12-12 09:49:04
end: 2012-12-12 09:49:05

but it didn't work.

I did a research and couldn't find a solution yet.

Someone can help me?

jk. jk.
Answer Source

Access to the real-time data is not yet available through the api. See the following:

Access to Real Time data

Scraping Real Time Visitors from Google Analytics

The only way to get it currently is to look at it in the Google Analytics web interface: