Skip to main content
Glama

mtgmon Mortgage Analytics

HMDA product analytics

get_hmda_product_analytics
Read-onlyIdempotent

HMDA origination counts, reported dollar amounts, averages, and year-over-year growth for one product family, optionally for one property state or one lender, with an annual history back to 2018.

Use for: HELOC, reverse-mortgage, or closed-end mortgage origination volume and growth; product mix by loan program (conventional/FHA/VA/USDA), purpose, lien, occupancy, construction method, or business purpose; state-level or lender-level product questions. Do not use for: lender rankings or market share (search_lenders / get_lender_profile) or GSE loan performance (get_loan_performance).

Important: product_family defaults to 'heloc'. Use 'closed_end_mortgage' for ordinary mortgages or 'all' for every HMDA origination. Source is the frozen annual FFIEC/CFPB HMDA Snapshot LAR (one release per year, 2018 onward); state filters use the property state, not the lender's headquarters.

Returns data.selected_year, data.current and data.previous (each {year, origination_count, reported_amount_count, reported_amount_sum, average_reported_amount, reported_amount_max, origination_count_yoy_pct, reported_amount_sum_yoy_pct, average_reported_amount_yoy_pct}), data.history (one such row per year), data.filters (applied filters), data.definition, and data.source_releases. Amounts are USD; YoY fields are percent; for HELOCs the amount is credit available, not the drawn balance.

Behavior: read-only, no auth or API key, no PII, idempotent and safe to retry. The public endpoint https://mtgmon.com/mcp allows about 60 requests/min and 250 tool calls/day per client IP. Result shape is {data, meta}; meta carries available, as_of, source_scope, weighting, units, cache_status, caveats, and truncated. If meta.available is false, never report it as zero: retry after a few seconds only when meta.cache_status is 'miss' (warming); otherwise report the data as unavailable.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_hmda_product_analytics"
  }
}

Input Schema

NameRequiredDescriptionDefault
yearNoHMDA activity year, 2018 or later. Default: latest published Snapshot year (see data.selected_year).
stateNoTwo-letter USPS code of the property state, e.g. 'TX' (not the lender HQ). Empty (default) = nationwide.
lenderNoCanonical HMDA lender key: the exact `name` value from a search_lenders result, e.g. 'Rocket/Quicken' or 'United Wholesale Mortgage'. Legal names such as 'Rocket Mortgage, LLC' do not match and return meta.available=false. Default: all lenders.
loan_programNo'all' (default), 'conventional', 'fha', 'va', 'usda_rhs', or 'unknown'.all
loan_purposeNo'all' (default), 'purchase', 'home_improvement', 'refinance' (rate/term), 'cash_out_refinance', 'other', 'not_applicable', or 'unknown'.all
lien_positionNo'all' (default), 'first', 'subordinate', 'not_secured', 'not_applicable', or 'unknown'.all
occupancy_typeNo'all' (default), 'principal_residence', 'second_residence', 'investment_property', or 'unknown'.all
product_familyNo'heloc' (DEFAULT: open-end lines of credit that are not reverse mortgages), 'closed_end_mortgage' (ordinary first and second mortgages), 'reverse_mortgage', 'unclassified_or_exempt', or 'all' (every HMDA origination). Set this explicitly; the default is not the whole market.heloc
business_purposeNo'all' (default: consumer + business + exempt/unknown records), 'consumer', 'business', or 'exempt_unknown'.all
credit_structureNo'all' (default), 'open_end', 'closed_end', or 'exempt_unknown'. Usually leave 'all'; product_family already implies it.all
construction_methodNo'all' (default), 'site_built', 'manufactured', or 'unknown'.all
reverse_mortgage_statusNo'all' (default), 'reverse', 'not_reverse', or 'exempt_unknown'. Usually leave 'all'; product_family already implies it.all

Output Schema

NameRequiredDescriptionDefault
dataNo
metaYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / $defs / ResultMeta / properties / cache_status / description
      Added value: +"Server cache state: hit; stale (older than its TTL, still served); stale-refresh; miss (warming, retry after a few seconds); failed or required-miss (not available now, a retry soon will not help); none; unknown."
  2. Changed12 schema fields changed
    • addedInput schema / properties / business_purpose / description
      Added value: +"'all' (default: consumer + business + exempt/unknown records), 'consumer', 'business', or 'exempt_unknown'."
    • addedInput schema / properties / construction_method / description
      Added value: +"'all' (default), 'site_built', 'manufactured', or 'unknown'."
    • addedInput schema / properties / credit_structure / description
      Added value: +"'all' (default), 'open_end', 'closed_end', or 'exempt_unknown'. Usually leave 'all'; product_family already implies it."
    • addedInput schema / properties / lender / description
      Added value: +"Canonical HMDA lender key: the exact `name` value from a search_lenders result, e.g. 'Rocket/Quicken' or 'United Wholesale Mortgage'. Legal names such as 'Rocket Mortgage, LLC' do not match and return meta.available=false. Default: all lenders."
    • addedInput schema / properties / lien_position / description
      Added value: +"'all' (default), 'first', 'subordinate', 'not_secured', 'not_applicable', or 'unknown'."
    • addedInput schema / properties / loan_program / description
      Added value: +"'all' (default), 'conventional', 'fha', 'va', 'usda_rhs', or 'unknown'."
    • addedInput schema / properties / loan_purpose / description
      Added value: +"'all' (default), 'purchase', 'home_improvement', 'refinance' (rate/term), 'cash_out_refinance', 'other', 'not_applicable', or 'unknown'."
    • addedInput schema / properties / occupancy_type / description
      Added value: +"'all' (default), 'principal_residence', 'second_residence', 'investment_property', or 'unknown'."
    • addedInput schema / properties / product_family / description
      Added value: +"'heloc' (DEFAULT: open-end lines of credit that are not reverse mortgages), 'closed_end_mortgage' (ordinary first and second mortgages), 'reverse_mortgage', 'unclassified_or_exempt', or 'all' (every HMDA origination). Set this explicitly; the default is not the whole market."
    • addedInput schema / properties / reverse_mortgage_status / description
      Added value: +"'all' (default), 'reverse', 'not_reverse', or 'exempt_unknown'. Usually leave 'all'; product_family already implies it."
    • addedInput schema / properties / state / description
      Added value: +"Two-letter USPS code of the property state, e.g. 'TX' (not the lender HQ). Empty (default) = nationwide."
    • addedInput schema / properties / year / description
      Added value: +"HMDA activity year, 2018 or later. Default: latest published Snapshot year (see data.selected_year)."
  3. Added

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already cover read-only, idempotent, non-destructive and open-world, yet the description adds rate limits (roughly 60 req/min, 250 calls/day per IP), no-auth/no-PII status, the frozen annual Snapshot source, the {data, meta} envelope, and a precise unavailable-vs-zero rule with retry conditions. That is materially more than the annotations convey.

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?

Front-loaded with purpose, then clearly partitioned into use/don't-use/important/returns/behavior blocks, and every block carries information an agent needs. Some length is unavoidable for a 12-parameter tool, though the product_family default is restated in both the description and the schema.

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 wide, 12-parameter, enum-heavy analytics tool this covers the gaps that matter: source vintage, unit conventions, filters applied, meta.available semantics, and retry policy. Despite an output schema existing, the field-by-field return listing still helps an agent formulate a correct answer without opening it.

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 100%, so the baseline is 3; the description earns above that by stressing the non-obvious product_family default, clarifying that state filters on property state rather than lender HQ, and explaining that HELOC amounts represent credit available rather than drawn balance. The lender-key caveat lives in the schema rather than the description, so it is not fully redundant-free at a 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?

The opening sentence names a specific verb-and-resource pair (HMDA origination counts, amounts, averages, YoY growth) and states the scoping dimensions (one product family, optional state or lender, annual history back to 2018). It also names the siblings it is not — search_lenders / get_lender_profile for rankings and get_loan_performance for GSE performance.

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?

Explicit 'Use for' and 'Do not use for' sections, the latter routing each excluded question to a named alternative. It further warns that product_family defaults to 'heloc' rather than the whole market, which is exactly the kind of trap that would cause a mis-call.

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