Let's find out how this stablecoin works DAI is a decentralized stablecoin anchored to the value of the US dollar.
It is designed as a solution to address the problem of price volatility in the cryptographic space. Stability is the holy grail for the cryptocurrency market. However, reality has told a different story. Although the cryptocurrency has gradually become more mainstream over the years, there are some critical problems that make its adoption as a real world currency rather difficult. One that has remained a constant and inevitable problem is its price volatility. Cryptocurrency prices can vary drastically in one day, let alone an hour.
Imagine that you have an amount of USD 2,000 to rent, then suddenly it drops to USD 800 in an hour. As a response to this problem, stablecoins arrive as a potential solution. A stablecoin is a cryptocurrency that is anchored to a stable asset, such as legal currencies, collateral or gold, etc.
A stablecoin can be built centralized or decentralized. Centralized stablecoins are generally supported by legal currencies (USD, EUR, JP ¥, etc.) or commodities and depend on third party governments or custodians. On the other hand, decentralized stablecoins are supported by other cryptocurrencies, making them more secure, unauthorized and transparent. Some stablecoin projects even use algorithms to set a constant value. In general, a stablecoin is a cryptocurrency that is not sensitive to extreme volatility. Once you enter the cryptographic space, you must have known at least one of these popular stablecoins such as Tether (USDT), TrueUSD (TUSD), Paxos Standard Token (PAX), USD Coin (USDC), Gemini Dollar (GUSD) and above all Dai (DAI ). However, there are fundamental factors that make Dai different from other counterparts.
What is DAI? Dai is a stablecoin launched by MakerDAO in December 2017, pegged to the U.S. dollar. This means that each Dai is worth $ 1 and will always be worth $ 1 USD. Unlike Tether and other stablecoins that are supported by legal reserves held in a bank, Dai is entirely built into the Ethereum network as an ERC20 token and supported by Ether, making it completely decentralized. Anyone with an Ethereum wallet can own, accept and transfer Dai freely as any other ERC20 token, regardless of intermediaries. Its value stability is supported within the Ethereum blockchain using smart contracts. The important question is how Dai maintains stability when supported by a cryptocurrency which can be very volatile. This requires further explanation.
How does the DAI remain stable? Dai uses game theory and balanced economic incentives to support his $ 1 value. In more technical terms, it all boils down to margin trading using the collateral debt position (CDP). CDP is a smart contract that supports users to receive DAI. It works effectively as a debt instrument with an interest rate. The CDP user has recorded collateral in excess of the loan value in order to secure his debt position. When a single Dai drops below $ 1, the smart contract pricing mechanisms incentivize users to increase the price.
When a Dai is worth more than $ 1, the incentives work the other way around. On one of these occasions, rational actors can make money because of price swings. The more Dai deviates from the average, the better the incentives to bring the price down to $ 1. Let's say you deposit 2 ETH (at the time of writing, ETH is worth $ 193 USD) in a CDP and borrow 193 Dai. To recover the full 2 ETHs, you must repay the borrowed amount of Dai which is 193 Dai plus a stability fee. If the Dai value falls below $ 1, the stability fee will increase to make Dai loans more expensive. If Dai loans are more expensive, fewer loans will be generated and Dai's offer will withdraw, causing the price to rise. Likewise, if the Dai value exceeds $ 1 USD, the stability fee is reduced in order to make the Dai loans cheaper, leading to an increase in supply on the market and lower prices.
Rather than being determined and manipulated by any centralized financial institution, company or government such as Tether, Dai is completely decentralized. Dai's Stability Commission is voted on by the community of people who hold MKR tokens - the governance token for the MakerDAO system. The Stability Commission is a commission that must be paid by the owners of the CDP. It is an annual percentage return which is calculated in addition to the CDP's existing debt. The Stability Commission is denominated in Dai, but can only be paid using the MKR token. The amount of the MKR token you need to pay is calculated based on a price feed of the MKR market price. Once paid, the MKR is burned, permanently removing it from the power supply.
CDPs have varying degrees of debt. When you open a CDP, you can extract up to 60% of the value in Dai. This means that if you deposit $ 1,000 of ETH, you can withdraw 600 Dai. However, not all CDP owners take 100% of the amount. As ETH fluctuates in price relative to USD, the debt-to-GDP ratio of each CDP also changes. As ETH increases in price, the CDP user becomes more secure as he is less indebted. As ETH falls in price, each CDP becomes more risky and more indebted. Riskier CDPs have higher debt ratios. As ETH falls in value, each CDP approaches the debt limit. If a CDP exceeds this threshold, the Maker system will automatically purchase the CDP warranty and subsequently sell it. The owner of the CDP will receive the value of the residual collateral less the debt, the Stability Fee and the liquidation penalty. Holders have an incentive to remove risky debt from the Dai system by paying it off. CDP owners who let debt become so risky are penalized for this, which incentives them not to have a risky debt. CDP owners can make their debt safer by paying off debt as CDP becomes more risky. Smarter CDP owners will check their CDP if it becomes more risky, then pay Dai in advance to avoid a penalty. Those who neglect their CDP will be penalized by the system if they cross the debt threshold.
In addition to the smart contract infrastructure, there are some external players to keep Dai's price stable: Oracles and Glabal Settlers are external key players with special permits in the system assigned to them by MKR voters. In order to protect the system from an attacker who gains control of most Oracles, all Oracle inputs go through the Oracle security module, which imposes a 1 hour delay on the data, leaving enough time for the governance community MKR and the Oracles emergency to analyze the data and react. A global agreement (also known as an emergency stop) is a final appeal to impose the target price on Dai owners. When a Glabal Settlers is activated, it immediately shuts down the system to protect the Maker platform from attacks. This means that owners of Dai and CDP users receive the net value of the assets to which they are entitled. The process is completely decentralized and Maker voters regulate access to it in an emergency. Keepers are independent (usually automated) actors who are incentivized by profit opportunities to contribute to decentralized systems. Keepers can also make profits by trading Dai. When Dai's market price is above $ 1 USD, the holders sell to increase supply and decrease demand, which lowers Dai's price to its target price. Keepers also purchase Dai when the price is less than $ 1 USD to lower the supply, which increases demand for the currency, in turn helping to push Dai's price to where it should be. To learn more about the mechanism behind the creation of Dai and price stability, which becomes a little more complex, you can read the Whitepaper of the Dai Stablecoin system.