Get flight-filter metadata for a route and travel dates
View all Tripadvisor Hotel, Rental & Travel Data endpoints →Retrieve flight-search filter metadata using required string query parameters classOfService, date, destinationAirportCode, itineraryType, and sourceAirportCode. Departure date uses YYYY-MM-DD. Documented itineraryType values are ONE_WAY and ROUND_TRIP. returnDate is an optional string in YYYY-MM-DD format; the evidence does not establish conditional validation rules for return journeys. Airport codes can be obtained from the airport-search operation; BOM and DEL are documented input examples. No accepted classOfService value list is supplied. The truncated HTTP 200 source example shows data.filters as an array of groups with param, title, and nested filters fields. Categorical entries contain label and value strings; time-range entries contain numeric index, rangeMin, and rangeMax plus title and subTitle strings. Visible groups concern stops, change/cancellation policies, flight times, airlines, alliance, duration, layover airports, and price; some nested filters arrays are empty. These fields come from an incomplete source example, not a saved probe call. The complete envelope, range units, required response fields, and current filter availability remain unverified. Returned param names and values are metadata, not additional declared inputs to this operation or proof of compatibility with another endpoint. This response is not a list of flight itineraries, a fare quote, or a booking result.
API Features
Live API Demo
🔒 Sign in to try it live
Log in to call this API with your own API key. New accounts get 100 free credits — no card required.
Log in / Sign upNo active API key found. Create one in your Dashboard, then reload this page. Dashboard →
/api/project/tripadvisor-data/get-filters API Response (JSON)
{} curl -X GET 'https://api.opendata-api.com/api/project/tripadvisor-data/get-filters?key=<API_KEY>&classOfService=<classOfService>&date=<date>&destinationAirportCode=<destinationAirportCode>&itineraryType=ONE_WAY&sourceAirportCode=<sourceAirportCode>'
Query Result
Use Cases
- Prototype a flight-search sidebar from returned group titles and label/value options while handling categorical and time-range item shapes separately.
- Compare saved filter metadata after a route or cabin edit to decide which previously selected UI options need review.
- Test a flight form that collects departure date, airport codes, cabin class, and itinerary type, displaying a return-date control for return-journey entry.
- Audit flight-filter snapshots for empty groups, duplicate param entries, or changed option values before updating client-side filter handling.
- Prepare a documented mapping review between returned filter param names and a separate flight-search contract without assuming that search accepts every metadata key.
Frequently asked questions
Which query inputs are required to get flight filters?
classOfService, date, destinationAirportCode, itineraryType, and sourceAirportCode are required strings. returnDate is an optional string. The request has no declared path or body inputs.
How should itineraryType and the date fields be formatted?
Use ONE_WAY for a one-way journey or ROUND_TRIP for a return journey. date is the departure or travel date in YYYY-MM-DD format, and returnDate uses YYYY-MM-DD when provided. The schema marks returnDate optional; the supplied evidence does not establish additional conditional rules.
Where do the airport codes and cabin-class values come from?
The parameter documentation directs callers to the airport-search operation for airportCode values. BOM and DEL are examples for the source and destination respectively. classOfService means traveler cabin class, but no accepted value list or default is supplied, so a specific cabin token is not asserted here.
What response fields can I use to render filter controls?
The source snippet shows data.filters groups with param, title, and nested filters. Categorical entries have label and value strings. Flight-time entries instead show numeric index, rangeMin, and rangeMax plus title and subTitle strings. The snippet includes empty nested arrays and does not document range units or a complete response schema.
Can I pass returned filter param names back to this endpoint?
They are response metadata, not additional declared inputs here. Preserve exact returned spelling, including the example key covidPolices, and verify any separate search endpoint contract before forwarding filter names or values. Matching names alone do not establish compatibility.
Does the filter response prove current flight availability or fares?
No. It describes filter metadata, not bookable itineraries or confirmed prices. There is no saved probe call for this operation, and the supplied source example is truncated; current options, complete envelope fields, and inventory must not be inferred from it.