Unlike reports in previous AdWords API versions, v201109 AdHoc reports are downloaded by POSTing XML to a URL rather than defining them using a SOAP service; therefore they have no WSDL document to describe the XML payload. To ensure that your ReportDefinition XML is valid when sending it to the API, we are now publishing an XML Schema Definition (XSD).

This XSD is tied to the versioned Report Download endpoint, allowing us to make incremental changes to reporting as needed. Here’s an example URL used to obtain the XSD for v201109 ReportDefinitions:


How to use this XSD

There are many tools to use to validate XML against an XSD. Here we will show how to use the common command-line tool xmllint to validate against the XSD. First, download the reportDefinition.xsd to a working directory. Next, save some ReportDefinition XML to a file, such as reportDefinition.xml:

<reportDefinition xmlns="https://adwords.google.com/api/adwords/cm/v201109">
 <reportName>Custom Adgroup Performance Report</reportName>

Now run the following command from the directory you placed these two files in:

$ xmllint --schema reportDefinition.xsd reportDefinition.xml
[xml omitted]
reportDefinition.xml validates

This step verifies that your ReportDefinition XML is well-formed for use with the AdWords API report downloads.

If you have any questions, please post on the forum or attend one of the AdWords API Office Hours Hangouts.