Agents

The ZIP markets this agent works, blended

POST
/v1/agents/{id}/markets

Rank the ZIP markets one real-estate agent works, with volume, transaction counts and mean sale price per market, plus a weighted summary across the whole footprint. Optionally narrow to a ZIP list or a date window. REACH, NOT MARKET SHARE: an agent belongs to every market they touch — where their office is AND everywhere they have transacted — so one agent is counted in several markets at once. Per-market agent counts therefore over-sum: they cannot be added together, and dividing one into a total does not produce a market share. The only percentage returned, shareOfScope, is each market's share of this agent's volume across the scope requested and sums to 100 over that scope; there is no share-of-whole-book figure, because the transaction records carry no per-agent total to divide by. TWO COUNTS, ON PURPOSE: transactions counts transaction records; units counts the ones carrying a price, which are the records behind volume and avgSalePrice. Roughly half of an agent's records are priced, so dividing volume by transactions understates the average by about 2×. Figures are computed live from the agent's transaction records — an agent record carries no stored market rollup — and are ranked across their busiest ZIP markets. When a ZIP scope returns no markets, reach.presentInScope distinguishes 'works there, nothing closed in the window' from 'not present at all'. The summary also carries a Community Lending mix: what kind of neighborhood these markets are, weighted by the agent's activity in each. These are U.S. Census tract-level aggregates describing whole neighborhoods — never an individual, household or client attribute — and on this surface the basis is always the markets in scope, since an agent record carries no stored neighborhood rollup.

Authorization

x-api-key<token>

In: header

Path Parameters

id*string

Agent ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/agents/string/markets" \  -H "Content-Type: application/json" \  -d '{}'
{
  "data": {
    "agentId": "string",
    "basis": "reach",
    "markets": [
      {
        "avgSalePrice": 0,
        "shareOfScope": 0,
        "transactions": 0,
        "units": 0,
        "volume": 0,
        "zipCode": "string"
      }
    ],
    "notes": [
      "string"
    ],
    "reach": {
      "presentInScope": true,
      "transactedInScope": true,
      "zipCodesRequested": [
        "string"
      ]
    },
    "source": {
      "mode": "live",
      "reasons": [
        "string"
      ]
    },
    "summary": {
      "avgSalePrice": 0,
      "communityLending": {
        "affordableHousingTractPct": 0,
        "basis": "entityRollup",
        "coveredProductionPct": 0,
        "difficultDevelopmentAreaPct": 0,
        "distressedTractPct": 0,
        "floodHazardTractPct": 0,
        "incomeLevelMix": {
          "low": 0,
          "middle": 0,
          "moderate": 0,
          "upper": 0
        },
        "loansWithCommunityData": 0,
        "lowModIncomeTractPct": 0,
        "majorityMinorityTractPct": 0,
        "marketsInScope": 0,
        "marketsWithCommunityData": 0,
        "opportunityZonePct": 0,
        "predominantIncomeLevel": "low",
        "ruralTractPct": 0,
        "usdaEligibleTractPct": 0
      },
      "marketCount": 0,
      "shareOfBook": null,
      "transactions": 0,
      "units": 0,
      "unresolved": {
        "transactions": 0,
        "units": 0,
        "volume": 0
      },
      "volume": 0
    }
  }
}
{
  "error": "string"
}
{
  "error": "string"
}
{
  "error": "string"
}
{
  "error": "string"
}
{
  "error": "string",
  "limit": 0,
  "size": 0
}