GeoRanker Docs

Google Flights API

Create a Google Flights report with route, travel dates, passengers, and cabin options.

Try API

Use the Google Flights API to find flight itineraries for an origin, destination, departure date, and passenger count. The API returns normalized listings in data.flights.

Set HV_API_KEY to your HV API key. This cURL 7.87 or later example searches one economy passenger from San Francisco to New York. Replace the departure date with a future date when running it.

curl --fail-with-body --silent --show-error \
  --request POST 'https://api.highvolume.georanker.com/serp/new' \
  --url-query "apikey=$HV_API_KEY" \
  --header 'Content-Type: application/json' \
  --data '{"searchEngine":"google-flights","region":"US","asynchronous":true,"travel":{"origin":"SFO","destination":"JFK","departureDate":"2027-01-15","passengers":1,"cabin":"economy","currency":"USD","hl":"en"}}'

HTTP 200 returns a report ID. Save it and retrieve the report with GET /serp/{id}. Check ready and faulty before reading the flight listings.

Flight request fields

FieldHow to use it
searchEngineSet to google-flights.
regionRequired. Sets the search location, such as US.
travel.origin, travel.destinationRequired three-letter airport or city codes.
travel.departureDateRequired date in YYYY-MM-DD format.
travel.returnDateAdd a date on or after departure for a round trip. Omit it for a one-way search.
travel.passengersPassenger count, at least 1.
travel.cabineconomy, premium-economy, business, or first. The default is economy.
travel.currencyThree-letter currency code, such as USD.
travel.hlTwo-letter search language, such as en.
asynchronousSet to true to submit and retrieve later.
maxResultsLimits normalized flight listings. Available limits depend on the engine and plan.
saveRawDataSet to true to retain the provider output in data.raw.

The API generates a descriptive keyword when keyword is omitted. Send the route and dates inside travel. All flight request fields and errors

Read the flight results

When ready is true and faulty is false, read data.flights. Listings can include company, price, departureTime, arrivalTime, duration, stops, priceType, and airports. Fields can be absent when the source does not provide them.

Keep the returned price text and priceType together when displaying a quote. The price field alone does not establish whether a quote covers each passenger or the full party. A successful flight report can have an empty data.organic array.

With saveRawData: true, provider entries with type: "JSON" contain JSON encoded as a string in content. Parse that string separately. The provider payload can contain more listings than the normalized array limited by maxResults. Flight response fields

Select Try API on this page and connect your key. Check pricing and credits before submitting. If submission times out before you receive an ID, check whether the report was created before sending it again.

Requests and responses