Unit 2: SDMX API

The SDMX (Statistical Data and Metadata Exchange) API provides programmatic access to official statistical data from sources like national statistics offices and international organisations. It supports standardised queries, making it easy to retrieve, filter, and analyse economic and social indicators—ideal for automating reports, dashboards, and data analysis workflows.

SDMX API v2 introduces improved performance, simplified query structures, and enhanced support for JSON and CSV formats. It aligns more closely with modern web standards, making integration easier. Key updates include better error handling, pagination, and more intuitive endpoints—streamlining access to complex statistical datasets for developers and data analysts alike.

In this unit, we'll go over what the SDMX API v2 allows and we'll review the importance of knowing the capabilities of the APIs you’re working with. We'll also explore some of the features of the ninth release of RESTful API SDMX 3.0 and provide you with links to useful resources.

What does the SDMX API v2 allow?

The SDMX REST API allows implementers to offer programmatic access to statistical data and metadata over HTTP.

SDMX API v2 offers a modern, streamlined interface for accessing both aggregated statistical data and microdata. Key features include support for multiple response formats—JSON, XML, and CSV—for flexible integration. The API introduces simplified RESTful endpoints, advanced query filtering, and pagination for efficient handling of large datasets. It enhances performance and provides clearer error messages for easier debugging. Crucially, v2 supports access to microdata, enabling more granular analysis beyond traditional time-series or aggregated statistics. It also includes metadata queries and access to Data Structure Definitions (DSDs), ensuring high interoperability with external systems and supporting robust data retrieval, analysis, and reporting workflows.

Select each tab below to learn more.

API URLs
The API URLs provide the ability to retrieve statistical data or reference metadata using keys (with options for wildcarding and support for the OR operator), data or metadata flows, and data or metadata providers.
API query strings
The API query strings provide the ability to:
  • Further refine queries for statistical data or reference metadata using time information (start period and end period)
  • Retrieve updates and revisions only
  • Return the results of a query in various formats, such as XML or JSON
Examples
Below are a few examples of API URLs and query strings. The URLs allow you to identify the resource to be retrieved, while the query strings give additional information about the desired results or allow you to filter further.

Data:
https://host/data/context/agency/id/version/key? + query string

Structure:
https://host/structure/type/agency/id/version/item? + query string

Data validity:
https://host/schema/context/agency/id/version? + query string

Data availability:
https://host/availability/context/agency/id/version/key/componentId? + query string

Metadata:
https://host/metadata/metadataset/provider/id/version? + query string
https://host/metadata/metadataflow/agency/id/version/provider? + query string
https://host/metadata/structure/type/agency/id/version/provider? + query string

Know SDMX API capabilities

SDMX API implementations differ, so it's important to know the capabilities of the APIs you are using. Let's go over a few details to help.

  • SDMX registries will provide structure resources but may not provide data resources.
  • SDMX data APIs will provide data resources but may not provide structure resources.
  • Each SDMX API implementation may differ in the SMDX API v2 features that it implements:
    • It may not implement the latest version of the standard.
    • It may not implement all features of the standard.

To find SDMX APIs and determine the capabilities of API(s) you are interested in, check out the SDMX Global Discovery Service (SGDS) and Test Compatibility Kit (TCK).

Web services – the SDMX v2 API

The RESTful API maintained by SDMX-TWG Task Force 4 has had nine releases since 2011. Its first release was called SDMX 2.1.

The ninth release (SDMX 3.0), which was launched in September of 2021, has the following features:

  1. Enhanced data queries and reference metadata support
  2. Restructured resources (breaks backwards compatibility to v1.*)
  3. Metadata maintenance (additional HTTP verbs – POST, PUT, DELETE)
  4. Schema query "allowed content" in more formats
  5. Improved clarity and documentation of the API
  6. Deprecated SOAP API

SDMX 3.0 RESTful API v2.0.0 resources

You are encouraged to review the following references for more details on SDMX 3.0 RESTful API v2.0.0:

  1. Open API definition
  2. Developers’ documentation & cheat sheet
  3. Features and report issues on GitHub
  4. API spec on SwaggerHub

What do you know?

It's time to test your knowledge. Which of the following statements are true?

Select all that apply and then select Submit.

Coming next

In this next unit, you'll learn about SDMX API data queries.

AI assistant

Need help finding something? I am an AI Assistant that's here to help!

Welcome to SDMX AI assistant

What are you looking for?

SDMX AI assistant

By using this AI-powered service ("Service"), you acknowledge and agree to the following:

This Service uses generative AI to assist with statistical analysis and research. While the Service strives to deliver useful information, the output ("Output") may contain inaccuracies, omissions, or biases. The Output is provided for informational purposes only and should not be considered professional advice. You remain responsible for how you interpret and use the Output.

The BIS makes no warranties regarding the accuracy or completeness of the Output and accepts no liability for any loss or damage resulting from its use.

Do not include or share personal, private, confidential or proprietary information when using the Service.

By using this technology, you agree to the Terms and Conditions.

How the assistant can help you

Understand SDMX standards

Ask and get clear explanations about SDMX standards.

Navigate the website

Find tools and documentation on website quickly.

Explore SDMX tools

Ask about API, software and libraries supporting SDMX.

Access documentation

Locate technical guides, specifications, and FAQs.