{
  "openapi": "3.0.1",
  "info": {
    "title": "Apartments.com Scraper By Rent, Beds & Pet Policy Filter",
    "description": "🏢 Apartments.com Scrape extracts listings, rent prices, amenities, and availability from Apartments.com with ease. 🚀 Perfect for market research, lead generation, and property analytics. 📊 Fast, reliable, and data-ready!",
    "version": "0.3",
    "x-build-id": "YOeOLpvjjJ1eduysw"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapio~apartments-com-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapio-apartments-com-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/scrapio~apartments-com-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapio-apartments-com-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/scrapio~apartments-com-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapio-apartments-com-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": {
          "searchLocations": {
            "title": "📍 Rental search locations",
            "type": "array",
            "description": "Cities, neighborhoods or ZIP codes to search, one per line. Each becomes an Apartments.com location index that the filters below are applied to.\n\n**Examples:** `Brookline MA` · `Miami Beach FL` · `10001`",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "🔗 Apartments.com URLs (optional)",
            "type": "array",
            "description": "Paste Apartments.com URLs directly — a location index (`/brookline-ma/`), a map search (`?bb=…`), or an individual property page. Filter segments are inserted into location-index URLs; map and property URLs are crawled unchanged.",
            "items": {
              "type": "string"
            }
          },
          "propertyLimit": {
            "title": "🔢 Maximum matching properties",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Stop after this many properties have been saved. `0` = no cap. Counted AFTER the card pre-filter and guard filters, so you get this many real matches. Default is 10.",
            "default": 10
          },
          "lastSearchPage": {
            "title": "📚 Last search page to crawl",
            "minimum": 0,
            "maximum": 28,
            "type": "integer",
            "description": "Stop paginating the filtered index after this page (40 cards per page). `0` = crawl until the results run out. Apartments.com serves at most 28 pages per search, so higher values are clamped to 28.",
            "default": 0
          },
          "bedrooms": {
            "title": "🛏️ Bedrooms",
            "enum": [
              "any",
              "studios",
              "1",
              "2",
              "3",
              "4"
            ],
            "type": "string",
            "description": "Compiles to Apartments.com's bedroom path segment. Verified live on `/brookline-ma/` (4,978 rentals unfiltered): studios → 573, 1 bed → 1,208, 2 beds → 1,505, 3 beds → 789, 4+ beds → 827.\n\n⚠️ `0-bedrooms` is deliberately NOT offered — the site accepts it but returns the full unfiltered result set. Use **Studios** instead.",
            "default": "any"
          },
          "maxRent": {
            "title": "💵 Maximum monthly rent (USD)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Compiles to the `/under-N/` segment. Verified live on `/brookline-ma/`: `under-3000` → 1,673 rentals, `under-1500` → 22.\n\n⚠️ Apartments.com has **no minimum-rent segment** — `min-2000-max-3000` is a 404 and is rejected by the builder. Use **Card minimum rent** below for a rent floor.",
            "default": 0
          },
          "petPolicy": {
            "title": "🐾 Pet policy",
            "enum": [
              "any-policy",
              "dog",
              "cat",
              "any"
            ],
            "type": "string",
            "description": "Compiles to the pet segment. Verified live on `/brookline-ma/`: dog-friendly → 1,281 rentals, cat-friendly → 2,271, any pet → 1,238.",
            "default": "any-policy"
          },
          "extraFilterSegment": {
            "title": "➕ Extra filter segment (advanced)",
            "type": "string",
            "description": "Append one more Apartments.com path segment, e.g. `furnished` or `luxury`. It is syntax-checked and rejected if it matches a known-bad pattern (`min-X-max-Y`, singular `studio`, `0-bedrooms`, `max-N`, `over-N`) — those either 404 or silently return unfiltered results. Rejections are logged and reported in `appliedFilters.rejected`."
          },
          "cardMinRent": {
            "title": "⬆️ Card minimum rent (USD)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Drop a property whose highest advertised search-card price is below this. Applied to the 40-card search payload, so rejected properties never cost a detail fetch. `0` = off.",
            "default": 0
          },
          "cardMaxRent": {
            "title": "⬇️ Card maximum rent (USD)",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Drop a property whose lowest advertised search-card price is above this. Useful as a tighter ceiling than the `/under-N/` segment, which the site applies loosely. `0` = off.",
            "default": 0
          },
          "requireSpecials": {
            "title": "🏷️ Only properties running a move-in special",
            "type": "boolean",
            "description": "Keep only cards carrying the Apartments.com **Specials** badge (concessions, free rent, look-and-lease offers).",
            "default": false
          },
          "requirePetsOnCard": {
            "title": "🐕 Only cards listing pets as an amenity",
            "type": "boolean",
            "description": "Keep only cards whose amenity chips mention pets. Independent of the pet path segment above — use both for the strictest pet filter.",
            "default": false
          },
          "requiredCardAmenities": {
            "title": "✨ Required card amenities",
            "type": "array",
            "description": "Case-insensitive substrings that must ALL appear in a card's amenity chips.\n\n**Examples:** `Fitness Center` · `In Unit Washer` · `Pool` · `Elevator` · `Dishwasher`",
            "items": {
              "type": "string"
            }
          },
          "minRating": {
            "title": "⭐ Minimum property rating",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Drop properties rated below this after the detail page is read. ⚠️ Apartments.com publishes a rating on roughly **1 in 3** properties — anything unrated is dropped when this is set. `0` = off.",
            "default": 0
          },
          "verifiedOnly": {
            "title": "✅ Verified listings only",
            "type": "boolean",
            "description": "Keep only properties carrying the Apartments.com **Verified Listing** badge on the property page.",
            "default": false
          },
          "minSqft": {
            "title": "📐 Minimum unit size (sq ft)",
            "minimum": 0,
            "maximum": 20000,
            "type": "integer",
            "description": "Drop a property whose largest published unit is smaller than this, read from the property's unit grid. Properties that publish no square footage are dropped when this is set. `0` = off.",
            "default": 0
          },
          "minBaths": {
            "title": "🛁 Minimum bathrooms",
            "minimum": 0,
            "maximum": 10,
            "type": "integer",
            "description": "Drop a property whose largest published unit has fewer bathrooms than this. Apartments.com has **no bathroom URL segment**, so this can only ever run as a post-fetch guard — it does not narrow the search itself. `0` = off.",
            "default": 0
          },
          "includeAllImages": {
            "title": "🖼️ Include the full image gallery",
            "type": "boolean",
            "description": "Adds an `images` array with every gallery photo URL published for the property (28–159 per property in live testing). Read from data already on the fetched page — no extra requests.",
            "default": false
          },
          "includeVirtualTours": {
            "title": "🎥 Include video & 3D tour links",
            "type": "boolean",
            "description": "Adds a `virtualTours` array with video tours (URL, thumbnail, upload date) and 3D tour links. Present on roughly 8–9 of every 10 properties.",
            "default": false
          },
          "requestDelay": {
            "title": "⏱️ Delay between page loads (seconds)",
            "minimum": 0,
            "maximum": 30,
            "type": "integer",
            "description": "Pause before each page load, plus a small random jitter. Raise it if pages start coming back blocked. Default is 1.",
            "default": 1
          },
          "proxyConfiguration": {
            "title": "🛡️ Proxy configuration",
            "type": "object",
            "description": "Apify **US Residential** proxy is used by default and is required for Apartments.com. If you paste your own proxy URLs here they are used instead, rotated whenever a page comes back blocked.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}