After several years of consolidation around the crypto space, emerging innovative protocols are finally starting to draw interest, and it is much more than just reminiscent of the 2017 ICO boom. DeFi, short for Decentralised Finance, is one of the most popular.
Bitcoin delivered blockchain technology and decentralization, but the crypto market remained plagued by centralized finance, which became laden with governance to meet regulatory and investor demands.
DeFi, however, stands as truly decentralised, with no actual governance and a trustless and permissionless ethos. The crypto space may look like a once-in-a-lifetime opportunity to roll out a decentralised financial service, but a deep understanding of how smart contracts work is critical.
With the explosion of the DeFi industry in 2020, the use of Smart Contracts - which provide their logic - necessarily grew alongside. While CeFi depends on intermediaries to manage transactions, DeFi uses immutable Smart Contracts to create trust and transparency.
Smart Contracts are self-executing programs running on a blockchain network, with the terms of the contracts between two parties - such as a seller and buyer - written into lines of code, rather than a formal, legal document.
Smart Contracts are written in a specific object-orientated programming language called Solidity.
The goal is to simplify business and trade between both identified and anonymous parties without needing an intermediary.
They enable developers to build far more sophisticated functionality than simply receiving or sending digital assets. These programs are known as dApps, short for decentralised applications, which, in their essence, are a series of linked Smart Contracts linked to a user interface..
Smart Contracts are deployed on blockchain networks to launch decentralised financial protocols and applications that run exactly as programmed.
Some Use Cases of Smart Contracts
To sum up, smart contracts can offer the following benefits:
Smart contracts on Ethereum platforms represent and manage tokens. The MakerDao protocol, for example, is the backbone of the DeFi sector. The project is a big part of the DeFi ecosystem because out of $1 billion of locked ETH in the DeFi market, 60% of ETH is held in MakerDAO.
DAI is the primary product of MakerDAO-a stablecoin pegged to 1 US dollar that maintains a consistent value via a system of price feeds and underlying collateral (ETH).
The project is deployed on the Ethereum blockchain and doesn't need any intermediary to function. MakerDAO issues loans directly in the DAI stablecoin via Smart Contracts that control Collateralized Debt Positions (CDP).
CDP allows borrowers to deposit a digital asset into a Smart Contract as collateral to take out a loan on MakerDAO's platform. Once the asset is deposited, the conditions are written in a way that the CDP holds the assets and allows the borrowers to generate the equivalent of USD value in DAI to take out a loan.
Let's look at how CDP- a type of Smart Contract works.
But, if the price of Ether goes down by an agreed amount, your CDP will automatically close. This provides a safety buffer to ensure against default on loans.
To prevent this, you need to either take out less DAI or put in more Ether as collateral. The CDP smart contract ensures that the MakerDAO system always has enough capital locked against the borrowed amount.
Other Conditions set by MakerDAO in CDP smart contract.
MakerDAO is a self-governing protocol, and the native MKR token allows token holders to make changes to the Maker Protocol through a voting process which is written in a smart contract. These changes include:
The MKR token holders interact with the voting smart contract, and their vote is permanently recorded on the MakerDAO's blockchain for complete transparency. This contract records the votes weighted in proportion to the number of tokens each voter uses. This means the larger holders have a greater influence on the decisions. After collecting the votes, MakerDAO's voting smart contract processes the vote results.
Again, another smart contract called "spell" is deployed to implement the changes decided by the contract. As of now, one of the members of the Smart Contract Team develops the contract. However, as the project progresses to become a truly decentralised platform, this process will be made automatic to remove a single point of failure from the system.
The use cases of smart contracts go beyond just simple payment transactions and can be used in a wide range of fields, including medical, entertainment, and prediction markets.
During medical trials, a patient visits different healthcare centres and carries all the documents physically to make it easier for doctors to understand the medical history. Smart contracts can ease up the hassle by offering 360 degree visibility of the data of a patient.
A prediction market is essential to gain valuable insights regarding public opinion about a campaign or an organisation. Smart contracts can record the predictable outcome of events transparently to get accurate forecasts.
Smart contracts can enable rights for the content in the entertainment industry to remove plagiarism and piracy by watermarking media content. As soon as someone tries to steal the data, the legit owner will know immediately.
Smart Contracts will seem alien to anyone that has no concept of how blockchains function. Once, however, you appreciate the way that blockchains can achieve consensus on data management without a central authority, the additional layer of complexity and logic that Smart Contracts seems both a natural progression and an exciting way to bring the benefits of blockchain technology to so many areas of our lives.
Next step: A guide to paying tax on cryptoGo to next step