Each REST API request can specify the data format we should use to format your results. You specify the desired output format by sending an Accept header with your
Accept header might look like this:
The header name (
Accept including the required space after the colon) is followed by a valid MIME type specification. The REST API accepts the following MIME type format specifiers:
application/xml: XML format. (
text/xmlwill also work.)
application/csv: Comma-separated value format
Not all REST API resources support the CSV MIME type. Consult the supported parameters for the specific REST API resource for details.
If you omit the Accept header from your request, the default output format is JSON.
The HTTPS response header
Content-type contains the MIME type code for the format used for the response output data. It should match what you asked for in your query.
For more information on the structure of the output data, see Data Models for REST API Payloads.