Our Google account rep's tech contact also recommends avoiding cross-
client reports and instead running once per account contained within
the MCC umbrella.

I'm currently requiring the human to download a report via the UI to
fetch a list of accounts, from which I generate a configuration file.
Fortunately, this list of accounts changes infrequently enough that
this may work for now.

But as of v201008, there is apparently no fix or work-around for cross-
client functionality-- even using older API versions-- or no one has
revealed anything to the contrary.


On Feb 4, 10:11 am, daniel <[email protected]> wrote:
> Thanks for the sample code.
>
> Unfortunately, the example Python code crashes well before that point
> due to the 'entries' field not being present following the call to
> GetCampaignService(), regardless of supplying IDs to the selector or
> not, modifying the early part of the example based upon what I've
> found to work with other sample code, etc.
>
> I'll keep digging...
>
> But I must vent a little: I was expecting more thorough examples, more
> robust failure messages (e.g., "not implemented" rather than the
> misleading errors noted earlier in this thread), etc., for an API
> labeled v13.  To that end, when I do get this working, I'll post
> whatever I can to help others in future.
>
> On Feb 3, 10:05 pm, AdWords API Advisor <[email protected]>
> wrote:
>
> > Hi Daniel,
>
> > We don't have a LISP library, all the libraries that we maintain are
> > listed athttp://code.google.com/apis/adwords/docs/clientlibraries.html
> > and kept upto date with the latest version of AdWords API. So you can
> > use the Python library if that suits you.
>
> > As for your issue,
>
> > - CampaignService.get can retrieve only the campaigns of one account
> > at a time. So if you don't specify a clientEmail header, it will
> > return an empty list of campaigns (since MCC can't have campaigns).
>
> > - Cross client reports can fetch statistics across multiple accounts.
> > However, cross client reports are supported only in v13, they are not
> > yet supported in v201008 of AdWords API.
>
> > - The code example you are referring to doesn't run a cross-client
> > report. You need to modify the job to something like:
>
> > job = {
> >     'name': 'Test Campaign Report',
> >     'selectedReportType': 'Campaign',
> >     'aggregationTypes': ['Summary'],
> >     'startDay': '2009-01-01',
> >     'endDay': '2009-01-31',
> >     'selectedColumns': ['Campaign', 'CampaignId', 'CPC', 'CTR'],
> >     'crossClient' : true,
> >     'clientEmails' : [the list of clientEmails, or provide an empty
> > list for all clients]
>
> > }
>
> > Seehttp://code.google.com/apis/adwords/docs/developer/DefinedReportJob.html
> > for all possible list of fields for job. Also, you can refer 
> > tohttp://code.google.com/apis/adwords/docs/developer/adwords_api_report...
> > for the list of fields, aggregation types, etc.
>
> > - You can also remove the section that tries to fetch the list of
> > campaign ids, since it is isn't needed in your case. Also, change the
> > urls in the code example from sandbox.google.com to
> > adwords.google.com, to make calls against the production account.
>
> > Let me know if you have more questions.
>
> > Cheers,
> > Anash P. Oommen,
> > AdWords API Advisor.
>
> > On Feb 4, 12:27 am, daniel <[email protected]> wrote:
>
> > > Unfortunately, v13 seems unable to get a list of Campaign IDs... or at
> > > least the example Python code associated with that version seems
> > > incapable.
>
> > > Running schedule_campaign_report.py fails because no 'entries' are
> > > found after the call to GetCampaignService().  Attempting to populate
> > > the list of campaign IDs within the 'selector' didn't resolve it,
> > > either.
>
> > > What is the most current, stable version of the API?  Should I switch
> > > from Python to another language? (Common Lisp would be preferred.)
>
> > > Thanks.
>
> > > On Feb 2, 11:05 pm, AdWords API Advisor <[email protected]>
> > > wrote:
>
> > > > Hi Daniel,
>
> > > > AdWords API v201008 does not support cross client reports, so you
> > > > cannot use it yet to get campaign budgets across all accounts. The
> > > > support for this will be added in a future version of AdWords API.
> > > > Till then, you might want to consider using the v13 cross-client
> > > > reports.
>
> > > > Cheers,
> > > > Anash P. Oommen,
> > > > AdWords API Advisor.
>
> > > > On Feb 3, 4:23 am, daniel <[email protected]> wrote:
>
> > > > > I'm attempting to:
> > > > >   1. define a Campaign Performance report
> > > > >   2. download report
> > > > >   3. process locally
> > > > >   4. revise budgets
>
> > > > > But stuck on running the second step.
>
> > > > > First of all, is downloading a report an appropriate way to fetch
> > > > > campaign budgets across all accounts?  (This works from the UI, and
> > > > > the Reporting docs suggest that if you can do it from the UI, it can
> > > > > be done through the API.  It works through both new and old UI
> > > > > reports.)
>
> > > > > Through the API, I'm finding "clientEmail" header to be required to
> > > > > run the report and therefore must also be added when creating the
> > > > > report.  If omitted or mismatched, running the report fails.
>
> > > > > Without the header, I get
> > > > > AuthenticationError.CLIENT_CUSTOMER_ID_IS_REQUIRED when attempting to
> > > > > download the report.
>
> > > > > With the header containing email address of the person who created the
> > > > > MCC account, I then get
> > > > > ReportDefinitionError.INVALID_REPORT_DEFINITION_ID when attempting to
> > > > > download the report.  (Same header, same value used in both scripts)
>
> > > > > With using my own address both when defining and downloading the
> > > > > report, I get a valid file but no content; e.g., CSV file with headers
> > > > > and Total row but nothing in between.
>
> > > > > example resulting .csv file:
>
> > > > > "Campaign Budgets (Feb 2, 2011)"
> > > > > Account,Campaign ID,Campaign,Budget,Cost,Cost / conv. (1-per-click)
> > > > > Total,,,,0.00,0.00
>
> > > > > I suspect that I'm simply supplying the wrong header or wrong value:
> > > > > in this case, the wrong email address, but I've used the only ones
> > > > > that seem appropriate: first, my own adwords email address and then
> > > > > the one associated with the MCC account.  The only other possibly
> > > > > relevant email addresses would be of individual client accounts within
> > > > > the umbrella of the MCC account, but then I'd be running one report
> > > > > for each account.
>
> > > > > I'm using v201008 with adwords_api_python_13.2.0 library, making only
> > > > > necessary changes to example code:
> > > > > add_keywords_performance_report_definition.py and download_report.py,
> > > > > changed for Campaign reports and adding the header.
>
> > > > > I couldn't find a clean way to inject the header, but this works:
>
> > > > > client = AdWordsClient(path=os.path.join('..', '..', '..', '..'))
> > > > > client._headers["clientEmail"] = "[email protected]"
>
> > > > > Any relevant recommendations would be appreciated.  Thanks!

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
http://adwordsapi.blogspot.com
http://groups.google.com/group/adwords-api
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en

Reply via email to