I use a slightly different format for the authorization; what you have may work in principle, too, but this is what I use (successfully):
Authorization: GoogleLogin auth=XXX Also, I'm formatting the clientCustomerId with dashes, 000-000-0000; I don't know if that's required. If you'd like to post what Fiddler shows for your exact request (masking IDs, of course), I can compare it to mine and possibly suggest something. On Tuesday, June 11, 2013 10:31:47 AM UTC-5, Keith wrote: > > Hi, I'm new to the Adwords API, and, at the moment, just figuring out how > to download my first ad hoc report. I'm using a language most of you are > probably not familiar with, but it's just a means of sending SOAP requests, > and I think the actual requests should be easy to understand. I'm not > including the language-specific parts of what I'm doing. My problem is that > I'm getting the error: > > ERROR: java.io.IOException: Server returned HTTP response code: 400 for > URL: > https://adwords.google.com/api/adwords/reportdownload/v201302 > > In your responses, please be kind :). I'm not only new to the Adwords API, > but to web services in general, and am not a web programmer. Thanks, Keith > P.s. info is below > The POST request has the following header (identifying info X'd out): > > authorization:GoogleLogin > developerToken:XXX ... > auth:XXXX..... > clientCustomerId:XXX-XX-XXXX > > I'm sending the POST request to: > https://adwords.google.com/api/adwords/reportdownload/v201302 using > "multipart/form-data" > > The body is: > > __rdxml="<reportDefinition> > <selector> > <fields>CampaignId</fields> > <fields>Id</fields> > <fields>Impressions</fields> > <fields>Clicks</fields> > <fields>Cost</fields> > <predicates> > <field>Status</field> > <operator>IN</operator> > <values>ENABLED</values> > <values>PAUSED</values> > </predicates> > </selector> > <reportName>Custom Adgroup Performance Report</reportName> > <reportType>ADGROUP_PERFORMANCE_REPORT</reportType> > <dateRangeType>LAST_7_DAYS</dateRangeType> > <downloadFormat>CSV</downloadFormat> > </reportDefinition>" > > > -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ 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 adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en --- You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.