data.bl.ch
Open data portalsCHdata.bl.ch
OpenDataSoft open data portal data.bl.ch (188 datasets); example dataset: Covid-19: Tägliche Fallzahlen (Februar 2020 - Januar 2023).
Capabilities (5)
GET /v1/data/data-bl-ch/dataset1 creditOne dataset's full metadata: title, description, theme, publisher, licence, record count and the complete field list with types and labels.
GET /v1/data/data-bl-ch/datasets1 creditSearch over the portal's catalogue: matching datasets with id, title, description, theme, publisher and the fields each dataset exposes, plus the total match count.
GET /v1/data/data-bl-ch/export-json1 creditThe dataset's records as a flat JSON array (no envelope, no total count), suitable for bulk download of small and medium datasets.
GET /v1/data/data-bl-ch/facets1 creditFacet value counts for one dataset: the distinct values of each faceted field with how many records carry them.
GET /v1/data/data-bl-ch/records1 creditA page of up to 100 records from one dataset as JSON objects keyed by field name, with the total record count for the query.
Response example
The shape of data from data-bl-ch/dataset (Dataset metadata). A sample, not live data.
Example truncated, full shape in JSON from the API.
{
"visibility": "domain",
"fields": [
{
"name": "datum",
"description": "Datum",
"annotations": {
"facetsort": "-count",
"timeserie_precision": "day"
},
"label": "datum",
"type": "date",
"label_de": "datum",
"label_fr": "datum",
"label_en": "datum",
"label_it": "datum",
"description_de": "Datum",
"description_fr": "Datum",
"description_en": "Datum",
"description_it": "Datum"
},
{
"name": "georegion",
"description": "Kanton",
"annotations": {},
"label": "geoRegion",
"type": "text",
"label_de": "geoRegion",
"label_fr": "geoRegion",
"label_en": "geoRegion",
"label_it": "geoRegion",
"description_de": "Kanton",
"description_fr": "Kanton",
"description_en": "Kanton",
"description_it": "Kanton"
},
{
"name": "entries",
"description": "Tägliche Fälle",
"annotations": {},
"label": "entries",
"type": "int",
"label_de": "entries",
"label_fr": "entries",
"label_en": "entries",
"label_it": "entries",
"description_de": "Tägliche Fälle",
"description_fr": "Tägliche Fälle",
"description_en": "Tägliche Fälle",
"description_it": "Tägliche Fälle"
},
{
"name": "sumtotal",
"description": "Total Fälle",
"annotations": {},
"label": "sumTotal",
"type": "int",
"label_de": "sumTotal",
"label_fr": "sumTotal",
"label_en": "sumTotal",
"label_it": "sumTotal",
"description_de": "Total Fälle",
"description_fr": "Total Fälle",
"description_en": "Total Fälle",
"description_it": "Total Fälle"
},
{
"name": "pop",
"description": "Ständige Wohnbevölkerung 2020",
"annotations": {},
"label": "pop",
"type": "int",
"label_de": "pop",
"label_fr": "pop",
"label_en": "pop",
"label_it": "pop",
"description_de": "Ständige Wohnbevölkerung 2020",
"description_fr": "Ständige Wohnbevölkerung 2020",
"description_en": "Ständige Wohnbevölkerung 2020",
"description_it": "Ständige Wohnbevölkerung 2020"
},
{
"name": "version",
"description": "Version",
"annotations": {},
"label": "version",
"type": "text",
"label_de": "version",
"label_fr": "version",
"label_en": "version",
"label_it": "version",
"description_de": "Version",
"description_fr": "Version",
"description_en": "Version",
"description_it": "Version"
},
{
"name": "per1000persons",
"description": "Tägliche Fälle pro 1000 Personen",
"annotations": {
"facetsort": "-count",
"decimals": 1
},
"label": "per1000persons",
"type": "double",
"label_de": "per1000persons",
"label_fr": "per1000persons",
"label_en": "per1000persons",
"label_it": "per1000persons",
"description_de": "Tägliche Fälle pro 1000 Personen",
"description_fr": "Tägliche Fälle pro 1000 Personen",
"description_en": "Tägliche Fälle pro 1000 Personen",
"description_it": "Tägliche Fälle pro 1000 Personen"
}
],
"dataset_id": "10340",
"dataset_uid": "da_okxt4w",
"has_records": true,
"features": [
"timeserie",
"analyze"
],
"attachments": [],
"alternative_exports": [],
"data_visible": true,
"metas": {
"default": {
"title": "Covid-19: Tägliche Fallzahlen (Februar 2020 - Januar 2023)",
"title_de": "Covid-19: Tägliche Fallzahlen (Februar 2020 - Januar 2023)",
"title_fr": "Covid-19: Tägliche Fallzahlen (Februar 2020 - Januar 2023)",
"title_en": "Covid-19: Tägliche Fallzahlen (Februar 2020 - Januar 2023)",
"title_it": "Covid-19: Tägliche Fallzahlen (Februar 2020 - Januar 2023)",
"description": "<p>Covid-19-Monitoring. Tägliche Fallzahlen von Personen mit Wohnsitz BL. Die DateAsk with this source
A prompt for your agent that names this source and how to call it through the crw MCP.
Dataset metadata
Use data.bl.ch (data-bl-ch) from fastCRW Pergamon, capability "Dataset metadata" (dataset). You have a dataset id and need its schema, licence or record count before querying it. Example options: id=10340. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "data-bl-ch" and capability "dataset". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
Dataset search
Use data.bl.ch (data-bl-ch) from fastCRW Pergamon, capability "Dataset search" (datasets). You want to find datasets on this portal by keyword or theme and do not know a dataset id. Example options: where=theme='Transport', order_by=modified desc, offset=0. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "data-bl-ch" and capability "datasets". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
Dataset export as JSON
Use data.bl.ch (data-bl-ch) from fastCRW Pergamon, capability "Dataset export as JSON" (export-json). You want the whole dataset, or a filtered slice of it, as a plain JSON array rather than a paged envelope. Example options: id=10340. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "data-bl-ch" and capability "export-json". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
Dataset facets
Use data.bl.ch (data-bl-ch) from fastCRW Pergamon, capability "Dataset facets" (facets). You want to know the value distribution of a dataset's categorical fields without downloading rows. Example options: id=10340. Use the crw MCP tools: crw_find_data to confirm the source and its options, then crw_get_data with provider "data-bl-ch" and capability "facets". Tell me the credits used and cite the licence from the response. If the crw MCP tools are missing, install them with: npx -y crw-mcp install --api-key <your fastCRW API key>
Licence
OGD is machine-readable government data that can be reused under an open license (including for commercial purposes).
https://data.bl.ch/pages/welcome?flg=de-chAttribution
Display this wherever you show the data. It arrives on every response as provenance.attribution_text.
Source: data.bl.ch (Bundesamt für Gesundheit).
Cache: up to 3600s
