Skip to main content
Glama
kintscher

swiss-rail-mcp

by kintscher

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
SWISS_TRANSPORT_DEBUGNoEnable verbose HTTP logging. Set to '1' to enable.

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
extensions
{
  "io.modelcontextprotocol/ui": {}
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
find_stationA

Search for Swiss public transport stations by name or partial name.

Use this tool to resolve a place name to one or more canonical station records before calling get_connections or get_stationboard, or to disambiguate between stations with similar names (e.g. "Bahnhof").

get_connectionsA

Find upcoming train, tram, bus, or boat connections between two stations.

Use this tool when the user asks for travel options between two named places in Switzerland (e.g. "next train from Bern to Zürich" or "how do I get from Lugano to Lausanne tomorrow at 8?"). Station names are resolved by the upstream API, so common spellings work directly.

get_stationboardA

Show the next departures from a Swiss public transport station.

Use this tool when the user asks "what's leaving from ?" or wants the live departure board for a specific stop, without a target destination in mind.

get_disruptionsA

Return currently active rail-traffic disruptions on the Swiss network.

Use this tool when the user asks "are there any disruptions today?", "is the line to X working?", or wants context on whether to expect delays on a route. Source: SBB rail-traffic-information feed.

get_station_facilitiesA

Report fixed facilities at a Swiss station: elevator, WiFi, step-free access, waiting room.

Use this tool when the user asks about accessibility, amenities, or what to expect at a station (e.g. "does Bern have step-free access?", "is there WiFi at Zürich HB?").

get_passenger_frequencyA

Return how busy a Swiss station typically is (average daily passengers).

Use this tool when the user asks "how busy is X?", "is it a major station?", or wants context for travel-time/connection planning.

last_train_homeA

Find the latest realistic train back to home_station tonight.

Use this tool when the user asks "when's the last train home from ?" or wants reassurance about staying out late. Looks at connections departing around 22:00 (or after_time if given) and returns the latest one, plus a human-readable summary.

plan_evening_outA

Plan an evening out: outbound options now plus the latest viable return.

Use this tool when the user is thinking about going somewhere for the evening and wants to know both how to get there and the safest last train back home.

commuter_summaryA

Daily commute snapshot: next connections home → work plus any active disruptions.

Use this tool for a quick morning sanity-check ("how's my commute looking?"). Combines opendata.ch connections with SBB rail-traffic-information.

journey_with_layoverA

Chain two connections with a deliberate layover at a chosen station.

Use this tool when the user wants to break a journey on purpose — to grab food at a hub, meet someone for an hour at a midway station, or sightsee briefly. Books the first leg ending at the layover, then the next leg starting at layover_minutes after arrival.

accessible_routeA

Find connections and annotate them with station-level accessibility info.

Note: transport.opendata.ch does not expose vehicle- or wagon-level accessibility. Annotation is based on station-level data from SBB's PRM (Persons with Reduced Mobility) dataset for the endpoint stations only. For wagon-level accessibility, use SBB's official "Reisende mit Handicap" service.

bike_friendly_routeA

Find connections and annotate each leg with a bike-allowed heuristic.

Heuristic only: S/RE/IR/R lines typically allow bikes without reservation, IC/EC/ICE require reservations (and on some routes do not allow bikes at all), buses and trams generally do not allow bikes. Always verify on sbb.ch/velo for the actual journey.

Prompts

Interactive templates invoked by user choice

NameDescription
plan_weekend_tripPlan a Swiss weekend day trip from a given station, returning the same day.
morning_commute_checkSame-day commute sanity-check: next connections plus disruptions.
last_train_checkFind tonight's last realistic train back to home_station from where the user currently is.
evening_out_plannerPlan an evening with safe return: outbound options now and the latest train back.

Resources

Contextual data attached and managed by the client

NameDescription
active_disruptions_resourceActive disruptions across the Swiss public transport network; refreshed on each read.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/kintscher/swiss-rail-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server