Recommended way to discover all website profiles for an account

25 views
Skip to first unread message

RG

unread,
May 9, 2012, 5:04:48 AM5/9/12
to Google APIs Client Library for Objective-C
Hi,

I'm trying to implement a basic setup process where the user of my
Cocoa app chooses from a drop down list which Google Analytics website
profile to use based on the Google account they used to sign in.

What is the best way to discover all website profiles for the user's
Google account?


From my understanding I have to run 3 separate queries:

(1) Query for all management accounts `[GTLQueryAnalytics
queryForManagementAccountsList]`

(2) Based on (1), query for all web properties `[GTLQueryAnalytics
queryForManagementWebpropertiesListWithAccountId:XYZ]`

(3) Based on (2), query for all website profiles `[GTLQueryAnalytics
queryForManagementProfilesListWithAccountId:XYZ webPropertyId:ABC]`

I've implemented 2 + 3 with batch queries.

Is this the most efficient way to discover all profiles or is there
another, recommended way?

Thanks,
Rico

Greg Robbins

unread,
May 9, 2012, 11:29:22 AM5/9/12
to google-api-obj...@googlegroups.com
Questions about use of the Google Analytics API should be directed to the forums at https://developers.google.com/analytics/community/

Reply all
Reply to author
Forward
0 new messages