search_stations

Pack: swisstransport · Endpoint: https://gateway.pipeworx.io/swisstransport/mcp

Search for Swiss public transport stations (train, bus, tram) by name query.

Parameters

NameTypeRequiredDescription
querystringyesStation name to search for (e.g., “Zurich HB”, “Bern”, “Geneva”).

Example call

Arguments

{
  "query": "Zurich HB"
}

curl

curl -X POST https://gateway.pipeworx.io/swisstransport/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"search_stations","arguments":{"query":"Zurich HB"}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('search_stations', {
  "query": "Zurich HB"
});

More examples

{
  "query": "Bern"
}

Response shape

Always returns: count, stations

FieldTypeDescription
countnumberNumber of stations returned
stationsarrayList of matching stations
Full JSON Schema
{
  "type": "object",
  "properties": {
    "count": {
      "type": "number",
      "description": "Number of stations returned"
    },
    "stations": {
      "type": "array",
      "description": "List of matching stations",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": [
              "string",
              "null"
            ],
            "description": "Station identifier"
          },
          "name": {
            "type": [
              "string",
              "null"
            ],
            "description": "Station name"
          },
          "coordinate": {
            "type": [
              "object",
              "null"
            ],
            "description": "Geographic coordinates",
            "properties": {
              "x": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "X coordinate (longitude)"
              },
              "y": {
                "type": [
                  "number",
                  "null"
                ],
                "description": "Y coordinate (latitude)"
              }
            }
          }
        }
      }
    }
  },
  "required": [
    "count",
    "stations"
  ]
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "swisstransport": {
      "url": "https://gateway.pipeworx.io/swisstransport/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build May 9, 2026