Skip to main content
Glama

Errance

🧭

plan_journey
Read-only

Computes public transport itineraries between two places (names, stop ids or 'lat,lon'), with walking legs, transfers and real-time data. Shows them as a list and on a map. Give it the place names of the user as they are: no need to search them first. Fails listing the candidates when a name is ambiguous: call it again with the value given for the right one. Between city names (e.g. 'Paris' to 'Nantes'), the long-distance itineraries start and end at the stations, without the local legs to/from the city center; give an address for door-to-door itineraries. The itineraries do not all leave from (or arrive at) the same station: give the user the station of each one (departure, arrival: name, time, local time and track of the boarding in the first vehicle and of the leaving of the last one). Service alerts (disruptions, works, closed lines or elevators) active at the time of a leg or departure are numbered after it, e.g. 'alerts [1]', and listed at the end: tell the user briefly about those of the options you propose. The itineraries do not avoid the lines with an alert: warn when one says the service is interrupted (NO_SERVICE).

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": {
      "to": "<to>"
    },
    "name": "plan_journey"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYesDestination: place name, stop id or 'lat,lon'. Names are searched near the origin.
bikeNoBike of the user: TO_STATION (ridden to the first stop, then left there), ON_BOARD (carried on board, ridden at both ends; only trips allowing bikes). Default NONE.
fromNoOrigin: place name, stop id or 'lat,lon'. Default: 'position'.
timeNoDeparture (or arrival with arriveBy) date-time, ISO-8601: with offset, or in the local time of the origin. Default: now.
countNoMinimum number of itineraries (default 5).
modesNoAllowed transit modes (default: all).
arriveByNotrue: 'time' is the latest arrival time.
languageNoPreferred language of the names, as ISO 639-1 code (e.g. fr, de). The names of the stations are translated in fr, es, en, nl, de and it ("Gérone" for Girona in fr).
positionNoCurrent position of the user, 'lat,lon': origin when 'from' is missing, else favors the places near it.
pageCursorNoCursor returned by a previous call, for earlier or later itineraries.
wheelchairNotrue: accessible paths for a wheelchair user.
maxTransfersNoMaximum number of transfers.
walkingSpeedNoWalking speed (default NORMAL, about 4.3 km/h).
maxWalkMinutesNoMaximum walk (or bike ride) to the first stop and from the last stop, in minutes (default 25): lower for a user who walks little.
transferMarginNoCOMFORTABLE: 5 more minutes reserved for each transfer (default NORMAL).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

The annotations only declare read-only/open-world, but the description discloses non-obvious behavior: an error mode that returns candidate names and requires a retry, the fact that city-to-city trips omit local legs and start/end at stations, numbered service alerts appended to each leg, and the important caveat that alerted lines are not avoided, so NO_SERVICE must be surfaced to the user. These are behavioral traits no annotation or schema field conveys.

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?

Front-loaded with the purpose and every sentence carries information, but the body is one dense block that blends input advice, failure recovery, and output/presentation instructions without separation. A short structural break between how-to-call and how-to-report would make it easier to scan for a 15-parameter tool.

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?

For a 15-parameter, open-world planner with no output schema, the description compensates well: it states the return presentation (list + map), the per-itinerary station detail the agent must relay, the alert referencing scheme ('alerts [1]'), and the ambiguity failure loop. Pagination is covered by the pageCursor schema field, so no gap remains that would cause a misinvocation.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description adds real semantic meaning to 'from'/'to' beyond the schema: what happens when those values are city names (station-anchored long-distance itineraries, no local legs), what to pass instead for door-to-door, and the accepted value forms. That materially changes how the agent chooses parameter values.

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

Purpose4/5

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

Opens with a specific verb+resource statement: 'Computes public transport itineraries between two places ... with walking legs, transfers and real-time data', and adds the output shape ('list and on a map'). The scope is unmistakable and clearly distinct from a status tool like departures or a reachability tool. It stops short of naming a sibling, so it's a strong 4 rather than a 5.

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 concrete routing guidance that steers the agent away from a wasted prerequisite call ('no need to search them first') and prescribes the correct recovery path on failure ('Fails listing the candidates when a name is ambiguous: call it again with the value given for the right one'). It also states the city-name vs address trade-off explicitly ('give an address for door-to-door itineraries'), which resolves the most common misuse of this tool.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.