{
  "openapi": "3.0.1",
  "info": {
    "title": "Otodom Scraper - Plus Imovirtual & Storia",
    "description": "Scrape Otodom, Imovirtual and Storia real estate listings in Poland, Portugal and Romania. Flats, houses, plots and more, for sale or rent. Get price, price per m2, area, rooms, district and photos, EUR prices, a per-m2 deal score and tracking of new listings and price drops. JSON, CSV, Excel, API.",
    "version": "0.1",
    "x-build-id": "WKLFHXoc2p3vBXVnd"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/difioprdy~otodom-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-difioprdy-otodom-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/difioprdy~otodom-scraper/runs": {
      "post": {
        "operationId": "runs-sync-difioprdy-otodom-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/difioprdy~otodom-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-difioprdy-otodom-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": {
          "preset": {
            "title": "Preset (what do you want to do?)",
            "enum": [
              "custom",
              "price_research",
              "deal_hunting",
              "market_report"
            ],
            "type": "string",
            "description": "Settings for a goal. price_research: one-off check of all listings with EUR prices, deal score per m2 and summaries. deal_hunting: scheduled watch that returns only new listings and price changes (needs a Monitor name), newest first. market_report: 500 listings per portal for a market overview. A preset other than Custom always sets Sort, Monitor mode and Report delisted listings (your values there are ignored); Max listings stays yours when filled.",
            "default": "custom"
          },
          "portals": {
            "title": "Portals",
            "minItems": 1,
            "uniqueItems": true,
            "type": "array",
            "description": "Sites to search, e.g. [\"otodom\"]. Each portal is a separate search with the same filters. Prices are mostly in PLN on otodom and in EUR on imovirtual and storia; a few listings use another currency (see the currency field), and every listing also gets priceEur.",
            "items": {
              "type": "string",
              "enum": [
                "otodom",
                "imovirtual",
                "storia"
              ],
              "enumTitles": [
                "Otodom (otodom.pl, Poland, PLN)",
                "Imovirtual (imovirtual.com, Portugal, EUR)",
                "Storia (storia.ro, Romania, EUR)"
              ]
            },
            "default": [
              "otodom"
            ]
          },
          "transaction": {
            "title": "Sale or rent",
            "enum": [
              "sale",
              "rent"
            ],
            "type": "string",
            "description": "sale = properties for sale (total price), rent = properties for rent (monthly rent).",
            "default": "sale"
          },
          "propertyType": {
            "title": "Property type",
            "enum": [
              "flat",
              "house",
              "plot",
              "commercial",
              "warehouse",
              "garage",
              "room"
            ],
            "type": "string",
            "description": "Type of property, available on all three portals. room exists only for rent. Developer projects (new buildings) appear in flat searches; see \"Include developer projects\".",
            "default": "flat"
          },
          "location": {
            "title": "City",
            "maxLength": 100,
            "type": "string",
            "description": "City or town in the local spelling, e.g. \"Warszawa\", \"Kraków\", \"Lisboa\", \"Porto\", \"Bucuresti\", \"Cluj-Napoca\". It is matched (ignoring case and accents) in a location table bundled with the Actor, built from each portal's own search results; a portal without that place is skipped, and for very small places you can paste a search URL into Start URLs instead. Leave empty for the whole country. Do not combine with Start URLs.",
            "default": ""
          },
          "startUrls": {
            "title": "Start URLs (instead of City)",
            "type": "array",
            "description": "Search results URLs copied from otodom.pl, imovirtual.com or storia.ro, with any filters you set on the site, e.g. https://www.otodom.pl/pl/wyniki/sprzedaz/mieszkanie/mazowieckie/warszawa/warszawa/warszawa?priceMax=800000. Each URL is one search. Page number and page size are set by the Actor; the filters below are added on top when you fill them.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "maxItems": {
            "title": "Max listings per search",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Maximum listings checked for each portal (or each Start URL). Your main cost control: always used when filled, also with a preset. Default 100 when left empty (market_report preset: 500). In monitor mode at most 30,000."
          },
          "priceMin": {
            "title": "Min price",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum price in the portal's currency (PLN on otodom, EUR on imovirtual/storia; the site converts for listings in another currency), e.g. 300000. 0 or empty = no limit. For rent this is the monthly rent.",
            "default": 0
          },
          "priceMax": {
            "title": "Max price",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum price in the portal's currency, e.g. 800000. 0 or empty = no limit.",
            "default": 0
          },
          "areaMin": {
            "title": "Min area (m²)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Minimum area in square metres, e.g. 40. 0 or empty = no limit.",
            "default": 0
          },
          "areaMax": {
            "title": "Max area (m²)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Maximum area in square metres, e.g. 80. 0 or empty = no limit.",
            "default": 0
          },
          "rooms": {
            "title": "Rooms",
            "uniqueItems": true,
            "type": "array",
            "description": "Number of rooms to include, e.g. [\"2\", \"3\"]. \"6\" means 6 or more. Empty = any.",
            "items": {
              "type": "string",
              "enum": [
                "1",
                "2",
                "3",
                "4",
                "5",
                "6"
              ],
              "enumTitles": [
                "1",
                "2",
                "3",
                "4",
                "5",
                "6 or more"
              ]
            },
            "default": []
          },
          "sort": {
            "title": "Sort",
            "enum": [
              "newest",
              "site_default"
            ],
            "type": "string",
            "description": "Ignored unless Preset is Custom. newest = newest listings first (default when left empty), site_default = the portal's own default order."
          },
          "includeDeveloperProjects": {
            "title": "Include developer projects",
            "type": "boolean",
            "description": "Developer project tiles (new buildings with several units, mostly on otodom) have a starting price per m² and an area range instead of one price. Turn off to get only single listings; skipped projects are not charged.",
            "default": true
          },
          "excludeKeywords": {
            "title": "Exclude keywords",
            "maxItems": 100,
            "type": "array",
            "description": "Drop listings whose title contains any of these words, e.g. [\"licytacja\", \"udział\"]. Matching ignores case and accents and works on whole words. Dropped listings are not charged.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "monitorMode": {
            "title": "Monitor mode (only new and changed)",
            "type": "boolean",
            "description": "Ignored unless Preset is Custom. Return only listings that are new or whose price changed since the last run with the same Monitor name and search. The first run returns everything as new. Unchanged listings are skipped and not charged. Off when left empty (deal_hunting preset: on)."
          },
          "monitorName": {
            "title": "Monitor name",
            "pattern": "^$|^[A-Za-z0-9](?:[A-Za-z0-9-]{0,61}[A-Za-z0-9])?$",
            "type": "string",
            "description": "Name of this watch, needed in monitor mode: letters, digits and hyphens, e.g. \"warsaw-flats\". Use a new name to start over.",
            "default": ""
          },
          "emitDelisted": {
            "title": "Report delisted listings",
            "type": "boolean",
            "description": "Ignored unless Preset is Custom. In monitor mode, also return listings that disappeared since the last run (changeType delisted, free). Only when the whole search was read. Off when left empty."
          },
          "belowMarketThreshold": {
            "title": "Below-market threshold, sale (%)",
            "minimum": -100,
            "maximum": 0,
            "type": "integer",
            "description": "Sale listings: isBelowMarket is true when the price per m² is at least this many percent below the median of the same search, city and property type, e.g. -25 (flags about 10% in our tests). From -100 to 0.",
            "default": -25
          },
          "belowMarketThresholdRent": {
            "title": "Below-market threshold, rent (%)",
            "minimum": -100,
            "maximum": 0,
            "type": "integer",
            "description": "Rent listings: the same, using monthly rent per m², e.g. -32 (flags about 10% in our tests; rents vary more per m² than sale prices). From -100 to 0.",
            "default": -32
          },
          "useResidentialProxy": {
            "title": "Always use residential proxy",
            "type": "boolean",
            "description": "Normally the Actor connects directly and switches to Apify residential proxy (in the portal's country) only if the site blocks it. Turn on to use residential proxy from the start (slower and adds proxy traffic cost).",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}