Retrieve flight results
Poll a search task for itineraries, mileage prices, and availability as each loyalty program returns results.
POST
https://apisv2.awardtoolapi.com/flight_retrieval/search_resultExample request
Shell
curl --request POST \
'https://apisv2.awardtoolapi.com/flight_retrieval/search_result' \
--header 'Content-Type: application/json' \
--data '{
"task_id": "example-flight-search-01",
"api_key": "YOUR_API_KEY"
}'Keep polling with the same key and task_id while finish is false, even if a poll returns an empty result array.
Merge each batch into the results you have already collected. Use ids.flight_deduplicate_id to recognize the same priced itinerary across responses.
Request body
task_idstring · Required- The task_id returned when you submitted the flight search.
api_keystring · Required- Your AwardTool API key.
Example response
JSON · response excerpt
{
"task_id": "example-flight-search-01",
"finish": false,
"finish_reason": "unknown",
"program_done": [
"program|AA|JFK|LHR|1:0|20270215"
],
"missing_keys": [
"program|AC|JFK|LHR|1:0|20270215"
],
"result": [
{
"program_code": "AA",
"date": "2027-02-15",
"cabin_type": "Business",
"award_points": 57500,
"surcharge": 5.6,
"currency": "USD",
"seats": 1,
"ids": {
"flight_deduplicate_id": "example-priced-itinerary"
}
}
],
"status": 200
}Response fields
finish- Stop polling when this flag is true.
finish_reason- Reason polling ended. The value can be unknown while the task runs.
program_done- Program searches that have finished, including those with zero awards.
missing_keys- Program searches whose results are still outstanding.
result- Itineraries in this batch, including cabin, points, taxes, seat count, and flight segments when available.
result[].ids.flight_deduplicate_id- Identifier for a particular itinerary and price.