{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Flights Scraper: Flight Prices, Itineraries",
    "description": "Flight prices from Google Flights for any route and date: each flight option's price, airlines, flight numbers, times, stops, layovers, aircraft and CO2 estimate, in Google's order. Search many routes and dates in one run, in any currency and country.",
    "version": "0.1",
    "x-build-id": "qiU3BwurjjOhIwNmr"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/kaleidoscopelabs~google-flights-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-kaleidoscopelabs-google-flights-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/kaleidoscopelabs~google-flights-scraper/runs": {
      "post": {
        "operationId": "runs-sync-kaleidoscopelabs-google-flights-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/kaleidoscopelabs~google-flights-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-kaleidoscopelabs-google-flights-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "routes": {
            "title": "Routes",
            "maxItems": 200,
            "type": "array",
            "description": "One route a line, as two airport codes: JFK-LHR flies from New York JFK to London Heathrow. An end takes up to 5 airports in one search: JFK/EWR-LHR/LGW. Use airport codes (JFK, LGA, EWR), not city codes (NYC). A line that is not a route is skipped and said in the log; a route given twice is read once.",
            "default": [
              "JFK-LHR"
            ],
            "items": {
              "type": "string"
            }
          },
          "departureDates": {
            "title": "Departure dates",
            "maxItems": 60,
            "type": "array",
            "description": "One a line: a date (2026-12-17), a range of days (2026-12-10..2026-12-20), or a number of days from today (+30), which keeps a saved or scheduled input current. Every route is searched on every date; a run reads at most 60 days.",
            "default": [
              "+30"
            ],
            "items": {
              "type": "string"
            }
          },
          "googleFlightsUrls": {
            "title": "Google Flights links",
            "maxItems": 200,
            "type": "array",
            "description": "Addresses of Google Flights results pages (https://www.google.com/travel/flights/search?tfs=…), one a line: each is its own search, with the link's route, dates, passengers and cabin, beside the routes above. One-way and round trips are read, between airports (up to 5 at an end) or cities as the link names them; a multi-city trip is skipped and said in the log. The run's currency, country, language and filters apply. With links given and Routes and Departure dates left at their defaults, only the links are searched.",
            "items": {
              "type": "string"
            }
          },
          "tripLengthDays": {
            "title": "Trip length (round trips)",
            "maxItems": 5,
            "type": "array",
            "description": "Leave empty for one-way flights. For round trips, the trip's length in days, as a list: [7] returns 7 days after each departure date; [7, 14] searches both. Every route is searched on every departure date with every length; at most 5 lengths of 1 to 60 days."
          },
          "returnDate": {
            "title": "Return date (round trips)",
            "type": "string",
            "description": "Leave empty for one-way flights or when you give trip lengths. A date like 2026-12-24, or +40 for 40 days from today: every route on every departure date before it is searched as a round trip back on this day. With trip lengths too, both are searched."
          },
          "returnOptionsFor": {
            "title": "Return flights for the first outbound options",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Round trips only. At 0, each record is an outbound flight option with the round trip's price, as Google Flights' first screen shows it. At 1 to 5, the return flights of that many of a search's first outbound options are read too: each of those outbound options gives one record for every return, up to Flight options per search of them, with the pair's price. Each pair is a flight option of its own: with 10 options per search and the returns of 2, a search stores up to 28.",
            "default": 0
          },
          "maxResults": {
            "title": "Flight options per search",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "How many flight options to store for each route, date and trip length, in Google Flights' order: its best flights first, then the others. You get as many as the search lists, up to this number. With return flights read, each of those outbound options gives up to this number of pairs in its place.",
            "default": 30
          },
          "monitorName": {
            "title": "Monitor ($)",
            "type": "string",
            "description": "Name a monitor, such as jfk-lhr-daily, to store only what changed: each search gives the flight options that are new since the monitor's last run and those whose price changed, with the price before. Its first run stores every option as the baseline. Each search read is one check. A date given as days from today is a new search each day. Up to 40 letters, digits, hyphens."
          },
          "adults": {
            "title": "Adults",
            "minimum": 0,
            "maximum": 9,
            "type": "integer",
            "description": "Adult passengers. Prices are for the whole party.",
            "default": 1
          },
          "children": {
            "title": "Children",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Passengers aged 2 to 11.",
            "default": 0
          },
          "infantsInSeat": {
            "title": "Infants in a seat",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Passengers under 2 with their own seat.",
            "default": 0
          },
          "infantsOnLap": {
            "title": "Infants on a lap",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Passengers under 2 on an adult's lap: one for each adult at most.",
            "default": 0
          },
          "cabinClass": {
            "title": "Cabin",
            "enum": [
              "economy",
              "premium_economy",
              "business",
              "first"
            ],
            "type": "string",
            "description": "The seat class to price.",
            "default": "economy"
          },
          "maxStops": {
            "title": "Stops",
            "enum": [
              "any",
              "0",
              "1",
              "2"
            ],
            "type": "string",
            "description": "Only flight options with at most this many stops.",
            "default": "any"
          },
          "airlines": {
            "title": "Airlines",
            "maxItems": 20,
            "type": "array",
            "description": "Only flight options whose flights are sold by these airlines or carry their code: two-character airline codes such as BA or VS, or an alliance (oneworld, Star Alliance, SkyTeam). Leave empty for every airline.",
            "items": {
              "type": "string"
            }
          },
          "maxPrice": {
            "title": "Price up to",
            "minimum": 1,
            "type": "integer",
            "description": "Only flight options at or below this price, in the currency of the run; an option Google Flights lists without a price is left out. Leave empty for any price."
          },
          "departureTimeFrom": {
            "title": "Departure from",
            "type": "string",
            "description": "Only flight options that leave at or after this hour, local time, such as 06:00. Whole hours. On a round trip it is the outbound's departure."
          },
          "departureTimeTo": {
            "title": "Departure to",
            "type": "string",
            "description": "Only flight options that leave before this hour, local time: 12:00 keeps departures up to 11:59. Whole hours, up to 24:00."
          },
          "arrivalTimeFrom": {
            "title": "Arrival from",
            "type": "string",
            "description": "Only flight options that land at or after this hour, local time, such as 08:00. Whole hours. On a round trip it is the outbound's arrival."
          },
          "arrivalTimeTo": {
            "title": "Arrival to",
            "type": "string",
            "description": "Only flight options that land before this hour, local time: 22:00 keeps arrivals up to 21:59. Whole hours, up to 24:00."
          },
          "maxDurationMinutes": {
            "title": "Duration up to",
            "minimum": 1,
            "type": "integer",
            "description": "Only flight options that take at most this many minutes from first departure to last arrival, each way. Leave empty for any duration."
          },
          "currency": {
            "title": "Currency",
            "pattern": "^[A-Za-z]{3}$",
            "type": "string",
            "description": "The currency of the prices, by its three-letter code such as USD, EUR or GBP.",
            "default": "USD"
          },
          "country": {
            "title": "Country",
            "pattern": "^[A-Za-z]{2}$",
            "type": "string",
            "description": "The country you buy from, by its two-letter code such as US, GB or DE: Google Flights' prices and sellers differ by country.",
            "default": "US"
          },
          "language": {
            "title": "Language",
            "pattern": "^[A-Za-z]{2,3}(-[A-Za-z0-9]{2,8})?$",
            "type": "string",
            "description": "The language of airline, airport and city names, by its code such as en, de or pt-BR.",
            "default": "en"
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}