Flexible Flight Search
Search one or two ordered flight legs in one request. Use it for multi-city routes, open-jaw trips, or any itinerary where adjacent legs use different airports. For ordinary one-way and round-trip searches, the dedicated endpoints remain the simplest choice.
Request body
| Parameter | Type | Required | Description |
|---|---|---|---|
| legs | array | Yes | One or two ordered leg objects. Dates must be chronological. |
| adults | integer | No | Number of passengers age 12 or older. Default: 1. Max total passengers: 9. |
| children | integer | No | Number of child passengers ages 2–11. Default: 0. |
| infants_in_seat | integer | No | Number of infants with their own seat. Default: 0. |
| infants_on_lap | integer | No | Number of lap infants. Cannot exceed number of adults. Default: 0. |
| cabin_class | string | No | One of "economy", "premium_economy", "business", or "first". Default: "economy". Fares use this requested cabin class. |
| min_carry_on_bags | integer | No | Minimum carry-on bags included. |
| min_checked_bags | integer | No | Minimum checked bags included. |
| max_price | integer | No | Strict maximum price in the market's currency. |
| airlines_include | string[] | No | Only include flights from these 2-character airline codes. A code cannot also appear in airlines_exclude. |
| airlines_exclude | string[] | No | Exclude flights from these 2-character airline codes. A code cannot also appear in airlines_include. |
| allow_self_transfer | boolean | No | Allow itineraries identified as requiring separate tickets (self-transfer). Setting false is a best-effort filter; same-carrier separate tickets may not be identifiable. Default: true. |
| market | string | No | 2-letter country code for pricing locale (e.g. "US", "GB"). Default: "US". |
Leg object
| Parameter | Type | Required | Description |
|---|---|---|---|
| origin | string | Yes | 3-letter IATA airport or metro code for this leg's departure. |
| destination | string | Yes | 3-letter IATA airport or metro code for this leg's arrival. |
| departure_date | string | Yes | Departure date in YYYY-MM-DD format. |
| max_stops | integer | No | Maximum stops for this leg: 0, 1, or 2. |
| departure_time_range | object | No | Local departure and arrival hour bounds for this leg, using the same fields as one-way search. |
Open-jaw example
curl -X POST "https://ignav.com/api/fares/search" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"legs":[{"origin":"SFO","destination":"DEN","departure_date":"2026-11-18"},{"origin":"COS","destination":"ORD","departure_date":"2026-11-22","max_stops":0}],"adults":2}'{
"legs": [
{
"origin": "SFO",
"destination": "DEN",
"departure_date": "2026-11-18"
},
{
"origin": "COS",
"destination": "ORD",
"departure_date": "2026-11-22"
}
],
"observed_at": "2026-01-01T12:00:00Z",
"itineraries": [
{
"price": {
"amount": 742,
"currency": "USD",
"status": "verified"
},
"legs": [
{
"carrier": "American Airlines",
"duration_minutes": 150,
"segments": [
{
"marketing_carrier_code": "AA",
"flight_number": "1412",
"operating_carrier_name": "American Airlines",
"departure_airport": "SFO",
"departure_time_local": "2026-11-18T09:00:00",
"departure_timezone": "America/Los_Angeles",
"departure_time_utc": "2026-11-18T16:00:00Z",
"arrival_airport": "DEN",
"arrival_time_local": "2026-11-18T12:30:00",
"arrival_timezone": "America/Denver",
"arrival_time_utc": "2026-11-18T18:30:00Z",
"duration_minutes": 150,
"aircraft": "Boeing 737"
}
]
},
{
"carrier": "American Airlines",
"duration_minutes": 150,
"segments": [
{
"marketing_carrier_code": "AA",
"flight_number": "2285",
"operating_carrier_name": "American Airlines",
"departure_airport": "COS",
"departure_time_local": "2026-11-22T09:00:00",
"departure_timezone": "America/Denver",
"departure_time_utc": "2026-11-22T15:00:00Z",
"arrival_airport": "ORD",
"arrival_time_local": "2026-11-22T12:30:00",
"arrival_timezone": "America/Chicago",
"arrival_time_utc": "2026-11-22T17:30:00Z",
"duration_minutes": 150,
"aircraft": "Boeing 737"
}
]
}
],
"cabin_class": "economy",
"requires_self_transfer": false,
"ignav_id": "b2c3d4e5f6789012345678abcdef0123"
}
]
}Ranked complete journeys
Each result is already a complete, compatible journey: its legs array matches the request order and its price describes that complete itinerary. You do not need to select one flight and search each remaining combination in turn.
Results cover returned first-leg choices and their compatible continuations, not every possible flight combination. If you need alternatives around one part of a trip, submit a narrower follow-up search. A search price does not guarantee a combined booking; check the booking offers for current prices and leg coverage.
Response fields
observed_at is the UTC time Ignav finished retrieving the search result, or null when unknown. It is not the airline’s quote time or a guarantee that the fare is still available. See the freshness FAQ.
| Parameter | Type | Required | Description |
|---|---|---|---|
| legs | array | Yes | Normalized route and date for each requested leg. |
| itineraries | array | Yes | Ranked complete itineraries. Each itinerary has price, legs, cabin_class, optional bags, requires_self_transfer, and ignav_id. |
Each itinerary leg uses the same leg and segment fields as one-way results. Pass its ignav_id to the booking-links endpoint. Flexible-search booking options use zero-based leg_indexes to show which requested legs a link books; one option may cover every leg, or separate options may cover individual legs.
For open-jaw and multi-city itineraries, airline-direct coverage may be returned as one separately purchased one-way option per leg. Ignav uses that path only when every requested leg is covered.
The ID is an opaque, account-scoped handoff token. Use the same account for the booking lookup, and do not assume a later search for the same flights will return the same ID.
{
"itinerary": {
"price": {
"amount": 742,
"currency": "USD",
"status": "verified"
},
"legs": [
{
"carrier": "American Airlines",
"duration_minutes": 150,
"segments": [
{
"marketing_carrier_code": "AA",
"flight_number": "1412",
"operating_carrier_name": "American Airlines",
"departure_airport": "SFO",
"departure_time_local": "2026-11-18T09:00:00",
"departure_timezone": "America/Los_Angeles",
"departure_time_utc": "2026-11-18T16:00:00Z",
"arrival_airport": "DEN",
"arrival_time_local": "2026-11-18T12:30:00",
"arrival_timezone": "America/Denver",
"arrival_time_utc": "2026-11-18T18:30:00Z",
"duration_minutes": 150,
"aircraft": "Boeing 737"
}
]
},
{
"carrier": "American Airlines",
"duration_minutes": 150,
"segments": [
{
"marketing_carrier_code": "AA",
"flight_number": "2285",
"operating_carrier_name": "American Airlines",
"departure_airport": "COS",
"departure_time_local": "2026-11-22T09:00:00",
"departure_timezone": "America/Denver",
"departure_time_utc": "2026-11-22T15:00:00Z",
"arrival_airport": "ORD",
"arrival_time_local": "2026-11-22T12:30:00",
"arrival_timezone": "America/Chicago",
"arrival_time_utc": "2026-11-22T17:30:00Z",
"duration_minutes": 150,
"aircraft": "Boeing 737"
}
]
}
],
"cabin_class": "economy",
"requires_self_transfer": false
},
"booking_options": [
{
"leg_indexes": [
0,
1
],
"links": [
{
"provider_name": "American Airlines",
"provider_type": "airline",
"price": {
"amount": 742,
"currency": "USD",
"status": "verified"
},
"url": "aa.com/booking/..."
}
]
}
]
}Related docs
Ready to get started?
Create a free account to get your API key, or try the playground — no signup required.