{
  "openapi": "3.0.1",
  "info": {
    "title": "Kiwi Flight Search Scraper",
    "description": "Search Kiwi.com by route, date and cabin and get every itinerary as a row: fare, airlines, flight numbers, times, stops, layovers, included bags and a direct booking link. Flags the cheap trips built from separate tickets and scores each connection. 37 currencies, one-way or return.",
    "version": "0.0",
    "x-build-id": "zaXtJfnGYalup3mzR"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/apt_marble~kiwi-flight-search-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-apt_marble-kiwi-flight-search-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/apt_marble~kiwi-flight-search-scraper/runs": {
      "post": {
        "operationId": "runs-sync-apt_marble-kiwi-flight-search-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/apt_marble~kiwi-flight-search-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-apt_marble-kiwi-flight-search-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",
        "required": [
          "origins",
          "destinations",
          "departureDates"
        ],
        "properties": {
          "origins": {
            "title": "Departure places",
            "type": "array",
            "description": "Where the trip starts. Use airport codes (JFK, LHR), city-wide codes (NYC, LON) or plain names (\"London Heathrow\", \"Milan\"). A name that names a whole city searches every airport of it; a name two airports answer equally well (\"Houston\", \"Frankfurt\") is refused with both codes named rather than one being chosen for you. Add several to compare departure points in one run.",
            "items": {
              "type": "string"
            }
          },
          "destinations": {
            "title": "Arrival places",
            "type": "array",
            "description": "Where the trip ends. Use airport codes (LAX, CDG), city-wide codes (PAR, MIL) or plain names (\"Los Angeles\", \"Rome\"). Same rule as the departure places: a city name searches the whole city, and a name two airports answer equally well is refused with both codes named.",
            "items": {
              "type": "string"
            }
          },
          "tripType": {
            "title": "Trip type",
            "enum": [
              "oneway",
              "return"
            ],
            "type": "string",
            "description": "One-way, or a return trip. A return trip needs either return dates or a trip length in nights.",
            "default": "oneway"
          },
          "departureDates": {
            "title": "Departure dates",
            "type": "array",
            "description": "Outbound dates in YYYY-MM-DD form. Every date is searched separately, so three dates on one route means three searches. Dates in the past are skipped.",
            "items": {
              "type": "string"
            }
          },
          "returnDates": {
            "title": "Return dates",
            "type": "array",
            "description": "Return dates in YYYY-MM-DD form, for return trips only. Each one is paired with each departure date; pairs that come back before they leave are skipped.",
            "items": {
              "type": "string"
            }
          },
          "nightsMin": {
            "title": "Shortest trip (nights)",
            "minimum": 0,
            "maximum": 60,
            "type": "integer",
            "description": "An alternative to fixed return dates: let the search pick the return date, as long as the trip lasts at least this many nights."
          },
          "nightsMax": {
            "title": "Longest trip (nights)",
            "minimum": 0,
            "maximum": 60,
            "type": "integer",
            "description": "The upper end of the trip length when you let the search pick the return date."
          },
          "dateFlexibilityDays": {
            "title": "Date flexibility (days)",
            "minimum": 0,
            "maximum": 7,
            "type": "integer",
            "description": "Widen each date into a window of this many extra days, to catch a cheaper departure a day or two either way. 0 means the exact dates only.",
            "default": 0
          },
          "adults": {
            "title": "Adults",
            "minimum": 1,
            "maximum": 9,
            "type": "integer",
            "description": "Adult travellers. Fares are for the whole party, exactly as the source prices them.",
            "default": 1
          },
          "children": {
            "title": "Children",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Children aged 2-11 travelling in their own seat.",
            "default": 0
          },
          "infants": {
            "title": "Infants",
            "minimum": 0,
            "maximum": 8,
            "type": "integer",
            "description": "Infants under 2 travelling on an adult's lap. Cannot exceed the number of adults.",
            "default": 0
          },
          "cabinClass": {
            "title": "Cabin",
            "enum": [
              "ECONOMY",
              "PREMIUM_ECONOMY",
              "BUSINESS",
              "FIRST_CLASS"
            ],
            "type": "string",
            "description": "The cabin to price. Higher cabins return far fewer options on most routes.",
            "default": "ECONOMY"
          },
          "currency": {
            "title": "Currency",
            "enum": [
              "USD",
              "EUR",
              "GBP",
              "CAD",
              "AUD",
              "CHF",
              "SEK",
              "NOK",
              "DKK",
              "PLN",
              "CZK",
              "HUF",
              "RON",
              "JPY",
              "KRW",
              "SGD",
              "HKD",
              "INR",
              "AED",
              "BRL",
              "MXN",
              "ZAR",
              "TRY",
              "NZD",
              "ILS",
              "THB",
              "PHP",
              "MYR",
              "IDR",
              "SAR",
              "CLP",
              "COP",
              "UAH",
              "ISK",
              "RSD",
              "PEN",
              "TWD"
            ],
            "type": "string",
            "description": "The currency to price fares in. Every row also carries the currency it was actually served in, so you always know what a number means.",
            "default": "USD"
          },
          "market": {
            "title": "Market",
            "enum": [
              "US",
              "GB",
              "DE",
              "FR",
              "ES",
              "IT",
              "NL",
              "CA",
              "AU",
              "IN",
              "AE",
              "SG",
              "JP",
              "BR",
              "MX",
              "PL",
              "SE",
              "CH",
              "IE",
              "ZA"
            ],
            "type": "string",
            "description": "The market the search is prepared for. Fares and availability can differ between markets, and every row records which one it came from.",
            "default": "US"
          },
          "locale": {
            "title": "Language",
            "enum": [
              "en",
              "de",
              "fr",
              "es",
              "it",
              "pt",
              "nl",
              "pl",
              "cs",
              "ja"
            ],
            "type": "string",
            "description": "Language for airline and airport names where the source translates them.",
            "default": "en"
          },
          "maxResultsPerSearch": {
            "title": "Maximum results per search",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "How many itineraries to keep for each route and date. Raise it for a full picture of a route, lower it when you only need the cheapest few.",
            "default": 50
          },
          "sortBy": {
            "title": "Sort results by",
            "enum": [
              "price",
              "duration",
              "quality",
              "departure",
              "arrival"
            ],
            "type": "string",
            "description": "Which itineraries come back first when a search returns more than you asked for.",
            "default": "price"
          },
          "maxStops": {
            "title": "Maximum stops",
            "minimum": 0,
            "maximum": 3,
            "type": "integer",
            "description": "Leave empty for any number of stops. Set 0 for non-stop only, 1 for at most one connection."
          },
          "maxDurationHours": {
            "title": "Maximum trip length (hours)",
            "minimum": 1,
            "maximum": 72,
            "type": "integer",
            "description": "Drop itineraries longer than this door-to-door. Leave empty for no limit."
          },
          "maxPrice": {
            "title": "Maximum fare",
            "minimum": 1,
            "maximum": 10000000,
            "type": "integer",
            "description": "Only return fares at or below this amount, in the currency you selected. Leave empty for no limit."
          },
          "includeAirlines": {
            "title": "Only these airlines",
            "type": "array",
            "description": "Two-character airline codes to restrict the search to, for example BA or LH. Leave empty for all airlines.",
            "items": {
              "type": "string"
            }
          },
          "excludeAirlines": {
            "title": "Exclude these airlines",
            "type": "array",
            "description": "Two-character airline codes to leave out of the results.",
            "items": {
              "type": "string"
            }
          },
          "excludeSelfTransferFares": {
            "title": "Single-ticket fares only",
            "type": "boolean",
            "description": "Leave off to see everything the source sells, including cheaper trips stitched together from separate tickets. Turn on to keep only trips booked as one ticket, where the airline is responsible for missed connections.",
            "default": false
          },
          "includeGroundTransport": {
            "title": "Allow train and bus legs",
            "type": "boolean",
            "description": "Some cheap trips include a train or coach leg between airports. Off by default, so results are flights only.",
            "default": false
          },
          "includeConnectionRisk": {
            "title": "Score connection risk",
            "type": "boolean",
            "description": "Add the self-transfer profile to every result: separate-ticket flags, hidden-city and throwaway flags, the shortest layover, airport changes, bag re-checks, protected connections and an overall risk level. Charged per scored result.",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}