Skip to main content
Glama

Bergbahn-Info – Demo-MCP-Server

Lernprojekt: ein eigener MCP-Server (Model Context Protocol) auf Cloudflare Workers, eingebunden als Plugin bzw. Connector in Claude und ChatGPT.

  • Bahnen, Lifte, Pisten, Schneebericht: erfundenes Skigebiet «Eigerblick» mit zwei Gebieten (sonnenhang, gletscherblick), Testdaten in src/daten.json.

  • Zugverbindungen: echte Fahrplandaten über transport.opendata.ch.

Inoffizielles Demoprojekt, keine Verbindung zu einer echten Bergbahn.

Tools

Tool

Eingaben

Antwort

list_lifts

gebiet, status (optional)

Bahnen und Lifte mit Typ, Status, Betriebszeit

get_lift_status

lift_id

Wartezeit, Grund bei Schliessung

list_slopes

gebiet, schwierigkeit, status

Pisten mit Status und Präparation

get_snow_report

gebiet

Schneehöhe, Neuschnee, Lawinenstufe, Wetter, offene Anlagen

search_connections

von, nach, datum, zeit

Zugverbindungen

Alle Tools lesen nur (readOnlyHint).

Related MCP server: swiss-outdoor-mcp

Lokal

npm install
npm test           # Tests
npm run dev        # Worker lokal: http://localhost:8787/mcp
npx @modelcontextprotocol/inspector   # zum Ausprobieren im Browser

Veröffentlichen (Cloudflare Workers)

Jeder Push nach main testet und veröffentlicht den Worker automatisch (.github/workflows/deploy.yml). Einmalig nötig:

  1. Cloudflare-Konto (Gratis-Plan genügt). Die Account-ID steht in wrangler.toml (kein Geheimnis).

  2. API-Token erstellen: My Profile → API Tokens → Vorlage «Edit Cloudflare Workers».

  3. Im GitHub-Repo unter Settings → Secrets and variables → Actions das Secret CLOUDFLARE_API_TOKEN anlegen.

Danach ist der Server unter https://bergbahn-mcp.stefan-eicher.workers.dev/mcp erreichbar.

Einbinden

Claude.ai / Claude Desktop: Einstellungen → Connectors → «Custom Connector» → URL https://bergbahn-mcp.stefan-eicher.workers.dev/mcp.

ChatGPT: Developer Mode einschalten, dann App/Connector mit derselben URL anlegen.

Claude Code als Plugin:

/plugin marketplace add stefaneicher/bergbahn-mcp
/plugin install bergbahn-info@bergbahn

Öffentliches Verzeichnis

Angaben für die Einreichung bei Anthropic und OpenAI: docs/einreichung.md. Datenschutz: https://bergbahn-mcp.stefan-eicher.workers.dev/privacy, Nutzungsbedingungen: https://bergbahn-mcp.stefan-eicher.workers.dev/terms.

Aufbau

src/index.ts      Worker: Endpunkt /mcp (Streamable HTTP, zustandslos)
src/tools.ts      die fünf Tools
src/seiten.ts     Startseite, Datenschutz, Nutzungsbedingungen, Icon
src/daten.json    Testdaten
test/             Tests (Vitest)
assets/           Icon (SVG, PNG)
docs/             Einreichung Verzeichnisse
wrangler.toml     Cloudflare-Konfiguration
.claude-plugin/   Plugin und Marketplace für Claude Code
.mcp.json         MCP-Konfiguration des Plugins (URL des Workers)

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      C
      maintenance
      Provides read-only access to structured Japanese railway data, enabling station searches without an API key and live Shinkansen timetable, fare, seat class, and stop queries with an Ekispert API key.
      7
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables LLM clients to plan Swiss mountain outings by public transport, providing computed facts such as launch sites, flyability probabilities, and train connections.
      1
      MIT
    • F
      license
      Not graded
      quality
      C
      maintenance
      Wraps four public railway APIs as 13 tools, 7 prompts and 5 resources, enabling an LLM client to answer live questions about station master data, timetables and timetable changes, elevator and escalator outages, and parking facilities and prognoses.
      2
      -
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables read-only public-transport station lookup, journey routing with realtime annotations and generated Deutsche Bahn search links, plus current IRIS departure boards by EVA.
      MIT