Ethereum has opened up a brand new world of cutting-edge technologies and a unique user experience. Automated sharing, smart marketplaces, medical record tracking, and even the internet without servers!
We cannot see how smart contracts are changing our life. They eliminate the thresholds and boost transparency in any kind of deal. First presented as a concept in 1994, it found its place in the public ledger environment. How are smart contracts developing and creating a new world without intermediaries? Here we explain smart contract basics and their implementation in real life.
What Are Smart Contracts Used for?
The smart contract is an agreement between two people/parties in the form of computer code. It ran on the blockchain so that nobody can change the code. The contract will be automatically activated when certain conditions are met.
In order to understand the smart contract better, let’s overview an example:
Bob wants to buy Alice’s house. We accept the agreement between them as a smart contract. IF Bob pays Alice 1,000 ETH, THEN Bob becomes the owner of the house. When this agreement is put on the blockchain, nobody can change it. This smart contract will be automatically executed once Bob pays Alice for the house.
If Bob and Alice don’t use smart contract technology, they need to apply to some third-party services like banks, government agents, etc.
Blockchain is the reason why a smart contract is such a great technology. It can be applied to many different spheres of life. No one has control of blockchain because it is a shared database.
Smart contracts became a point where a business meets blockchain. Smart contracts can help ease the process in almost every sphere: government, real estate, automobile, healthcare, supply chain, and more. We’ll describe some of them in the Smart Contract Implementation in Real Life section.
Who Created and Who Uses Smart Contracts
The concept of smart contracts was first introduced back in 1994 by the US computer scientist, Nick Szabo. His idea could not be implemented because there was no suitable environment. Szabo is one of the most influential figures in the crypto and tech world. He is a pioneering cryptographer and legal scholar who defined the term Smart Contracts and its importance for financial institutions.
Even though blockchain technology wasn’t even invented, Nick Szabo described the whole mechanism in the book called ‘Smart Contracts: Building Blocks for Digital Free Market’ in 1996.
When the first blockchain was introduced in 2009, the smart contracts finally retrieved the suitable environment. The blockchain can save the transaction and process it. The ordinary user doesn’t see this technology but uses its advantages.
The technology saves time and helps to avoid the conflicts of intermediaries. Users can exchange money, property, or anything valuable in an easy and conflict-free way. It can be implemented almost anywhere – insurance, breach contracts, property law, credit enforcement, and more.
How Do Smart Contracts Work
Smart contracts work as a digital vending machine. Bob puts a quarter in the vending machine and then receives a Soda, whereas Alice puts a one-dollar bill and gets a soda and a change back. The vending machine acts as a contract bearer that offers anyone who has some coins to participate in an exchange.
In a blockchain, the user gives a required amount of cryptocurrency into a smart contract, so the wanted element drops to his/her account. The user can write the conditions, rules, and any other details that should be done in terms of a smart contract to have it completed.
The smart contract technology has a unique functionality:
- It is multi-signature. That means that funds are spent only when the required percentage of people agree.
- It provides utility to other contracts. Smart contracts can be dependent on one another: if one contract is completed, the next starts.
- It stores information about applications.
In order to execute a smart contract, the user should write a code in Solidity or Vyper and have enough ETH coins to deploy a contract. Technically, its deployment is a process of making the Ethereum transaction. The sender needs to pay a fee in Gas. Note that the Gas costs for the contract deployment are higher than for a regular transaction.
In order to function properly, smart contracts operate within a suitable environment. First of all, it should be equipped with a public-key cryptography function. Then, this environment should be an open and decentralized database, so all parties can trust each other. The last requirement is the reliability of the environment. Smart contracts cannot get information about real-world events because this technology does not send HTTP requests.
The only way for contracts to get the info from the outer-blockchain world is through an oracle. The oracle is an information supplier. It sends reliable information from the off-chain world, which is critical for the correct contract execution.
What Do Smart Contracts Give You?
It’s obvious that smart contracts have plenty of advantages. Here is what smart contracts do:
- Smart contracts solve the trust issue.
- They work on the IF-THEN principle, which can ultimately guarantee the complete process.
- They work as an escrow service. Money, ownership rights, insurance can be stored in the system and distributed to the parties at the exact same time.
One of the important advantages is the lack of intermediaries. It gives a smart contract’s participants an opportunity to work on favorable terms (cost and time cutting). Moreover, smart contracts carry out conditions automatically. Necessary checks and calculations are implemented in a proper sequence.
Smart contracts create a conflict-free environment because the parties are isolated from each other. If some changes are needed to be made, technology requires the approval of both participants.
Smart Contract Implementation in Real Life
There are a lot of ways to implement smart contract technology. It started being widespread back in 2016-2017 when the ICOs crowdfunding became a thing. The technology can be applied to financial services such as money transferring and loan payments.
However, the possibilities are endless: insurance, legal processes, health system, logistics, government, real estate, etc. Let’s see the real smart contract implementation.
- Insurance. AXA is a French insurance company which first tested the flight-delay insurance based on smart contracts. If the flight is delayed by an agreed time, then the customer gets paid automatically.
- Prediction Market. Prediction platforms such as Augur and Gnosis became quite popular. The users create a prediction contract for any event and then get an automatic payout. It’s a thing for any bookmakers.
- Computer Power. Golem project is a great example of smart contract implementation. It represents the sharing economy, like Airbnb. However, instead of accommodation, the users rent computing power.
- Real Estate. Smart contracts act as a real estate agent. PropertyClub is a New-York-based real estate agency that works on the blockchain. It allows users to search, buy, sell, and invest in real estate properties. The company has its own PropertyClub Coin (PCC) cryptocurrency.
- Government. Smart contracts improve the voting system by introducing ledger-protected votes, so they can be decoded by requiring excessive computer power.
- Bank Credit. Banco Bilbao Vizcaya Argentaria (BBVA) uses smart contracts to provide money lending. BBVA issued a loan to a corporate client worth 75 million Euros. The deal was conducted using a smart contract on the Ethereum network. Distributed ledger technology and smart contracts simplified fraud and reduced time costs. This operation took only a few hours instead of a couple of days.
The implementation and realization of smart contracts are limited only by developers’ imagination.
ERC-20 is a standard for fungible tokens that are the same in type and value. ERC stands for Ethereum Request for Comments. This type of token was proposed by Fabian Vogelsteller in 2015. ERC-20 can represent anything that is transferred to virtual reality, for example, financial assets, lottery tickets, reputation points, etc. Token applications that are interoperable with products and services. In order to create an interface to any ERC-20 token, the user needs to use Contract Application Binary.
There is one more significant token standard in the Ethereum ecosystem – ERC-721. It is a non-fungible token that is used to identify something or someone in a quite unique way. It is usually represented with collectible items, seats for concerts of sports matches, etc. The decentralized applications (dApps) can input the tokenId and get an image of something like kitten images in the CryptoKitties game.
Ethereum Smart Contracts – Bottom Line
The smart contract technology is not as perfect as it seems to be at first sight. There can be some bugs and errors in the code that should be checked and eliminated. However, smart contracts tend to be a terrific technology in the sense of how people and organizations can interact with each other.
Blockchain became that environment where smart contracts can be executed in the correct way. The technology needs such additional features as oracles to improve smart contracts and make them accessible for parties to interact without any middlemen.