{
  "openapi": "3.0.1",
  "info": {
    "title": "Flatfox Scraper - Swiss rentals, homes for sale, flatshares",
    "description": "Flatfox.ch scraper: Swiss rentals and homes for sale by city or map area, with price, rooms, area, address, coordinates, features, agency and photos. Newest first. No login, no API key, no browser. $0.003 per listing.",
    "version": "0.1",
    "x-build-id": "Sg14fq5L25FTPkcdH"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/datagleaner~flatfox-swiss-property-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-datagleaner-flatfox-swiss-property-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/datagleaner~flatfox-swiss-property-scraper/runs": {
      "post": {
        "operationId": "runs-sync-datagleaner-flatfox-swiss-property-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/datagleaner~flatfox-swiss-property-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-datagleaner-flatfox-swiss-property-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": {
          "locations": {
            "title": "Cities or areas",
            "type": "array",
            "description": "Swiss cities such as Zurich, Geneva, Basel, Bern, Lausanne, Winterthur, Lucerne, St. Gallen, Lugano, or Switzerland for the whole country. For any other place use a circle as lat,lon,radiusKm (47.05,8.31,10) or a box as south,west,north,east. Each entry is one search; a city covers its surroundings (about 5 to 9 km).",
            "items": {
              "type": "string"
            }
          },
          "offerType": {
            "title": "Rent or buy",
            "enum": [
              "RENT",
              "SALE",
              "ANY"
            ],
            "type": "string",
            "description": "RENT for rentals, SALE for properties for sale, ANY for both.",
            "default": "RENT"
          },
          "categories": {
            "title": "Property categories",
            "type": "array",
            "description": "Optional. Keep only these categories: APARTMENT, HOUSE, SHARED (flatshares and rooms), INDUSTRY (offices, shops, workshops), PARK (parking and garages), GASTRO (restaurants and bars), PROPERTY (land). Leave empty for all.",
            "items": {
              "type": "string"
            }
          },
          "minPrice": {
            "title": "Minimum price (CHF)",
            "minimum": 0,
            "type": "integer",
            "description": "Optional. Monthly rent for rentals, purchase price for sales."
          },
          "maxPrice": {
            "title": "Maximum price (CHF)",
            "minimum": 0,
            "type": "integer",
            "description": "Optional. Monthly rent for rentals, purchase price for sales."
          },
          "minRooms": {
            "title": "Minimum rooms",
            "minimum": 0,
            "type": "number",
            "description": "Optional. Swiss room count, for example 2.5 or 3.5. Listings without a room count are dropped when this is set."
          },
          "maxRooms": {
            "title": "Maximum rooms",
            "minimum": 0,
            "type": "number",
            "description": "Optional. Swiss room count."
          },
          "minAreaM2": {
            "title": "Minimum living area (m2)",
            "minimum": 0,
            "type": "integer",
            "description": "Optional. Listings without an area are dropped when this is set."
          },
          "startUrls": {
            "title": "Listing links",
            "type": "array",
            "description": "Optional. Flatfox listing links (https://flatfox.ch/en/flat/8047-zurich/86442411/) to read those listings directly.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "listingIds": {
            "title": "Listing IDs",
            "type": "array",
            "description": "Optional. Flatfox listing numbers, the last number in a listing link, for example 86442411.",
            "items": {
              "type": "string"
            }
          },
          "maxItems": {
            "title": "Max listings",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Upper bound on listings returned in total, newest first. Each returned listing is billed, so this is also your cost cap.",
            "default": 100
          },
          "includeDescription": {
            "title": "Include full description",
            "type": "boolean",
            "description": "Add the advertiser's full description text (German, French, Italian or English as written). Turn off for smaller rows.",
            "default": true
          },
          "includeImages": {
            "title": "Include photo links",
            "type": "boolean",
            "description": "Add links to all photos of each listing.",
            "default": true
          },
          "requestDelaySeconds": {
            "title": "Delay between requests (seconds)",
            "minimum": 0,
            "maximum": 30,
            "type": "number",
            "description": "Base pause before each request to Flatfox; the actual pause is randomised up to 1.4x. Raise it if Flatfox answers with rate limits (HTTP 429).",
            "default": 0.5
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Optional. The default is no proxy, which works from Apify's servers. Enable Apify Proxy only if Flatfox rate-limits you."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}