Hi,
Before I pose the question, please allow me to describe what I am trying accomplish. I am using AdHoc reports v201302 within C# .net (I think using the .net library). My goal is to grab reports from multiple accounts (different ClientCustomerIDs) contained within an MCC account and combine them into a single report.
Now I have already designed a logic to do this, which is as follows:
1. Create an AdwordsUser object and set the AdwordsUser.Config.ClientCustomerID property to the MCC Account's ClientCustomerID.
2. Get a list of accounts in the MCC account using the following classes: ManagedCustomerService, ManagedCustomerPage, ManagedCustomer (1 API Call)
3. Iterate through the ManagedCustomerPage.entries
3a. Parse ManagedCustomer.customerID to ClientCustomerID format (ex. 123-456-7890)
3b. Set AdwordsUser.Config.ClientCustomerID to parsed ManagedCustomer.customerID value
3c. Download report for particular account using ReportUtilties.GetClientReport() (1 API Call)
The above logic works fine although I think it is a bit inefficient in terms of API Calls. The number of API calls is 1 + n, where n is the number of accounts in an MCC account. So if there are 5 accounts, there will be six API calls.
So my question is as follows: Is there a more efficient way of accomplishing the logic using just less API calls? (1 API call would be ideal)
I am looking forward to your help. Thank you in advance.
Best regards,
Mark Ibanez