GET Export Report XML Format


Description of the XML export format of the GET Export Report API.

Table of Contents

The xml format writes XML to the HTTP response body.

Format Parameter:  xml

Response Content-Type:  application/xml

Response Content-Disposition:  The Content-Disposition HTTP header is set to the value of the <report> name attribute with the underscore character (_) substituted for any space, comma, or semicolon character plus the .xml extension.

OK Response

Status Code:  200

XML responses without error have this DTD structure:

<!ELEMENT results (meta,data)>

<!-- meta: contains meta information about the results. -->
<!ELEMENT meta (filters?,subqueries?,sorts?,columns,totalCount)>

<!-- data: contains zero or more rows of data -->
<!ELEMENT data (row*)>

<!-- filters: (Optional) contains information about the filters applied to this 
     export result if applicable. -->
<!ELEMENT filters (filter+)>

<!-- filter: Contains information about one filter applied to this export result. -->
<!ELEMENT filter (source,readable)>

<!-- source: String representation of the original filter or sort parameter. -->
<!ELEMENT source (#PCDATA)>

<!-- readable: Contains the readable filter String with Table and Column 
     DisplayName's substituted for id's. -->
<!ELEMENT readable (#PCDATA)>

<!-- subqueries: (Optional) contains information about the subqueries applied to this 
     export result. Only present if a <subquery>'s parent <table> is included 
     within the export result and the <subquery> has a description. -->
<!ELEMENT subqueries (subquery+)>

<!-- subquery: meta information about subquery used to fill the export result -->
<!ELEMENT subquery (tablePath,displayName,description)>

<!-- sorts: (Optional) contains information about the sorts applied to this 
     export result if applicable. -->
<!ELEMENT sorts (sort+)>

<!-- sort: Contains information about one sort term applied to this export result. -->
<!ELEMENT sort (tablePath,columnId,source)>

<!ATTLIST sort direction (asc|desc) #REQUIRED>

<!-- columns: meta information about the columns of the export result. The order 
     of child <column> elements matches the order of <v> elements in each 
     <data> <row>. -->
<!ELEMENT columns (column+)>

<!-- column: meta information about one the columns of the export result. -->
<!ELEMENT column (id,displayName,tablePath)>

<!-- id: The id of the column -->

<!-- tablePath: The table resource path -->
<!ELEMENT tablePath (#PCDATA)>

<!-- columnId: The column id -->
<!ELEMENT columnId (#PCDATA)>

<!-- displayName: The displayName of the column or table -->
<!ELEMENT displayName (#PCDATA)>

<!-- description: descriptive text -->
<!ELEMENT description (#PCDATA)>

<!-- totalCount:  The total number of results to be returned based on the 
     filter and columns parameters. This can differ from the length of the 
     data array if the limit and offset parameters are specified. -->

<!ELEMENT totalCount (#PCDATA)>

<!-- row: One row of results -->
<!ELEMENT row (v+)>

<!-- v: One "cell" of results. "v" means "value" -->

<!-- attribute v:url: The url of the value as configured by the <column>'s 
     <url_template> -->
Example 1. Example XML Output Format
<?xml version="1.0" encoding="UTF-8"?>
             <source>/student@fname like 'J%'</source>
             <readable>'Student', 'First Name' like 'J%'</readable>
             <source>/student@lname = 'Hernadez'</source>
             <readable>'Student', 'Last Name' = 'Hernandez'</readable>
        <sort direction="asc">
            <source>/student@lname asc</source>
        <sort direction="asc">
            <source>/student@fname asc</source>
            <displayName>Student ID</displayName>
            <displayName>First Name</displayName>
            <displayName>Last Name</displayName>
        <v url="/some/url/177">Hernandez</v>
        <v url="/some/url/213">Hernandez</v>

Error Response

Status Code:  400 and 500

XML responses with error have this DTD structure:

<!DOCTYPE messages [
<!-- messages: The set of error messages -->
<!ELEMENT messages (message+)>

<!-- message: one error message -->
<!ELEMENT message (#PCDATA)>
Example 2. Example XML Error Output Format
<?xml version="1.0" encoding="UTF-8"?>
    <message>The filter "/student@id &amp; 173" does not match filter grammar. The "Operator" definition is missing or unparseable.</message>