TravelCaster API - Fulfillment - SearchExchangeAlternatives
Back to Fulfillment home.
Searches for available flight alternatives for the specified legs of an existing booking. Returns one or more exchange offers, each containing replacement itinerary options and the associated pricing differences.
The RecommendationID in the response is required for the subsequent FulfillExchange call. It expires 60 minutes after issuance.
Request
JSON
https://endpoint/api/version/FulfillmentService.json/SearchExchangeAlternatives[POST]request:
ExchangeSearchRequestresponse:
ExchangeSearchResponse
Structure of the ExchangeSearchRequest object
ExchangeSearchRequest
|
|_ Token (string - required - access token from AuthService)
|_ BookingNumber (string - required - record locator of the booking to exchange)
|_ LegsToExchange (ExchangeQueryLeg[] - required - one entry per leg to replace)
|
|_ LegNumber (int - required - 1-based leg number from the original booking)
|_ DepartureAirport (string - IATA 3-letter - original departure airport)
|_ ArrivalAirport (string - IATA 3-letter - original arrival airport)
|_ FlightDate (string - YYYY-MM-DD - original flight date)
|_ NewDepartureAirportCity (string - optional - new departure if changing origin)
|_ NewArrivalAirportCity (string - optional - new arrival if changing destination)
|_ NewFlightDate (string - optional - YYYY-MM-DD - desired new date)
|_ NewFlightTime (string - optional - HH:MM - preferred departure time)
|_ FlexibleDateRange (int - optional - search within ±N days of NewFlightDate)
Structure of the ExchangeSearchResponse object
ExchangeSearchResponse
|
|_ TransactionID (string)
|_ TransactionCode (string - "0" = success)
|_ TransactionMessage (string)
|
|_ RecommendationID (string - required for FulfillExchange - valid 60 minutes)
|_ BookingNumber (string - record locator)
|_ VoidAvailable (bool - true if the booking can be voided instead of exchanged)
|_ AllowedFormsOfPayment (ExchangeFormOfPayment[])
| |
| |_ PaymentType (string - CASH or CARD)
| |_ AllowedCards (CreditCardType[])
| | |_ Code (string - e.g. VI, CA, AX)
| | |_ Name (string - display name)
| |_ CardAllowedAuthMethods (string[] - e.g. CVV, AUTHCODE)
|
|_ Offers (ExchangeOffer[])
|
|_ RefNumber (string - provider reference for this offer)
|_ ExchangeTotalAmount (AmountData - fare+tax difference before penalty)
| |_ Amount (decimal)
| |_ Currency (string - ISO 3-letter)
|_ PenaltyAmount (AmountData - exchange penalty)
| |_ Amount (decimal)
| |_ Currency (string - ISO 3-letter)
|_ TotalDue (AmountData - total amount due: difference + penalty + fees)
| |_ Amount (decimal)
| |_ Currency (string - ISO 3-letter)
|_ EquivTotalDue (AmountData - TotalDue in purchase currency)
| |_ Amount (decimal)
| |_ Currency (string - ISO 3-letter)
|_ LastTicketingDate (string - ISO 8601 ticketing deadline)
|_ PaxFareDetails (ExchangeOfferPaxFare[] - per-passenger-type breakdown)
| |
| |_ PTC (string - ADT, CHD, INF)
| |_ Count (int - number of passengers of this type)
| |_ FareDifferenceAmount (AmountData - fare portion of the difference)
| |_ TaxDifferenceAmount (AmountData - tax portion of the difference)
| |_ PenaltyAmount (AmountData - penalty for this passenger type)
| |_ TotalDifferenceAmount (AmountData - total including penalty)
|
|_ Legs (ExchangeOfferLeg[] - one per leg included in the offer)
|
|_ LegNumber (int - 1-based)
|_ DepartureAirportCity (string - IATA 3-letter)
|_ ArrivalAirportCity (string - IATA 3-letter)
|_ FlightDate (string - YYYY-MM-DD)
|_ ShopRequested (bool - true if alternatives were searched; false if original leg is kept)
|_ Options (ExchangeOfferOption[] - available replacement itineraries for this leg)
|
|_ LegNumber (int)
|_ OptionNumber (int - 1-based option index within this leg)
|_ RefNumber (string - use this value in FulfillExchange.LegsToExchange.ReplaceWithOptionRef)
|_ DurationMinutes (int - total journey duration)
|_ Segments (FlightSegment[])
|
|_ SegmentNumber (int)
|_ Airline (string - IATA 2-letter marketing carrier)
|_ OperatingAirline (string - IATA 2-letter)
|_ FlightNumber (int)
|_ BookingClass (string - 1-letter RBD)
|_ CabinClass (string - 1-letter: Y=Economy, W=Premium Economy, C=Business, F=First)
|_ FareBasis (string)
|_ Status (string)
|_ Equipment (string - IATA aircraft type)
|_ Baggage (string - e.g. 1PC, 23K)
|_ Duration (int - segment duration in minutes)
|_ Departure (FlightEvent)
| |_ AirportCode (string - IATA 3-letter)
| |_ Date (string - YYYY-MM-DD)
| |_ Time (string - HH:MM local time)
|_ Arrival (FlightEvent)
|_ AirportCode (string - IATA 3-letter)
|_ Date (string - YYYY-MM-DD)
|_ Time (string - HH:MM local time)
Notes
- Each
ExchangeOfferrepresents a pricing scenario. A single offer may contain options for multiple legs. - Legs where
ShopRequested = falsekeep the original flights; theirOptionsarray will contain a single entry mirroring the current itinerary. - The
RecommendationIDmust be passed unchanged toFulfillExchange. It is validated server-side and expires after 60 minutes. - To fulfil an offer, select one
Option.RefNumberper leg and pass them inFulfillExchange.LegsToExchange.
Back to Fulfillment home.
See change history for this file
Loading...