SDMX-REST Service Clients

Note

Additional information about how to execute SDMX-REST queries against a specific service can be found in the following tutorial:

Build SDMX-REST queries.

class pysdmx.api.qb.ApiVersion(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)

The version of the SDMX-REST API.

class pysdmx.api.qb.RestService(api_endpoint, api_version, data_format=DataFormat.SDMX_JSON_2_0_0, structure_format=StructureFormat.SDMX_JSON_2_0_0, schema_format=SchemaFormat.SDMX_JSON_2_0_0_STRUCTURE, refmeta_format=RefMetaFormat.SDMX_JSON_2_0_0, avail_format=AvailabilityFormat.SDMX_JSON_2_0_0, registry_format=RegistryFormat.FUSION_JSON, pem=None, timeout=5.0)

Synchronous connector to SDMX-REST services.

api_endpoint

The entry point (URL) of the SDMX-REST service.

api_version

The most recent version of the SDMX-REST specification supported by the service.

data_format

The default format for data queries.

structure_format

The default format for structure queries.

schema_format

The default format for schema queries.

refmeta_format

The default format for reference metadata queries.

avail_format

The default format for availability queries.

registry_format

The default format for registration queries.

pem

In case the service uses SSL/TLS with self-signed certificate, this attribute should be used to pass the pem file with the list of trusted certicate authorities.

timeout

The maximum number of seconds to wait before considering that a request timed out. Defaults to 5 seconds.

availability(query)

Execute an availability query against the service.

Return type:

bytes

data(query)

Execute a data query against the service.

Return type:

bytes

reference_metadata(query)

Execute a reference metadata query against the service.

Return type:

bytes

registration(query)

Execute a registration query against the service.

Return type:

bytes

schema(query)

Execute a schema query against the service.

Return type:

bytes

structure(query)

Execute a structure query against the service.

Return type:

bytes