MISSING PARAMETER /INVALID PARAMETER error on report download

600 views
Skip to first unread message

API_DCH

unread,
May 30, 2018, 10:55:11 PM5/30/18
to AdWords API and Google Ads API Forum
Hi,

I am using the following url and the xml request to retrieve data from KEYWORD_PERFORMANCE_REPORT.


XML:

<?xml version="1.0" encoding="utf-8"?>
<soap:Header>
<developerToken>{{User::varDevToken}}</developerToken>
<clientCustomerId>{{User::varClientId}}</clientCustomerId>
<userAgent>v1</userAgent>
</RequestHeader>
</soap:Header>
<soap:Body>

<reportDefinition>
       <fields>CampaignId</fields>
       <fields>AdGroupId</fields>
       <fields>Id</fields>
       <fields>Date</fields>
       <fields>Device</fields>
       <fields>AdNetworkType2</fields>
       <fields>AveragePosition</fields>
       <fields>Clicks</fields>
       <fields>Cost</fields>
       <fields>Impressions</fields>
       <fields>Interactions</fields>
       <predicates>
           <field>CampaignStatus</field>
           <operator>IN</operator>
           <values>ENABLED</values>
           <values>PAUSED</values>
           <values>REMOVED</values>
       </predicates>
       <predicates>
           <field>AdGroupStatus</field>
           <operator>IN</operator>
           <values>ENABLED</values>
           <values>PAUSED</values>
           <values>REMOVED</values>
       </predicates>
       <predicates>
           <field>Status</field>
           <operator>IN</operator>
           <values>ENABLED</values>
           <values>REMOVED</values>
           <values>PAUSED</values>
       </predicates>
       <predicates>
           <field>IsNegative</field>
           <operator>NOT_EQUALS</operator>
           <values>true</values>
       </predicates>
       <predicates>
           <field>Id</field>
           <operator>NOT_IN</operator>
           <values>3000000</values>
           <values>3000004</values>
           <values>3000006</values>
       </predicates>
       <dateRange>
           <min>20180101</min>
           <max>20180430</max>
       </dateRange>
   </selector>
   <reportName xmlns="https://adwords.google.com/api/adwords/cm/v201802">Test Report</reportName>
   <reportType xmlns="https://adwords.google.com/api/adwords/cm/v201802">KEYWORDS_PERFORMANCE_REPORT</reportType>
   <dateRangeType xmlns="https://adwords.google.com/api/adwords/cm/v201802">CUSTOM_DATE</dateRangeType>
   <downloadFormat xmlns="https://adwords.google.com/api/adwords/cm/v201802">XML</downloadFormat>
</reportDefinition>

</soap:Body>
</soap:Envelope>


When I initiate the call I am receiving following error message. I also tried to include _rdxml parameter inside the xml body before <reportDefinition> tag, I receive the same error message. 
Please help me to resolve this issue.

<ApiError><type>ReportDownloadError.MISSING_PARAMETER</type><trigger>Missing report definition</trigger><fieldPath></fieldPath></ApiError><ApiError><type>ReportDownloadError.INVALID_PARAMETER</type><trigger>Missing client information</trigger><fieldPath></fieldPath></ApiError>

Thanks
Sam

Dannison Yao (AdWords API Team)

unread,
May 31, 2018, 2:28:24 AM5/31/18
to AdWords API and Google Ads API Forum
Hi Sam,

It seems that there is no problem with your report definition. Could you confirm if you have properly entered your clientCustomerId? The error "Missing client information" means that you may not be passing the client account information in your request.

Regards,
Dannison
AdWords API Team

API_DCH

unread,
May 31, 2018, 9:25:15 AM5/31/18
to AdWords API and Google Ads API Forum
Hi Dannison,

Yes, I have  correct customerID, I have other api call using the same customerid which works well. I think the problem is xml request body is looking for a parameter for storing the response data because I have choose to download the report in XML format.
How to pass a parameter in the xml body. I tried various combinations from examples that I saw on google but it returns the same error.
Can you please check my url, the header and the xml body request for any errors. It looks simple call but for some reason I am unable to retrieve the data from this specified report.

Can you please provide me a sample code for retrieving data from KEYWORD_PERFORMANCE_REPORT that contains

1. URL
2. Header 
3. XML request.

Thanks
Sam

Dannison Yao (AdWords API Team)

unread,
Jun 1, 2018, 3:17:50 AM6/1/18
to AdWords API and Google Ads API Forum
Hi Sam,

Could you try using an HTTP POST method instead of a SOAP structure request for passing your account information (i.e. client Id, developer token, etc.)? Here is an example for your reference. Let me know how this works out for you.
Reply all
Reply to author
Forward
0 new messages