Skip to main content
Glama

search_stations

Find Swiss public transport stations using name searches or coordinate-based location queries to access transport information.

Instructions

Search for Swiss public transport stations/stops by name or coordinates

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryNoStation name to search for
xNoLongitude (WGS84)
yNoLatitude (WGS84)
typeNoFilter: all, station, poi, address

Implementation Reference

  • Handler logic for search_stations, which calls the transport API and formats the result.
    case "search_stations": {
      const url = buildUrl(`${BASE}/locations`, {
        query: args.query as string,
        x: args.x as number,
        y: args.y as number,
        type: args.type as string,
      });
      const data = await fetchJSON<{ stations: Station[] }>(url);
      return JSON.stringify(data.stations.map(slimStation));
    }
  • Schema definition for search_stations including input parameters.
    {
      name: "search_stations",
      description: "Search for Swiss public transport stations/stops by name or coordinates",
      inputSchema: {
        type: "object",
        properties: {
          query: { type: "string", description: "Station name to search for" },
          x: { type: "number", description: "Longitude (WGS84)" },
          y: { type: "number", description: "Latitude (WGS84)" },
          type: { type: "string", description: "Filter: all, station, poi, address" },
        },
      },
    },
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions the search functionality but fails to describe key behaviors such as response format, pagination, rate limits, error handling, or whether it's a read-only operation. This leaves significant gaps in understanding how the tool behaves.

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

Conciseness5/5

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

The description is a single, efficient sentence with zero waste. It front-loads the core purpose and is appropriately sized for a search tool, making it easy to parse quickly.

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

Completeness2/5

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

Given the lack of annotations and output schema, the description is incomplete. It doesn't explain what the tool returns (e.g., list of stations with details), how results are structured, or any behavioral constraints. For a search tool with 4 parameters, this leaves the agent under-informed about critical operational aspects.

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?

The schema description coverage is 100%, so the schema already documents all parameters. The description adds marginal value by implying that 'query' is for name-based searches and 'x'/'y' for coordinate-based searches, but it doesn't provide additional syntax, format details, or usage examples beyond what the schema specifies.

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?

The description clearly states the tool's purpose with a specific verb ('Search') and resource ('Swiss public transport stations/stops'), and distinguishes it from siblings by focusing on station search rather than other transport or location tools. It specifies the search criteria ('by name or coordinates'), making it highly specific.

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?

The description provides no guidance on when to use this tool versus alternatives like 'get_nearby_stations' or 'search_places'. It lacks explicit instructions on prerequisites, exclusions, or typical use cases, leaving the agent to infer usage from the purpose alone.

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

Install Server

Other Tools

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/vikramgorla/mcp-swiss'

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