First Credit Delegation on Aave Protocol to DeversiFi is Here 🔥

Stani Kulechov
Aave Blog
Published in
3 min readAug 6, 2020

During this year DeFi has grown from a few hundreds of millions to a few billions in locked value (TVL). Locking value into DeFi allows activities such as lending, borrowing and trading across DeFi.

When Aave Protocol was launched during January this year, the thesis was to figure out ways to unlock locked value in DeFi and improve capital movements within the ecosystem. Thus followed Flash Loans, aTokens and recently Credit Delegation, unlocking capital from smart contracts.

What is Credit Delegation?

Credit Delegation is a simple transaction where an Aave Protocol depositor delegates a credit line to someone they trust. You can also delegate a credit line to another smart contract that executes predefined functions, removing that trust.

For example, Karen deposits USDC into Aave Protocol to earn interest. Since Karen only uses Aave Protocol to earn and not to borrow, she does not need to exercise her credit line. Instead, Karen delegates her credit line to Chad to earn additional interest. Once the credit line is delegated, Chad can draw the funds from a dedicated Credit Delegation Vault, a simple debt wrapper built on top of Aave Protocol. To ensure a smooth ride, Karen and Chad use OpenLaw to sign an agreement for the terms.

DeversiFi First to Draw Credit Line via Credit Delegation

Aave is glad to announce that DeversiFi, a decentralized exchange, was the first one to experiment with Credit Delegation by drawing a credit line from a Credit Delegation Vault! 🔥

Karen and DeversiFi first used OpenLaw to conclude the loan agreement. Here is a link to the OpenLaw agreement template used for this Credit Delegation. Feel free to use it, copy it, improve etc.

The interesting legal engineering in the agreement is the direct references to the Credit Delegation Proxy functions such as deployVault().

Part of the Agreement
Signing the agreement

The cool thing about OpenLaw is that it allows the tying of legal agreements with executable Ethereum code. After signing the agreements, the Credit Delegation Vault proxy deployVault() function was called directly from OpenLaw via MetaMask.

Executing code from OpenLaw

Here is the Vault used for Credit Delegation to DeversiFi. After the deployment the following steps were:

  1. Credit Delegator sets the borrowing limitations
  2. Credit Delegator deposits aTokens which are used as a collateral in Aave Protocol
  3. DeversiFi executed the Borrow! 👻
The Process

Anyone with aTokens in their wallet can delegate their credit by deploying a Credit Delegation Vault with a Credit Delegation Proxy. The code is experimental but audited by PeckShield.

To learn more about Credit Delegation functionality, check out these docs! For user interaction feel free to use https://yborrow.finance/

Credit Delegation might be a way to source liquidity from Aave Protocol across DeFi and into traditional finance without demanding borrower side collateral. Stay tuned 🙌

Special thanks to the Aave Fam, DeversiFi team, PeckShield and Andre Cronje for making this happen! ❤️

--

--