Skip to main content
Glama

Homesage.ai MCP

Get Sold Count by ZIP

get_sold_count_by_zip
Read-only

What it returns

Just the count of residential properties sold in a ZIP within the last 365 days. Same dedup + recency rules as sold-by-zip, but only the integer count — useful when you don't need the property details and want to minimize cost.

When to use it

  • Display market velocity in a header widget (no need to render rows).

  • Drive a chart of monthly sales trend across many ZIPs cheaply.

  • Pre-check whether a ZIP has enough comp activity before calling sold-by-zip.

Date range

By default the endpoint returns the full trailing 365 days. Pass start_date, end_date, or both (YYYY-MM-DD) to narrow that to a specific window — for example one calendar month at a time instead of re-pulling the whole year on every poll:

?zip=95630&start_date=2026-08-01&end_date=2026-08-31

Both bounds are optional and inclusive, and both are independent: pass only start_date for an open-ended window, or only end_date to cut off recent sales. Passing neither leaves existing behaviour unchanged.

Either bound must fall within the last 365 days. An older date returns 400 naming the earliest date we can serve, rather than quietly returning a partial set.

Property type

Pass property_type (one value or a comma-separated list, same values as sold-by-zip) to count only those types:

?zip=65802&property_type=single_family

Omitting it counts every type. Unknown values return 400.

Pricing

1 credit per call regardless of the count.

FAQ

What's the difference between this and sold-by-zip?

This returns one integer (1 credit). sold-by-zip returns the full list (1 credit per 20 properties). Use this for cost-efficient screening; use sold-by-zip when you need details.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "zip": "<zip>"
    },
    "name": "get_sold_count_by_zip"
  }
}

Input Schema

NameRequiredDescriptionDefault
zipYes5-digit US ZIP code.
end_dateNoLatest sale date to include, as `YYYY-MM-DD`. Optional — omit for no upper bound. Inclusive: a sale on this exact date is returned. Must be on or after `start_date` and within the last 365 days.
start_dateNoEarliest sale date to include, as `YYYY-MM-DD`. Optional — omit for the full 365-day window. Inclusive: a sale on this exact date is returned. Must fall within the last 365 days; anything older returns `400`, since that is the whole window we retain.
property_typeNoCount only these property types. One value or a comma-separated list, e.g. `single_family` or `single_family,townhomes`. Optional — omit for every type. Values are the ones the response's `property_type` field carries, chiefly `single_family`, `condos`, `townhomes`, `multi_family`, `apartment`, `mobile`, `duplex_triplex`, `coop`, `condo`, `land`, `farm`, `other`. Case-insensitive; `-` and spaces are read as `_`. An unknown value returns `400` listing the full accepted set.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well beyond the readOnly/destructive/openWorld annotations: it discloses cost (1 credit per call regardless of count), the 400 error behavior for out-of-window dates, the dedup + recency rules shared with `sold-by-zip`, and the 365-day retention ceiling. It doesn't describe the shape of the returned count object, but an output schema exists to carry that.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Strongly front-loaded with "What it returns" before usage, cost, and edge cases, and headers make it skimmable. It is longer than needed for a 4-parameter tool — the date-range and property-type sections restate schema text, and the closing FAQ repeats the comparison already made in the opening.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a low-complexity read tool with annotations covering the safety profile and an output schema covering the return value, everything an agent needs is present: cost, error semantics, date-window limits, and type filtering. No material gap remains.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so the baseline is 3. The description still adds value by stressing that `start_date` and `end_date` are independent and both inclusive, giving a worked URL example, and enumerating accepted `property_type` values with the case/`-`/space normalization rule. Much of this duplicates the schema, so it doesn't reach 5.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a precise statement of the resource and exact scope: "Just the count of residential properties sold in a ZIP within the last 365 days." It explicitly distinguishes itself from the sibling `sold-by-zip`/`get_sold_properties_by_zip`, which returns full property rows, so an agent can pick between them without opening either schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides an explicit when-to-use list (header widget, cheap chart across many ZIPs, pre-check before calling `sold-by-zip`) and names the alternative with the condition that selects it (cost-efficient screening vs. needing details). The FAQ reinforces the routing rule with concrete credit economics.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources