Description
An operation that is similar to the search operation, but with the option of returning partial search results by polling the API.
Partial Searching can be enabled by adding the following to a LowFareSearchRQ:
...
<PartialSearchInfo>
<PartialSearchAction>Search</PartialSearchAction>
</PartialSearchInfo>
...
See example request - Initial OTA_AirLowFareSearchRQ (partial search)
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="http://www.opentravel.org/OTA/2003/05">
<soapenv:Header/>
<soapenv:Body>
<OTA_AirLowFareSearchRQ TimeStamp="2012-04-18T07:30:42.663Z"
Target="Production" Version="1.0"
PrimaryLangID="en" AltLangID="en"
RetransmissionIndicator="false" xmlns="http://www.opentravel.org/OTA/2003/05">
<POS>
<Source ISOCountry="ZA" ISOCurrency="ZAR"
DisplayCurrency="ZAR" DisplayRate="1.0"
FirstDepartPoint="CPT" FinalDestinationPoint="JNB">
<RequestorID Type="Company" ID="website"
ID_Context="ts" MessagePassword="<PASSWORD>">
<CompanyName>
<USERNAME>
</CompanyName>
</RequestorID>
</Source>
</POS>
<OriginDestinationInformation RefNumber="0">
<DepartureDateTime>2012-07-26T00:00:00CAT</DepartureDateTime>
<OriginLocation LocationCode="CPT" CodeContext="iata"
/>
<DestinationLocation LocationCode="JNB" CodeContext="iata"
/>
</OriginDestinationInformation>
<OriginDestinationInformation RefNumber="1">
<DepartureDateTime>2012-07-29T00:00:00CAT</DepartureDateTime>
<OriginLocation LocationCode="JNB" CodeContext="iata"
/>
<DestinationLocation LocationCode="CPT" CodeContext="iata"
/>
</OriginDestinationInformation>
<TravelPreferences>
<FlightTypePref FlightType="Nonstop" DirectAndNonStopOnlyInd="true"
/>
<!-- This line is optional – include to filter direct flights only -->
<CabinPref Cabin="Economy" />
</TravelPreferences>
<TravelerInfoSummary>
<AirTravelerAvail>
<PassengerTypeQuantity Code="7" Quantity="0"
/>
<PassengerTypeQuantity Code="8" Quantity="0"
/>
<PassengerTypeQuantity Code="9" Quantity="0"
/>
<PassengerTypeQuantity Code="10" Quantity="1"
/>
</AirTravelerAvail>
</TravelerInfoSummary>
<PartialSearchInfo>
<PartialSearchAction>Search</PartialSearchAction>
</PartialSearchInfo>
</OTA_AirLowFareSearchRQ>
</soapenv:Body>
</soapenv:Envelope>
Expected output
The initial response will not contain any PricedItineraries; it will contain the following attributes on the OTA_AirLowFareSearchRS tag:
PartialSearchId="LUFYQP1378985409222" PartialSearchResultsRemaining="true"
Please see example response - OTA_AirLowFareSearchRS (partial search)
<SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP:Body>
<OTA_AirLowFareSearchRS TimeStamp="2013-09-12T11:12:20.28Z"
Target="Production" Version="1.0"
PrimaryLangID="en" RetransmissionIndicator="false"
CorrelationID="1NVMMPCUCVGE8UUF97RSJ5E0C2"
PlatformCurrency="ZAR" Regionality="Domestic"
Bundled="false" PartialSearchId="LUFYQP1378985409222"
PartialSearchResultsRemaining="true"
xmlns="http://www.opentravel.org/OTA/2003/05">
<Success/>
<PricedItineraries/>
</OTA_AirLowFareSearchRS>
</SOAP:Body>
</SOAP:Envelope>
The client would then make subsequent API calls using the same LowFareSearchRequest with the following Partial Search Information:
...
<PartialSearchInfo PartialSearchId="LUFYQP1378985409222">
<PartialSearchAction>Poll</PartialSearchAction>
</PartialSearchInfo>
...
The PartialSearchId should be the value returned by the initial LowFareSearch Response. Also, the Partial Search Action should be set to Poll.
Please see example request - Polling OTA_AirLowFareSearchRQ (partial search)
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns="http://www.opentravel.org/OTA/2003/05">
<soapenv:Header/>
<soapenv:Body>
<OTA_AirLowFareSearchRQ TimeStamp="2012-04-18T07:30:42.663Z"
CorrelationID="1NVMMPCUCVGE8UUF97RSJ5E0C2"
Target="Production" Version="1.0"
PrimaryLangID="en" AltLangID="en"
RetransmissionIndicator="false" xmlns="http://www.opentravel.org/OTA/2003/05">
<POS>
<Source ISOCountry="ZA" ISOCurrency="ZAR"
DisplayCurrency="ZAR" DisplayRate="1.0"
FirstDepartPoint="CPT" FinalDestinationPoint="JNB">
<RequestorID Type="Company" ID="website"
ID_Context="ts" MessagePassword="<PASSWORD>">
<CompanyName><USERNAME></CompanyName>
</RequestorID>
</Source>
</POS>
...... Same contents of original request
......
<PartialSearchInfo PartialSearchId="LUFYQP1378985409222">
<PartialSearchAction>Poll</PartialSearchAction>
</PartialSearchInfo>
</OTA_AirLowFareSearchRQ>
</soapenv:Body>
</soapenv:Envelope>
Each poll search response will contain a PartialSearchResultsRemaining attribute on the OTA_AirLowFareSearchRS tag which will be set to true or false . A value of false indicates that there are no more search results and that the search is complete.