{
  "openapi": "3.0.1",
  "info": {
    "title": "sdano-sreality",
    "description": "Extract real estate listing data from sreality.cz. Scrape structured data from the website sitemap or from the arbitrary real estate listing URLs on sreality.cz.",
    "version": "0.0",
    "x-build-id": "htBP0y6GzlMjf8e2C"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/tkhnv~sdano-sreality/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-tkhnv-sdano-sreality",
        "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/tkhnv~sdano-sreality/runs": {
      "post": {
        "operationId": "runs-sync-tkhnv-sdano-sreality",
        "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/tkhnv~sdano-sreality/run-sync": {
      "post": {
        "operationId": "run-sync-tkhnv-sdano-sreality",
        "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": {
          "startUrl": {
            "title": "Start URL",
            "type": "string",
            "description": "Bezrealitky home page URL",
            "default": "https://www.sreality.cz/hledani/filtr"
          },
          "sitemapStartUrl": {
            "title": "Sitemap start URL",
            "type": "string",
            "description": "Sitemap URL to crawl from",
            "default": "https://www.sreality.cz/sitemap.xml"
          },
          "parseSitemap": {
            "title": "Parse sitemap",
            "type": "boolean",
            "description": "If true, the crawler will only parse the articles from the sitemap. If false, the crawler will parse the article URLs from the pagination pages.",
            "default": false
          },
          "parseArticleUrls": {
            "title": "Parse articles",
            "type": "array",
            "description": "Overrides the default behavior of extracting article URLs from the sitemap. If provided, the crawler will only parse provided article URLs.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "includeAllCountries": {
            "title": "Include all countries",
            "type": "boolean",
            "description": "If true, all countries will be included. If false, only the countries in the includeCountries list plus Czechia will be included.",
            "default": false
          },
          "includeCountries": {
            "title": "Countries to include",
            "type": "array",
            "description": "Countries to include. Ignoring all coutries except for Czechia by default. See ISO_3166-1_alpha-2 for the list of country codes. WARNING: This property won't speed up the search of required articles since it's still necessary to scrape the data from each url.",
            "default": [
              "CZ"
            ],
            "items": {
              "type": "string"
            }
          },
          "ignoreUrls": {
            "title": "Ignore URLs",
            "type": "array",
            "description": "If provided, the crawler will ignore these article URLs.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "datasetName": {
            "title": "Dataset Name",
            "type": "string",
            "description": "Name of the dataset to store the scraped data in."
          },
          "constraintEstateTypes": {
            "title": "Constraint estate types",
            "type": "array",
            "description": "If provided, the crawler will only parse articles with these estate types. Possible values (mapped to sreality native enums): APARTMENT (byt), HOUSE (dům), LAND (pozemek), GARAGE (ostatni -> garáž), OFFICE (komerční), NON_RESIDENTIAL (ostatní -> all except for garáž and mobilní domek), COTTAGE (dům -> chalupa), SUMMER_HOUSE (dům -> chata), OTHER (ostatní -> jiné nemovitosti or mobilní domek).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "constraintOfferTypes": {
            "title": "Constraint offer types",
            "type": "array",
            "description": "If provided, the crawler will only parse articles with these offer types. Possible values (mapped to sreality native enums): SALE (prodej), RENT (pronajem), COLIVING (pronajem -> pokoj).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "constraintLayouts": {
            "title": "Constraint layouts",
            "type": "array",
            "description": "If provided, the crawler will only parse apartment articles with these layouts. Possible values (mapped to sreality native enums): ONE (mapped to both \"1+kk\" and \"pokoj\"), ONE_PLUS_ONE, TWO, TWO_PLUS_ONE, THREE, THREE_PLUS_ONE, FOUR, FOUR_PLUS_ONE, FIVE, FIVE_PLUS_ONE; SIX, SIX_PLUS_ONE, SEVEN, SEVEN_PLUS_ONE are all mapped to \"6 a vice\"; OTHER (mapped to atypický)",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "location": {
            "title": "Location",
            "type": "string",
            "description": "WARNING: you should set parseSitemap to false to use this option. Location to filter the listings by. This will be used to fuzzy search the location on the landing page. The first suggested location will be used."
          },
          "minPrice": {
            "title": "Min price",
            "type": "integer",
            "description": "Min price to filter the listings by. If set, will ignore listings without price listed."
          },
          "maxPrice": {
            "title": "Max price",
            "type": "integer",
            "description": "Max price to filter the listings by."
          },
          "minArea": {
            "title": "Min area",
            "type": "integer",
            "description": "Min area to filter the listings by. If set, will ignore listings without area listed."
          },
          "maxArea": {
            "title": "Max area",
            "type": "integer",
            "description": "Max area to filter the listings by."
          },
          "publishedFrom": {
            "title": "Published from",
            "pattern": "^(\\d{4})-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$",
            "type": "string",
            "description": "Published from date to filter the listings by. Format: YYYY-MM-DD"
          },
          "publishedTo": {
            "title": "Published to",
            "pattern": "^(\\d{4})-(0[1-9]|1[0-2])-(0[1-9]|[12]\\d|3[01])$",
            "type": "string",
            "description": "Published to date to filter the listings by. Format: YYYY-MM-DD"
          },
          "maxArticles": {
            "title": "Max articles",
            "type": "integer",
            "description": "Max number of articles to scrape. If set, the crawler will stop after scraping this number of articles. Set to -1 to scrape all articles.",
            "default": 10
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}