Skip to main content
Glama

Get Prices

get_prices
Read-onlyIdempotent

Get ticket prices for one or more Swiss train connections. Apply Half-Fare or GA discounts. With SwissTrip, enter traveler names to obtain family pricing.

Instructions

Get ticket prices for one or more train connections. Supports Half-Fare card (Halbtax) and GA travelcard discounts. When connected to SwissTrip (SWISSTRIP_TOKEN), pass traveler_names to get family pricing for multiple travelers.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
trip_idsYesTrip IDs from search_connections results
traveler_typeNoTraveler type (used when no traveler_names given)ADULT
reduction_cardNoSwiss reduction card (used when no traveler_names given)HALF_FARE
traveler_namesNoNames of SwissTrip travelers to price for (e.g. ["Fabian", "Anna"]). Requires SWISSTRIP_TOKEN. Each traveler's reduction card is applied automatically.
Behavior4/5

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

Annotations already declare readOnlyHint=true and idempotentHint=true. The description adds useful behavioral context such as support for Half-Fare and GA discounts and family pricing via traveler_names, which goes beyond the annotations.

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 three sentences, front-loaded with the main purpose, and every sentence adds value. No wasted words.

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

Completeness4/5

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

Given the tool has 4 parameters (1 required) and no output schema, the description explains reduction cards and traveler_names usage. It does not specify return format, but for a pricing tool it is reasonably complete.

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?

The schema has 100% description coverage, so the description does not need to add much. However, it clarifies the use of reduction_card options and traveler_names, adding meaning beyond the schema.

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 'Get ticket prices for one or more train connections,' using a specific verb and resource. It distinguishes itself from sibling tools like get_trip_details or search_connections.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains when to use the tool (for pricing with reduction cards) and how to use it with 'traveler_names' for family pricing when connected to SwissTrip. It does not explicitly list alternatives but the context is clear.

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/Fabsbags/sbb-mcp'

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