The BoB Booking API supports booking of Demand Responsive Transport, a form of transport which needs to be requested in advance and is not scheduled in a timetable. It can be added as a request to an ordinary combined journey.
When a travel is requested from the sales channel the Product API uses the optional field bookingRequired to tell the sales channel that it has to call the Booking API. The sales channel requests a booking for the trip chosen by the traveller which results in a preliminary booking of the Demand Responsive Transport part of the journey. The sales channel requests the ticket for the given manifest from the Ticket API. The ticket (MTB) is returned from the Ticket API. The sales channel calls Booking API to confirm the preliminary booking. MTB is attached as proof of purchase. A confirmation is received that the booking is confirmed by the Booking API. When the traveler has completed the payment the sales channel presents the ticket to the traveler.
For implemenentation and documentation details for each API request described on this page please see OpenAPI specifcation for that specific API.
Bob Booking API
Additional API used
The following example is provided as guidance for implementation supporting combined journeys including demand responsive transport.
Traveller buys a ticket for a trip from A to D via B and C. In other words, a trip with three legs A-B-C-D. The trip begins and ends with Demand Responsive Transport.
An input from a journey planner for a journey from start to end is needed before a ticket can be requested.
For editing of sequence diagram - Use below code in: https://sequencediagram.org/ title Booking participantspacing equal actor "Traveller" as traveller autonumber sales->auth_api: Request JWT traveller->sales: Request ticket for trip A-D sales->product_api: Request products (with certain criterias) sales-->traveller: Return price and options A-D sales->product_api: Request manifest valid for A-D sales->booking_api: Request booking for X (since bookingRequired is true for the product) sales-->traveller: Display booking-related\ndetails/conditions for trip X traveller->sales: Confirms booking details sales->psp_api: Reserve payment for X sales->ticket_api: Request ticket given manifest sales->booking_api: Confirm preliminary booking for X on given MTB sales->psp_api: Request payment for X sales-->traveller: MTB valid for X |