Skip to Content
docs

Aave V3 Credit Delegation

Credit delegation allows a supplier to contribute liquidity to the Aave protocol to earn interest, and delegate borrowing power (i.e. their credit) to other users. The enforcement of the borrow position and its terms are agreed upon between the supplier and borrowers, which can be either offchain via legal agreements or onchain via smart contracts.

This enables:

  • The supplier (aka delegator) to earn extra yield on top of the yield they already earn from the protocol.
  • The borrowers (aka delegatees) to access uncollateralized liquidity.
DelegateeDelegatorDebt TokenPool
Credit Delegation

The delegatee can only borrow assets allowed in the delegator’s E-Mode category. For example, if the delegator is in a stablecoin E-Mode category, a delegated borrow of WETH reverts.

A borrow that would drop the delegator’s Health Factor below 1 reverts, so a delegatee cannot force the delegator into liquidation.

Approve the Delegation

The approveDelegation or delegationWithSig function on the VariableDebtToken contract must be called by the supplier (delegator), approving the borrower (delegatee) a certain amount.

This is done for each debt token that needs to be delegated.

The delegator does not need to already have supplied funds in the protocol to approveDelegation. However, before the delegatee executes borrow, there must be sufficient collateral supplied by delegator in the protocol.

Borrow the Credit

The borrower (delegatee) calls the borrow function on the Pool, using the supplier’s (delegator’s) address in final parameter onBehalfOf.

The borrower’s available credit is reduced by the borrowed amount.

Repay the Credit

Anyone can repay the debt on the delegator’s behalf with the Pool repay or repayWithPermit functions. The delegator can also use repayWithATokens to repay with aTokens of the same underlying asset.