MCP server for Swiss Federal Statistical Office (BFS) data access
This server presents well-structured catalog and data tools with generally good naming conventions and complete Zod schemas. Most tools follow verb_noun patterns (search_datasets, get_dataset_info, list_themes). However, there are significant gaps: output schemas are not formally documented in the tool definitions, descriptions lack actionable recovery hints, and error handling returns generic error messages without self-correction guidance. The server shows above-average attention to parameter constraints (enums, ranges) and descriptions, placing it solidly in the 'fair to good' range. Parameter descriptions average ~80 chars and are present for all parameters, which is strong. Tool compositions are logical (search → get_info → get_metadata → query), but output field naming consistency and error categorization need improvement.
Get a simplified view of available dimensions and their values for a PXWEB dataset. This is useful for quickly understanding what filters you can apply when querying data. Returns dimension codes and all possible values.
Get detailed information about a specific BFS dataset using its BFS number or asset number. Returns comprehensive metadata including title, description, available languages, publication date, and links to data files.
Get complete metadata structure for a BFS dataset from the PXWEB API. Returns information about all available dimensions, their codes, and possible values. Use this before querying data to understand what filters you can apply.
Retrieve time-series data from the Swiss Stats Explorer (SSE) API. This is a modern SDMX-based API that works well for time-series data. Use get_sse_metadata first to see available dimensions. You can filter by dimensions and time periods.
Get metadata for a Swiss Stats Explorer (SSE) dataset. Returns available dimensions and their possible values. Use this before calling get_sse_data to understand what filters you can apply.
Output schemas are not formally documented. Tools return structured responses (JSON in text fields), but callers cannot know the exact shape, field types, or presence guarantees of returned objects. search_datasets returns datasets array with title/numberBfs/numberAsset/publicationDate fields, but this is inferred from code, not declared in the tool schema.
Error responses lack recovery guidance and categorization. The catch blocks return generic 'Error {message}' text without telling the LLM whether the error is retryable, user-fixable, or fatal. Example from catalog-tools.js: 'Error searching catalog: {error.message}' does not indicate what the agent should do next (retry? ask user for different query? call a different tool?).
Inferred effective spec: <=2025-11-25.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-22 | D | 58 | <=2025-11-25 | v2 |
| 2026-03-09 | D | 50 | - | v1 |
Retrieve statistical data from a BFS dataset using the PXWEB API. You can optionally filter by specific dimensions. Use get_dataset_metadata first to see available dimensions and values for filtering. Returns data in JSON-stat format by default.
List all available statistical themes (categories) in the BFS catalog. Each theme has a name, prodima number (for filtering), and theme code. Use the prodima number with search_datasets to filter by theme.
Search for statistical datasets in the Swiss Federal Statistical Office (BFS) catalog. Search by keywords, themes, spatial divisions, and other criteria. Returns a list of matching datasets with their BFS numbers and metadata.
Parameter descriptions lack format specifications and constraints. Examples: 'numberBfs' description says 'BFS number (FSO number) of the dataset (e.g., "px-x-1502040100_131")' includes a hardcoded example value that LLMs may reuse literally. 'publishingYearStart' and 'publishingYearEnd' descriptions lack regex patterns or date format guidance ('YYYY' vs 'YYYY-MM-DD'?). 'query' parameter in get_sse_data lacks explanation of valid dimension codes and expected array vs single value behavior.
Output chaining IDs are not guaranteed. If an LLM calls search_datasets and gets back 'numberBfs', it can immediately call get_dataset_info or get_statistical_data. However, the response structure uses inconsistent field names ('numberBfs' in search results vs 'numberBfs' parameter in get_dataset_info, naming is consistent here, but other tools may not preserve this). No documentation confirms all necessary IDs for multi-step workflows are included.
Descriptions for similar tools lack clear disambiguation. 'get_dataset_metadata' vs 'get_dataset_dimensions' both retrieve metadata about datasets, the distinction (one returns full dimension info from PXWEB, one returns 'simplified view') is not obvious from descriptions alone. LLMs may pick the wrong one or call both unnecessarily.
No explicit documentation of optional vs mutually-exclusive parameters. In get_dataset_info, both 'numberBfs' and 'numberAsset' are optional, but what happens if both are provided? If neither is provided? The description doesn't state which is required or whether they are mutually exclusive. Same for get_statistical_data and get_sse_data 'query' parameter, is it always optional, or required for certain dataset types?
No pagination or result-limiting guidance in descriptions. Tools like search_datasets default to limit=50 (good), but other tools (get_dataset_metadata, get_sse_metadata) do not mention how many results they return or whether pagination is supported. If dimensions or SSE values number in the thousands, responses could balloon the context window.