Get the ticket number
Ask for the e-ticket number of a booking: FX-Port asks the airline when the number is not stored yet.
POST/api/v1/flights/get_ticket_number
Returns the e-ticket number of a booking, asking the airline for it when it is not stored yet. Use it after an instant booking whose ticket number has not arrived, or to find out whether the tickets of a booking were issued.
Permission: Read. Rate group: default (6,000 requests per minute per key).
Request body
| Field | Type | Required | Description |
|---|---|---|---|
booking_id | string | Yes | The PNR, the supplier order id or the FX-Port UUID. order_id and pnr are accepted as other names. |
Legacy names: bookingId and orderId. If booking_id is sent together with order_id or pnr and the values differ, booking_id wins and an ignored_field warning names the dropped one. Only bookings of your agency in the environment of your key are answered (a sandbox key never reads a live booking); anything else, including the booking of another agency, is 404 booking_not_found.
Request example
curl https://api.fx-port.com/api/v1/flights/get_ticket_number \
-H "Authorization: Bearer fxp_test_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{
"booking_id": "Y7PAEU"
}'Response: not yet
A hold has no ticket; an instant booking can have none for a few seconds. Real response of 2026-11-01 for a hold:
{
"environment": "sandbox",
"success": true,
"requestId": "921cee35",
"ticket_available": false,
"ticket_number": null,
"booking_id": "Y7PAEU",
"supplier_order_id": "eJzTd9ePNA9wdA0FAAs8AmE",
"message": "The airline has not returned a ticket number yet. Please retry shortly.",
"booking_response": { "...": "the stored booking, see below" }
}Response: issued
The same booking after pay_order:
{
"environment": "sandbox",
"success": true,
"requestId": "a8e2164f",
"ticket_available": true,
"ticket_number": "124-2446977397",
"booking_id": "Y7PAEU",
"supplier_order_id": "eJzTd9ePNA9wdA0FAAs8AmE",
"booking_response": { "...": "the stored booking, see below" }
}| Field | Meaning |
|---|---|
ticket_available | true when the airline has returned a ticket number. |
ticket_number | The e-ticket number, for example 124-2446977397 (Amadeus); in the Duffel sandbox the text 1. When there are several tickets they are joined in one text. null until available. |
booking_id | The PNR (twin: pnr). |
supplier_order_id | The supplier's order id (twin: order_id). |
message | Only when ticket_available is false. |
booking_response | The stored answer of the booking, in the shape of the book response (booking, supplier, pricing, passengers, itinerary, documents ...), without the supplier's costs and commissions. Use get_booking for a stable description of the booking. |
Errors
| Status | Code | When | What to do |
|---|---|---|---|
400 | bad_request | No booking_id (booking_id is required). | Send it. |
400 | invalid_booking_id, invalid_json, invalid_body | The id is not a valid token, or the body is not a JSON object. | Fix the request. |
400 | unsupported_supplier | The booking is not an Amadeus, Travelport or Duffel booking. | Use get_booking. |
404 | booking_not_found | No such booking for your agency. | Check the id. |
Related
- Get a flight booking and Get the ticket PDF.
- ACD passport uploads: the
ticket_numberof an ACD traveler isnulluntil the airline returns it.