{
  "openapi": "3.0.1",
  "info": {
    "title": "US Airline On-Time and Delay Analytics",
    "description": "Get on-time performance for US airlines, routes and airports from the official federal monthly reports. Each row has on-time percent, delay percentiles, delay causes, cancellations and taxi times, or choose single flights. Export to CSV or Excel.",
    "version": "1.0",
    "x-build-id": "TPgQUi99W6YAbybcM"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/parselab~us-airline-on-time-delay-analytics-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-parselab-us-airline-on-time-delay-analytics-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/parselab~us-airline-on-time-delay-analytics-scraper/runs": {
      "post": {
        "operationId": "runs-sync-parselab-us-airline-on-time-delay-analytics-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/parselab~us-airline-on-time-delay-analytics-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-parselab-us-airline-on-time-delay-analytics-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": {
          "maxItems": {
            "title": "Max Items",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000."
          },
          "mode": {
            "title": "What to collect",
            "enum": [
              "summary",
              "flights"
            ],
            "type": "string",
            "description": "Summary returns one row of on-time statistics per route, airline, airport, day or other group. Flights returns one row per individual flight with scheduled and actual times, delay minutes and causes.",
            "default": "summary"
          },
          "groupBy": {
            "title": "Group statistics by",
            "enum": [
              "route",
              "airline",
              "airlineRoute",
              "originAirport",
              "destAirport",
              "month",
              "date",
              "dayOfWeek",
              "departureHour",
              "tailNumber"
            ],
            "type": "string",
            "description": "Only for the summary mode. Route means origin to destination airport pairs.",
            "default": "route"
          },
          "monthFrom": {
            "title": "From month",
            "type": "string",
            "description": "First month as YYYY-MM, for example 2025-06. Leave empty to use only the newest month that is published. Data starts in 1987."
          },
          "monthTo": {
            "title": "To month",
            "type": "string",
            "description": "Last month as YYYY-MM. Leave empty for the newest published month. One run reads up to 12 months in the summary mode and 3 months in the flights mode."
          },
          "airlines": {
            "title": "Airlines",
            "type": "array",
            "description": "Two letter airline codes, for example DL, AA, UA, WN, B6.",
            "items": {
              "type": "string"
            }
          },
          "origins": {
            "title": "Departure airports",
            "type": "array",
            "description": "Airport codes, for example JFK, ATL, ORD.",
            "items": {
              "type": "string"
            }
          },
          "destinations": {
            "title": "Arrival airports",
            "type": "array",
            "description": "Airport codes, for example LAX, MIA, SFO.",
            "items": {
              "type": "string"
            }
          },
          "originStates": {
            "title": "Departure states",
            "type": "array",
            "description": "Two letter state codes, for example NY, TX, CA.",
            "items": {
              "type": "string"
            }
          },
          "destinationStates": {
            "title": "Arrival states",
            "type": "array",
            "description": "Two letter state codes of the arrival airport.",
            "items": {
              "type": "string"
            }
          },
          "splitByMonth": {
            "title": "One row per month",
            "type": "boolean",
            "description": "Split every group by month, so you get a monthly trend for each route or airline.",
            "default": false
          },
          "minFlights": {
            "title": "Minimum flights per group",
            "minimum": 1,
            "type": "integer",
            "description": "Drops small groups so that percentages are meaningful, for example 100.",
            "default": 1
          },
          "sortBy": {
            "title": "Sort groups by",
            "enum": [
              "scheduledFlights",
              "onTimePercent",
              "latePercent",
              "cancellationPercent",
              "disruptionPercent",
              "avgArrivalDelayMin",
              "p90ArrivalDelayMin",
              "severeDelayPercent",
              "avgTaxiOutMin"
            ],
            "type": "string",
            "description": "Field used to order the summary rows.",
            "default": "scheduledFlights"
          },
          "sortOrder": {
            "title": "Sort order",
            "enum": [
              "desc",
              "asc"
            ],
            "type": "string",
            "description": "Descending puts the highest value first.",
            "default": "desc"
          },
          "minArrivalDelayMinutes": {
            "title": "Flights mode: minimum arrival delay (minutes)",
            "type": "integer",
            "description": "Only return flights that arrived at least this many minutes late, for example 180."
          },
          "cancelledOnly": {
            "title": "Flights mode: cancelled flights only",
            "type": "boolean",
            "description": "Return only flights that were cancelled, with the official cancellation cause.",
            "default": false
          },
          "divertedOnly": {
            "title": "Flights mode: diverted flights only",
            "type": "boolean",
            "description": "Return only flights that landed at a different airport than planned.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}