{
  "openapi": "3.0.1",
  "info": {
    "title": "Airbnb Market Occupancy Scraper",
    "description": "Occupancy for every listing in an Airbnb market. Walks each 12-month calendar and corrects for the host's booking horizon and owner blocks, giving real occupancy per listing, per month, and market-wide — not the naive blocked-day count, which can overstate occupancy by 15x.",
    "version": "0.1",
    "x-build-id": "hm17fUj7BbyLu9GSt"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/cirkit~airbnb-market-occupancy-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-cirkit-airbnb-market-occupancy-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/cirkit~airbnb-market-occupancy-scraper/runs": {
      "post": {
        "operationId": "runs-sync-cirkit-airbnb-market-occupancy-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/cirkit~airbnb-market-occupancy-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-cirkit-airbnb-market-occupancy-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": {
          "location": {
            "title": "Market / location",
            "type": "string",
            "description": "The market to analyse, for example \"Joshua Tree, CA\" or \"Gatlinburg, Tennessee\". Resolved to a centre point, then searched within `radiusKm`. Ignored when `boundingBox` is set."
          },
          "boundingBox": {
            "title": "Bounding box (overrides location)",
            "type": "object",
            "description": "Exact search area as neLat, neLng, swLat, swLng. Use this for irregular markets or to split a large region across several runs."
          },
          "radiusKm": {
            "title": "Search radius (km)",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Half-width of the search box around the resolved location. 12 km suits a town; raise it for a metro area or a spread-out region.",
            "default": 12
          },
          "maxListings": {
            "title": "Max listings to analyse",
            "minimum": 0,
            "type": "integer",
            "description": "Hard cap on listings analysed, and therefore on run cost. Set 0 for no cap — a dense metro can hold many thousands of listings.",
            "default": 300
          },
          "occupancyWindows": {
            "title": "Occupancy windows (days)",
            "type": "array",
            "description": "Forward-looking windows to score, in days. 90 days is the most reliable read: far enough out to capture demand, near enough that most hosts have their calendar open.",
            "default": [
              30,
              60,
              90
            ]
          },
          "monthsAhead": {
            "title": "Months of calendar to scan",
            "minimum": 1,
            "maximum": 12,
            "type": "integer",
            "description": "How far ahead to pull each calendar, 1 to 12. Airbnb silently caps this at 12.",
            "default": 12
          },
          "longBlockDays": {
            "title": "Owner-block threshold (days)",
            "minimum": 2,
            "maximum": 365,
            "type": "integer",
            "description": "An unbroken run of unavailable days at least this long is treated as an owner block (renovation, personal use) rather than a booking, and is removed from the occupancy denominator. Lower it in markets dominated by long stays.",
            "default": 21
          },
          "includeDailyCalendar": {
            "title": "Include the raw day-by-day calendar",
            "type": "boolean",
            "description": "Adds a `days` array to every listing row. Useful for your own modelling; it makes the dataset far larger.",
            "default": false
          },
          "includeMarketSummary": {
            "title": "Include the market summary row",
            "type": "boolean",
            "description": "Appends one roll-up row with market-wide occupancy percentiles and a month-by-month curve.",
            "default": true
          },
          "minBedrooms": {
            "title": "Minimum bedrooms",
            "minimum": 0,
            "maximum": 50,
            "type": "integer",
            "description": "Restrict the market to listings with at least this many bedrooms."
          },
          "priceMin": {
            "title": "Minimum nightly price",
            "minimum": 0,
            "type": "integer",
            "description": "Lower bound on nightly price, in `currency`."
          },
          "priceMax": {
            "title": "Maximum nightly price",
            "minimum": 0,
            "type": "integer",
            "description": "Upper bound on nightly price, in `currency`."
          },
          "maxSubdivisionDepth": {
            "title": "Max subdivision depth",
            "minimum": 0,
            "maximum": 6,
            "type": "integer",
            "description": "Airbnb truncates any single search at 270 results, so cells that come back full are split into quadrants and re-searched. Each extra level can quadruple coverage in dense markets, at proportionally more search requests.",
            "default": 3
          },
          "maxConcurrency": {
            "title": "Max concurrency",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "Parallel calendar requests. Airbnb rate-limits per IP, so raise this only alongside a rotating proxy.",
            "default": 8
          },
          "maxRunSecs": {
            "title": "Run time budget (seconds)",
            "minimum": 60,
            "maximum": 86400,
            "type": "integer",
            "description": "The Actor stops cleanly at this point and still writes everything it has gathered, rather than being killed by the platform timeout.",
            "default": 3300
          },
          "currency": {
            "title": "Currency",
            "type": "string",
            "description": "Three-letter ISO currency code for price fields.",
            "default": "USD"
          },
          "locale": {
            "title": "Locale",
            "type": "string",
            "description": "Locale tag passed to Airbnb, for example en-US or en-GB.",
            "default": "en-US"
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Apify Proxy is enabled by default and pinned to US exit IPs. Airbnb's edge serves a different response shape and overrides currency based on exit country, so changing the country degrades the output. Rotation is what keeps throughput up, since Airbnb rate-limits per IP.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyCountry": "US"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}