Before you start
- Get an API keySign up for 100 free credits, no card. Keys start with
gs_live_. - Put it in the environmentEvery example reads it from
GROUNDSOCIAL_API_KEY:export GROUNDSOCIAL_API_KEY=gs_live_… - Set up JavaScript
node --version # 18 or newer: fetch is built in, nothing to install
Call Search Redfin homes API from JavaScript
GET /v1/redfin/search. Save this as main.mjs and run node main.mjs. It reads the items in homes and prints price.value for each.
// main.mjs: Node.js 18+, no dependencies
const url = new URL('https://api.groundsocial.dev/v1/redfin/search')
url.searchParams.set('location', '78704')
const res = await fetch(url, {
headers: {
Authorization: `Bearer ${process.env.GROUNDSOCIAL_API_KEY}`,
},
signal: AbortSignal.timeout(60_000),
})
if (!res.ok) {
const { error } = await res.json()
throw new Error(`${error.code}: ${error.hint ?? error.message}`)
}
const data = await res.json()
for (const item of data.homes) {
console.log(item.price?.value)
}
console.log('credits charged:', res.headers.get('x-credits-charged'))The response
A real Redfin response to this call, recorded from the live API on 27 Nov 2026 and shortened for display: arrays keep their first items and … marks every cut. The recorded page had 100 items in homes. Live calls return current data in the same shape.
{
"homes": [
{
"propertyId": 31203978,
"listingId": 228228624,
"url": "/TX/Austin/1401-Kinney-Ave-78704/home/31203978",
"price": {
"value": 2450000,
"level": 1
},
"beds": 4,
"baths": 3.5,
"sqFt": {
"value": 3363,
"level": 1
},
"city": "Austin",
"state": "TX",
"zip": "78704",
"mlsStatus": "Active",
"uiPropertyType": 1,
"mlsId": {
"label": "MLS#",
"value": "7388941"
},
"showMlsId": false,
"showDatasourceLogo": false,
"hideSalePrice": false,
"hoa": {
"level": 1
},
"isHoaFrequencyKnown": true,
"pricePerSqFt": {
"value": 729,
"level": 1
},
"lotSize": {
"value": 6359,
"level": 1
},
"fullBaths": 3,
"partialBaths": 1,
"location": {
"value": "Templer J W",
"level": 1
},
"stories": 3,
"…": "43 more fields"
},
{
"propertyId": 31176417,
"listingId": 228368721,
"url": "/TX/Austin/2525-S-Lamar-Blvd-78704/unit-302/home/31176417",
"price": {
"value": 475000,
"level": 1
},
"beds": 2,
"baths": 1,
"sqFt": {
"value": 942,
"level": 1
},
"city": "Austin",
"state": "TX",
"zip": "78704",
"mlsStatus": "Coming Soon",
"uiPropertyType": 2,
"mlsId": {
"label": "MLS#",
"value": "2245952178588426409"
},
"showMlsId": false,
"showDatasourceLogo": false,
"hideSalePrice": false,
"hoa": {
"level": 1
},
"isHoaFrequencyKnown": true,
"pricePerSqFt": {
"value": 504,
"level": 1
},
"lotSize": {
"level": 1
},
"location": {
"value": "Low Theodore Heights",
"level": 1
},
"latLong": {
"value": {
"latitude": 30.2459322,
"longitude": -97.7772561
},
"level": 1
},
"streetLine": {
"value": "2525 S Lamar Blvd #302",
"level": 1
},
"unitNumber": {
"value": "#302",
"level": 1
},
"…": "39 more fields"
},
"… 98 more"
],
"region": {
"region_id": 34098,
"region_type": 2
},
"searchMedian": {
"price": 950000,
"sqFt": 1736,
"pricePerSqFt": 588,
"dom": 23,
"beds": 3,
"baths": 2.5
},
"dataSources": []
}Top-level fields
| Field | Type | Description |
|---|---|---|
homes | RedfinHome[] | – |
region | object | null | The Redfin region searched, or null for a map box search. |
searchMedian | object | null | Redfin’s medians for the search: price, sqFt, price per sqFt, beds, baths, DOM. |
dataSources | object[] | The MLSs the listings come from. |
Parameters
| Name | In | Type | Description |
|---|---|---|---|
url | query | string | A Redfin search link. Example: https://www.redfin.com/city/30818/TX/Austin. |
location | query | string | A ZIP code (or a Redfin search link). Example: 78704. |
region_id | query | integer | – |
region_type | query | integer | 1 neighborhood, 2 ZIP code, 5 county, 6 city, 11 school district. |
map_bounds | query | string | A map box, west,south,east,north in degrees. |
status | query | "for_sale" | "sold" | Default for_sale. One of for_sale, sold. |
sold_within_days | query | integer | With status sold: how far back (default 90). |
property_type | query | string | Comma-separated: house, condo, townhouse, multi_family, land, other, manufactured, co_op. Default all. |
sort | query | "recommended" | "newest" | "price_asc" | "price_desc" | "sqft" | Default recommended. One of recommended, newest, price_asc, price_desc, sqft. |
price_min | query | integer | null | Minimum price, USD. |
price_max | query | integer | null | Maximum price, USD. |
beds_min | query | integer | null | – |
beds_max | query | integer | null | – |
baths_min | query | number | null | – |
sqft_min | query | integer | null | Minimum living area, square feet. |
sqft_max | query | integer | null | Maximum living area, square feet. |
limit | query | integer | – |
Errors and retries
Every error is JSON with error.code (stable: branch on it), message, hint (what to do next), docs_url and retryable. A failed call is never charged. Retry only when retryable is true, after the Retry-After header.
async function call(url, init = {}, attempt = 0) {
const res = await fetch(url, {
...init,
headers: { Authorization: `Bearer ${process.env.GROUNDSOCIAL_API_KEY}`, ...init.headers },
signal: AbortSignal.timeout(60_000),
})
if (res.ok) return res.json()
const { error } = await res.json()
// Branch on error.code (stable); error.hint says what to do next.
if (error.retryable && attempt < 2) {
const wait = Number(res.headers.get('retry-after') ?? 2)
await new Promise((r) => setTimeout(r, wait * 1000))
return call(url, init, attempt + 1)
}
throw Object.assign(new Error(error.hint ?? error.message), { code: error.code })
}| Status | Meaning |
|---|---|
200 | Homes in the area. |
400 | Invalid input. Nothing was charged. |
401 | Missing or invalid API key. |
402 | Not enough credits, a spend cap was reached, or payment is required. |
403 | The target is private, or the account is suspended. |
404 | No Redfin property or ZIP code by that id. |
429 | Too many requests. Wait for Retry-After seconds. |
503 | Redfin is temporarily unavailable. Retryable; nothing was charged. |
Every error code and what to do about it.
Pricing
| Cost | |
|---|---|
| Per call | 1 credit per call |
| 1,000 calls | $1.00 on the starter pack, $0.40 at volume |
| No key (MPP or x402) | $0.01 per call |
| Failed call | Refunded, never charged |
Every response has x-credits-charged and x-credits-remaining headers. Credits never expire. Packs and calculator.
From an AI agent (MCP)
The same call is the redfin_search_all tool on the hosted MCP server, so Claude, Cursor or any MCP client can make it without code. Add the server once:
claude mcp add --transport http groundsocial https://api.groundsocial.dev/mcpThen ask for it in words (“Redfin homes for sale or sold in a region or map box, with filters (up to 350)”), or call the tool directly:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "redfin_search_all",
"arguments": {
"location": "78704"
}
}
}MCP setup for Claude Desktop, Cursor, VS Code and ChatGPT.
Use Redfin search all in a pipeline
Homes for_sale (default, incl. coming soon) or sold (within sold_within_days, default 90) in an area: url (a Redfin search link such as https://www.redfin.com/city/30818/TX/Austin/filter/min-beds=3; its /filter/ part is applied), location (a ZIP code), region_id + region_type, or map_bounds (west,south,east,north).
Keep going
- This call in Python, TypeScript, Go, PHP, cURL.
- Search Redfin homes API reference: every field and status code.
- Redfin tutorials and all JavaScript tutorials.
- Redfin API: every endpoint and price.
- How to get a Redfin property with JavaScript: One Redfin property: facts, listing, estimate, parcel and walk/transit scores.
Run it on your own data
One key for Redfin and 76 more platforms, over REST or MCP. Free credits on signup, no card.
Redfin is a trademark of its owner. We are not affiliated with or endorsed by it.