{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Flights Scraper",
    "version": "0.1",
    "x-build-id": "GJ5neuWKJVQPsyQEg"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapebase~google-flights-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapebase-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/scrapebase~google-flights-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapebase-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/scrapebase~google-flights-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapebase-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": {
          "departureIATA": {
            "title": "🛫 Departure Airport(s)",
            "type": "string",
            "description": "3-letter IATA code(s) (e.g., LAX, JFK). Multiple codes supported.",
            "default": "LAX"
          },
          "arrivalIATA": {
            "title": "🛬 Destination Airport(s)",
            "type": "string",
            "description": "List of IATA codes separated by commas (supports bulk input). Use 'london' for LHR, LGW, STN, LTN, LCY.",
            "default": "JFK"
          },
          "departureDate": {
            "title": "📅 Departure Date",
            "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
            "type": "string",
            "description": "Pick your travel date.",
            "default": "2026-07-28"
          },
          "departureDateRng": {
            "title": "🗓️ Departure Flex Days",
            "type": "string",
            "description": "Optional range for departure (e.g., +1, -1).",
            "default": ""
          },
          "arrivalDate": {
            "title": "🔙 Return Date",
            "pattern": "^(\\d{4}-\\d{2}-\\d{2})?$",
            "type": "string",
            "description": "Pick your return date (leave empty for one-way).",
            "default": ""
          },
          "arrivalDateRng": {
            "title": "🗓️ Return Flex Days",
            "type": "string",
            "description": "Optional range for return (e.g., +1, -1).",
            "default": ""
          },
          "multi_city_json": {
            "title": "🗺️ Multi-City JSON",
            "type": "string",
            "description": "JSON string for multi-city trips. Format: [{\"departure_id\":\"...\",\"arrival_id\":\"...\",\"date\":\"...\"}]. When provided, departure_id, arrival_id, and outbound_date are not required.",
            "default": ""
          },
          "adults": {
            "title": "🧔 Adults",
            "minimum": 1,
            "maximum": 9,
            "type": "integer",
            "description": "Number of adult passengers (12+ years).",
            "default": 1
          },
          "children": {
            "title": "👦 Children",
            "minimum": 0,
            "maximum": 9,
            "type": "integer",
            "description": "Number of children (2-12 years).",
            "default": 0
          },
          "infants": {
            "title": "👶 Infants",
            "minimum": 0,
            "maximum": 9,
            "type": "integer",
            "description": "Number of infants (under 2 years, on lap).",
            "default": 0
          },
          "seatclass": {
            "title": "💺 Cabin Class",
            "enum": [
              "1",
              "2",
              "3",
              "4"
            ],
            "type": "string",
            "description": "Choose your comfort level.",
            "default": "1"
          },
          "stops": {
            "title": "🛑 Max Stops",
            "enum": [
              "0",
              "1",
              "2"
            ],
            "type": "string",
            "description": "Filter by number of layovers.",
            "default": "0"
          },
          "alliances": {
            "title": "🤝 Alliances",
            "type": "string",
            "description": "Filter by (STAR, SKYTEAM, ONEWORLD).",
            "default": "ALL"
          },
          "airlines": {
            "title": "✈️ Specific Airlines",
            "type": "string",
            "description": "Comma-separated airline codes (e.g., AA, DL).",
            "default": "ALL"
          },
          "maxPrice": {
            "title": "💰 Budget Limit",
            "minimum": 0,
            "type": "integer",
            "description": "Set a maximum price (0 for no limit).",
            "default": 0
          },
          "currency": {
            "title": "💵 Currency",
            "minLength": 3,
            "maxLength": 3,
            "type": "string",
            "description": "Preferred currency (USD, EUR, BDT, etc.).",
            "default": "USD"
          },
          "hl": {
            "title": "🌐 Language Code",
            "enum": [
              "en",
              "es",
              "fr",
              "de",
              "it",
              "pt",
              "ru",
              "ja",
              "ko",
              "zh",
              "ar",
              "hi",
              "tr",
              "pl",
              "nl",
              "sv",
              "da",
              "no",
              "fi",
              "cs",
              "hu",
              "ro",
              "el",
              "th",
              "vi",
              "id",
              "ms",
              "he",
              "uk"
            ],
            "type": "string",
            "description": "Language code for results (e.g., 'en', 'fr', 'de', 'es'). Default: 'en'",
            "default": "en"
          },
          "gl": {
            "title": "🌍 Country Code",
            "enum": [
              "us",
              "uk",
              "ca",
              "au",
              "de",
              "fr",
              "es",
              "it",
              "nl",
              "pl",
              "br",
              "ru",
              "jp",
              "kr",
              "cn",
              "tw",
              "in",
              "sa",
              "tr",
              "se",
              "dk",
              "no",
              "fi",
              "cz",
              "hu",
              "ro",
              "mx",
              "ar",
              "ch",
              "at",
              "be",
              "ie",
              "nz",
              "sg",
              "my",
              "th",
              "ph",
              "id",
              "vn"
            ],
            "type": "string",
            "description": "Country code for results (e.g., 'us', 'uk', 'fr', 'de'). Default: 'us'",
            "default": "us"
          },
          "max_pages": {
            "title": "📜 Scroll Depth",
            "minimum": 1,
            "type": "integer",
            "description": "How many 'More flights' buttons to click.",
            "default": 1
          },
          "maximum": {
            "title": "🔢 Max Results",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Total number of flights to collect.",
            "default": 20
          },
          "proxyConfiguration": {
            "title": "🛡️ Proxy Settings",
            "type": "object",
            "description": "Keep your requests safe and undetected."
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}