{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Flights Scraper",
    "description": "Scrape Google Flights for any route and date and get every itinerary with price, airlines, flight numbers, aircraft, legroom, layovers, CO2 and contrail warming, plus route price history and what changed since your last run. There is no proxy to set up and no proxy charge. $0.20 per 1,000 flights.",
    "version": "1.0",
    "x-build-id": "AJlFVFJ1oDQxZeBRn"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/boncross~google-flights-search/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-boncross-google-flights-search",
        "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/boncross~google-flights-search/runs": {
      "post": {
        "operationId": "runs-sync-boncross-google-flights-search",
        "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/boncross~google-flights-search/run-sync": {
      "post": {
        "operationId": "run-sync-boncross-google-flights-search",
        "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": {
          "origin": {
            "title": "Origin airport or city",
            "type": "string",
            "description": "Departure airport code such as LHR. A city code such as LON or NYC searches every airport in that city. Several can be given, separated by commas, to search them together: \"LHR,LGW,LCY\". Note LAX, BKK and SHA are both an airport and a city code, so list the airports explicitly if you mean the whole area. You can also type a place name such as \"Barcelona\" or \"Heathrow\" and it is resolved for you."
          },
          "destination": {
            "title": "Destination airport or city",
            "type": "string",
            "description": "Arrival airport code such as JFK. A city code such as NYC searches every airport in that city. Several can be given, separated by commas: \"JFK,EWR,LGA\". You can also type a place name such as \"Barcelona\" or \"Heathrow\" and it is resolved for you."
          },
          "departureDate": {
            "title": "Departure date",
            "type": "string",
            "description": "Outbound date as YYYY-MM-DD."
          },
          "returnDate": {
            "title": "Return date",
            "type": "string",
            "description": "Return date as YYYY-MM-DD. Leave empty for a one way search.",
            "default": ""
          },
          "extraRoutes": {
            "title": "More routes",
            "type": "array",
            "description": "One route per line as origin, destination, departure date and an optional return date. Commas separate the fields, so a multi-airport origin uses + instead: \"LHR+LGW,JFK+EWR,2026-11-05,2026-11-12\".",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "searchUrls": {
            "title": "Google Flights URLs",
            "type": "array",
            "description": "Paste search URLs straight from Google Flights. The route, dates, cabin and filters already in the URL are used as they are.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Start URLs (bulk upload)",
            "type": "array",
            "description": "Google Flights page addresses, with the option to load them in bulk from a file, a Google Sheet or a remote list. Use this when you have more links than you want to paste. Combined with anything in the list above.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "maxResultsPerSearch": {
            "title": "Max itineraries per search",
            "minimum": 0,
            "maximum": 1000,
            "type": "integer",
            "description": "Stop after this many itineraries for each route. 0 returns every itinerary Google lists.",
            "default": 0
          },
          "maxItems": {
            "title": "Maximum results for the whole run",
            "minimum": 0,
            "type": "integer",
            "description": "A run-wide ceiling across every route. Zero means no run-wide limit. Rows that report an input the actor could not resolve are not counted here and are never charged for.",
            "default": 0
          },
          "cabinClass": {
            "title": "Cabin",
            "enum": [
              "economy",
              "premium_economy",
              "business",
              "first"
            ],
            "type": "string",
            "description": "Travel class the fares are quoted in.",
            "default": "economy"
          },
          "adults": {
            "title": "Adults",
            "minimum": 1,
            "maximum": 9,
            "type": "integer",
            "description": "Number of adult passengers.",
            "default": 1
          },
          "children": {
            "title": "Children (2 to 11)",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Number of children aged 2 to 11.",
            "default": 0
          },
          "infantsInSeat": {
            "title": "Infants in seat",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Number of infants travelling in their own seat.",
            "default": 0
          },
          "infantsOnLap": {
            "title": "Infants on lap",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Number of infants travelling on an adult lap.",
            "default": 0
          },
          "carryOnBags": {
            "title": "Carry-on bags",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Keep only fares that include this many carry-on bags.",
            "default": 0
          },
          "checkedBags": {
            "title": "Checked bags",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Keep only fares that include this many checked bags.",
            "default": 0
          },
          "maxStops": {
            "title": "Maximum stops",
            "minimum": 0,
            "maximum": 3,
            "type": "integer",
            "description": "Leave empty for any number of stops. 0 keeps nonstop flights only, 1 keeps one stop or fewer, 2 keeps two or fewer."
          },
          "airlines": {
            "title": "Airlines or alliances",
            "type": "array",
            "description": "Keep only these carriers. Two letter airline codes such as BA or AA, or an alliance: ONEWORLD, SKYTEAM, STAR_ALLIANCE.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxPrice": {
            "title": "Maximum price",
            "minimum": 1,
            "type": "integer",
            "description": "Keep only itineraries at or below this fare, in the currency you asked for."
          },
          "departureTimeFrom": {
            "title": "Earliest departure hour",
            "minimum": 0,
            "maximum": 23,
            "type": "integer",
            "description": "Keep only flights leaving at or after this hour, 0 to 23."
          },
          "departureTimeTo": {
            "title": "Latest departure hour",
            "minimum": 0,
            "maximum": 23,
            "type": "integer",
            "description": "Keep only flights leaving at or before this hour, 0 to 23."
          },
          "arrivalTimeFrom": {
            "title": "Earliest arrival hour",
            "minimum": 0,
            "maximum": 23,
            "type": "integer",
            "description": "Keep only flights landing at or after this hour, 0 to 23."
          },
          "arrivalTimeTo": {
            "title": "Latest arrival hour",
            "minimum": 0,
            "maximum": 23,
            "type": "integer",
            "description": "Keep only flights landing at or before this hour, 0 to 23."
          },
          "maxDurationMinutes": {
            "title": "Maximum journey time",
            "minimum": 60,
            "maximum": 4000,
            "type": "integer",
            "description": "Keep only itineraries no longer than this many minutes door to door."
          },
          "minLayoverMinutes": {
            "title": "Minimum layover",
            "minimum": 30,
            "maximum": 1440,
            "type": "integer",
            "description": "Drop itineraries with a connection shorter than this many minutes."
          },
          "maxLayoverMinutes": {
            "title": "Maximum layover",
            "minimum": 30,
            "maximum": 1440,
            "type": "integer",
            "description": "Drop itineraries with a connection longer than this many minutes."
          },
          "onlyConnectingAirports": {
            "title": "Connect only through",
            "type": "array",
            "description": "Keep only itineraries that connect through these airports. Three letter codes such as BOS or AMS.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "excludeConnectingAirports": {
            "title": "Connecting airports to avoid",
            "type": "array",
            "description": "Drop itineraries that connect through these airports. Three letter codes such as ORD or CDG.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "lessCo2Only": {
            "title": "Lower emissions only",
            "type": "boolean",
            "description": "Keep only the itineraries Google marks with its green lower-emissions badge (well below typical CO2 for the route). Every row also carries emissionsKg, emissionsTypicalKg and emissionsVsTypicalPct if you want a threshold of your own.",
            "default": false
          },
          "includePriceHistory": {
            "title": "Include price insights",
            "type": "boolean",
            "description": "Add one record per search with the current, lowest and typical price plus a day by day price history for the route.",
            "default": true
          },
          "currency": {
            "title": "Currency",
            "type": "string",
            "description": "Three letter currency code the prices come back in. Default USD.",
            "default": "USD"
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "Language code for airport and airline names.",
            "default": "en"
          },
          "trackPriceChanges": {
            "title": "Compare with the last run",
            "type": "boolean",
            "description": "Remember each itinerary's price between runs and report what changed. Fills previousPrice, priceChange, priceChangePct and previousScrapedAt.",
            "default": false
          },
          "priceMemoryStore": {
            "title": "Price memory name",
            "type": "string",
            "description": "Named storage the remembered prices live in. Use different names to keep separate watchlists apart.",
            "default": "google-flights-prices"
          },
          "excludeAirlines": {
            "title": "Airlines or alliances to exclude",
            "type": "array",
            "description": "Airline codes to leave out, such as \"AA\". An alliance name (ONEWORLD, STAR_ALLIANCE, SKYTEAM) excludes its members. An itinerary is dropped if any of its flights match. Alliance membership is maintained here rather than published by the site, so a very recently joined member may not be recognised.",
            "items": {
              "type": "string"
            }
          },
          "sortBy": {
            "title": "Sort results by",
            "enum": [
              "top",
              "price",
              "duration",
              "departure_time",
              "arrival_time",
              "emissions",
              "stops"
            ],
            "type": "string",
            "description": "Order of the returned rows. \"top\" keeps the ranking the site itself uses.",
            "default": "top"
          },
          "bookingOffers": {
            "title": "Also return every seller and its price",
            "type": "boolean",
            "description": "Adds a row per seller for the first few itineraries, with price, website and booking link. One extra resolved search is charged per itinerary looked up.",
            "default": false
          },
          "maxOfferItineraries": {
            "title": "How many itineraries to price",
            "minimum": 1,
            "maximum": 25,
            "type": "integer",
            "description": "Sellers are fetched one itinerary at a time, so this caps the cost. Sorting by price first puts the cheapest itineraries at the front of the queue.",
            "default": 3
          },
          "excludeBasicEconomy": {
            "title": "Hide basic economy fares",
            "type": "boolean",
            "description": "Leave out the strippedown fares that do not include a seat choice or a carry-on. Only markets that sell them are affected: a US domestic search drops around an eighth of its results, a transatlantic one usually none.",
            "default": false
          },
          "maxConcurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 32,
            "type": "integer",
            "description": "How many requests run at once across the whole run. The default is the fastest level measured clean; lower it only if a run reports refusals or errors.",
            "default": 8
          },
          "restartAttempt": {
            "title": "Restart attempt (internal)",
            "type": "integer",
            "description": "Set by the actor when it restarts itself in a fresh container after being refused. Leave it alone.",
            "default": 0
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}