This page contains examples and descriptions of best-practice for how to structure data in the SIRI format in accordance with the Nordic SIRI Profile. The catalogue is openly available and is meant to cover the most common use cases. Suggestions for additional examples to the catalogue are welcome.
All real-time datasets must be in one of the three supported formats (SIRI-ET, SIRI-SX, SIRI-VM), and sent as a single XML-file (per format) with the root node "ServiceDelivery
".
The XML examples can all be found on GitHub at https://github.com/entur/profile-norway-examples/tree/master/siri
All examples are linked to XML-files in GitHub. Some examples have been more extensively described on a separate page.
Eksempel | XML | Beskrivelse | Kommentar |
---|---|---|---|
Vehicle before departure | GitHub | Real-time data for a departure. | |
Partial cancellation (last leg) | GitHub (before departure) GitHub (underway) | See own document | Examples of real-time data before departure, and real-time data underway. |
Partial cancellation (first leg) | GitHub | See own document | Example of cancellation after departing. |
Cancelled in the middle of the route before departure | GitHub | See own document | |
Cancelled before departure | GitHub | Real-time data for a cancelled departure | |
Replacement departure | Examples of real-time data before departure, and real-time data underway. | ||
Changed platform | GitHub (before change) GitHub (after change) | See own document |
Eksempel | XML | Beskrivelse | Kommentar |
---|---|---|---|
Message on a Line | GitHub | See own document | |
Message on a leg for multiple Vehicles | GitHub | See own document | |
Message on a Network | GitHub | Applies to all departures (Vehicles) in a Network | |
Message on a Stop | GitHub | See own document | |
Message on a Stop for specific Lines | GitHub | See own document | |
Message with stopCondition on a Vehicle | GitHub (boarding/alighting) GitHub (boarding) GitHub (passing) GitHub (board./alight./pass.) | See own document | |
Message on a Vehicle | See own document | ||
Message on multiple Vehicles and multiple Dates | GitHub | See own document | |
Validity of a message | GitHub (set validity time) GitHub (open) GitHub (closing) | See own document |
Eksempel | XML | Beskrivelse | Kommentar |
---|---|---|---|
Message on a Vehicle before arriving the next Stop | GitHub | A vehicle underway to monitored stop | |
Message on a Vehicle while serving a Stop | GitHub | A vehicle which has stopped at a monitored stop | |
Message with the coordinates of a Vehicle | GitHub | Minimum-example with position, but does not indicate the progress of the trip |
If you want to expand the samples or add new ones in GitHub, eg. the need for modelling special cases not already covered follow these guidelines.
Further information about the use of pull request in GitHub is located at https://help.github.com/articles/using-pull-requests/.
It is recommended to use tools which support automatic validation of the data structure while working with XML files, eg. Notepad++ with XML Tools plugin (free, the XML-plugin could be installed automatically in Notepad++ or downloaded separate) or licensed tools like Oxygen or XMLspy.