Reference · step 7 of 9
POST/flights/booking/details
{{base_url}}/flights/booking/details
The booking as stored: status, payment status, the flights with the PNR, the passengers with their fare and ticket number per flight, the price.
Headers
| Content-Type | application/json |
| Authorization | Bearer {{token}} |
Reply (4 notes)
- journeys[] is the booking journey by journey: its dates, its flights (segment_index restarts at 0 inside each journey; operating airline shown only on a codeshare) and, for every passenger on it, who they are (passenger_index is the same person on every journey), the status, the PNR, the ticket number, the fare paid for that journey in the components of the search price plus ancillaries, the fare attributes (fare_ref, refundable_type, cabin, booking class, fare basis, included baggage) and the ancillaries bought (a seat or meal with its segment_index, a bag without).
- status per passenger per journey is PENDING until the booking is held or ticketed, then CONFIRMED; CANCELLED, VOIDED or REISSUED come later. price is the booking as a whole in the same components, total_fare and net_fare included.
- pay_till appears on a held booking. Zero fare fields are omitted (omitempty).
- status values are the API's order statuses: CREATED, PENDING, SUCCESS, ONHOLD, FAILED, PNR_RELEASED, CANCELLED, ABORTED.
Keys and what they mean
Request
| key | type | when present | importance | meaning |
|---|---|---|---|---|
| booking_id | string | required | must read | The id book returned. |
| Total: 1 keys | ||||
Reply
| key | type | when present | importance | meaning |
|---|---|---|---|---|
| status | string | always | must read | The booking's state: CREATED, ONHOLD, SUCCESS, PNR_RELEASED, CANCELLED, FAILED. |
| payment_status | string | always | must read | PENDING until paid, then SUCCESS; FAILED or REFUNDED later. |
| pay_till | datetime | on a hold | must read | Until when a held booking can be confirmed; after it the airline releases the seats. |
| journeys[] | array | always | must read | The booking journey by journey: its dates, its flights and, for every passenger on it, who they are, their state, the PNR, the ticket, the fare paid for that journey and the add-ons. |
| journeys[].passengers[].pnr | string | once the airline confirmed | must read | The airline's record locator for this passenger on this journey. Empty until the hold or the ticket is confirmed. |
| journeys[].passengers[].status | string | always | must read | PENDING until confirmed, then CONFIRMED; CANCELLED, VOIDED or REISSUED when something happened to this passenger on this journey. |
| price | object | always | must read | The booking's price as a whole, in the components of the search price (base_fare, yq, yr, airline_gst, booking_fee, commission, other_taxes, total_fare, net_fare) plus ancillaries and fees. |
| journeys[].passengers[].fare | object | always | must read | What this passenger's journey cost, in the components of the search price plus ancillaries bought on it. |
| Total: 8 keys | ||||
Errors this call answers with (4)
| HTTP | code | message | detail | when |
|---|---|---|---|---|
| 401 | 9001 | Authentication required | Invalid token | |
| 403 | 9002 | You do not have permission for this action | Role without bookings.read. | |
| 400 | 3000 | Invalid request | Booking_id is required | |
| 404 | 9005 | Not found | Booking not found |
Questions developers ask (1)
- Why is pnr empty?
- The airline has not confirmed yet: the passenger reads PENDING. It appears once the hold or the ticket is confirmed.
Real captures of this call
- Domestic, one way, 1 adult · HTTP 200 · reply in the viewer
- Domestic, one way, 1 adult, 1 child, 1 infant · HTTP 200 · reply in the viewer
- Domestic, return, 1 adult · HTTP 200 · reply in the viewer
- Domestic, return, 1 adult, 1 child, 1 infant · HTTP 200 · reply in the viewer
- Book on hold, plain · HTTP 200 · reply in the viewer
- Book on hold with GST details · HTTP 200 · reply in the viewer
- Book on hold with a seat, a meal and a bag, one flight · HTTP 200 · reply in the viewer
- Book on hold with ancillaries on a two-flight journey · HTTP 200 · reply in the viewer
- Direct booking (paid, no hold), plain · HTTP 200 · reply in the viewer
- Direct booking (paid, no hold) with GST details · HTTP 200 · reply in the viewer
- Direct booking (paid, no hold) with a seat, a meal and a bag, one flight · HTTP 200 · reply in the viewer
- Direct booking (paid, no hold) with ancillaries on a two-flight journey · HTTP 200 · reply in the viewer
- Hold, then confirm (pay) the hold · HTTP 200 · reply in the viewer
- Hold, then release the hold · HTTP 200 · reply in the viewer