• 0xFave
  • Posts
  • Collateralised debt position (CDP)

Collateralised debt position (CDP)

If you are an auditor looking to understand Collateralised debt position then I get you covered! Check out this article detailing everything you need to know about CDP

Collateralised debt position (CDP) is a crucial component of lending and borrowing protocols, that allows users to lock up their crypto asset as collateral to borrow other tokens or stablecoin, which serves as a guarantee for the borrowed funds.

Let's simplify what CDPs are

Let me remind you that CDP puts together two words, "collateralization and borrowing". Most platforms in this realm operate on stablecoins for borrowing purposes to create stability.

Collateralisation - Backing Your Promises.

collateralization is like putting up something valuable to ensure you keep your financial promises. It's a bit like a security deposit when renting a house - it's there to protect both parties involved.

Borrowing allows you to access liquidity while using your crypto assets as collateral.

Advantages of CDPs in DeFi
  1. CDPs allow you to access liquidity without actually selling your valuable cryptocurrency assets.

  2. CDPs can act as a hedge against the volatility of your locked assets. If you're concerned about a price drop, you can take a loan, which remains stable, while your locked assets are subject to market fluctuations.

  3. DeFi CDP systems are typically decentralized and governed by smart contracts, reducing the need for intermediaries like banks. This means greater control and transparency in your financial transactions.

  4. CDPs can act as a hedge against the volatility of your locked assets. If you're concerned about a price drop, you can take a loan, which remains stable, while your locked assets are subject to market fluctuations.

How it works

To create a CDP, a user deposits cryptocurrency into a smart contract. The smart contract then generates a stablecoin loan equivalent to a certain percentage of the value of the deposited collateral. For example, if a user deposits $100 worth of Ethereum, they may be able to borrow up to $66 worth of DAI.

The user must maintain a certain level of collateralization, which is the ratio of the value of the collateral to the value of the loan. If the collateralization ratio falls below a certain threshold, the CDP can be liquidated instantly, through auction to the highest bidder or partial liquidation

CDP protocols allow users to supply liquidity by depositing their funds into a shared pool. In exchange, users receive an interest rate on their deposited funds. The interest rate is dynamic and is calculated using an algorithm that takes into account the utilization ratio. The utilization ratio is the proportion of assets borrowed to the amount available for lending within the pool. When the utilization ratio reaches a critical level, the interest rate rises significantly.

This mechanism serves two purposes. First, it entices creditors to provide liquidity when the protocol needs it by offering a higher Annual Percentage Rate (APR). Second, it motivates borrowers to close their CDPs because they would be paying a higher interest rate to keep their loans.

Types of CDP

CDP protocols can be classified based on various features for example

  1. Based on the type of collateral accepted whether it's ERC20, NFTs from popular collections like BAYC, LP tokens or even tokens from other CDPs like Aave or Compound

  2. Based on the oracle being used, chainlink or TWAP oracles to get the right price to keep the price in check

  3. Based on market types can be an isolated market where borrowers can only borrow one specific token or provide the token, or across other markets in the same CDP that allows users to borrow cross-market with different tokens by depositing one token

  4. Through their interest type which can be fixed or a variable rate

  5. Through the way their liquidation works auction, instant or partial

Well, that’s it anons!

Remember you can’t understand everything at once but this will help you to grasp the idea of what CDP is.

The next article will be on hacks of CDP Protocols

Cheers to a safer web3!