# Trenitalia train search API

Search Trenitalia journeys by stations, date and passengers via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Apish, pass parameters such as days_ahead, from, limit, and retrieve structured data including source journey-solution identifier, source departure timestamp, source arrival timestamp, source connection count, and starting-fare currency for journey list, and fare comparison.

Documentation: https://openany.si/market/apis/trenitalia/trenitalia-train-search-api/?offering=5d345aaf-1452-4101-a38b-4a6b981c3325
API ID: 5d345aaf-1452-4101-a38b-4a6b981c3325
Provider: apish
Contract revision: 3
Method: GET
Endpoint: https://api.openany.si/v1/agent-apis/apish/trenitalia/v1/search
Page update time: 2026-12-03T02:46:48.361Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: none
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0.002 / billing credit
API-key calls use your shared balance. Review the published billing rules before making a paid request.
Price source: OpenAny public API contract. Price update time: not supplied.
Contract update time: 2026-12-03T02:46:46.065Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "rules",
  "parameters": [],
  "policy_version": 2,
  "sale": {
    "addons": [],
    "base_price_micro_usd": "0",
    "max_cost_micro_usd": "2000",
    "quantities": [
      {
        "id": "upstream_credits",
        "label": "Actual API.SH credits consumed",
        "max_quantity": "1",
        "measure": "value",
        "pointer": "/credits_used",
        "price_micro_usd": "2000",
        "quantity_scale": 0,
        "source": "response",
        "unit": "credit",
        "unit_quantity": "1"
      }
    ],
    "rounding": "ceil",
    "variants": []
  }
}
```

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Trenitalia train search API request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {}
    },
    "query": {
      "type": "object",
      "properties": {
        "from": {
          "type": "string",
          "description": "Departure station: a station id from /trenitalia/v1/stations or a name (the best match is used)."
        },
        "to": {
          "type": "string",
          "description": "Arrival station: an id or a name."
        },
        "date": {
          "type": "string",
          "description": "Departure day, YYYY-MM-DD. Give this or `days_ahead`."
        },
        "days_ahead": {
          "type": "integer",
          "description": "Departure day as days from today (0-365), when `date` is not given."
        },
        "time": {
          "type": "string",
          "description": "Earliest departure, HH:MM (default 00:00)."
        },
        "adults": {
          "type": "integer",
          "description": "Adults (default 1)."
        },
        "children": {
          "type": "integer",
          "description": "Children (default 0)."
        },
        "trains": {
          "type": "string",
          "description": "`all` (default), `frecce`, `regional` or `intercity`.",
          "enum": [
            "all",
            "frecce",
            "regional",
            "intercity"
          ]
        },
        "direct": {
          "type": "string",
          "description": "`1` for trains without changes only.",
          "enum": [
            "0",
            "1"
          ]
        },
        "best_fare": {
          "type": "string",
          "description": "`1` to price each train with its best fare.",
          "enum": [
            "0",
            "1"
          ]
        },
        "bike": {
          "type": "string",
          "description": "`1` for trains that carry bikes.",
          "enum": [
            "0",
            "1"
          ]
        },
        "sort": {
          "type": "string",
          "description": "`departure` (default), `arrival` or `fastest`.",
          "enum": [
            "departure",
            "arrival",
            "fastest"
          ]
        },
        "offset": {
          "type": "integer",
          "description": "Results to skip. Pass `next_offset` back here."
        },
        "limit": {
          "type": "integer",
          "description": "Trains per page (1-10, default 10)."
        },
        "raw": {
          "type": "string",
          "description": "0 leaves out the bulky `raw` source blocks (often 10-30x smaller).",
          "enum": [
            "0",
            "1"
          ]
        },
        "fields": {
          "type": "string",
          "description": "Comma-separated fields to return, e.g. `posts.id,posts.title`. Call metadata is always included."
        },
        "fresh": {
          "type": "string",
          "description": "1 skips the 24-hour cache and fetches live.",
          "enum": [
            "1"
          ]
        },
        "output": {
          "type": "string",
          "description": "JSON only for this OpenAny product. Omit output or use json; CSV and NDJSON are not supported.",
          "enum": [
            "json"
          ]
        },
        "records": {
          "type": "string",
          "description": "With output=csv|ndjson: the top-level list to turn into rows (e.g. `reviews`), or `.` for the whole object as one row."
        }
      },
      "required": [
        "from",
        "to"
      ]
    },
    "headers": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "path",
    "query",
    "headers"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "applied_filters": {
      "type": "object",
      "properties": {
        "best_fare": {
          "type": "boolean"
        },
        "bike": {
          "type": "boolean"
        },
        "direct": {
          "type": "boolean"
        },
        "sort": {
          "type": "string"
        },
        "trains": {
          "type": "string"
        }
      }
    },
    "cached": {
      "type": "boolean"
    },
    "count": {
      "type": "integer"
    },
    "credits_used": {
      "type": "integer"
    },
    "date": {
      "type": "string"
    },
    "fetched_at": {
      "type": "string"
    },
    "from": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "name": {
          "type": "string"
        }
      }
    },
    "messages": {
      "type": "array",
      "items": {}
    },
    "next_offset": {
      "type": "integer"
    },
    "offset": {
      "type": "integer"
    },
    "passengers": {
      "type": "object",
      "properties": {
        "adults": {
          "type": "integer"
        },
        "children": {
          "type": "integer"
        }
      }
    },
    "solutions": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "arrival": {
            "type": "string"
          },
          "changes": {
            "type": "integer"
          },
          "classes": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "leg": {
                  "type": "string"
                },
                "leg_id": {
                  "type": "string"
                },
                "services": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "description": {
                        "type": "string"
                      },
                      "group": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "offers": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "can_change": {
                              "type": "boolean"
                            },
                            "can_refund": {
                              "type": "boolean"
                            },
                            "description": {
                              "type": "string"
                            },
                            "loyalty_program": {
                              "type": "boolean"
                            },
                            "name": {
                              "type": "string"
                            },
                            "price": {
                              "anyOf": [
                                {
                                  "type": "object",
                                  "properties": {
                                    "amount": {
                                      "type": "number"
                                    },
                                    "currency": {
                                      "type": "string"
                                    },
                                    "indicative": {
                                      "type": "boolean"
                                    },
                                    "original_amount": {
                                      "type": "null"
                                    }
                                  }
                                },
                                {
                                  "type": "null"
                                }
                              ]
                            },
                            "seats_available": {
                              "type": "integer"
                            },
                            "status": {
                              "type": "string"
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "departure": {
            "type": "string"
          },
          "destination": {
            "type": "string"
          },
          "duration": {
            "type": "string"
          },
          "id": {
            "type": "string"
          },
          "legs": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "arrival": {
                  "type": "string"
                },
                "departure": {
                  "type": "string"
                },
                "destination": {
                  "type": "string"
                },
                "origin": {
                  "type": "string"
                },
                "train": {
                  "type": "object",
                  "properties": {
                    "acronym": {
                      "type": "string"
                    },
                    "brand": {
                      "type": "string"
                    },
                    "category": {
                      "type": "string"
                    },
                    "number": {
                      "type": "string"
                    },
                    "urban": {
                      "type": "boolean"
                    }
                  }
                }
              }
            }
          },
          "loyalty_points": {
            "type": "number"
          },
          "messages": {
            "type": "array",
            "items": {}
          },
          "next_day": {
            "type": "boolean"
          },
          "origin": {
            "type": "string"
          },
          "price_from": {
            "type": "object",
            "properties": {
              "amount": {
                "type": "number"
              },
              "currency": {
                "type": "string"
              },
              "indicative": {
                "type": "boolean"
              },
              "original_amount": {
                "type": "null"
              }
            }
          },
          "seat_map": {
            "type": "boolean"
          },
          "status": {
            "type": "string"
          },
          "trains": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "acronym": {
                  "type": "string"
                },
                "brand": {
                  "type": "string"
                },
                "category": {
                  "type": "string"
                },
                "number": {
                  "type": "string"
                },
                "urban": {
                  "type": "boolean"
                }
              }
            }
          }
        }
      }
    },
    "time": {
      "type": "string"
    },
    "to": {
      "type": "object",
      "properties": {
        "id": {
          "type": "integer"
        },
        "name": {
          "type": "string"
        }
      }
    }
  }
}
```

## Request example
Scenario: Official example · Live API.SH response · Minimal request
```bash
curl \
  'https://api.openany.si/v1/agent-apis/apish/trenitalia/v1/search?days_ahead=30&from=Roma+Termini&limit=1&output=json&raw=0&time=08%3A00&to=Milano+Centrale' \
  -X GET \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json'
```

## Response example
Example from the provider's documentation. Field values in your results will differ.
Sample response · Documented HTTP 200
```json
{
  "applied_filters": {
    "best_fare": false,
    "bike": false,
    "direct": false,
    "sort": "departure",
    "trains": "all"
  },
  "cached": false,
  "count": 1,
  "credits_used": 1,
  "date": "2026-12-19",
  "fetched_at": "2026-11-19T12:25:41.228Z",
  "from": {
    "id": 830008409,
    "name": "Roma Termini"
  },
  "messages": [],
  "next_offset": 1,
  "offset": 0,
  "passengers": {
    "adults": 1,
    "children": 0
  },
  "solutions": [
    {
      "arrival": "2026-12-19T11:51:00.000+01:00",
      "changes": 0,
      "classes": [
        {
          "leg": "Frecciarossa 9516",
          "leg_id": "xf2e88d54-3b86-4427-a4b2-3f5ac7d26bff",
          "services": [
            {
              "description": "Reclining upholstered or faux-leather seats. Individual electrical sockets. Complimentary on-board Wi-Fi and access to the FRECCIAPlay. Screen for travel information and entertainment. The Café/Snack Bar is always available in coach 5 for all train passengers.",
              "group": "STANDARD",
              "name": "STANDARD",
              "offers": [
                {
                  "can_change": true,
                  "can_refund": true,
                  "description": "This ticket allows unlimited booking changes prior to departure. For Frecce Trains, if the Base price level originally paid is not available, you are required to request a ticket change and pay the resulting price difference. Refund with deduction.",
                  "loyalty_program": true,
                  "name": "BASE",
                  "price": {
                    "amount": 95,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 236,
                  "status": "SALEABLE"
                },
                {
                  "can_change": true,
                  "can_refund": false,
                  "description": "Reservation change allowed before departure. Refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Economy",
                  "price": {
                    "amount": 74.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 236,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Super Economy",
                  "price": {
                    "amount": 49.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 236,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Offer reserved for CartaFreccia holders under 30 years of age. No ticket changes or refunds permitted. Subject to seat availability.",
                  "loyalty_program": false,
                  "name": "FrecciaYOUNG",
                  "price": {
                    "amount": 39,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 236,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "This offer is reserved for CartaFreccia holders aged 60 or over (the passenger travelling under this offer must be the CartaFRECCIA cardholder). No ticket changes or refunds permitted. Subject to seat availability.",
                  "loyalty_program": false,
                  "name": "FrecciaSENIOR",
                  "price": {
                    "amount": 49,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 236,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": false,
                  "name": "FrecciaDAYS",
                  "price": null,
                  "seats_available": 0,
                  "status": "SOLD_OUT"
                }
              ]
            },
            {
              "description": "Reclining leather seats. Individual electrical sockets. Complimentary on-board Wi-Fi and access to the FRECCIAPlay. Screen for travel information and entertainment. A service to welcome you on board, with savoury and sweet snacks. The FRECCIABistrò in coach 5 remains available to all train passengers.",
              "group": "PREMIUM",
              "name": "PREMIUM",
              "offers": [
                {
                  "can_change": true,
                  "can_refund": true,
                  "description": "This ticket allows unlimited booking changes prior to departure. For Frecce Trains, if the Base price level originally paid is not available, you are required to request a ticket change and pay the resulting price difference. Refund with deduction.",
                  "loyalty_program": true,
                  "name": "BASE",
                  "price": {
                    "amount": 112,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 48,
                  "status": "SALEABLE"
                },
                {
                  "can_change": true,
                  "can_refund": false,
                  "description": "Reservation change allowed before departure. Refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Economy",
                  "price": {
                    "amount": 80.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 48,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Super Economy",
                  "price": {
                    "amount": 52.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 48,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "This offer is reserved for CartaFreccia holders aged 60 or over (the passenger travelling under this offer must be the CartaFRECCIA cardholder). No ticket changes or refunds permitted. Subject to seat availability.",
                  "loyalty_program": false,
                  "name": "FrecciaSENIOR",
                  "price": {
                    "amount": 54,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 48,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": false,
                  "name": "FrecciaDAYS",
                  "price": null,
                  "seats_available": 0,
                  "status": "SOLD_OUT"
                }
              ]
            },
            {
              "description": "More space for your journey. Spacious single and double reclining leather seats. Seats are spaced more than one metre apart. Individual electrical sockets. Complimentary on-board Wi-Fi and access to the FRECCIAPlay. Screen for travel info and entertainment. The FrecciaBistrò in coach 5 remains available to all train passengers.",
              "group": "BUSINESS",
              "name": "BUSINESS",
              "offers": [
                {
                  "can_change": true,
                  "can_refund": true,
                  "description": "This ticket allows unlimited booking changes prior to departure. For Frecce Trains, if the Base price level originally paid is not available, you are required to request a ticket change and pay the resulting price difference. Refund with deduction.",
                  "loyalty_program": true,
                  "name": "BASE",
                  "price": {
                    "amount": 129,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 104,
                  "status": "SALEABLE"
                },
                {
                  "can_change": true,
                  "can_refund": false,
                  "description": "Reservation change allowed before departure. Refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Economy",
                  "price": {
                    "amount": 93.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 104,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Super Economy",
                  "price": {
                    "amount": 59.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 104,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "This offer is reserved for CartaFreccia holders aged 60 or over (the passenger travelling under this offer must be the CartaFRECCIA cardholder). No ticket changes or refunds permitted. Subject to seat availability.",
                  "loyalty_program": false,
                  "name": "FrecciaSENIOR",
                  "price": {
                    "amount": 59,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 104,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "FrecciaDAYS",
                  "price": {
                    "amount": 51.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 33,
                  "status": "SALEABLE"
                }
              ]
            },
            {
              "description": "Maximum relaxation and no mobile phone use. Large single and double leather seats equipped with electric reclining systems and adjustable headrests. Individual electrical sockets. Complimentary on-board Wi-Fi and access to the FRECCIAPlay. Screen for travel info and entertainment. No mobile phone use. The FrecciaBistrò in coach 5 remains available to all train passengers.",
              "group": "BUSINESS",
              "name": "BUSINESS AREA SILENZIO",
              "offers": [
                {
                  "can_change": true,
                  "can_refund": true,
                  "description": "This ticket allows unlimited booking changes prior to departure. For Frecce Trains, if the Base price level originally paid is not available, you are required to request a ticket change and pay the resulting price difference. Refund with deduction.",
                  "loyalty_program": true,
                  "name": "BASE",
                  "price": {
                    "amount": 129,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 11,
                  "status": "SALEABLE"
                },
                {
                  "can_change": true,
                  "can_refund": false,
                  "description": "Reservation change allowed before departure. Refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Economy",
                  "price": {
                    "amount": 93.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 11,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Super Economy",
                  "price": {
                    "amount": 59.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 11,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "This offer is reserved for CartaFreccia holders aged 60 or over (the passenger travelling under this offer must be the CartaFRECCIA cardholder). No ticket changes or refunds permitted. Subject to seat availability.",
                  "loyalty_program": false,
                  "name": "FrecciaSENIOR",
                  "price": {
                    "amount": 59,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 11,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "FrecciaDAYS",
                  "price": {
                    "amount": 51.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 11,
                  "status": "SALEABLE"
                }
              ]
            },
            {
              "description": "Maximum privacy. Reserved Area with 4 large, reclining, leather seats. Individual electrical sockets. Complimentary on-board Wi-Fi and access to the FRECCIAPlay. Screen for travel information and entertainment. The FrecciaBistrò in coach 5 remains available to all train passengers.",
              "group": "BUSINESS",
              "name": "BUSINESS SALOTTINO",
              "offers": [
                {
                  "can_change": true,
                  "can_refund": true,
                  "description": "This ticket allows unlimited booking changes prior to departure. For Frecce Trains, if the Base price level originally paid is not available, you are required to request a ticket change and pay the resulting price difference. Refund with deduction.",
                  "loyalty_program": true,
                  "name": "BASE",
                  "price": {
                    "amount": 139,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 4,
                  "status": "SALEABLE"
                },
                {
                  "can_change": true,
                  "can_refund": false,
                  "description": "Reservation change allowed before departure. Refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Economy",
                  "price": {
                    "amount": 102.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 4,
                  "status": "SALEABLE"
                },
                {
                  "can_change": false,
                  "can_refund": false,
                  "description": "Reservation change and refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Super Economy",
                  "price": {
                    "amount": 65.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 4,
                  "status": "SALEABLE"
                }
              ]
            },
            {
              "description": "The Executive travel experience features an exclusive welcome with the utmost care, class and taste, at any time of the day. Maximum comfort. 8 large single leather seats with spacious reclining backrests and extendable leg rests, spaced 150 cm apart. Individual electrical sockets. Complimentary access to our Wi-Fi internet service and the FRECCIAPlay. Screen for travel information and entertainment. For more details, please consult the Trenitalia website: www.trenitalia.com",
              "group": "EXECUTIVE",
              "name": "EXECUTIVE",
              "offers": [
                {
                  "can_change": true,
                  "can_refund": true,
                  "description": "This ticket allows unlimited booking changes prior to departure. For Frecce Trains, if the Base price level originally paid is not available, you are required to request a ticket change and pay the resulting price difference. Refund with deduction.",
                  "loyalty_program": true,
                  "name": "BASE",
                  "price": {
                    "amount": 295,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 7,
                  "status": "SALEABLE"
                },
                {
                  "can_change": true,
                  "can_refund": false,
                  "description": "Reservation change allowed before departure. Refund not allowed. Limited seats",
                  "loyalty_program": true,
                  "name": "Economy",
                  "price": {
                    "amount": 250.9,
                    "currency": "EUR",
                    "indicative": false,
                    "original_amount": null
                  },
                  "seats_available": 3,
                  "status": "SALEABLE"
                }
              ]
            }
          ]
        }
      ],
      "departure": "2026-12-19T08:05:00.000+01:00",
      "destination": "Milano Centrale",
      "duration": "3h 46min",
      "id": "xce005fff-7144-4756-b78a-e0446b288a2b",
      "legs": [
        {
          "arrival": "2026-12-19T11:51:00.000+01:00",
          "departure": "2026-12-19T08:05:00.000+01:00",
          "destination": "Milano Centrale",
          "origin": "Roma Termini",
          "train": {
            "acronym": "FR",
            "brand": "FRECCIAROSSA",
            "category": "Frecciarossa",
            "number": "9516",
            "urban": false
          }
        }
      ],
      "loyalty_points": 49.9,
      "messages": [],
      "next_day": false,
      "origin": "Roma Termini",
      "price_from": {
        "amount": 49.9,
        "currency": "EUR",
        "indicative": false,
        "original_amount": null
      },
      "seat_map": true,
      "status": "SALEABLE",
      "trains": [
        {
          "acronym": "FR",
          "brand": "FRECCIAROSSA",
          "category": "Frecciarossa",
          "number": "9516",
          "urban": false
        }
      ]
    }
  ],
  "time": "08:00",
  "to": {
    "id": 830001700,
    "name": "Milano Centrale"
  }
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Available implementations
- apish: https://openany.si/market/apis/trenitalia/trenitalia-train-search-api/?offering=5d345aaf-1452-4101-a38b-4a6b981c3325

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
