latestOpenAPI 3.0.12026-08-102668257.3 KB

8e9a8f8010ab

Shopping and Ticketing

Smart Search(Only For TMC)

Advantages of Smart Search:

  • Supports real-time search for booking windows and routes not covered in "Search API".
  • Enhances search result rate and overall coverage.

Points to note:

  • Smart Search will be activated "on demand". Please contact your account manager or sales director if you want this feature to be activated.
  • The ist response will return the results from the cache. if the "smartEnd"=false, send the subsequent requests until if the "smartEnd"=true to get all the results from the LIVE search.
  • <span style="color:rgb(255, 140, 0)">Use production endpoint being used for APls other than search APl.</span>

Workflow:

  • Send the "Smart Search" request(called First Request) and receive the response, which includes an ID (requestId) used to identify the entire search process, and may also contain part of the flight data(routings).
  • After receiving the response, if thesmartEnd=false, then send another request (called Subsequent Request) only with therequestId.
  • Follow this flow untilsmartEnd=true. This means that the smart search has been completed.

Endpoint: https://sandbox.atriptech.com/smartSearch.do

post/smartSearch.do

Headers

Acceptstring required
Content-Typestring required
Accept-Encodingstring required
x-atlas-client-idstring required
x-atlas-client-secretstring required

Request body

requestIdstring required

Only required in Subsequent Request

tripType'1' | '2' required

The trip type(1=one way or 2=round trip) you want to search

adultNuminteger required

Adult passenger count. Please note that the total number of adults(adultNum) and children(childNum) cannot exceed 9.

childNuminteger required

Child passenger count. Please note that the total number of adults(adultNum) and children(childNum) cannot exceed 9

infantNuminteger required

Infant passenger count, no more than the number of adult

fromCitystring required

IATA code of the departure city or airport (in capital letters).When the airport code you sent is different from the code of the city where the airport is located, we can recognize that it is an airport, otherwise we will treat it as a city code. We will filter flights based on your departure location type.

toCitystring required

IATA code of the arrival city or airport (in capital letters).When the airport code you sent is different from the code of the city where the airport is located, we can recognize that it is an airport, otherwise we will treat it as a city code. We will filter flights based on your departure location type.

fromAirportstring nullable

IATA code of the departure airport

toAirportstring nullable

IATA code of the arrival airport

fromDatestring date required

Departure date, the format is YYYYMMDD

retDatestring date nullable

Return date, the format is YYYYMMDD. If you are searching for round-trip, the return date is mandatory.

airlinesstring[] nullable

An array of IATA Codes(in capital letters) of airlines. The result will only contain the airlines specified in the search request.

fromFlightNumbersstring[] nullable

Search for specified departure flights. Each element represents one flight. Connecting flight numbers are separated by "," (comma). Example:

  • ["FR123"]: A direct flight
  • ["FR456,FR789"]: A connecting flight
  • ["FR123", "FR456,FR789"]: 2 flights, a direct flight and a connecting flight
retFlightNumbersstring[] nullable

Search for specified return flights. Each element represents one flight. Connecting flight numbers are separated by "," (comma).

includeMultipleFareFamilyboolean nullable

Search only for the lowest fare or for the Fare Families. By default, each flight only returns the lowest fare, and each array element in the response represents: flight - lowest fare. If this parameter is turned on, each element of the search results will be a combination of flight and one of the fares, that is, different elements will have the same flight but different ticket fare.

currencystring nullable

This is the settlement currency. The 3-letter currency code should be entered. This field is optional, and when you want to settle with Atlas in different currencies (especially when you have opened multiple deposit accounts in different currencies in Atlas), you need to use this parameter.

displayCurrencystring nullable

The currency for the display fares in response. If no display currency is specified, the display amount will be null.

requestSourcestring nullable

Identify the source of the search traffic, E.g. Google Flights, Oganic Search, SkyScanner.

syncboolean

Is smart search synchronized return, default is asynchronous

residentCodestring nullable

Resident discount code

Response

status100 | 101 | 102 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 116 | 123 | 124 | 126 | 900 | 9999 required
msgstring

It serves as an additional description of the response result. Especially when the interface reports an error (status !=0), it is usually a human-readable error message. Note: Do not use this field in any programming scenarios. For example, do not judge whether the interface responds successfully based on this field. Instead, you should only determine it by checking whether the status is equal to0at any time.

requestIdstring required

Unique identifier for the search process.

smartEndboolean required

Informing whether the request has been completed. -true: Indicates that the search has ended -false: Indicates that the search is still in progress