Hello everyone,
Following @Damien’s request, here is an external integration to track real-time transport in the Île-de-France region within Gladys.
GitHub - William-De71/gladys-idfm · GitHub
What it does
Real-time next departures
Up to 3 stops followed, with for each:
- the line (« RER B », « Transilien P », « Metro 13 », « T3a », « Bus 91 ») ;
- the direction (words from the destination, for example « Paris » or « Saint-Rémy | Massy ») ;
- an optional time slot and travel days.
Each stop becomes a device: next departure, waiting time, delay, number of disrupted departures. For RER and Transilien, delays and cancellations are detected.
Traffic info
Up to 6 lines followed. Each becomes a device: normal, disrupted, or interrupted traffic, with the official message from IDFM (incident, works…).
Scenes
- Triggers:
- « my train is delayed » (choose the level: less than 15 min, 15 to 29, 30 and more) ;
- « my departure is canceled » ;
- « my metro is passing in 5 min » (2, 5, 10, 15, 20 or 30 min, counted on the real schedule) ;
- « my line is disrupted » (filter interrupted/disrupted and incident/works) ;
- « back to normal ».
- Actions: « next departures » from a stop and « traffic of a line ».
Each event provides a ready-to-use sentence for a notification or the speaker:
« Massy - Palaiseau: the RER B KASE → CDG Airport 2 departs in 15 min, at 07:42 (4 min delay). »
A few ideas:
- receive an alert in the morning if your RER is canceled;
- have « your metro is passing in 5 minutes » announced while you put on your shoes;
- turn on an orange light when your line is disrupted.
Widgets
- Departures: the table of next departures from a stop, like the screens at the station (« 3 min », « +4 min », « Canceled », « At the platform »).
- Traffic: the status of your lines and current or upcoming disruptions within 24 hours. Touch a disruption to read the full message.
Installation
- Create a free account on PRIM, the open data platform of IDFM, then generate a token in « My authentication tokens ».
- Install the integration, paste the token, and enter your stops and lines by their name. The « Search for a stop » and « Search for a line » buttons help in case of doubt.
- Click on « Test the connection », then add the devices from the Discovery tab.
Good to know: the quota
A new PRIM account is limited to 1,000 requests per day. To stay within the limit:
- set a time slot for your stops (for example 07:00-09:30 on weekdays): the stop is then read only around this time slot, i.e. approximately 65 requests per day instead of 600;
- the integration spaces out its readings if your stops require more than the quota;
- traffic info costs approximately 290 requests per day, regardless of the number of lines;
- you can request a higher quota from PRIM for free, then report it in the integration settings.
The metro and most buses do not have a theoretical schedule in real-time data: we know the waiting time, but not a « delay » in the strict sense.
Feedback welcome
This is a first version. It has been tested on real responses from the API, but not yet on a real daily journey. If you try it, let me know if the stops are well found, if the schedules match what you see at the station, and what you are missing. ![]()
Community integration, with no link to Île-de-France Mobilités, the SNCF, or the RATP.