# Borrow & Repay

### <mark style="color:orange;">Preliminaries on Morpho Vaults and Curators</mark>

* Morpho Vaults are smart contracts that accept deposits of a single loan asset (e.g., USDC, WETH).
* **Curators** (e.g., Steakhouse, Gauntlet) manage the vault's strategy, dynamically allocating funds to Morpho markets based on risk and yield potential.
* Each market consists of one loan asset and one collateral asset, and the collateral asset must be ERC-20 compliant. Curators can choose which asset is used as the collateral.

<figure><img src="/files/zbaTfVHRdTkkIbzkY9gh" alt=""><figcaption></figcaption></figure>

### <mark style="color:orange;">Borrow Flow</mark>

**(i) Supply BTC as Collateral**

A Borrower is required to supply their Bitcoin (BTC) into a dedicated Bitcoin-native Vault, designated as the Optimex Collateral Vault. This vault is implemented as a 2-of-2 multi-signature (multisig) address on the Bitcoin network. The two required signers are the Borrower and the Validation Network.

If liquidation becomes necessary, it will be executed through Optimex Swap, with liquidators selected from the Market Makers already onboarded onto Optimex Swap.\
Additionally, the Borrower must provide pre-signed transactions that authorize the expenditure of the BTC within the vault by the appointed liquidators.

**(ii) Mint oBTC Accounting Token**

Operationally, the state of the Optimex Collateral Vault is mirrored on the Ethereum network via an accounting token called **oBTC**. This oBTC token represents the locked BTC and interfaces directly with the Morpho Market (implemented as a smart contract), serving as the collateral asset within that market.

Once the Validation Network confirms the successful BTC supply on the Bitcoin network and validates the Borrower’s pre-signed signatures, they mint a corresponding amount of oBTC.\
This newly minted oBTC is then supplied to the Morpho lending market, enabling the Borrower to obtain a USDC loan.

**(iii) Draw USDC Loan**

After the Borrower supplies oBTC as collateral to the Morpho Market, they are authorized to draw a USDC loan.\
The borrowing capacity is strictly governed by the Loan-to-Value (LTV) ratio and other configuration parameters defined in the Morpho Market.

*Remark: The oBTC tokens exist solely to facilitate Optimex’s integration with the current implementation of Morpho Markets. These tokens are **not** designed to function as wrapped or fungible representations of BTC for general use. Their usage is strictly limited to the Morpho Market smart contract.*\
*They are not circulated, transferred, held, or traded by any end users of either the Optimex or Morpho platforms.*

### <mark style="color:orange;">Repay</mark>

**Loan Repayment by the Borrower**

Using the Optimex User Interface (UI), the Borrower repays the USDC loan and all accrued interest directly to the Morpho Market. After the loan obligations are fully settled, the Borrower becomes eligible to redeem the BTC collateral from the Optimex Collateral Vault on the Bitcoin network.

**Collateral Redemption Procedure**

This redemption process is formally effected by the Validation Network through the execution of the following two sequential actions:

* Redeem the oBTC tokens from the Morpho Market and burn the redeemed tokens.
* Trigger the Optimex Collateral Vault to transmit the BTC collateral back to the Borrower.


---

# Agent Instructions: 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:

```
GET https://docs.optimex.com/optimex-revolutionizing-bitcoin-finance/optimex-borrow/how-it-works/borrow-and-repay.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
