> For the complete documentation index, see [llms.txt](https://docs.altum.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.altum.ai/english/financing/mortgage-calculation-api/authentication-input-and-response.md).

# Authentication, input and response

### Calculate Mortgage for a Dutch Residential Property

{% tabs %}
{% tab title="v1" %} <mark style="color:$success;">**`POST`**</mark> `https://api.altum.ai/v1/mortgage-calculator`

#### Headers

<table><thead><tr><th width="258.1484375">Name</th><th width="199.80078125">Type</th><th>Description</th></tr></thead><tbody><tr><td>x-api-key<mark style="color:red;">*</mark></td><td>string</td><td>Unique API Key from Altum. Create one via Mopsus (https://mopsus.altum.ai)</td></tr><tr><td>Content-Type</td><td>string</td><td>application/json</td></tr></tbody></table>

#### Request Body

<table><thead><tr><th width="252.66796875">Name</th><th width="199.78125">Type</th><th>Description</th></tr></thead><tbody><tr><td>postcode</td><td>string</td><td>Zipcode of the object in 4-digit + 2-letter format (e.g. "1234AB")</td></tr><tr><td>housenumber</td><td>number</td><td>House number of the object</td></tr><tr><td>houseaddition</td><td>string</td><td>House letter and addition of the object</td></tr><tr><td>gross_annual_income<mark style="color:red;">*</mark></td><td>number</td><td>Primary applicant's gross annual income (in €)</td></tr><tr><td>partner_gross_income</td><td>number</td><td>Partner's gross annual income (in €). Defaults to 0</td></tr><tr><td>applicant_type</td><td>string</td><td>"single" or "couple". Affects the €17,000 single-applicant bonus. Defaults to "single"</td></tr><tr><td>existing_debts</td><td>number</td><td>Monthly existing debt obligations (in €). Reduces borrowable amount. Defaults to 0</td></tr><tr><td>student_loan</td><td>number</td><td>Monthly student loan payment (in €). Reduces borrowable amount. Defaults to 0</td></tr><tr><td>interest_rate</td><td>number</td><td>Annual interest rate as a percentage (e.g. 3.5 for 3.5%)</td></tr><tr><td>mortgage_type<mark style="color:red;">*</mark></td><td>string</td><td>"annuity" or "linear"</td></tr><tr><td>loan_term_years<mark style="color:red;">*</mark></td><td>number</td><td>Loan term in years. Maximum is 30</td></tr><tr><td>purchase_price</td><td>number</td><td>Purchase price (in €). Used as market value if address enrichment cannot find a WOZ value.p</td></tr><tr><td>down_payment</td><td>number</td><td>Own funds to reduce principal (in €). Defaults to 0</td></tr><tr><td>fixed_rate_period</td><td>number</td><td>Years the interest rate is fixed</td></tr><tr><td>nhg_eligible</td><td>boolean</td><td>Whether NHG applies. If omitted, derived automatically: true when purchase price ≤ €470,000</td></tr><tr><td>first_time_buyer</td><td>boolean</td><td>True if the primary applicant is a first-time buyer. Affects transfer tax. Defaults to false</td></tr><tr><td>applicant_age</td><td>number</td><td>Primary applicant age. Required for first-time buyer transfer tax exemption</td></tr><tr><td>partner_age</td><td>number</td><td>Partner age, Required for first-time buyer transfer tax exemption if it's couple </td></tr><tr><td>energy_label</td><td>string</td><td>Energy label of the property (E/F/G/C/D/A/B/A+/A++/A+++/A++++/A++++_warranty). Affects extra mortgage amount and NHG limit</td></tr><tr><td>sustainability_measures</td><td>boolean</td><td>True if sustainability measures from the TRHK list are included in the mortgage. Affects renovation bonus and NHG limit. Defaults to false</td></tr><tr><td>table_type</td><td>string</td><td>Nibud DSTI table to use. One of: "non_aow_box1" (default), "aow_box1", "non_aow_box3", "aow_box3"</td></tr></tbody></table>

{% tabs %}
{% tab title="200: OK Successful response" %}

```json
{
	"postcode": "9636AA",
	"housenumber": 5,
	"houseaddition": null,
	"max_mortgage_amount": 378000.0,
	"max_mortgage_by_income": 385248.93,
	"principal": 378000.0,
	"monthly_payment_gross": 1731.33,
	"monthly_payment_net": 1299.22,
	"total_interest_paid": 245278.39,
	"total_costs": 633038.39,
	"transfer_tax": 7560.0,
	"transfer_tax_rate_used": 0.02,
	"affordability_ratio": 0.2597,
	"nhg_compliance": true,
	"rate_used": 3.66,
	"rate_fetched_from": "dnb",
	"effective_rate_used": 3.66,
	"loan_term_years": 30,
	"mortgage_type": "annuity",
	"dsti_ratio_used": 0.253,
	"table_type_used": "non_aow_box1",
	"single_bonus_applied": 17000.0,
	"energy_label_bonus": 0.0,
	"renovation_bonus": 0.0,
	"debt_deduction_applied": 0.0,
	"data_enrichment_status": "enriched",
	"enrichment_data": {
		"found": true,
		"woz_latest": 378000.0,
		"woz_latest_year": 2024,
		"energy_label": "F"
	},
	"warnings": [
		"Income allows a higher mortgage, but you are capped at the NHG mortgage cap of €450,000."
	],
	"metadata": {
		"table_type": "non_aow_box1",
		"dsti_ratio_used": 0.253,
		"effective_rate_used": 3.66,
		"nhg_price_limit": 470000,
		"nhg_mortgage_cap": 450000.0,
		"energy_label_bonus": 0.0,
		"renovation_bonus": 0.0,
		"single_bonus_applied": 17000.0,
		"mortgage_interest_deduction_rate": 0.3748,
		"notary_cost": 1500.0,
		"appraisal_cost": 700.0,
		"market_value_source": "woz",
		"market_value_used": 378000.0,
		"market_value_note": "WOZ used — no purchase_price provided",
		"evaluation_date": "20260510"
	}
}
```

{% endtab %}

{% tab title="400: Bad Request" %}

```json
{
  "error": "Unable to process mortgage calculation at this time."
}
```

{% endtab %}

{% tab title="401: Unauthorized" %}

```json
{
  "output": "Please use https://api.altum.ai or visit https://mopsus.altum.ai to make your request."
}
```

{% endtab %}

{% tab title="403: Forbidden" %}

```json
{
  "message": "Forbidden"
}
```

{% endtab %}

{% tab title="500: Internal Server Error Service is not available and/or down" %}

```json
{
  "message": "Internal server error"
}
```

{% endtab %}

{% tab title="422: Unprocessable Entity" %}

```json
{
  "detail": [
    {
      "type": "value_error",
      "msg": "applicant_type must be \"single\" or \"couple\"."
    }
  ]
}
```

{% endtab %}
{% endtabs %}

### Request body

#### Example Request

```json
{
  "postcode": "9636AA",
  "housenumber": 5,
  "gross_annual_income": 80000,
  "mortgage_type": "annuity",
  "loan_term_years": 30
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.altum.ai/english/financing/mortgage-calculation-api/authentication-input-and-response.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
