{
  "openapi": "3.0.1",
  "info": {
    "title": "RealestateCo NZ Scraper",
    "description": "Search and extract all real estate properties for sale, rent, and sold across New Zealand from realestate.co.nz.",
    "version": "1.0",
    "x-build-id": "7931NZUYsF20cKBlX"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/abotapi~realestate-co-nz-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-abotapi-realestate-co-nz-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/abotapi~realestate-co-nz-scraper/runs": {
      "post": {
        "operationId": "runs-sync-abotapi-realestate-co-nz-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/abotapi~realestate-co-nz-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-abotapi-realestate-co-nz-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",
        "required": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "Search Mode",
            "enum": [
              "location",
              "url"
            ],
            "type": "string",
            "description": "Search by Location builds URLs from region/district/suburb. Search List URLs lets you paste realestate.co.nz search result page URLs directly.",
            "default": "location"
          },
          "locations": {
            "title": "Locations",
            "type": "array",
            "description": "Locations to search (Location mode only). Region is required. District and suburb are optional — omit for broader searches.",
            "items": {
              "type": "object",
              "properties": {
                "region": {
                  "title": "Region",
                  "type": "string",
                  "description": "New Zealand region",
                  "enum": [
                    "Auckland",
                    "Bay of Plenty",
                    "Canterbury",
                    "Central North Island",
                    "Central Otago / Lakes District",
                    "Coromandel",
                    "Gisborne",
                    "Hawkes Bay",
                    "Manawatu / Whanganui",
                    "Marlborough",
                    "Nelson & Bays",
                    "Northland",
                    "Otago",
                    "Pacific Islands",
                    "Southland",
                    "Taranaki",
                    "Waikato",
                    "Wairarapa",
                    "Wellington",
                    "West Coast"
                  ],
                  "editor": "select"
                },
                "district": {
                  "title": "District (Optional)",
                  "type": "string",
                  "description": "District name, e.g. Auckland City, Manukau City, Wellington City. Leave empty for region-wide search.",
                  "editor": "textfield"
                },
                "suburb": {
                  "title": "Suburb (Optional)",
                  "type": "string",
                  "description": "Suburb name, e.g. Ponsonby, Papatoetoe, Thorndon. Leave empty for wider search.",
                  "editor": "textfield"
                }
              },
              "required": [
                "region"
              ]
            }
          },
          "urls": {
            "title": "Search List URLs",
            "type": "array",
            "description": "Paste realestate.co.nz search result page URLs (URL mode only). These are URLs that show multiple properties. Do NOT use individual property detail URLs. Each URL is scraped as a single page — no pagination.",
            "items": {
              "type": "string"
            }
          },
          "listingType": {
            "title": "Listing Type",
            "enum": [
              "buy",
              "rent",
              "sold",
              "new_builds"
            ],
            "type": "string",
            "description": "Type of property listings to scrape. Sold returns historical sales data (sale prices, council valuations, estimated values). New Builds filters for new construction only.",
            "default": "buy"
          },
          "propertyTypes": {
            "title": "Property Types (Optional)",
            "type": "array",
            "description": "Filter by property type. Leave empty for all types.",
            "items": {
              "type": "string",
              "enum": [
                "house",
                "apartment",
                "townhouse",
                "unit",
                "section",
                "lifestyle_property",
                "lifestyle_section",
                "home_and_income",
                "studio",
                "retirement_living",
                "multiple_properties",
                "boat_shed",
                "carpark",
                "other"
              ],
              "enumTitles": [
                "House",
                "Apartment",
                "Townhouse",
                "Unit",
                "Section",
                "Lifestyle Property",
                "Lifestyle Section",
                "Home & Income",
                "Studio",
                "Retirement Living",
                "Multiple Properties",
                "Boat Shed",
                "Carpark",
                "Other"
              ]
            }
          },
          "priceMin": {
            "title": "Minimum Price (Optional)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum property price in NZD"
          },
          "priceMax": {
            "title": "Maximum Price (Optional)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum property price in NZD"
          },
          "bedroomsMin": {
            "title": "Minimum Bedrooms (Optional)",
            "minimum": 0,
            "maximum": 20,
            "type": "integer",
            "description": "Minimum number of bedrooms"
          },
          "bathroomsMin": {
            "title": "Minimum Bathrooms (Optional)",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "Minimum number of bathrooms"
          },
          "includeNeighbouringSuburbs": {
            "title": "Include Neighbouring Suburbs",
            "type": "boolean",
            "description": "Include properties from neighbouring suburbs in results. When unchecked, only the exact suburb is searched. Most useful when searching at suburb level.",
            "default": false
          },
          "sort": {
            "title": "Sort Order",
            "enum": [
              "latest",
              "price-asc",
              "price-desc",
              "default"
            ],
            "type": "string",
            "description": "Sort order for search results. For Sold listings, 'latest' uses 'latest-sale' ordering automatically.",
            "default": "latest"
          },
          "maxListings": {
            "title": "Maximum Listings",
            "minimum": 1,
            "type": "integer",
            "description": "Stop after scraping this many listings. Leave empty for no limit.",
            "default": 25
          },
          "maxPages": {
            "title": "Maximum Pages per Location",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum search result pages per location (Location mode only). Each page has ~20 results. Ignored in URL mode.",
            "default": 100
          },
          "outputFormat": {
            "title": "Output Formats",
            "type": "array",
            "description": "Export data in these formats",
            "items": {
              "type": "string",
              "enum": [
                "json",
                "csv"
              ],
              "enumTitles": [
                "JSON",
                "CSV"
              ]
            },
            "default": [
              "json"
            ]
          },
          "proxyConfiguration": {
            "title": "Proxy Configuration",
            "type": "object",
            "description": "Configure proxy for bypassing anti-bot protection. NZ residential proxies recommended."
          },
          "resumeFromCheckpoint": {
            "title": "Resume from Checkpoint",
            "type": "boolean",
            "description": "Continue from last saved checkpoint if the run was interrupted",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}