Difference between revisions of "Data Query Web Service"
(→Extended HTTP Query Parameters) |
(→Overview) |
||
Line 2: | Line 2: | ||
= Overview = | = Overview = | ||
− | The Data Query web service offers both a RESTful GET API which conforms the SDMX Specification, and a RESTful POST API which supports advanced features such as joining mulitple datasets and selecting lists of series. Both the GET and POST web service support the SDMX standard parameters such as startPeriod and endPeriod, in addition to this, both APIs support advanced parameters to support features such as paging and calculations. | + | The Data Query web service offers both a RESTful GET API which conforms the [https://github.com/sdmx-twg/sdmx-rest/blob/master/v2_1/ws/rest/docs/4_4_data_queries.md SDMX Specification], and a RESTful POST API which supports advanced features such as joining mulitple datasets and selecting lists of series. Both the GET and POST web service support the SDMX standard parameters such as startPeriod and endPeriod, in addition to this, both APIs support advanced parameters to support features such as paging and calculations. |
Both REST and POST APIs offer the same [[Category:SdmxDataFormat|data formats]] as valid reponse formats, this can be controlled via the '''format''' data query parameter, or by using the HTTP Accept Header. | Both REST and POST APIs offer the same [[Category:SdmxDataFormat|data formats]] as valid reponse formats, this can be controlled via the '''format''' data query parameter, or by using the HTTP Accept Header. |
Revision as of 13:39, 9 December 2020
Contents
Overview
The Data Query web service offers both a RESTful GET API which conforms the SDMX Specification, and a RESTful POST API which supports advanced features such as joining mulitple datasets and selecting lists of series. Both the GET and POST web service support the SDMX standard parameters such as startPeriod and endPeriod, in addition to this, both APIs support advanced parameters to support features such as paging and calculations.
Both REST and POST APIs offer the same as valid reponse formats, this can be controlled via the format data query parameter, or by using the HTTP Accept Header.
This document describes the Syntax of both the GET and POST API. Both APIs share the same Header Parameters and Query Parameters, as such these sections are applicable to both APIs.
REST GET
Entry Point | /ws/public/sdmxapi/rest |
Access | Public |
Http Method | GET |
Compression | gzip supported |
Response Format | Determined by Accept Header - default SDMX 2.1 Structure Specific Data |
Response Statuses | 200 - Ok 400 - Bad URL Syntax 500 - Server Error |
HTTP Headers
The Accept Header is used to define the output format, to transform the data to. The supported accept header values are
In addition, the following optional header parameters can be used to provide further details on the incoming dataset. If these details are not provided, the Fusion Registry will interrogate the dataset header to get the information. If the dataset is a non-SDMX format, or does not contain the required information in the header, then an error response will be returned.
HTTP Header | Purpose | Allowed Values |
---|---|---|
Accept | This can be used to define the response format of the data | See Accept Headers |
Accept-Language |
This optional header can be used to set the locale to return any multilingual text in (names and descriptions). If the text does not exist in the specified locale, then the default rules will be applied to find the next best appropriate locale. The corresponding locale parameter can be used to override this HTTP Header |
Any valid locale, example: en |
Standard HTTP Query Parameters
The Extended query paramters are supported by both GET and POST queries, and are part of the official SDMX API.
Request Parameter | Purpose |
---|---|
param name | param value |
Extended HTTP Query Parameters
The Extended query paramters are supported by both GET and POST queries, and are not part of the official SDMX API.
Request Parameter | Purpose |
---|---|
param name | param value |