Thanks Anash, It worked with advertiser account when tested on live adwords 
account, though It gives me below error when tested on sandbox environment. 

Bad Request AuthenticationError.CUSTOMER_NOT_FOUND @ ; trigger:'7972347823' 
Service[ReportInfoService.get

Can you suggest why is this error ?

Sumit

 Bad Request AuthenticationError.CUSTOMER_NOT_FOUND @ ; 
trigger:'7972347823' Service[ReportInfoService.get

On Thursday, June 28, 2012 3:37:59 PM UTC+5:30, Anash P. Oommen wrote:
>
> Hi Sumit,
>
> Looks like you are trying to download report for an MCC account rather 
> than an Advertiser account. Could you confirm if you are setting 
> clientCustomerId correctly in your code?
>
> Cheers,
> Anash P. Oommen,
> AdWords API Advisor.
>
> On Wednesday, 27 June 2012 19:12:57 UTC+5:30, sumit wrote:
>>
>> Hi, I am using the following example code provided in python client 
>> library to download a report. It is giving me the following error.
>>
>> AdWordsError: HTTP Error 400: Bad Request 
>> [ReportDefinitionError.CUSTOMER_SERVING_TYPE_REPORT_MISMATCH @ selector]
>>
>>
>> I am a beginner in this.Can anyone help on this please.
>>
>>
>> import os
>> import sys
>> sys.path.insert(0, os.path.join('..', '..', '..', '..', '..'))
>>
>> # Import appropriate classes from the client library.
>> from adspygoogle import AdWordsClient
>>
>>
>> # Specify where to download the file here.
>> path = 'c:/python26/tmp/report_download.csv'
>>
>>
>> def main(client, path):
>>   # Initialize appropriate service.
>>   report_downloader = client.GetReportDownloader(
>>       'https://adwords.google.com', 'v201109')
>>
>>   # Create report definition.
>>   report = {
>>       'reportName': 'Last 7 days CAMPAIGN_PERFORMANCE_REPORT',
>>       'dateRangeType': 'LAST_7_DAYS',
>>       'reportType': 'CAMPAIGN_PERFORMANCE_REPORT',
>>       'downloadFormat': 'CSV',
>>       'selector': {
>>         'fields': ['CampaignID','Clicks', 'Impressions','Cost']
>>         },
>>       # Enable to get rows with zero impressions.
>>       'includeZeroImpressions': 'false'
>>   }
>>
>>   file_path = report_downloader.DownloadReport(report, file_path=path)
>>
>>   print 'Report was downloaded to \'%s\'.' % file_path
>>
>>
>> if __name__ == '__main__':
>>   # Initialize client object.
>>   client = AdWordsClient(path=os.path.join('..', '..', '..', '..', '..'))
>>
>>   main(client, path)
>>
>>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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

Reply via email to