{
  "openapi": "3.0.1",
  "info": {
    "title": "VivaReal & ZAP Imóveis Scraper - Brazil Real Estate",
    "description": "Scrape VivaReal & ZAP Imóveis — Brazil's top real estate portals. Apartments & houses for sale or rent with prices, condo fees, IPTU, area, photos, geo, amenities & broker leads (phone, WhatsApp, website, CRECI). Filter by city, price, bedrooms. Monitor new listings & price drops. Export JSON, CSV.",
    "version": "0.1",
    "x-build-id": "a2qHpYUtD1ePgDlkt"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapesage~vivareal-zap-imoveis-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapesage-vivareal-zap-imoveis-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/scrapesage~vivareal-zap-imoveis-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapesage-vivareal-zap-imoveis-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/scrapesage~vivareal-zap-imoveis-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapesage-vivareal-zap-imoveis-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": {
          "portal": {
            "title": "Portal",
            "enum": [
              "vivareal",
              "zap"
            ],
            "type": "string",
            "description": "Which Brazilian portal to scrape. Both share the same listing database; pick the one whose ranking and inventory you want.",
            "default": "vivareal"
          },
          "locationQueries": {
            "title": "Locations (city or neighborhood)",
            "type": "array",
            "description": "Free-text Brazilian locations — a city (<code>São Paulo, SP</code>, <code>Rio de Janeiro</code>) or a neighborhood (<code>Pinheiros</code>, <code>Copacabana</code>). Each is resolved automatically to the right portal location and searched with the filters below.",
            "items": {
              "type": "string"
            }
          },
          "businessType": {
            "title": "For sale or for rent",
            "enum": [
              "SALE",
              "RENTAL"
            ],
            "type": "string",
            "description": "Transaction type to search.",
            "default": "SALE"
          },
          "propertyStatus": {
            "title": "Listing type",
            "enum": [
              "USED",
              "DEVELOPMENT"
            ],
            "type": "string",
            "description": "Resale/used properties or new developments (lançamentos).",
            "default": "USED"
          },
          "unitTypes": {
            "title": "Property types",
            "type": "array",
            "description": "Optional property types (codes): <code>APARTMENT</code>, <code>HOME</code>, <code>CONDOMINIUM</code>, <code>PENTHOUSE</code>, <code>FLAT</code>, <code>KITNET</code>, <code>FARM</code>, <code>OFFICE</code>, <code>COMMERCIAL_PROPERTY</code>, <code>BUSINESS</code>, <code>ALLOTMENT_LAND</code>, <code>BUILDING</code>. Leave empty for all.",
            "items": {
              "type": "string"
            }
          },
          "searchUrls": {
            "title": "Start URLs (optional)",
            "type": "array",
            "description": "Paste VivaReal or ZAP Imóveis search-page URLs (e.g. <code>https://www.vivareal.com.br/venda/sp/sao-paulo/apartamento_residencial/</code>) or raw glue-api URLs. Used in addition to the locations above.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "priceMin": {
            "title": "Min price (BRL)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum price. For rentals this is the monthly rent."
          },
          "priceMax": {
            "title": "Max price (BRL)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum price. For rentals this is the monthly rent."
          },
          "minBedrooms": {
            "title": "Min bedrooms",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Minimum number of bedrooms."
          },
          "minBathrooms": {
            "title": "Min bathrooms",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Minimum number of bathrooms."
          },
          "minParkingSpaces": {
            "title": "Min parking spaces",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "Minimum number of parking spaces."
          },
          "minArea": {
            "title": "Min usable area (m²)",
            "minimum": 0,
            "type": "integer",
            "description": "Minimum usable area in square meters."
          },
          "maxArea": {
            "title": "Max usable area (m²)",
            "minimum": 0,
            "type": "integer",
            "description": "Maximum usable area in square meters."
          },
          "amenities": {
            "title": "Amenities",
            "type": "array",
            "description": "Optional amenity codes the property must have: <code>POOL</code>, <code>GYM</code>, <code>BARBECUE_GRILL</code>, <code>PLAYGROUND</code>, <code>PARTY_HALL</code>, <code>ELEVATOR</code>, <code>BALCONY</code>, <code>FURNISHED</code>, <code>AIR_CONDITIONING</code>, <code>GATED_COMMUNITY</code>, <code>PETS_ALLOWED</code>.",
            "items": {
              "type": "string"
            }
          },
          "sort": {
            "title": "Sort order",
            "enum": [
              "relevance",
              "price-asc",
              "price-desc",
              "newest",
              "area-desc"
            ],
            "type": "string",
            "description": "Result ordering.",
            "default": "relevance"
          },
          "maxResults": {
            "title": "Max properties",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of property records to scrape across all locations.",
            "default": 100
          },
          "includeAgencyLeads": {
            "title": "Emit agency / broker lead records",
            "type": "boolean",
            "description": "In addition to property records, output one deduplicated lead record per real-estate agency / broker (type = \"agencyLead\") with name, phone, mobile, WhatsApp, website, CRECI license, address, active-listing count and a 0–100 lead score.",
            "default": true
          },
          "maxAgencyLeads": {
            "title": "Max agency leads",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of deduplicated agency lead records to output.",
            "default": 200
          },
          "monitorMode": {
            "title": "Monitor mode (only new + changed)",
            "type": "boolean",
            "description": "Remember listings seen on previous runs (in a named key-value store) and flag new listings (<code>isNewListing</code>) and price changes (<code>priceChangedSinceLastRun</code>, <code>previousPrice</code>). Combine with Apify Schedules to build a fresh-listing / price-drop feed.",
            "default": false
          },
          "monitorKey": {
            "title": "Monitor key",
            "type": "string",
            "description": "Name for this monitor's saved state. Use a different key per saved search so their histories don't mix.",
            "default": "default"
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Proxies to use. Residential Brazil proxies are required — the listing API blocks datacenter IPs.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ],
              "apifyProxyCountry": "BR"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}