Aion University

So you want to be a DApp developer?


Well you've come to the right place. You'll find comprehensive guides and documentation to help you start developing with Aion as quickly as possible, as well as support if you get stuck. Let's jump right in!

Let's DApp

What is a Smart Contract?

Bounty

This page is under development - please read the rules on how to contribute. Make sure you've familiarized yourself with the Tone and Voice Guidelines for content contributions. Keywords you can focus on for this page smart contracts, smart contracts explained, smart contracts blockchain,
smart contract software, smart contract use cases

Disclaimer

We've done our best to walk-through this topic in a way that anyone can consume it regardless of their technical background. If you already know what a smart contract is and how it works, you should likely start here instead.

Overview

A contract is an agreement between two or more parties that often involves a set of promises enforced by a trusted authority. These agreements usually require a third party to write up, verify, and terminate the contract.

A smart contract eliminates the need of a third party agent to enforce terms within a contract. Instead of having individuals act as intermediaries, the role of a "middleman" is assumed by a computer protocol. The contract and agreements are written directly into code, then deployed and distributed across the decentralized blockchain network. Once a smart contract is deployed, any transactions within it are transparent and unable to be changed.

Here's great analogy to understand smart contracts a little better. Imagine a vending machine - you have to either input coins, bills, or a credit card to pay for a certain item in the vending machine, and then your product (say certain funds, a Cryptokitty, escrow, license, etc) gets distributed into your account. There is no interaction with a 3rd party - simply satisfy the requirement of the contract and receive what the expected outcome.

Who's using Smart Contracts?

Although Nick Szabo may have been the first to propose smart contracts on distributed ledgers in 1994, it was not until later in the 2010's that the concept of self-executing contracts on blockchain received increased adoption.

Since then, thousands of blockchain development companies have been created, many of which focus on designing smart contracts, integrating them with existing software, and then delivering this blockchain solution for the client to implement. There are also online platforms that have pre-written smart contract templates that you can edit to customize to your situation. With an increasing number of global corporations exploring the implementation of smart contracts in their business processes, it is exciting to envision greater adoption of blockchain technology to make the world more efficient, secure, and equitable.

Why are Smart Contracts better than traditional contracts?

Asides the advantage of bypassing dissatisfying roles middlemen play in most business transaction, smart contracts can work to your advantage in different ways

High level of Trust - You won’t have anyone coming back to you because your contract was misplaced, smart contracts are coded to follow specific orders and rules which tend to increase the trust level

Safety -  Your documents are kept safe via cryptography (a high level of encryption) unlike the traditional contracts where the level of insecurity is high. smart contract has higher stance of been safe from theft and major security concerns

High Accuracy Rate - just like the scenario giving above of buying an apple watch from amazon compared to buying from an enterprise blockchain platform, the level of accuracy is high while using a smart contract to execute any transaction,Since your contracts run on code and are not filled out manually, which also allows maximum efficiency, you can avoid traditional issues that can cost time and money

Speed – You’d ordinarily have to spend chunks of time and paperwork to manually process documents. Smart contracts use software code to automate tasks, thereby shaving hours off a range of business processes.

Savings – Smart contracts save you money since they knock out the presence of an intermediary. You would, for instance, have to pay a notary or a middleman to witness your transaction.

Autonomy – You’re the one making the agreement; there’s no need to rely on a broker, lawyer or other intermediaries to confirm. Incidentally, this also knocks out the danger of manipulation by a third party, since execution is managed automatically by the network, rather than by one or more, possibly biased, individuals who may err.

Backup – Imagine if your bank lost your savings account. On the blockchain, each and every one of your friends has your back. Your documents are duplicated many times over.

Smart Contracts Use Cases

So now comes the question - where can one implement a smart contract?
Here are a few examples of cases and industries where this technology can help to achieve a goal:

Finance

From insurance to trade settlement, smart contracts can be used to check payment history, validate transaction receipts, manage agreement terms, execute mortgage payments, and automatically calculate and release funds under pre-determined conditions. Smart contracts can improve efficiency and decrease friction in settling disputes and preventing fraud.

Supply Chain

Smart contracts can be used to streamline complicated supply chains by maintaining transparency in the production, transport, and sale of goods. The ability to track the origin of an item can be crucial in a situation where an issue affects a particular plant, batch, or resource. Furthermore, multi-signature implementation can allow payment or value-transfer to immediately occur when an order has been fulfilled.They facilitate granular-level inventory tracking, benefitting supply chain financing, insurance and risk. Such enhanced tracing and verification reduce the risk of theft and fraud.The identities of supply chain players have to be attested over time, including companies, institutions, individuals, sensors, facilities and products.

Digital Identity

Imagine being in full control of the data you carry. This means being able to release health records, passwords, banking information, citizenship, and other assets to your discretion. Smart contract technology could greatly change the ownership of our digital identity, and prevent parties from unknowingly accessing, mining, and profiting from our personal information. You will be in charge of your consolidated data, and can manage with whom you wish to share your information.

Research

Individuals frequently come across a new discovery or innovation to spend significant resources exploring it, only to discover that the idea has already been developed or is undergoing a patent application process. Smart contracts can not only record information in the order they are uploaded, but the owner of the data can then choose to share their findings knowing that they have already been credited for their work.

Different Types of Smart Contracts

Smart Contracts can be categorized into different types based on their collective roles and functions, some of them are outlined below:

  1. Initial Coin Offereing (ICO)
  2. Money Management
  3. Voting and Pool Contracts
  4. Escrow Contracts
  5. Notary Services
  6. Virtual Communities
  7. Supply Chain Management and Logistics
  8. Project Management
  9. Real Estate Transactions