Skip to main content
Glama

Realtime delays at a station (GTFS-RT)

get_realtime_delays
Read-only

Retrieve realtime arrival and departure delays and cancellations for a single Swiss station using its 7-digit UIC number. Returns GTFS trip and route IDs, delay minutes, and status.

Instructions

Realtime arrival/departure delays and cancellations at one Swiss station from the national GTFS-RT trip-update feed (opentransportdata.swiss). Input the 7-digit UIC station number (use search_stations to find it; e.g. 8503000 = Zürich HB, 8507000 = Bern). Returns GTFS trip_id/route_id, delay in minutes and status (CANCELED/SKIPPED). Requires env OPENTRANSPORTDATA_API_KEY (free). For line names and platforms prefer get_departures.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "station_id": "<station_id>"
    },
    "name": "get_realtime_delays"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNo
station_idYes7-digit UIC/DiDok number, e.g. '8503000'
min_delay_minutesNoOnly trips delayed at least this much (cancellations always shown)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.3

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint and openWorldHint, and the description adds real behavioral context: the upstream data source, the required OPENTRANSPORTDATA_API_KEY env var (with a note that it is free), and the shape of returned data (trip_id/route_id, delay minutes, CANCELED/SKIPPED status). It stops short of describing pagination or how the limit interacts with results, which keeps it from a 5.

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?

Four compact sentences, front-loaded with what the tool returns and immediately followed by the input requirement and the alternative. Parenthetical examples and env-var notes are dense but each carries decision-relevant information.

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

Completeness5/5

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

With no output schema, the description still summarizes the return fields and status values, discloses the API-key requirement, and covers input sourcing and the sibling alternative. Nothing an agent needs to invoke it correctly is missing.

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

Parameters3/5

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

Schema coverage is 67% and the schema already documents station_id format with a pattern and example plus the min_delay_minutes semantics including the cancellations-always-shown caveat. The description mainly reinforces station_id sourcing via search_stations and says nothing about the limit parameter, so it adds only marginal meaning beyond the schema.

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

Purpose5/5

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

States a specific verb and resource (realtime arrival/departure delays and cancellations) scoped to one Swiss station and names the source feed. It also explicitly distinguishes itself from get_departures, so an agent can choose without opening a schema.

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

Usage Guidelines5/5

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

Gives the prerequisite step (use search_stations to obtain the 7-digit UIC number), concrete example IDs, and an explicit routing rule to get_departures when line names or platforms are wanted. Both when-to-use and the alternative are spelled out.

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

Deploy Server

Other Tools