italoinviaggio.italotreno.com APIitaloinviaggio.italotreno.com ↗
Search Italo train stations and get real-time departures, arrivals, delays, and platform data for any station on the Italo network.
curl -X GET 'https://api.parse.bot/scraper/d7a24cdd-bda3-4315-8fbe-aee3cffaf64b/search_stations' \ -H 'X-API-Key: $PARSE_API_KEY'
Search for Italo train stations by name. Returns matching stations with their codes, coordinates, and type information. Use this to find station_code values needed by get_live_trains.
| Param | Type | Description |
|---|---|---|
| queryrequired | string | Station or city name to search for (e.g. 'Roma', 'Milano', 'Napoli'). |
{
"type": "object",
"fields": {
"count": "integer",
"stations": "array of station objects with station_code, name, latitude, longitude, is_italo_station, is_itabus_station, is_mac, mac_stations"
},
"sample": {
"count": 3,
"stations": [
{
"name": "Roma (Tutte)",
"is_mac": true,
"latitude": "",
"longitude": "",
"mac_stations": [
{
"name": "Roma Termini",
"station_code": "RMT"
},
{
"name": "Roma Tiburtina",
"station_code": "RTB"
}
],
"station_code": "RM0",
"is_italo_station": true,
"is_itabus_station": false
},
{
"name": "Roma Termini",
"is_mac": false,
"latitude": "41.90063611",
"longitude": "12.50201349",
"mac_stations": [],
"station_code": "RMT",
"is_italo_station": true,
"is_itabus_station": false
}
]
}
}About the italoinviaggio.italotreno.com API
This API exposes 2 endpoints covering the Italo high-speed rail network in Italy: search_stations lets you look up stations by name and retrieve their codes and coordinates, while get_live_trains returns real-time departure and arrival boards for a given station, including delay minutes, scheduled and actual times, platform assignments, and route details.
Station Search
The search_stations endpoint accepts a query string — a city or station name such as Roma, Milano, or Napoli — and returns a list of matching station objects. Each object includes a station_code (e.g. RMT for Roma Termini), name, latitude, longitude, and boolean flags: is_italo_station, is_itabus_station, and is_mac. The mac_stations field lists any associated MAC (multi-access) station groupings. Use this endpoint to resolve the station_code values required by the live trains endpoint.
Real-Time Train Boards
The get_live_trains endpoint takes a station_code and matching station_name and returns the current departure and arrival boards for that station. Both departures and arrivals are arrays of train objects, each containing train_number, origin_destination, scheduled_time, actual_time, delay_minutes, platform, and route_info. The last_update field shows the timestamp of the most recent data refresh in HH:MM format. The is_empty boolean indicates whether the board has any trains listed — useful for detecting overnight windows when no services are running.
Coverage and Freshness
Coverage is limited to stations on the Italo and Itabus network; it does not include Trenitalia or regional rail services. During overnight hours, get_live_trains may return an empty board (is_empty: true) for all stations, which reflects actual service gaps rather than a data error. The count field in search_stations responses lets you quickly check how many stations matched a given query before iterating over results.
- Display a live departure board for a specific Italo station in a travel app using delay_minutes and platform fields
- Build a delay-monitoring alert that triggers when delay_minutes exceeds a threshold on a tracked train_number
- Geocode Italo stations onto a map using latitude and longitude from search_stations
- Resolve user-typed city names to station_code values before querying live train data
- Identify which stations support Itabus connections using the is_itabus_station flag
- Show passengers the actual_time vs scheduled_time difference for incoming trains at a station
- Detect service gaps by checking is_empty during late-night hours for operational scheduling tools
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 250 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does Italo Treno offer an official developer API?+
What does get_live_trains return, and how do departures differ from arrivals?+
departures and arrivals arrays in the response share the same object structure: train_number, origin_destination, scheduled_time, actual_time, delay_minutes, platform, and route_info. The distinction is directional — departures show trains leaving the station, arrivals show trains approaching it. The last_update field tells you when the board was last refreshed.Does the API cover Trenitalia, Frecciarossa, or regional Italian rail services?+
is_italo_station and is_itabus_station flags returned by search_stations. Trenitalia and regional services are not included. You can fork this API on Parse and revise it to target a different rail operator's data source.Why does get_live_trains sometimes return no trains?+
is_empty: true and empty departures and arrivals arrays. This is expected behavior and reflects actual service availability, not a data error.