OJPStopEventRequest 2.0

#AutoTranslate

Brief Description

The StopEvent service is used to construct a departure or arrival monitor. All journeys from a stop and its assigned stops are included. Unlike with the router, however, no neighbouring stops are output if no results are available for the requested stop.

Technical Description

API Explorer

You can try out your own requests – direct link to API Explorer.

Request

The request is made with a OJPStopEventRequest, which contains different parameters for the request, the following is an example from Bern:

<OJP xmlns="http://www.vdv.de/ojp" xmlns:siri="http://www.siri.org.uk/siri" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xsi:schemaLocation="http://www.vdv.de/ojp" version="2.0">
    <OJPRequest>
        <siri:ServiceRequest>
            <siri:ServiceRequestContext>
                <siri:Language>de</siri:Language>
            </siri:ServiceRequestContext>
            <siri:RequestTimestamp>2025-02-11T14:11:26.795Z</siri:RequestTimestamp>
            <siri:RequestorRef>SKIPlus</siri:RequestorRef>
            <OJPStopEventRequest>
                <siri:RequestTimestamp>2025-02-11T14:11:26.795Z</siri:RequestTimestamp>
                <siri:MessageIdentifier>SER_1</siri:MessageIdentifier>
                <Location>
                    <PlaceRef>
                        <siri:StopPointRef>8507000</siri:StopPointRef>
                        <Name>
                            <Text>Bern</Text>
                        </Name>
                    </PlaceRef>
                    <DepArrTime>2025-02-11T14:11:21.539Z</DepArrTime>
                </Location>
                <Params>
                    <NumberOfResults>10</NumberOfResults>
                    <StopEventType>departure</StopEventType>
                    <IncludePreviousCalls>true</IncludePreviousCalls>
                    <IncludeOnwardCalls>true</IncludeOnwardCalls>
                    <UseRealtimeData>full</UseRealtimeData>
                </Params>
            </OJPStopEventRequest>
        </siri:ServiceRequest>
    </OJPRequest>
</OJP>

Following are the parameters of the OJPStopEventRequestStructure:

Element Cardinality Description Example
RequestTimestamp 1:1 Timestamp of the request. Preferably in UTC.
<siri:RequestTimestamp>2025-02-11T14:11:26.795Z</siri:RequestTimestamp>
MessageIdentifier 0:1 The identifier of the message. Can be selected by the user. Can be useful in case of support. This is returned in the response if available.
<siri:MessageIdentifier>SER_1</siri:MessageIdentifier>
Location/PlaceRef 0:1 It’s best to use a StopPlaceRef. Location Name is ignored.Please note: Both Didok and SLOID can occur. More Info.
<PlaceRef>
    <siri:StopPointRef>8507000</siri:StopPointRef>
    <Name>
        <Text>Bern</Text>
    </Name>
</PlaceRef>
Location/DepArrTime 0:1 The time to be used. Zulu-Time’Z’ is best used as Zulu-Time (i.e. independent of time zones). For Z, it is essential to specify the seconds. If the format is not correct or if Z is not available, the system will try to interpret the time as local time.
<DepArrTime>2025-02-11T14:11:21.539Z</DepArrTime>
Location/TimeAllowance 0:1 Additional time needed to reach/leave this location (e.g. B. max. 5 minutes on foot, but 10 minutes by bike). xs:Duration.
<Location>
    <PlaceRef>
        <siri:StopPointRef>8507000</siri:StopPointRef>
        <Name>
            <Text>Bern</Text>
        </Name>
     </PlaceRef>
     <TimeAllowance>PT5M</TimeAllowance>
</Location>

 

Location/IndividualTransportOptions 0:* Options for reaching or leaving a stop or a place.Permitted modes (currently): walk, cycle Later: taxi, self-drive-car, others-drive-car, motorcycle, truck. Distances are in metres. Speed relative to normal (=100%). AdditionalTime is additional time in this mode.
<IndividualTransportOptions>
	<Mode>walk</Mode>
	<MaxDistance>5000</MaxDistance>
	<MaxDuration>PT5M</MaxDuration>
	<MinDistance>0</MinDistance>
	<MinDuration>PT0M</MinDuration>
	<Speed>100</Speed>
	<AdditionalTime>PT10M</AdditionalTime>
</IndividualTransportOptions>

 

Params 0:1 the parameters
<Params>
	<StopEventType>both</StopEventType>
	<IncludePreviousCalls>true</IncludePreviousCalls>
	<IncludeOnwardCalls>true</IncludeOnwardCalls>
	<IncludeOperatingDays>true</IncludeOperatingDays>
	<UseRealtimeData>full</UseRealtimeData>
</Params>

Params of the StopEventDataFilters

Element Cardinality Description Example
PtModeFilter 0:1 Filter by mode. The Exclude element indicates whether the modes should be included or excluded. 1:* modes can be added.

See PtModeFilter under Trip Service

<PtModeFilter>
	<Mode>
		<Exclude>true</Exclude>
		<PtMode>bus</PtMode>
		<siri:BusSubmode>localBusService</siri:BusSubmode>
	</Mode>
</PtModeFilter>
LineFilter 0:1 Filter by line. The Exclude element indicates whether the lines are to be included or excluded. 1:* Line can be added.

 

<LineFilter>
	<Line>
		<siri:LineRef>sbb:91018:A</siri:LineRef>
		<siri:DirectionRef>H</siri:DirectionRef>
	</Line>
	<Exclude>true</Exclude>
</LineFilter>
OperatorFilter 0:1 Filter by operator. The Exclude element indicates whether the operators are to be included or excluded. 1:* OperatorRef can be added.
<OperatorFilter>
	<Exclude>false</Exclude>
        <siri:OperatorRef>11</siri:OperatorRef>
</OperatorFilter>

 

NumberOfResults 0:1 Number of results
<NumberOfResults>10</NumberOfResults>
StopEventType 0:1 Type of StopEvents:

  • arrival
  • departure
  • both
<StopEventType>both</StopEventType>
IncludePreviousCalls 0:1 Should the previous stops also be specified for the individual journeys?
<IncludePreviousCalls>true</IncludePreviousCalls>
IncludeOnwardCalls 0:1 For the individual journeys, should the subsequent stops also be specified?
<IncludeOnwardCalls>true</IncludeOnwardCalls>
IncludeOperatingDays 0:1 Include operating day information for this StopEvent as well?
<IncludeOperatingDays>true</IncludeOperatingDays>
UseRealtimeData 0:1 Determines how real-time is taken into account, full = everything; explanatory = also delayed and cancelled Connections (most detailed variant); none = only in accordance with Timetable.
<UseRealtimeData>explanatory</UseRealtimeData>

Response

The received result is a OJPStopEventDelivery Message consisting of the TripResponseContext and the different TripResults and looks as listed:

<OJP xmlns:siri="http://www.siri.org.uk/siri" xmlns="http://www.vdv.de/ojp" version="2.0">
    <OJPResponse>
        <siri:ServiceDelivery>
           <siri:ResponseTimestamp>2025-02-14T18:03:51.3185811+01:00</siri:ResponseTimestamp>
           <siri:ProducerRef>MENTZ</siri:ProducerRef>
           <OJPStopEventDelivery>
               <siri:ResponseTimestamp>2025-02-14T18:03:51.3185821+01:00</siri:ResponseTimestamp>
               <siri:RequestMessageRef>c5c59047-5c59-4ade-b635-9c942a0125ec</siri:RequestMessageRef>
               <siri:DefaultLanguage>de</siri:DefaultLanguage>
               <CalcTime>42</CalcTime>
               <StopEventResponseContext>
                   <Places>
                       <Place>
                           <StopPlace>
                               <StopPlaceRef>8591178</StopPlaceRef>
                               <StopPlaceName>
                                   <Text xml:lang="de">Zürich, Hardturm</Text>
                               </StopPlaceName>
                               <TopographicPlaceRef>23026261:27</TopographicPlaceRef>
                           </StopPlace>
                           <Name>
                               <Text xml:lang="de">Zürich, Hardturm</Text>
                           </Name>
                           <GeoPosition>
                               <siri:Longitude>8.50455</siri:Longitude>
                               <siri:Latitude>47.39415</siri:Latitude>
                           </GeoPosition>
                       </Place>
                       <Place>
                           <StopPoint>
                               <siri:StopPointRef>ch:1:sloid:91178::0</siri:StopPointRef>
                               <StopPointName>
                                   <Text xml:lang="de">Zürich, Hardturm</Text>
                               </StopPointName>
                               <ParentRef>8591178</ParentRef>
                               <TopographicPlaceRef>23026261:27</TopographicPlaceRef>
                           </StopPoint>
                           <Name>
                               <Text xml:lang="de">Zürich, Hardturm</Text>
                           </Name>
                           <GeoPosition>
                               <siri:Longitude>8.50455</siri:Longitude>
                               <siri:Latitude>47.39415</siri:Latitude>
                           </GeoPosition>
                       </Place>
                       <Place>
                           <TopographicPlace>
                               <TopographicPlaceCode>23026261:27</TopographicPlaceCode>
                               <TopographicPlaceName>
                                   <Text xml:lang="de">Zürich</Text>
                               </TopographicPlaceName>
                           </TopographicPlace>
                           <Name>
                               <Text xml:lang="de">Zürich</Text>
                           </Name>
                           <GeoPosition>
                               <siri:Longitude>8.50455</siri:Longitude>
                               <siri:Latitude>47.39415</siri:Latitude>
                           </GeoPosition>
                       </Place>
<!-- ... --> 
                       <Place>
                           <StopPoint>
                               <siri:StopPointRef>ch:1:sloid:91178::3</siri:StopPointRef>
                               <StopPointName>
                                   <Text xml:lang="de">Zürich, Hardturm</Text>
                               </StopPointName>
                               <ParentRef>8591178</ParentRef>
                               <TopographicPlaceRef>23026261:27</TopographicPlaceRef>
                           </StopPoint>
                           <Name>
                               <Text xml:lang="de">Zürich, Hardturm</Text>
                           </Name>
                           <GeoPosition>
                               <siri:Longitude>8.50429</siri:Longitude>
                               <siri:Latitude>47.39473</siri:Latitude>
                           </GeoPosition>
                       </Place>
                   </Places>
                   <Situations/>
               </StopEventResponseContext>
               <StopEventResult>
                   <StopEvent>
                       <PreviousCall>
                           <CallAtStop>
                               <siri:StopPointRef>ch:1:sloid:91178::0</siri:StopPointRef>
                               <StopPointName>
                                   <Text xml:lang="de">Zürich, Hardturm</Text>
                               </StopPointName>
                               <ServiceDeparture>
                                   <TimetabledTime>2025-02-17T08:33:00Z</TimetabledTime>
                               </ServiceDeparture>
                               <Order>1</Order>
                           </CallAtStop>
                       </PreviousCall>
<!-- ... --> 
                       <ThisCall>
                           <CallAtStop>
                               <siri:StopPointRef>ch:1:sloid:30813::0</siri:StopPointRef>
                               <StopPointName>
                                   <Text xml:lang="de">Zürich, Kreuzplatz</Text>
                               </StopPointName>
                               <ServiceDeparture>
                                   <TimetabledTime>2025-02-17T09:01:00Z</TimetabledTime>
                               </ServiceDeparture>
                               <Order>19</Order>
                           </CallAtStop>
                       </ThisCall>
                       <OnwardCall>
                           <CallAtStop>
                               <siri:StopPointRef>ch:1:sloid:91119::0</siri:StopPointRef>
                               <StopPointName>
                                   <Text xml:lang="de">Zürich, Englischviertelstrasse</Text>
                               </StopPointName>
                               <ServiceArrival>
                                   <TimetabledTime>2025-02-17T09:02:00Z</TimetabledTime>
                               </ServiceArrival>
                               <ServiceDeparture>
                                   <TimetabledTime>2025-02-17T09:03:00Z</TimetabledTime>
                               </ServiceDeparture>
                               <Order>20</Order>
                            </CallAtStop>
                        </OnwardCall>
<!-- ... --> 
                        <OnwardCall>
                            <CallAtStop>
                                <siri:StopPointRef>ch:1:sloid:91233::1</siri:StopPointRef>
                                <StopPointName>
                                    <Text xml:lang="de">Zürich, Klusplatz</Text>
                                </StopPointName>
                                <PlannedQuay>
                                    <Text xml:lang="de">B</Text>
                                </PlannedQuay>
                                <ServiceArrival>
                                    <TimetabledTime>2025-02-17T09:06:00Z</TimetabledTime>
                                </ServiceArrival>
                            </CallAtStop>
                        </OnwardCall>
                        <Service>
                            <Mode>
                                <PtMode>tram</PtMode>
                                <siri:TramSubmode>cityTram</siri:TramSubmode>
                                <Name>
                                    <Text xml:lang="de">Tram</Text>
                                </Name>
                                <ShortName>
                                    <Text xml:lang="de">T</Text>
                                </ShortName>
                            </Mode>
                            <ConventionalModeOfOperation>scheduled</ConventionalModeOfOperation>
                            <TrainNumber>4619</TrainNumber>
                            <siri:LineRef>ojp:91008:H</siri:LineRef>
                            <siri:OperatorRef>3849</siri:OperatorRef>
                            <PublicCode>Tram</PublicCode>
                            <PublishedServiceName>
                                <Text xml:lang="de">8</Text>
                            </PublishedServiceName>
                            <ProductCategory>
                                <Name>
                                    <Text xml:lang="de">Tram</Text>
                                </Name>
                                <ShortName>
                                    <Text xml:lang="de">T</Text>
                                </ShortName>
                                <ProductCategoryRef>2</ProductCategoryRef>
                            </ProductCategory>
                            <siri:DirectionRef>H</siri:DirectionRef>
                            <JourneyRef>ch:1:sjyid:100648:plan:3183eb5d-c26c-4ef4-972d-c92c4416363a</JourneyRef>
                            <OperatingDayRef>2025-02-17</OperatingDayRef>
                            <Cancelled>false</Cancelled>
                            <Unplanned>false</Unplanned>
                            <Deviation>false</Deviation>
                            <Attribute>
                                <UserText>
                                    <Text xml:lang="de">Niederflureinstieg</Text>
                                </UserText>
                                <Code>A__NF</Code>
                            </Attribute>
                            <OriginStopPointRef>ch:1:sloid:91178::0</OriginStopPointRef>
                            <DestinationStopPointRef>ch:1:sloid:91233::1</DestinationStopPointRef>
                            <OriginText>
                                <Text xml:lang="de">Zürich, Hardturm</Text>
                            </OriginText>
                            <DestinationText>
                                <Text xml:lang="de">Zürich, Klusplatz</Text>
                            </DestinationText>
                        </Service>
                        <OperatingDays>
                            <From>2025-02-02</From>
                            <To>2025-12-12</To>
                            <Pattern>01111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100011110011111000111000111110011111001111100111110011110001111100101110011111001111100111110010111001111000011110011111001111100111110011111001111100111110011111001111100111110011111</Pattern>
                        </OperatingDays>
                    </StopEvent>
                </StopEventResult>
<!-- ... --> 
            </OJPStopEventDelivery>
        </siri:ServiceDelivery>
    </OJPResponse>
</OJP>
+

The answer is in one OJPStopEventDelivery which is structured as follows:

Element Cardinality Description Example
siri:ResponseTimestamp 1:1 The timestamp of the answer
<siri:ResponseTimestamp>2020-04-03T14:47:59Z</siri:ResponseTimestamp>
siri:RequesteMessageRef 0:1 The message that has been requested is referenced here
<siri:RequestMessageRef>756</siri:RequestMessageRef>
siri:DeliveryStatus 0:1 The status of the response, true, means that the request has been processed.
<siri:Status>true</siri:Status>
CalcTime 0:1 The calculation time in milliseconds
<CalcTime>139</CalcTime>
StopEventResponseContext 0:1 Reference information such as the stops used is returned here.See separate table
StopEventResult 0:* The effective results. See example above.
<StopEventResult>
    <StopEvent>
        <PreviousCall>
            <CallAtStop>
                <siri:StopPointRef>ch:1:sloid:91178::0</siri:StopPointRef>
                <StopPointName>
                    <Text xml:lang="de">Zürich, Hardturm</Text>
                </StopPointName>
                <ServiceDeparture>
                    <TimetabledTime>2025-02-17T08:33:00Z</TimetabledTime>
                </ServiceDeparture>
                <Order>1</Order>
            </CallAtStop>
        </PreviousCall>
<!-- ... -->
        <ThisCall>
<!-- ... -->
        </ThisCall>
<!-- ... -->
        <OnwardCall>
<!-- ... -->
        </OnwardCall>
StopEventResult/Id 1:1 The ID of the result
<ResultId>ID-5194D714-33A5-48B0-8895-BDCBAB540958</ResultId>
StopEventResult/StopEvent 1:1 The individual journeysSee separate table

ResponseContextStucture

Structure with travel-related response contexts that include collections of places and situations as:

  • Operator
  • Places
  • Situation
Element Cardinality Description Example
Operators 0:1 Structure for operator objects. Only operator objects referred to in the response should be output. n/a
Places 0:1 Only those placement objects that are referred to in the answer should be included in the structure.
<Places>
    <Place>
        <StopPlace>
            <StopPlaceRef>8507000</StopPlaceRef>
            <StopPlaceName>
                <Text xml:lang="de">Bern</Text>
            </StopPlaceName>
            <TopographicPlaceRef>23006351:1</TopographicPlaceRef>
        </StopPlace>
        <Name>
            <Text xml:lang="de">Bern</Text>
        </Name>
        <GeoPosition>
            <siri:Longitude>7.43772</siri:Longitude>
            <siri:Latitude>46.94929</siri:Latitude>
        </GeoPosition>
    </Place>
<!-- ... -->
</Places>
Situations 0:1 Structure for SIRI SX situation objects. Only situations referred to in the response should be output.
<Situations>
    <PtSituation>
        <siri:CreationTime>2024-10-24T08:46:00Z</siri:CreationTime>
        <siri:ParticipantRef>ski-ddip-out-sx_prod</siri:ParticipantRef>
        <siri:SituationNumber>ch:1:sstid:100001:57f8d406-b6f7-420d-9a03-46eb48a4de24-1</siri:SituationNumber>
        <siri:Version>7</siri:Version>
        <siri:Source>
            <siri:SourceType>directReport</siri:SourceType>
        </siri:Source>
        <siri:ValidityPeriod>
            <siri:StartTime>2025-02-02T21:30:00Z</siri:StartTime>
            <siri:EndTime>2025-12-08T04:55:00Z</siri:EndTime>
        </siri:ValidityPeriod>
        <siri:AlertCause>unknown</siri:AlertCause>
        <siri:Priority>3</siri:Priority>
        <siri:ScopeType>stopPoint</siri:ScopeType>
        <siri:Language>de</siri:Language>
        <siri:PublishingActions>
        <siri:PublishingAction>
            <siri:PublishAtScope>
                <siri:ScopeType>stopPoint</siri:ScopeType>
                <siri:Affects/>
            </siri:PublishAtScope>
            <siri:PassengerInformationAction>
                <siri:ActionRef/>
                <siri:RecordedAtTime>2024-10-24T08:46:00Z</siri:RecordedAtTime>
                <siri:Perspective>stopPoint</siri:Perspective>
                <siri:TextualContent>
                    <siri:SummaryContent>
                        <siri:SummaryText xml:lang="de">Der Bahnverkehr zwischen Bern und Olten ist eingeschränkt.</siri:SummaryText>
                    </siri:SummaryContent>
                    <siri:ReasonContent>
                        <siri:ReasonText xml:lang="de">Der Grund dafür sind Bauarbeiten.</siri:ReasonText>
                    </siri:ReasonContent>
                    <siri:DurationContent>
                        <siri:DurationText xml:lang="de">Die Einschränkung dauert von 02.02.2025, 22:30 bis 03.02.2025, 05:55. Die Einschränkung dauert von 04.05.2025, 22:30 bis 05.05.2025, 05:55. Die Einschränkung dauert von 15.06.2025 bis 20.06.2025, jeweils von 22:30 bis 05:55. Die Einschränkung dauert von 22.06.2025 bis 27.06.2025, jeweils von 22:30 bis 05:55. Die Einschränkung dauert von 27.07.2025, 22:30 bis 28.07.2025, 05:55. Die Einschränkung dauert von 21.09.2025 bis 26.09.2025, jeweils von 22:30 bis 05:55. Die Einschränkung dauert von 28.09.2025 bis 03.10.2025, jeweils von 22:30 bis 05:55. Die Einschränkung dauert von 07.12.2025, 22:30 bis 08.12.2025, 05:55.</siri:DurationText>
                    </siri:DurationContent>
                </siri:TextualContent>
            </siri:PassengerInformationAction>
        </siri:PublishingAction>
    </siri:PublishingActions>
</PtSituation>

StopEventStructure

The StopEvent consists of:

  • PreviousCall(s): If parameter selected
  • ThisCall: The currently selected stop
  • OnwardCall(s): Future stops on the journey
  • Service: Information about the trip
Element Cardinality Description Example
PreviousCall 0:* PreviousCalls are the stops before the one requested.All information is contained in a CallAtStop. See relevant section
<PreviousCall>
    <CallAtStop>
        <siri:StopPointRef>8591142</siri:StopPointRef>
        <StopPointName>
            <Text>Zürich, Friedhof Enzenbühl</Text>
        </StopPointName>
        <ServiceArrival>
            <TimetabledTime>2020-04-03T15:32:00Z</TimetabledTime>
        </ServiceArrival>
        <ServiceDeparture>
            <TimetabledTime>2020-04-03T15:32:00Z</TimetabledTime>
        </ServiceDeparture>
        <Order>2</Order>
    </CallAtStop>
</PreviousCall>
ThisCall 1:1 This is the stop to which the request refers.All information is contained in a CallAtStop. See relevant section
<ThisCall>
    <CallAtStop>
        <siri:StopPointRef>8530813</siri:StopPointRef>
        <StopPointName>
            <Text>Zürich Kreuzplatz</Text>
        </StopPointName>
        <ServiceArrival>
            <TimetabledTime>2020-04-03T15:40:00Z</TimetabledTime>
        </ServiceArrival>
        <ServiceDeparture>
            <TimetabledTime>2020-04-03T15:40:00Z</TimetabledTime>
        </ServiceDeparture>
        <Order>9</Order>
    </CallAtStop>
</ThisCall>
OnwardCall 0:* The OnwardCall are the stops after the current stop that was requested in the request.All information is contained in a CallAtStop. See relevant section
<OnwardCall>
    <CallAtStop>
        <siri:StopPointRef>8591049</siri:StopPointRef>
        <StopPointName>
            <Text>Zürich, Auzelg</Text>
        </StopPointName>
        <ServiceArrival>
            <TimetabledTime>2020-04-03T16:16:00Z</TimetabledTime>
        </ServiceArrival>
        <Order>34</Order>
    </CallAtStop>
</OnwardCall>
Service 1:1 The service is the actual information for the entire journey.
<Service>
    <OperatingDayRef>2020-04-03</OperatingDayRef>
    <JourneyRef>ch:1:sjyid:100001:627-001</JourneyRef>
    <siri:LineRef>sbb:91011:A</siri:LineRef>
    <siri:DirectionRef>R</siri:DirectionRef>
    <Mode>
        <PtMode>tram</PtMode>
        <siri:TramSubmode>cityTram</siri:TramSubmode>
        <Name>
            <Text xml:lang="de">Tram</Text>
        </Name>
    </Mode>
    <PublishedLineName>
        <Text>11</Text>
    </PublishedLineName>
    <OperatorRef>sbb:3849</OperatorRef>
    <OriginStopPointRef>8591315</OriginStopPointRef>
    <OriginText>
        <Text xml:lang="de">Zürich, Rehalp</Text>
    </OriginText>
    <DestinationStopPointRef>8591049</DestinationStopPointRef>
    <DestinationText>
        <Text xml:lang="de">Zürich, Auzelg</Text>
    </DestinationText>
</Service>
OperatingDays 0:1 The validity of the specified journey and the pattern on which days this connection was searched
<OperatingDays>
    <From>2025-02-02</From>
    <To>2025-12-12</To>
    <Pattern>01111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100011110011111000111000111110011111001111100111110011110001111100101110011111001111100111110010111001111000011110011111001111100111110011111001111100111110011111001111100111110011111</Pattern>
</OperatingDays>
OperatingDays/From 1:1 Description
<From>2025-02-02</From>
OperatingDays/To 1:1 Description
<To>2025-12-12</To>
OperatingDays/Pattern 1:1 Further information on how to interpret the pattern can be found here: Line calendar
<Pattern>01111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100111110011111001111100011110011111000111000111110011111001111100111110011110001111100101110011111001111100111110010111001111000011110011111001111100111110011111001111100111110011111001111100111110011111</Pattern>

CallAtStopStructure

 

Element Cardinality Description Example
siri:StopPointRef 1:1 The stop number. At present, it is still a DiDok number. It can also be a NeTEx ID or a SLOID.Please note that both Didok and sloid can be present. More Info.
<siri:StopPointRef>8530813</siri:StopPointRef>
StopPointName 1:1 The name of the stop
<StopPointName>
    <Text>Zürich Kreuzplatz</Text>
</StopPointName>
PlannedQuay 0:1 The planned platform
<PlannedQuay>
    <Text xml:lang="de">1</Text>
</PlannedQuay>
EstimatedQuay 0:1 The current platform, if available
<EstimatedQuay>
    <Text xml:lang="de">1</Text>
</EstimatedQuay
ServiceArrival 0:1 The first stop has no arrival.
<ServiceArrival>
    <TimetabledTime>2020-04-03T15:40:00Z</TimetabledTime>
    <EstimatedTime>2020-04-03T15:40:00Z</EstimatedTime>
</ServiceArrival>
ServiceDeparture 0:1 The last stop has no departure.
<ServiceDeparture>
    <TimetabledTime>2020-04-03T15:40:00Z</TimetabledTime>
    <EstimatedTime>2020-04-03T15:40:00Z</EstimatedTime>
</ServiceDeparture>
Order 1:1 The order of the stops
<Order>9</Order>

 

RequestStop 0:1 Request stop. Boolean.Not implemented, planned for a future version. n/a
UnplannedStop 0:1 Stop that was not planned. Boolean.Not implemented, planned for a future version. n/a
NotServicedStop 0:1 Contrary to planning, no stops will be made (cancellations).
<NotServicedStop>true</NotServicedStop>
NoBoardingAtStop 0:1 Boarding is not possible at this stop.
<NoBoardingAtStop>true</NoBoardingAtStop>
NoAlightingAtStop 0:1 It is not possible to alight at this stop.
<NoAlightingAtStop>true</NoAlightingAtStop>

The ContinousServiceStructure

Element Cardinality Description Example
OperatingDayRef 1:1 The relevant operating day
<OperatingDayRef>2020-04-03</OperatingDayRef>
JourneyRef 1:1 The ID of the journey.
<JourneyRef>ch:1:sjyid:100001:627-001</JourneyRef>
siri:LineRef 1:1 The ID of the line:
<siri:LineRef>ojp:91021:H</siri:LineRef>
siri:DirectionRef 0:1 The ID of the direction.
<siri:DirectionRef>R</siri:DirectionRef>
Mode 1:1 The transport mode.The list of modes can be found at LocationInformationRequest
<Mode>
    <PtMode>tram</PtMode>
    <siri:TramSubmode>cityTram</siri:TramSubmode>
    <Name>
        <Text xml:lang="de">Tram</Text>
    </Name>
</Mode>
PublishedLineName 1:1 The published name of the list
<PublishedLineName>
    <Text>11</Text>
</PublishedLineNam
OperatorRef 0:1 The reference to the operator.Attention: will still change.
<siri:OperatorRef>11</siri:OperatorRef>
Attribute 0:* Attributes are properties usually related to journeys. E.g. low-floor bus, bar, reservation required.Mandateory is true if the attribute must be displayed to the user.
<Attribute>
    <Text>
        <Text xml:lang="de">Linie 31: Niederflureinstieg</Text>
    <Text>
    <Code>30</Code>
    <Mandatory>false</Mandatory>
</Attribute>
OrginStopPointRef 0:1 The Didok number of the start point.Attention: The ID will still change.
<OriginStopPointRef>8591315</OriginStopPointRef>
OriginText 0:1 The name of the departure stop.
<OriginText>
    <Text xml:lang="de">Zürich, Rehalp</Text>
</OriginText>
DestinationStopPointRef 0:1 The DiDok number of the destination stop.Please note: The ID will still change.
<DestinationStopPointRef>8591049</DestinationStopPointRef>
DestinationText 0:1 The name of the destination stop.
<DestinationText>
    <Text xml:lang="de">Zürich, Auzelg</Text>
</DestinationText>
Unplanned 0:1 Indicates whether an additional journey is not included in the regular timetable. Boolean.
<Unplanned>true</Unplanned>
Cancelled 0:1 Journey cancelled. Boolean.
<Cancelled>true</Cancelled>
Deviation 0:1 Indicates whether the journey will not be carried out according to the timetable.Planned for a future version n/a
BookingArrangements 0:1 The feature is not supported. n/a
ParticipantRef 1:1 Is used to communicate incidents or other exceptional situations.Planned for a future version n/a
siri:SituationNumber 1:1 Is used to communicate incidents or other exceptional situations.Planned for a future version n/a

Further information

Real-time

Important concepts:

  • Operating days: Days on which a train runs. Can ultimately last more than 24h. However, notation DD-MM-YYYY as Operating Days, e.g. in service/mode.
  • Zulu time: Corresponds to UTC time and is given as 2025-02-02T11:24:00Z, otherwise also so ISO 8601 Time with time zone deviation 2025-02-02T09:24:00+0200. There is no daylight saving time change in UTC time. Outputting fractions of a second is customary, especially for timestamps.
  • Hysteresis: In the area of customer information, only changes that exceed a certain size are forwarded. This is done by means of delay. This means that delays are not polled but only forwarded after a certain change has occurred. Deviations are communicated in 1/10 minutes.

Real-time or real-time is only output for the current operating day. The difference is specified in each case in relation to the StopPointRef, which also corresponds to the element available in the timetable, whereas a StopPlaceRef refers to a point in a station. In Switzerland, the same IDs are used for StopPointRef and StopPlaceRef.

Here is an example with real time using a ‘CallAtStop’. The same concept can be applied to all points in OJP where deviations from the timetable are reported:

<CallAtStop>
    <siri:StopPointRef>ch:1:sloid:91128::0</siri:StopPointRef>
    <StopPointName>
        <Text xml:lang="de">Zürich, Fernsehstudio</Text>
    </StopPointName>
    <ServiceArrival>
        <TimetabledTime>2025-02-17T13:06:18Z</TimetabledTime>
        <EstimatedTime>2025-02-17T13:05:54Z</EstimatedTime>
    </ServiceArrival>
    <ServiceDeparture>
        <TimetabledTime>2025-02-17T13:06:30Z</TimetabledTime>
        <EstimatedTime>2025-02-17T13:06:00Z</EstimatedTime>
    </ServiceDeparture>
    <Order>2</Order>
</CallAtStop>

The discrepancy between the ‘TimetabledTime’ and the ‘EstimatedTime’ is the real-time deviation from the timetable; this is also indicated if, for example, an earlier arrival. It therefore makes sense to implement the logic for outputting the deviation so that only deviations that are relevant to the customer, such as a delay, are output.

Car tunnel trains

<OJP xmlns="http://www.vdv.de/ojp" xmlns:siri="http://www.siri.org.uk/siri" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xsi:schemaLocation="http://www.vdv.de/ojp" version="2.0">
    <OJPRequest>
        <siri:ServiceRequest>
            <siri:ServiceRequestContext>
                <siri:Language>de</siri:Language>
            </siri:ServiceRequestContext>
            <siri:RequestTimestamp>2025-02-17T08:03:02.813Z</siri:RequestTimestamp>
            <siri:RequestorRef>SKIPlus_ATZ</siri:RequestorRef>
            <OJPStopEventRequest>
                <siri:RequestTimestamp>2025-02-17T08:03:02.813Z</siri:RequestTimestamp>
                <Location>
                    <PlaceRef>
                        <siri:StopPointRef>8511171</siri:StopPointRef>
                        <Name>
                            <Text>Kandersteg Autoverlad</Text>
                        </Name>
                    </PlaceRef>
                </Location>
                <Params>
                    <IncludeAllRestrictedLines>true</IncludeAllRestrictedLines>
                    <NumberOfResults>10</NumberOfResults>
                    <StopEventType>departure</StopEventType>
                    <IncludePreviousCalls>true</IncludePreviousCalls>
                    <IncludeOnwardCalls>true</IncludeOnwardCalls>
                    <UseRealtimeData>full</UseRealtimeData>
                </Params>
            </OJPStopEventRequest>
        </siri:ServiceRequest>
    </OJPRequest>
</OJP>

Large-capacity profiles (at BLS) are identifiable by the GF attribute:

<Attribute>
    <Text>
        <Text xml:lang="de">Grossraumprofil</Text>
    </Text>
    <Code>A__GF</Code>
</Attribute>