Skip to main content
Glama
malkreide

SBB Open Data MCP Server

by malkreide

SBB Passagierfrequenz nach Bahnhof

sbb_get_passenger_frequency
Read-onlyIdempotent

Fetch passenger frequency data for SBB stations. Includes daily, workday, and non-workday boarding and alighting averages, filterable by station, canton, and year.

Instructions

Ruft Passagierfrequenzdaten (Ein-/Aussteigende) für SBB-Bahnhöfe ab.

Datensatz wird jährlich aktualisiert. Enthält Tagesschnitt (DTV), Werktagesschnitt (DWV) und Nicht-Werktages-Schnitt (DNWV) pro Bahnhof und Jahr.

Args: params (PassengerFrequencyInput): Filterparameter: - station_name (Optional[str]): Bahnhofsname (Teilsuche) - canton (Optional[str]): Kantonskürzel, z.B. 'ZH' - year (Optional[str]): Jahr, z.B. '2024' - limit (int): Max. Resultate (1–100), Standard 20 - offset (int): Offset für Paginierung - response_format (str): 'markdown' oder 'json'

Returns: str: Passagierfrequenzdaten mit DTV/DWV-Werten und Paginierungsinfo. Schema: {station, year, daily_avg, workday_avg, non_workday_avg, canton, operator}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultsYesRecords as returned by data.sbb.ch
paginationYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.4.0
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$defs": {
      +    "PaginationOutput": {
      +      "properties": {
      +        "has_more": {
      +          "title": "Has More",
      +          "type": "boolean"
      +        },
      +        "next_offset": {
      +          "anyOf": [
      +            {
      +              "type": "integer"
      +            },
      +            {
      +              "type": "null"
      +            }
      +          ],
      +          "title": "Next Offset"
      +        },
      +        "offset": {
      +          "title": "Offset",
      +          "type": "integer"
      +        },
      +        "returned": {
      +          "title": "Returned",
      +          "type": "integer"
      +        },
      +        "total_count": {
      +          "title": "Total Count",
      +          "type": "integer"
      +        }
      +      },
      +      "required": [
      +        "total_count",
      +        "returned",
      +        "offset",
      +        "has_more",
      +        "next_offset"
      +      ],
      +      "title": "PaginationOutput",
      +      "type": "object"
      +    }
      +  },
      +  "description": "A page of raw data.sbb.ch records plus pagination.",
      +  "properties": {
      +    "pagination": {
      +      "$ref": "#/$defs/PaginationOutput"
      +    },
      +    "results": {
      +      "description": "Records as returned by data.sbb.ch",
      +      "items": {
      +        "additionalProperties": true,
      +        "type": "object"
      +      },
      +      "title": "Results",
      +      "type": "array"
      +    }
      +  },
      +  "required": [
      +    "pagination",
      +    "results"
      +  ],
      +  "title": "PagedRecordsOutput",
      +  "type": "object"
      +}
  2. Changed3 schema fields changedv0.3.4
    • changedInput schema / $defs / PassengerFrequencyInput / properties / canton / anyOf
      Previous value: -[
      -  {
      -    "maxLength": 2,
      -    "minLength": 2,
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "maxLength": 2,
      +    "minLength": 2,
      +    "pattern": "^[A-Za-z]{2}$",
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / $defs / PassengerFrequencyInput / properties / year / anyOf
      Previous value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "pattern": "^\\d{4}$",
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedOutput schema / (root)
      Previous value: -{
      -  "properties": {
      -    "result": {
      -      "title": "Result",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "result"
      -  ],
      -  "title": "sbb_get_passenger_frequencyOutput",
      -  "type": "object"
      -}New value: +null
  3. First observedv0.1.0

TDQS

A3.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Die Annotationen decken bereits readOnly, idempotent, openWorld und non-destructive ab. Die Beschreibung ergänzt nützlichen Kontext: jährliche Aktualisierung, enthaltene Kennzahlen (DTV/DWV/DNWV), Rückgabeschema und Paginierungshinweis. Angaben zu Auth oder Rate Limits fehlen, sind aber angesichts der Annotationen nicht kritisch.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Die Zweckbeschreibung steht vorne, gefolgt von strukturierten Args- und Returns-Abschnitten. Die Länge ist für ein Tool mit sechs Parametern angemessen, wenngleich die Parameterliste das Schema teilweise wiederholt.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Für ein Datensuchtool mit Output-Schema, klaren Annotationen und sechs Filterparametern ist die Beschreibung weitgehend vollständig: sie erklärt Zweck, Aktualisierungsfrequenz, Filter und Rückgabefelder. Es fehlt lediglich eine Einordnung, wann dieses Tool gegenüber den Geschwistern zu verwenden ist.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Da die Schema-Beschreibungsabdeckung als 0% angegeben ist, muss die Beschreibung die Parameter erklären. Sie listet alle Filter (station_name, canton, year, limit, offset, response_format) mit Typen, Beispielen und Standardwerten auf und kompensiert damit die Lücke, auch wenn sie teilweise das Schema dupliziert.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Die Beschreibung nennt ein klares Verb (abrufen) und eine spezifische Ressource (Passagierfrequenzdaten für SBB-Bahnhöfe). Sie grenzt sich inhaltlich von Geschwistern wie sbb_get_trains_per_segment oder sbb_compare_stations ab, benennt aber keine konkreten Alternativen.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Es wird nicht gesagt, wann dieses Tool gegenüber Alternativen wie sbb_compare_stations oder sbb_search_stations zu wählen ist. Die Filterparameter implizieren eine Nutzung, aber es fehlen explizite Einsatzbedingungen oder Abgrenzungen.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.