Lending Contracts

Overview

The Lending module unlocks liquidity by letting investors pledge fractional tokens as collateral. Borrowers can draw $REAL or stablecoins up to an LTV threshold.


Purpose

  • Provide liquidity without asset sales.

  • Secure borrowing with collateral.

  • Liquidate unhealthy positions.


Key Features

  • Collateral deposits.

  • Borrow stablecoins or $REAL.

  • LTV enforcement.

  • Liquidation mechanism.

  • Compliance hooks.


Architecture

  • RealLending.sol – manages collateral, loans, liquidation.


Roles

  • Borrower – deposits, borrows, repays.

  • Liquidator – liquidates unsafe positions.

  • Admin – configures LTV and params.


Files

  • contracts/lending/RealLending.sol


Example Flow

  1. Borrower deposits 100 fractions as collateral.

  2. Borrower borrows 1000 USDC.

  3. Collateral price falls → health < threshold.

  4. Liquidator repays debt and seizes collateral.

Last updated