Getting source/medium by date.

57 views
Skip to first unread message

Royce

unread,
Aug 9, 2009, 1:28:58 PM8/9/09
to google-analytics-api - GA Data Export API
Hi there, I am trying to use the API to extract visits by date by
medium/source (e.g. like on the Analytic Traffic Sources pages. I
can't find a way to specify the dimensions/metrics to give me this
information.

I am currently using:
'dimensions','ga:source'
metrics','ga:visits'
'filters','ga:source==(direct),ga:medium==referral,ga:medium==organic'

and I get the totals for my time period, but I would like the
individual amounts for each filter by day. I hope I am clear on this.

Thanks for any help!

Nick

unread,
Aug 10, 2009, 12:43:46 PM8/10/09
to google-analytics-api - GA Data Export API
Hi,

You can just remove the filter you have (to get all sources and
mediums) and add the ga:date dimension to get the breakdown by day.
Here's a link to an example:
http://code.google.com/apis/analytics/docs/gdata/gdataExplorer.html?dimensions=ga%253Adate%252Cga%253Asource%252Cga%253Amedium&metrics=ga%253Avisits&start-date=2009-07-27&end-date=2009-08-10&max-results=50

-Nick
Reply all
Reply to author
Forward
0 new messages