Show journey options (interactive)
mostrar_horariosSearch Portuguese train journeys and display interactive cards with buy buttons so users can compare options and choose which ticket to purchase.
Instructions
Same search as horarios, but also shows the options to the user as interactive cards in the chat, each with a buy button. Use it only when the user wants to see and compare trains to pick one, or wants to buy. Do NOT use it for quick factual questions (next train, a price, a single time), for checks you make for yourself, or when you will answer in one sentence; use horarios for those. Do not call both for the same search.
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": {
"from": "<from>",
"to": "<to>"
},
"name": "mostrar_horarios"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | Destination station: name or CP code | |
| date | No | Travel date YYYY-MM-DD (Europe/Lisbon). Default: today | |
| from | Yes | Origin station: name (fuzzy, accents optional) or CP code like 94-30007 | |
| lang | No | Language for names and messages | PT |
| after | No | Earliest departure HH:MM | |
| before | No | Latest departure HH:MM | |
| services | No | Keep only journeys whose every leg uses one of these service codes. Valid codes could not be loaded at startup; they are checked against CP at call time. | |
| passengers | No | Number of adults | |
| direct_only | No | Only journeys without transfers | |
| return_date | No | Optional return date YYYY-MM-DD | |
| travel_class | No | 1 = 1st/Conforto, 2 = 2nd/Turística |