# Redfin Housing Market Data Scraper — Trends, Comps, Hotness (`sian.agency/redfin-market-analytics-scraper`) Actor

Pull US housing market data for any ZIP, city, or neighborhood: 60-month median sale price and demand trends, Compete Score market hotness, recently sold comps, school ratings, climate risk, and national trends. One structured row per location and dataset. Built for investors, analysts, and ETL.

- **URL**: https://apify.com/sian.agency/redfin-market-analytics-scraper.md
- **Developed by:** [SIÁN OÜ](https://apify.com/sian.agency) (community)
- **Categories:** Real estate, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $6.00 / 1,000 market dataset row extracteds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Redfin Housing Market Data Scraper — Trends, Comps & Hotness 🚀

[![SIÁN Agency Store](https://img.shields.io/badge/Store-SI%C3%81N%20Agency-1AE392)](https://apify.com/sian.agency?fpr=sian) [![Redfin Property Scraper](https://img.shields.io/badge/Store-Redfin%20Property%20Scraper-A02021)](https://apify.com/sian.agency/redfin-property-scraper?fpr=sian) [![Zillow Market Analytics](https://img.shields.io/badge/Store-Zillow%20Market%20Analytics-1F4E79)](https://apify.com/sian.agency/zillow-market-analytics-scraper?fpr=sian) [![Property Skip Tracing](https://img.shields.io/badge/Store-Property%20Skip%20Tracing-1AE392)](https://apify.com/sian.agency/property-skip-tracing?fpr=sian)

#### 🎉 60 months of housing market history per ZIP code — price trends, Compete Score hotness, sold comps, schools & climate risk in ONE run
##### Built for real-estate investors, analysts, and data teams who rank markets before they buy

---

### 📋 Overview

**Stop copy-pasting market stats from housing pages** — this actor pulls complete US housing market intelligence for any ZIP code, city, county, or neighborhood and delivers it as clean, structured dataset rows ready for BigQuery, Snowflake, pandas, or Excel.

**Why data teams choose us:**
- ✅ **60-month trend series**: median sale price, homes sold, days on market, sale-to-list ratio, % sold above list, % price drops — every monthly point with value AND year-over-year change
- 🔥 **Compete Score market hotness**: 0–100 competitiveness score with typical offer counts, waived contingencies, and nearby-ZIP comparison — data no other scraper exposes
- 🏠 **Freshest sold comps per location**: the latest sales with sold price, $/sqft, beds/baths, sold date, MLS number, coordinates, listing remarks — in one charged row
- 🎓 **Schools + climate risk in the same run**: school ratings with parent reviews counts, plus flood/fire/heat/wind risk scores — replaces two extra tools
- 💰 **One row = one full dataset**: a whole 60-month series (360+ datapoints) costs a single per-row fee — not hundreds of per-item charges
- ✨ **NEW — Listing demand signals**: tour counts, view popularity vs the top-10% threshold, and price-drop eligibility per active listing

---

### ✨ Features

- 📈 **Market Trends**: 6 metrics × 60 monthly datapoints per location, each with YoY change
- 🔥 **Market Hotness**: Compete Score aggregates + the same scores for nearby ZIP codes
- 🏠 **Recently Sold Comps**: the latest sold homes per location with full pricing detail
- 🎓 **School Intelligence**: elementary/middle/high schools with 1–10 ratings, parent ratings, student-teacher ratios
- 🌊 **Climate Risk**: flood, fire, heat, and wind scores with properties-at-risk counts
- 🇺🇸 **National Baseline**: US-wide supply/demand series incl. the average 30-year mortgage rate
- 🎯 **Listing Demand Signals**: per-listing tour counts, view counts, price-drop eligibility
- 📍 **Free-form locations**: ZIP, "City, ST", county, or neighborhood — resolved automatically
- 🔗 **Join-ready output**: every row carries a resolved region ID and region name

---

### 🎬 Quick Start

Enter one or more locations, tick the datasets you want, and press Start. Each location × dataset produces one structured row. Export as JSON, CSV, or Excel.

```bash
curl -X POST "https://api.apify.com/v2/acts/sian.agency~redfin-market-analytics-scraper/runs?token=YOUR_TOKEN" \
-H 'Content-Type: application/json' \
-d '{"locations": ["Austin, TX", "78759"]}'
````

***

### 🚀 Getting Started (3 Simple Steps)

#### Step 1: Add locations

ZIP codes, cities, counties, or neighborhoods — mix them freely.

#### Step 2: Pick your datasets

Market trends, hotness, and sold comps are on by default; add schools, climate risk, or the national baseline with one click.

#### Step 3: Run and export

In under a minute you'll have:

- One row per location per dataset with the resolved region attached
- Full 60-month time series ready for charting
- Sold comps ready for underwriting models

***

### 📥 Input Configuration

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| locations | array | No\* | US locations — ZIP, "City, ST", county, or neighborhood |
| includeMarketTrends | boolean | No | 60-month price & demand series (default: true) |
| includeMarketHotness | boolean | No | Compete Score + nearby comparison (default: true) |
| includeRecentlySold | boolean | No | Latest sold comps (default: true) |
| includeSchools | boolean | No | Schools & ratings (default: false) |
| includeClimateRisk | boolean | No | Flood/fire/heat/wind risk (default: false) |
| includeNationalTrends | boolean | No | US baseline series, once per run (default: false) |
| listingSignals | array | No\* | `propertyId:listingId` pairs for demand signals |

\* Provide at least one location, one listing-signal pair, or enable the national baseline.

**Example:**

```json
{
  "locations": ["Austin, TX", "78759", "Travis County, TX"],
  "includeMarketTrends": true,
  "includeMarketHotness": true,
  "includeRecentlySold": true,
  "includeSchools": true,
  "includeClimateRisk": true,
  "includeNationalTrends": true
}
```

**Listing demand signals** (get both IDs from any row of our [Redfin Property Scraper](https://apify.com/sian.agency/redfin-property-scraper?fpr=sian)):

```json
{
  "listingSignals": ["31327561:217326962"]
}
```

***

### 📤 Output

One row per location per dataset. Key fields:

| Field | Type | Description |
|-------|------|-------------|
| dataset | string | marketTrends, marketHotness, recentlySold, schools, climateRisk, nationalTrends, listingSignals |
| queryLocation | string | Your input location |
| regionId / regionName | string | Resolved region — stable join key |
| trendMetrics | array | Per metric: label, current value, 60 monthly {date, value, yoy} points |
| competeScore | object | Hotness score 0–100, sale-to-list, days on market, typical offers |
| nearbyCompeteScores | array | The same scores for neighboring ZIP codes |
| soldHomes | array | Sold comps: price, $/sqft, beds/baths, sold date, MLS#, coordinates |
| schools | array | Level, rating, parent rating, students, ratios, links |
| climateRisk | object | Flood/fire/heat/wind blocks with properties-at-risk counts |
| tourInsights / popularityInfo / priceDropInfo | object | Listing demand signals |
| fetchedAt | string | Extraction timestamp |

**Example (marketTrends row, abbreviated):**

```json
{
  "dataset": "marketTrends",
  "queryLocation": "78759",
  "regionId": "34149",
  "regionName": "78759, TX, USA",
  "trendMetrics": [
    {
      "section": "overview",
      "label": "Median Sale Price",
      "currentValue": "$614,817",
      "series": [
        { "date": "2026-05-31", "value": 614817, "yoy": "-10.2%" }
      ]
    }
  ],
  "fetchedAt": "2026-07-02T14:00:00.000Z"
}
```

***

### 💼 Use Cases & Examples

#### 1. Market ranking for real-estate investors

**Investors rank 50 target ZIP codes by price momentum and competitiveness before allocating capital.**

**Input:** 50 ZIP codes, trends + hotness enabled
**Output:** 100 rows — 60-month series and Compete Scores per ZIP
**Use:** Sort by YoY price change and hotness score to shortlist buy markets.

#### 2. Sold-comp feeds for underwriting

**Acquisition analysts refresh sold comps weekly for valuation models.**

**Input:** target neighborhoods with `includeRecentlySold` enabled
**Output:** the freshest sales per area with $/sqft and sold dates
**Use:** Feed automated ARV and cap-rate models with fresh comparable sales.

#### 3. Neighborhood quality scoring for relocation platforms

**PropTech products score neighborhoods on schools and climate safety.**

**Input:** city list, schools + climate risk enabled
**Output:** rated schools and flood/fire/heat/wind blocks per city
**Use:** Build a location-quality index behind your search UI.

#### 4. Market-vs-nation dashboards

**Analysts index every local metric against the US baseline.**

**Input:** metro list + `includeNationalTrends: true`
**Output:** local series + one national row incl. 30-year mortgage rates
**Use:** Show whether a market outperforms the national trend line.

#### 5. Demand tracking for listing agents

**Agents monitor buyer interest on their active listings.**

**Input:** `propertyId:listingId` pairs from the Redfin Property Scraper
**Output:** tour counts, view popularity, price-drop eligibility per listing
**Use:** Time price adjustments with hard demand data.

#### 6. Housing research & journalism

**Researchers pull 5-year price histories across dozens of counties in minutes.**

**Input:** county names
**Output:** consistent monthly series with YoY deltas
**Use:** Publish data-backed housing stories without manual collection.

***

### 🔗 Integration Examples

#### JavaScript/Node.js

```javascript
import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_TOKEN' });

const run = await client.actor('sian.agency/redfin-market-analytics-scraper').call({
  locations: ['Austin, TX', '78759']
});

const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items[0]);
```

#### Python

```python
from apify_client import ApifyClient
client = ApifyClient('YOUR_TOKEN')

run = client.actor('sian.agency/redfin-market-analytics-scraper').call(
    run_input={'locations': ['Austin, TX', '78759']}
)

for item in client.dataset(run['defaultDatasetId']).iterate_items():
    print(item['dataset'], item['regionName'])
```

#### cURL

```bash
curl -X POST 'https://api.apify.com/v2/acts/sian.agency~redfin-market-analytics-scraper/runs?token=YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{"locations": ["78759"]}'
```

#### Automation Workflows (n8n / Zapier / Make)

1. **Trigger**: weekly schedule
2. **HTTP Request**: start this actor with your market watchlist
3. **Process**: read the dataset rows
4. **Action**: update dashboards, alert on hotness or price-drop shifts

***

### 📊 Performance & Pricing

#### FREE Tier (Try It Now)

- **5 locations** and **5 listing-signal pairs** per run — full feature access, same data quality
- No credit card required
- Perfect for evaluating a new market

#### PAID Tier (Production Ready)

- **Unlimited** locations and listing signals per run
- Pay-per-row: one flat fee per location × dataset row — a full 60-month series counts as ONE row
- Priced for scheduled, fleet-wide market monitoring

💰 **Best value on the market** — comparable tools charge per datapoint or per listing; here one row fee buys an entire dataset for the location.

🔗 [View current pricing](https://apify.com/sian.agency/redfin-market-analytics-scraper?fpr=sian)

***

### ❓ Frequently Asked Questions

**Q: What location formats are supported?**
A: ZIP codes (`78759`), cities (`Austin, TX`), counties (`Travis County, TX`), and neighborhoods. Each is resolved automatically to a market region echoed back in the row.

**Q: How much history do the trend series cover?**
A: 60 monthly datapoints (5 years) per metric, each with the value and its year-over-year change.

**Q: How many sold comps do I get?**
A: The most recent sales per location (typically the 8 latest) — all inside one charged row. Need the full sold inventory? Use our [Redfin Property Scraper](https://apify.com/sian.agency/redfin-property-scraper?fpr=sian) with the sold filter.

**Q: Where do I get the IDs for listing demand signals?**
A: Every row of our [Redfin Property Scraper](https://apify.com/sian.agency/redfin-property-scraper?fpr=sian) contains both `propertyId` and `listingId`.

**Q: What output formats are available?**
A: JSON, CSV, and Excel — export directly from the Apify dataset.

**Q: Can I filter trends by property type?**
A: Not currently — trend series cover all property types combined.

**Q: Is this legal?**
A: We only extract publicly available market statistics. See the [legal section](#%EF%B8%8F-is-it-legal-to-scrape-data) below.

***

### 🐛 Troubleshooting

**A location returns an error or no row**

- Check the spelling and add the state, e.g. `Austin, TX` instead of `Austin`
- Very small or rural areas may not have a resolvable market region — try the county

**Listing signals return empty objects**

- Signals only populate for ACTIVE listings; sold or delisted homes return zeros
- Verify the pair format: `propertyId:listingId` (both numeric)

**Fewer sold comps than expected**

- The dataset returns the latest sales snapshot; quiet markets have fewer — the row's `soldHomesReturned` shows the real count
- For the complete sold inventory of an area, use the [Redfin Property Scraper](https://apify.com/sian.agency/redfin-property-scraper?fpr=sian) sold mode

***

### ⚠️ Trademark Disclaimer

Redfin is a registered trademark of Redfin Corporation. This actor is an independent tool and is **not affiliated with, endorsed by, or sponsored by Redfin Corporation**. All trademarks, service marks, and company names are the property of their respective owners. This actor only accesses publicly available data.

***

### ⚖️ Is it legal to scrape data?

Our actors are ethical and do not extract any private user data, such as email addresses, gender, or location. They only extract what the user has chosen to share publicly. We therefore believe that our actors, when used for ethical purposes by Apify users, are safe.

However, you should be aware that your results could contain personal data. Personal data is protected by the **GDPR** in the European Union and by other regulations around the world. You should not scrape personal data unless you have a legitimate reason to do so. If you're unsure whether your reason is legitimate, consult your lawyers.

You can also read Apify's blog post on the [legality of web scraping](https://blog.apify.com/is-web-scraping-legal/).

***

### 🤝 Support

[![Telegram Support](https://img.shields.io/badge/Telegram-Support%20Group-0088cc?logo=telegram)](https://t.me/+vyh1sRE08sAxMGRi)

**Join our active support community**

- For issues or questions, open an issue in the actor's repository
- Check [SIÁN Agency Store](https://apify.com/sian.agency?fpr=sian) for more automation tools
- 📧 <apify@sian-agency.online>

***

**Built by [SIÁN Agency](https://www.sian-agency.online)** | **[More Tools](https://apify.com/sian.agency?fpr=sian)**

# Actor input Schema

## `locations` (type: `array`):

📍 **US LOCATIONS TO ANALYZE.** Free-form — each entry is resolved server-side to a market region.

✅ **Accepted formats:**

- ZIP code — `78759`
- City — `Austin, TX`
- County — `Travis County, TX`
- Neighborhood — `Great Hills, Austin, TX`

💡 **TIP:** One dataset row is produced per location per enabled dataset below.

🔓 **TIER LIMITS:**

- **FREE users:** up to 5 locations per run
- **PAID users:** unlimited locations

## `includeMarketTrends` (type: `boolean`):

📈 **60 MONTHLY DATAPOINTS PER METRIC** — median sale price, homes sold, median days on market, sale-to-list ratio, % sold above list, % listings with price drops. Every point carries the value **and** the year-over-year change.

## `includeMarketHotness` (type: `boolean`):

🔥 **COMPETE SCORE (0–100)** with sale-to-list ratio, average days on market, typical number of offers, waived-contingency share — plus the same scores for nearby ZIP codes for instant comparison.

## `includeRecentlySold` (type: `boolean`):

🏠 **SOLD COMPS** — the most recently sold homes in the location (typically the 8 latest sales) with sold price, price per sqft, beds/baths, sqft, sold date, days on market, MLS number, coordinates, photos count and listing remarks — all inside ONE charged row per location.

## `includeSchools` (type: `boolean`):

🎓 **SCHOOL INTELLIGENCE** — elementary, middle and high schools serving the location with ratings (1–10), parent ratings, grade ranges, public/private type, student counts, student-teacher ratios and website links.

## `includeClimateRisk` (type: `boolean`):

🌊 **CLIMATE RISK** — flood, fire, heat and wind risk scores with properties-at-risk counts, regional vs national risk change, and deep links to the underlying risk reports.

## `includeNationalTrends` (type: `boolean`):

🇺🇸 **US-LEVEL SERIES** (one extra row per run): median sale price, homes sold, homes for sale, new listings, months of supply, days on market, demand ratios — plus the national average 30-year fixed mortgage rate, 60 monthly points each.

## `listingSignals` (type: `array`):

🎯 **PER-LISTING DEMAND INTEL.** One entry per active listing in the form `propertyId:listingId` (e.g. `31327561:217326962`).

🔎 **Where to get the IDs:** every row of our [Redfin Property Scraper](https://apify.com/sian.agency/redfin-property-scraper?fpr=sian) carries both `propertyId` and `listingId`.

📦 **Each pair returns ONE merged row:** tour insights (agent tour count, notes), popularity (home views vs the top-10% threshold, popular flag), and price-drop eligibility.

🔓 **TIER LIMITS:** FREE up to 5 pairs · PAID unlimited

## Actor input object example

```json
{
  "locations": [
    "Austin, TX",
    "78759"
  ],
  "includeMarketTrends": true,
  "includeMarketHotness": true,
  "includeRecentlySold": true,
  "includeSchools": false,
  "includeClimateRisk": false,
  "includeNationalTrends": false
}
```

# Actor output Schema

## `results` (type: `string`):

One row per location per dataset: 60-month trend series, Compete Score hotness, sold comps, school ratings, climate risk, national baseline, or per-listing demand signals.

## `scrapingSummary` (type: `string`):

HTML summary showing per-location and per-dataset row counts, errors, and run metrics.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "locations": [
        "Austin, TX",
        "78759"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("sian.agency/redfin-market-analytics-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "locations": [
        "Austin, TX",
        "78759",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("sian.agency/redfin-market-analytics-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "locations": [
    "Austin, TX",
    "78759"
  ]
}' |
apify call sian.agency/redfin-market-analytics-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=sian.agency/redfin-market-analytics-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Redfin Housing Market Data Scraper — Trends, Comps, Hotness",
        "description": "Pull US housing market data for any ZIP, city, or neighborhood: 60-month median sale price and demand trends, Compete Score market hotness, recently sold comps, school ratings, climate risk, and national trends. One structured row per location and dataset. Built for investors, analysts, and ETL.",
        "version": "1.0",
        "x-build-id": "0crJinZJQf60srRdm"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/sian.agency~redfin-market-analytics-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-sian.agency-redfin-market-analytics-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/sian.agency~redfin-market-analytics-scraper/runs": {
            "post": {
                "operationId": "runs-sync-sian.agency-redfin-market-analytics-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/sian.agency~redfin-market-analytics-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-sian.agency-redfin-market-analytics-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": {
                    "locations": {
                        "title": "📍 Locations (ZIP, City, County or Neighborhood)",
                        "uniqueItems": true,
                        "type": "array",
                        "description": "📍 **US LOCATIONS TO ANALYZE.** Free-form — each entry is resolved server-side to a market region.\n\n✅ **Accepted formats:**\n- ZIP code — `78759`\n- City — `Austin, TX`\n- County — `Travis County, TX`\n- Neighborhood — `Great Hills, Austin, TX`\n\n💡 **TIP:** One dataset row is produced per location per enabled dataset below.\n\n🔓 **TIER LIMITS:**\n- **FREE users:** up to 5 locations per run\n- **PAID users:** unlimited locations",
                        "default": [
                            "Austin, TX"
                        ],
                        "items": {
                            "type": "string"
                        }
                    },
                    "includeMarketTrends": {
                        "title": "📈 Market Trends (60-month series)",
                        "type": "boolean",
                        "description": "📈 **60 MONTHLY DATAPOINTS PER METRIC** — median sale price, homes sold, median days on market, sale-to-list ratio, % sold above list, % listings with price drops. Every point carries the value **and** the year-over-year change.",
                        "default": true
                    },
                    "includeMarketHotness": {
                        "title": "🔥 Market Hotness (Compete Score)",
                        "type": "boolean",
                        "description": "🔥 **COMPETE SCORE (0–100)** with sale-to-list ratio, average days on market, typical number of offers, waived-contingency share — plus the same scores for nearby ZIP codes for instant comparison.",
                        "default": true
                    },
                    "includeRecentlySold": {
                        "title": "🏠 Recently Sold Comps",
                        "type": "boolean",
                        "description": "🏠 **SOLD COMPS** — the most recently sold homes in the location (typically the 8 latest sales) with sold price, price per sqft, beds/baths, sqft, sold date, days on market, MLS number, coordinates, photos count and listing remarks — all inside ONE charged row per location.",
                        "default": true
                    },
                    "includeSchools": {
                        "title": "🎓 Schools & Ratings",
                        "type": "boolean",
                        "description": "🎓 **SCHOOL INTELLIGENCE** — elementary, middle and high schools serving the location with ratings (1–10), parent ratings, grade ranges, public/private type, student counts, student-teacher ratios and website links.",
                        "default": false
                    },
                    "includeClimateRisk": {
                        "title": "🌊 Climate Risk Scores",
                        "type": "boolean",
                        "description": "🌊 **CLIMATE RISK** — flood, fire, heat and wind risk scores with properties-at-risk counts, regional vs national risk change, and deep links to the underlying risk reports.",
                        "default": false
                    },
                    "includeNationalTrends": {
                        "title": "🇺🇸 National Trends Baseline",
                        "type": "boolean",
                        "description": "🇺🇸 **US-LEVEL SERIES** (one extra row per run): median sale price, homes sold, homes for sale, new listings, months of supply, days on market, demand ratios — plus the national average 30-year fixed mortgage rate, 60 monthly points each.",
                        "default": false
                    },
                    "listingSignals": {
                        "title": "🎯 Listing Demand Signals (propertyId:listingId pairs)",
                        "uniqueItems": true,
                        "type": "array",
                        "description": "🎯 **PER-LISTING DEMAND INTEL.** One entry per active listing in the form `propertyId:listingId` (e.g. `31327561:217326962`).\n\n🔎 **Where to get the IDs:** every row of our [Redfin Property Scraper](https://apify.com/sian.agency/redfin-property-scraper?fpr=sian) carries both `propertyId` and `listingId`.\n\n📦 **Each pair returns ONE merged row:** tour insights (agent tour count, notes), popularity (home views vs the top-10% threshold, popular flag), and price-drop eligibility.\n\n🔓 **TIER LIMITS:** FREE up to 5 pairs · PAID unlimited",
                        "items": {
                            "type": "string"
                        }
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
