> For the complete documentation index, see [llms.txt](https://docs.term.finance/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.term.finance/protocol/term-repos/defaults.md). Agents can also search and read this documentation through its [MCP server](https://docs.term.finance/~gitbook/mcp).

# Defaults

Default occurs when a borrower (i) fails to maintain sufficient margin or (ii) fails to repurchase on time (or within the repurchase window).

Default occurs when a borrower (1) fails to maintain sufficient margin or (2) fails to repurchase its collateral tokens within the repayment window.

<details>

<summary>Margin deficit</summary>

A margin deficit occurs when the value of a borrower's collateral is no longer sufficient to meet the [maintenance margin ratio](https://docs.term.finance/protocol/term-repos/terminology.md#maintenance-margin-ratio). The protocol tracks this by monitoring a borrower's [transaction exposure](https://docs.term.finance/protocol/term-repos/conventions.md#transaction-exposure), which is calculated as follows:

$$\text{transactionExposure} = \text{maintenanceMarginRatio}\*\text{repurchasePrice}-\text{collateralMarketValue}$$

where the [collateral market value ](https://docs.term.finance/protocol/term-repos/terminology.md#collateral-market-value)is measured in real-time using [Chainlink oracle price feeds](https://data.chain.link/). Where a borrower's [Transaction Exposure ](https://docs.term.finance/protocol/term-repos/terminology.md#transaction-exposure)is negative, their collateral is eligible for [liquidation](https://docs.term.finance/protocol/term-repos/defaults/liquidation.md).

</details>

<details>

<summary>Failure to repurchase</summary>

The repurchase date marks the maturity date of a Term Repo. Borrowers are required to repurchase their collateral tokens on the repurchase date and they must do so within the [repurchase window](https://docs.term.finance/protocol/term-repos/terminology.md#repurchase-window), which typically lasts 12 to 24 hours from the repurchase date. Failure to do so means that the borrower is in default and their collateral is eligible for [liquidation](https://docs.term.finance/protocol/term-repos/defaults/liquidation.md).

</details>
