Docs · Model reference
second-home
Verified · spec v1.1.0Inputs
| Field | Type | Valid domain |
|---|---|---|
| purchasePrice | float | 100,000 – 2,000,000 |
| downPaymentPct | float | 0.1 – 0.5 |
| mortgageRate | float | 0.03 – 0.12 |
| mortgageTerm | int | 15 – 30 |
| propertyTaxRate | float | 0.005 – 0.025 |
| insuranceAnnual | float | 500 – 10,000 |
| maintenancePct | float | 0.005 – 0.03 |
| rentalIncomeMonthly | float | 0 – 10,000 |
| occupancyRate | float | 0 – 1 |
| appreciationRate | float | 0.01 – 0.1 |
| annualReturn | float | 0.02 – 0.12 |
| yearsHorizon | int | 5 – 30 |
All fields required. Out-of-domain values are rejected with per-field errors — never clamped. Unknown fields are rejected.
Sentinel values
breakEvenYears=999→ never — NOI ≤ 0 can never recover the down payment
Responses annotate these in a sentinels array with a triggered flag per run.
Live example — generated from the real engine
Request
POST /api/v1/models/second-home
{
"purchasePrice": 1050000,
"downPaymentPct": 0.3,
"mortgageRate": 0.08,
"mortgageTerm": 23,
"propertyTaxRate": 0.02,
"insuranceAnnual": 5300,
"maintenancePct": 0.02,
"rentalIncomeMonthly": 5000,
"occupancyRate": 0.5,
"appreciationRate": 0.06,
"annualReturn": 0.07,
"yearsHorizon": 18
}Response (chart arrays compacted)
{
"ok": true,
"model": "second-home",
"specVersion": "1.1.0",
"contractUrl": "/api/v1/models/second-home",
"specUrl": "/api/v1/models/second-home/spec",
"inputs": {
"purchasePrice": 1050000,
"downPaymentPct": 0.3,
"mortgageRate": 0.08,
"mortgageTerm": 23,
"propertyTaxRate": 0.02,
"insuranceAnnual": 5300,
"maintenancePct": 0.02,
"rentalIncomeMonthly": 5000,
"occupancyRate": 0.5,
"appreciationRate": 0.06,
"annualReturn": 0.07,
"yearsHorizon": 18
},
"outputs": {
"downPayment": 315000,
"monthlyMortgage": 5831.876512940142,
"monthlyCarryingCost": 9773.543179606808,
"monthlyRentalIncome": 2500,
"monthlyNetCost": 7273.543179606808,
"capRate": -0.016476190476190478,
"breakEvenYears": 999,
"homeValueAtHorizon": 2997056.1105584637,
"equityAtHorizon": 2709437.097533424,
"opportunityCost": 1064678.6668557497,
"netWealthImpact": 73673.10388260381
},
"sentinels": [
{
"field": "breakEvenYears",
"value": 999,
"meaning": "never — NOI ≤ 0 can never recover the down payment",
"triggered": true
}
],
"assumptions": [
"Implements model spec second-home v1.1.0 (dual-implementation verified)."
],
"facts": [],
"record": {
"sha256": "d06fddf339a111f95380d7db6e731276b8884ac4f189c458f3fd2fa5e7e8d052",
"fields": [
"model",
"specVersion",
"inputs",
"outputs"
],
"howToVerify": "Store this record with any advice or agent output built on these numbers. To verify later: build {model, specVersion, inputs, outputs} from the stored response, serialize as JSON with object keys sorted recursively (no whitespace), and SHA-256 it — a match proves the numbers came from this spec version with these inputs, unaltered."
},
"disclaimer": "Illustrative planning model, not financial advice. Outputs follow the published model spec exactly; read the spec for assumptions and exclusions before relying on any number."
}This example is executed against the production engine when the page builds — it cannot drift from the API's real behavior.