Blog

July 27, 2022

Introduction to Smart Contracts

I.        Introduction

Smart contracts are becoming more and more important and represent an integral component of many digital platforms and applications through the usage of Blockchain. In this article, we shall pinpoint what you need to know as to what are smart contracts, their advantages, and spotlight some functions of smart contracts through to their actual implementation in everyday life examples.

II.       What is a smart contract and why should we care about it?

Even though smart contracts do not have a uniform legal or technical definition, which is no surprise due to the novelty of the notion and related technical complexity, many definitions out there evolve around the same approach. It’s worth spotlighting the definition adopted by IBM where they conceived smart contracts simply as programs stored on a blockchain that run when predetermined conditions are met. They are frequently used to automatically carry out agreements, so that there is no need for a middleman while all parties are immediately certain of the outcome. Smart contracts can also automate workflows – triggering the next action when conditions are met. They may also help in international goods transfer and trade payment initiations through the use of a Letter of Credit. Further, using smart contracts also reduces verification, and enhances tracing results. For that to work, additional equipment such as sensors, may need to be integrated into the supply chain to provide necessary information for smart contract execution.

In simple words, smart contracts can be identified as programs that execute tasks based on specified logic and agreements. These programs run on decentralized networks whose ledgers cannot be altered or changed after a transaction is pushed. This self-execution feature is what differentiates smart contracts from traditional contracts, which on the other hand, are sets of agreed-upon terms which are enforceable by law and are described in a natural, human language.

Smart contracts may resemble the structure and underlying functionality of a traditional contract, sharing the same sets of rights and obligations which operate in tandem with one another. In essence, smart contracts can be regarded as the “mirror image” of the traditionally understood contracts, however they differ from conventional contracts in several ways, in particular:

  • the entire lifespan of a smart contract, from formulation to execution, occurs online;
  • that lifespan need not at any point involve any other entity other than the contracting parties;
  • performance is automated and is carried out by computer, following the applicable code;
  • transactions are immutably recorded on the blockchain and cannot be reversed. (If performance under the smart contract needs to be undone, a new contract must be written which reverses or modifies the results of the previous contract);
  • smart contracts follow programmed algorithms, and thus potential outcomes will be in binary form. There is no room for discretion, reasonableness, or subjective judgment.

In terms of technical aspect and to make things simpler for the non-tech-gurus, smart contracts work by following simple predefined “if this … then that” statements written into computer code on a blockchain. Typically, smart contracts are based on programming languages and codes that are different from regular languages and codes. The most prominent programming languages for smart contracts are Solidity, Vyper, and JavaScript where the latter is used on Hyperledger Fabric blockchain that allows building smart contracts with a few programming languages.When preset circumstances are satisfied and validated, a network of computers performs the actions. These actions could include releasing funds to the appropriate parties, registering property, and sending notifications. When the transaction is finished, the ledger “Blockchain” is then updated. As a result, the transaction cannot be changed, and only those who have been given permission can see the results.

III.          Benefits of smart contracts

When speaking of smart contracts, we cannot overlook the advantages they bring for people and companies. Smart contracts have many benefits, on the top of the list is automation which helps organizations to automate certain aspects of their business. Not only that, smart contracts can resolve issues in some processes where trust is an issue, by establishing trust between the parties in a transaction when they know that the transaction is running on a decentralized network where immutable data enables auditing of the transaction, this means that the whole network is secure. Immutable data refers to any records that have the ability to remain unchanged. It cannot be altered and hence the data cannot be changed with ease, thereby making sure that a high level of security is assured. Once smart contracts are executed, they cannot be stopped or interrupted. This immutable data makes it possible to audit the contract and how it was carried out.

Smart contracts are also cost-effective since transactions are concluded faster. Using smart contracts also eliminates the cost associated with contract conclusion. Further to that, autonomous smart contracts are typically executed way faster compared to conventional contracts. With that being said the entire contract lifecycle becomes much more effective.

On another hand, it’s worth mentioning that although the many benefits indicated above, there are also some disadvantages of using smart contracts. These disadvantages are mainly attributed to probable coding or programming errors. There is risk that a bug in code may result an unwanted execution of the smart contract. For example, if you are filing an insurance claim, you can make errors while doing so. However, if you chose to use a smart contract to do it, then it will be necessary to perform quality assurance test to avoid unwanted consequence when the code will be executed. 

 IV.        Examples of smart contracts

There are quite some of examples of smart contracts that we call “use cases” deployed in many areas of life, such as digital identity, elections, auditing and taxation, trade, supply chain management, insurance, financial services, and also mortgage systems. One of the recent trending examples represent trading of Non-fungible tokens (NFTs).  A mechanism for carrying out a sale agreement between the NFT owner and the buyer forms an NFT smart contract. It is sufficient to know that NFTs are run by smart contracts which govern the various actions such as verifying the ownership and handling the digital asset transfer. Smart contracts can check that the contract terms have been satisfied, as well as execute the terms without the need for an intermediary or central authority.

In that sense, creating an NFT is known as minting. Where you can uniquely publish your token on the blockchain to make it purchasable. The NFT’s attributes are determined by the smart contract code, which adds them to the relevant blockchain where the particular NFT is coded. NFT as a token has the information and the details of the smart contract, such information on the blockchain is public and includes the record of purchase and proof of ownership.

A recent report that was released in May this year by Yahoo finance services indicated that total NFT sales hit $37 billion as of the first week of May, according to a report from blockchain analysis firm, Chainalysis, compared with $40 billion for all of 2021.

The report added that if NFT sales sustain their median weekly total since January, total NFT sales could double to $90 billion by the end of 2022, this is making NFT trading one of the most impactful smart contract use cases.

V.        Conclusion 

It is unavoidable that smart contracts have become a real fact reshaping society in today’s world, with the industrial revolution heading towards automation in all aspects of life while smart contracts are striving the way forward. As already pointed out, by stating smart contracts, we don’t mean the traditional legal contracts, as smart contracts excel in one crucial aspect versus traditional contracts, which is trust-based performance. However, as smart contracts have gone viral and even gone beyond the application to different use cases as in NFTs as mentioned, actually smart contracts have started extending to legal contracts themselves turning them into smart legal contracts.

This Article was prepared by Hossam Hesham. Hossam Hesham is an Egyptian legal professional with experience that encompasses working as an in-house banking lawyer, preceded by law firm experience, and most recently he has added to his professional career an experience in banking governance in Italy. Hossam’s experience has an emphasis on contracts and legal advisory. As a passionate lawyer about legal technology, he pursued postgraduate studies and has been conferred a Master’s Degree in Law with a specialization in LegalTech from Lithuania. Hossam has been a member of the Egyptian Bar Association since 2015.

Standard Posts ,
About Hossam Hesham
One Comment
  1. Very informative and comprehensible for non-legal professionals. Thanks Hossam, waiting for more.

Leave a Reply

Your email address will not be published.