# Bundesbank SDMX Web Service API
1 **What is the Bundesbank SDMX Web Service API?**
--------------------------------------------------
[Bundesbank SDMX Web Service API](https://api.statistiken.bundesbank.de/doc/index.html?urls.primaryName=Deutsche%20REST%20API%20Dokumentation){#par-oui7o8}
With the Bundesbank SDMX Web Service, the Bundesbank offers a technical REST-API interface that can be used to automatically download statistical data by calling a URL.{#par-e56u2i}
Content provided:{#par-o1e86a}
* Statistical data (e.g. Macroeconomic time series, real-time data)
Metadata about the data
* Data formats: SDMX-ML 2.1, SDMX-JSON, CSV
Metadata only as SDMX-ML
Technical basics:{#par-ia9o11}
* REST API (i.e. communication via standardised web addresses)
* Default format: JSON
Access via HTTPS (encrypted).
The API is updated regularly.
For more information on SDMX: [sdmx.org](https://sdmx.org/){#par-e763i9}
2 **Retrieve data**
-------------------
### 2.1 **Retrieve individual time series**
**Endpoint:**{#par-aa1aia}
/data/{flowRef}/{key}{#par-ao6u8o}
**flowRef** : Identifier of the data flow (e.g. BBEX3)
**key**: Time series key (e.g. D.USD.EUR.BB.AC.000){#par-a3132u}
**Example:**{#par-uieao5}
{#par-ui4iu2}
**Wildcard and OR Operator**{#par-a358oa}
**Wildcard:**
Parts of the key can be left empty to query multiple time series.
Example: D..EUR.BB.AC.000 (all currencies against the Euro){#par-o1u924}
**OR Operator:**
Use + to specify multiple values in a single component.
Example: M.ISK.EUR+USD.CA.AC.A01 (ISK/EUR and ISK/USD){#par-i76ua3}
### 2.2 **Retrieve all time series of a data flow**
**Endpoint:**{#par-u8oa6o}
/data/{flowRef}{#par-i772u6}
**Example:**{#par-i1a83u}
{#par-i9e785}
**Note:** Depending on the amount of data, the response may take longer.{#par-ae932i}
### 2.3 **Retrieve multiple time series at once**
**Endpoint:**{#par-ao1e3e}
/data/tsIdList (POST request){#par-u1a4o9}
**Example Request:**{#par-e4i47e}
\[
"BBEX3.M.DKK.EUR.BB.AC.A01",
"BBEX3.M.DKK.EUR.BB.AC.A02"
\]{#par-io4eie}
### 2.4 **Formats for data queries - See chapter 4**
3 **Retrieve metadata**
-----------------------
Metadata on data structures, data flows, codelists, and concept schemes can also be queried.{#par-u4a7a4}
**Datastructure**
/metadata/datastructure/BBK/{resourceID}
Example:
**Data flow**
/metadata/dataflow/BBK/{resourceID}
Example:
**Codelist**
/metadata/codelist/BBK/{resourceID}
Example:
**Conceptscheme**
/metadata/conceptscheme/BBK/{resourceID}
Example: {#par-ii5u7i}
**Parameters**{#par-a6u653}
The amount and type of information provided **can be controlled** using the following parameters:{#par-o3iaee}
* **format**: Specifies the format of the response.
* **detail**: Determines the level of detail in the response.
* **references** : Specifies whether references to related metadata should be included.
To retrieve all metadata for data structures, data flows, codelists, and concept schemes, omit the **{resourceID}** in the endpoint.{#par-i24i7u}
4 **Data query parameters**
---------------------------
| Query parameters | Description |
|---------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| **startPeriod** **endPeriod** | By passing a date range with the query parameter "startPeriod"/"endPeriod", it is possible to limit the period of observation. The supported formats are: **YYYY** for annual data (e.g. 2016) Example [https://api.statistiken.bundesbank.de/rest/data/BBBZ1/A.ZV00.INET.A00.A12.000.IN.DE.N?startPeriod=2012\&endPeriod=2016](https://api.statistiken.bundesbank.de/rest/data/BBBZ1/A.ZV00.INET.A00.A12.000.IN.DE.N?startPeriod=2012&endPeriod=2016) **YYYY-S\[1-2\]** for semi-annual data (e.g. 2019-S1) Example [https://api.statistiken.bundesbank.de/rest/data/BBDB2/H.DE.Y.A.C.IFRS.B.A.K.E.E001.VGH.A?startPeriod=2017-S1\&endPeriod=2019-S1](https://api.statistiken.bundesbank.de/rest/data/BBDB2/H.DE.Y.A.C.IFRS.B.A.K.E.E001.VGH.A?startPeriod=2017-S1&endPeriod=2019-S1) **Y** **YYY-Q \[1-4\]** for quarterly data (e.g. 2020-Q2) Example [https://api.statistiken.bundesbank.de/rest/data/BBEE1/Q.DE.AAA.XY0AAA.R.AADTB.M00?startPeriod=2019-Q4\&endPeriod=2020-Q2](https://api.statistiken.bundesbank.de/rest/data/BBEE1/Q.DE.AAA.XY0AAA.R.AADTB.M00?startPeriod=2019-Q4&endPeriod=2020-Q2) **YYYY-MM** for monthly data (e.g. 2019-01) Example [https://api.statistiken.bundesbank.de/rest/data/BBDP1/M.DE.N.HVPI.C.A00000.VGJ.LV?format=sdmx_generic_xml\&lang=de\&startPeriod=2018-06\&endPeriod=2020-06](https://api.statistiken.bundesbank.de/rest/data/BBDP1/M.DE.N.HVPI.C.A00000.VGJ.LV?format=sdmx_generic_xml&lang=de&startPeriod=2018-06&endPeriod=2020-06) **YYYY-W\[01-53\]** for weekly data (e.g. 2019-W01) Example [https://api.statistiken.bundesbank.de/rest/data/BBDE1/W.DE.Y.WAI.A2N400000.A.N.R00.A?format=bbk_csv\&startPeriod=2025-W45](https://api.statistiken.bundesbank.de/rest/data/BBDE1/W.DE.Y.WAI.A2N400000.A.N.R00.A?format=bbk_csv&startPeriod=2025-W45) **YYYY-MM-DD** for daily and business data (e.g. 2019-01-01) Example [https://api.statistiken.bundesbank.de/rest/data/BBEX3/D.USD.EUR.BB.AC.000?startPeriod=2020-11-05\&endPeriod=2020-11-10](https://api.statistiken.bundesbank.de/rest/data/BBEX3/D.USD.EUR.BB.AC.000?startPeriod=2020-11-05&endPeriod=2020-11-10) |
| **preparedAfter** | The parameter preparedAfter can be used to query all time series that have been updated since a certain point in time. The preparedAfter parameter must be specified in the format YYY-MM-DD'T'hh:mm:ss hh:mm, e.g. 2026-01-01T16:30:00+01:00 Example [https://api.statistiken.bundesbank.de/rest/data/bbex3/D..EUR.BB.AC.000?preparedAfter=2026-01-01T16:30:00+01:00](https://api.statistiken.bundesbank.de/rest/data/bbex3/D..EUR.BB.AC.000?format=bbk_csv&preparedAfter=2026-01-01T16%3A30%3A00%2B01%3A00&detail=full) |
| **detail** | The detail parameter can be used to specify the desired amount of information returned by the web service. Possible options are: **full**: All data values and attributes are returned (default). Example **dataonly**: Only data values are returned, without attributes. Example **serieskeyonly**: Time series keys, without attributes and data values. Example **nodata**: Time series keys, including attributes, but without data values. Example |
| **firstNObservations** | The firstNObservations parameter allows the maximum number of observations to be returned per requested time series, starting with the first observation. Example [https://api.statistiken.bundesbank.de/rest/data/BBEX3/D.USD.EUR.BB.AC.000?detail=full\&firstNObservations=27](https://api.statistiken.bundesbank.de/rest/data/BBEX3/D.USD.EUR.BB.AC.000?detail=full&firstNObservations=27) |
| **lastNObservations** | The parameter lastNObservations allows the maximum number of observations to be returned per requested time series, starting from the last observation (backwards). Example [https://api.statistiken.bundesbank.de/rest/data/BBEX3/D.USD.EUR.BB.AC.000?detail=full\&lastNObservations=12](https://api.statistiken.bundesbank.de/rest/data/BBEX3/D.USD.EUR.BB.AC.000?detail=full&lastNObservations=12) |
| **firstNVintages** | The parameter firstNVintages is used to determine how many of the first available computational versions per indicator are returned. This parameter applies only to real-time data. Example |
| **lastNVintages** | The parameter lastNVintages is used to determine how many of the last available computational versions per indicator are returned. This parameter applies only to real-time data. Example |
| **startVintage** **endVintage** | The startVintage and endVintage parameters define a period from which the vintages for real-time data are to be returned. The supported formats are **YYYY** , **YYYY-MM-DD** This parameter applies only to real-time data. Example [https://api.statistiken.bundesbank.de/rest/data/BBKRT/M.DE.S.P.CM1.PP000.R.I?startVintage=2020\&endVintage=2023](https://api.statistiken.bundesbank.de/rest/data/BBKRT/M.DE.S.P.CM1.PP000.R.I?startVintage=2020&endVintage=2023) |
{#par-u97ueu}
**Note:**{#par-ua7i4o}
If more than 200 time series or different periodicities are in CSV format, a ZIP file is returned. {#par-i4oi7e}
5 **Return parameters**
-----------------------
The response format is selectable.{#par-a199au}
| SDMX-ML 2.1 | sdmx_generic_xml / application/xml | XML-Format |
|-------------|------------------------------------------------|-----------------------------------------------|
| SDMX-JSON | sdmx_json / application/json | JSON-Format |
| SDMX-CSV | sdmx_csv / text/csv | CSV-Format (max. 200 time series per request) |
| BBK-CSV | bbk_csv / application/vnd.bbk.data+csv | Bundesbank CSV format |
| BBK-CSV-ZIP | bbk_csv_zip / application/vnd.bbk.data+csv-zip | ZIP containing multiple CSV files |
{#par-o6a33i}
6 **Language of return**
------------------------
* **de** (e.g. "de-DE"): German attributes, otherwise English as fallback
* **en** (e.g. "en-US"): English attributes, otherwise German as fallback
* **No specification:** Complete document
7 **Status codes (server responses)**
-------------------------------------
| **Status code** | **Significance** |
|-----------------|------------------------------------------------------------------------------------------|
| **200** | Request successful, data will be delivered. |
| **400** | Incorrect request (e.g. invalid parameters). |
| **404** | No matching results were found. |
| **406** | Requested format is not supported. |
| **410** | Requested resource is no longer supported. |
| **413** | Too much data. The data is generated in the background and can be requested again later. |
| **500** | Internal error, please try again later. |
| **501** | Function not yet implemented. |
| **503** | Web service temporarily unavailable. |
{#par-ie383a}
8 **Further information**
-------------------------
The API is very flexible and offers many ways to query data and metadata in a targeted manner.{#par-i2a2o7}
For large volumes of data, the response time may be longer.{#par-e4348o}
For details on SDMX, see [sdmx.org](http://sdmx.org/) .{#par-a945i4}
**Tip**: Use the examples from this guide and adapt them to your needs. This allows you to quickly and easily retrieve the data you want.{#par-u4e798}
If you have any questions or problems, please contact the Bundesbank support hotline.