Get real-time departure information via the TRIAS interface – quick and easy to read thanks to caching and various output formats.
TRIAS is an XML-based, standardized exchange format for passenger information systems, developed by the Verband Deutscher Verkehrsunternehmen (VDV). It is used for structured communication between information systems, timetable services, and third-party applications. TRIAS is not yet in widespread use in Germany, but is currently being rolled out or piloted by many transport companies and data platforms.
More information & specifications: vdv.de/ip-kom-oev.aspx
Note
easyTRIAS is an unofficial project. You need access to a valid TRIAS endpoint (e.g., Connect Niedersachsen or MobiData BW). The access data must be entered in the configuration file.
- Live departure data: Querying live departure data via TRIAS using a
stopPointReffor the stop. - Multiple formats: Output as
json,xml,csv,htmlorraw(TRIAS-XML). - Caching: File-based caching to conserve API quotas.
- Walking time filter: Filter for departures that are too early based on the walking time to the stop.
- Icons & Colors: Mapping of transport types (e.g. bus, train, tram) to icons/colors is configurable.
- Easy to deploy: Runs on PHP web servers from version 7.2 onwards with write permissions for the cache directory.
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
stopPointRef |
string | ✓ | – | TRIAS stop ID (e.g. de:03241:31) |
format |
string | ✗ | html |
Output format: json, xml, csv, html, raw |
walkingMinutes |
integer | ✗ | 0 |
Walking time to the stop in minutes – earlier departures are filtered |
forceRefresh |
0/1 |
✗ | 0 |
If set to 1, the cache will be bypassed and a fresh request is made |
Cache duration and directory are configurable in /.env.ini; deactivation via duration 0.
HTML table:
https://example.com/departures.php?stopPointRef=de:03241:31JSON with walking time filter:
https://example.com/departures.php?stopPointRef=de:03241:31&format=json&walkingMinutes=5Raw TRIAS XML for debugging:
https://example.com/departures.php?stopPointRef=de:03241:31&format=raw- Main settings are defined in the
/.env.inifile - Mappings are defined in the
/src/Dictionaries.phpfile
This project is licensed under the Apache 2.0 License.
You may freely use, modify, and redistribute the code, even in commercial projects as long as the license and copyright notices are retained. Liability is excluded.
Dennis Krüger · Hanover, Germany · https://www.denniskr.de
Do you have ideas, feedback, or would like to collaborate?
Feel free to open an issue on GitHub or reach out directly via email: easytrias@denniskr.de