Blockchain And Cryptocurrency Provider

What is a Blockchain Oracle?

Blockchain Oracle

Table of Contents

Introduction

The concept of blockchain Oracles is as old as Bitcoin itself, but only in recent years did it resurface in the minds of the general Crypto public following the rise of the Chainlink project and their associated token (LINK).

 

Blockchain technology is defined by all the information that is publically available on the decentralised ledger. For “traditional” use cases like the storing and transfer value mechanism in Bitcoin’s currency, you don’t need more than the information available on the Bitcoin blockchain (ie. which addresses hold the coins currently). But blockchain technology has the potential to offer much more possibilities and solve many use cases. 

Smart contracts were developed, unlocking further potential for blockchain technology, bringing in an era or “programmable money”.

 

For example, instead of manually sending someone cryptocurrency, a smart contract could instead be deployed that would send crypto automatically from one account to another if an action or task was performed, or for example a certain amount of time had passed. This begs the question: how does the smart contract know if the task was performed or time had passed? 

 

So, to unlock the full potential of smart contracts we often need access to trusted external real world information. For example, to run a simple smart contract: you would need a data source external to the native blockchain providing you with the correct time. This is where the Oracles come in.

What is an Oracle?

An Oracle is an information bridge between the blockchain and the real world. They provide external data feeds and are designed to be used with smart contracts. They can provide information to the smart contract such as current time, whether a payment has succeeded, a price has reached some limit or any other external factors like the weather or a sport event results.

 

Oracles are essential to the functioning of smart contracts. They provide essential inputs and allow for the legitimate interaction of these contracts with real the world and external factors.Oracles can form part of multisignature contracts where the original trustees  sign a contract that will only execute or release the funds after all of those external conditions have been met.

 

The manner in which blockchain operates, makes it quite difficult for it to interact with external and off chain factors. This is due to  the deterministic nature of how events follow each in a logical order. For instance, you will have transactions or the creation of a block which are handled deterministically. However, gathering external information off chain that is not in sequential order would be impossible for the blockchain to understand.

Bridging the gap

Blockchains were designed specifically in this way in order to achieve it’s unique immutable characteristic, that is the idea that the data on chain cannot be altered in any way. In the real world, we know all too well that things are not deterministic. Events occur at random times in any specific order. This creates a fundamental challenge for blockchains as there is no defined recording of the sequence with which the events occurred.

 

 

This is where Oracles are able to bridge the gap. They are able to take these real world events and digest it into a deterministic form which would allow a blockchain to effectively verify conditions.

Oracle Diagram
Figure 1: Simple Oracles diagram

Types Of Oracles

Given that we are seeing a large increase in demand for smart contracts, it’s natural that the demand for Oracle solutions has also increased. There are a number of developers who have designed Oracles that are able to interact with the blockchain. These Oracles are in essence smart contracts themselves and hence require developers who can code solutions both on and off chain.

 

Oracles can already allow connections from the blockchain to existing web APIs, allow payments to be made between the blockchain and other off-chain payment processors as well as the integration of smart contracts with other blockchains entirely. Below are a few examples of Oracle solutions.

Hardware

Some smart contracts have been coded in order to interact with the physical world. They are designed to execute when certain conditions have been met. For example, with supply chains on the blockchain, once a product has crossed a certain stage or once a ship has landed at a particular port it can trigger an event that is recorded on-chain. There are obviously certain worries about data security with this. VeChain (VET) is using this type of deployment.

Software

Software Oracles will handle all online information required by the smart contract. This includes data such as asset prices, weather conditions, flight information. The Oracle will gather this information through web APIs and then send it to the smart contract. This is not an ideal solution because there is only one information source and there could be problems with availability or integrity of the data.

Concensus Building

When a smart contract relies on information from a number of different sources, this is where consensus based Oracles are best used. For example, with prediction markets where bets are placed on the outcome of potential future events, it is crucial that the information of the event is 100% correct. They require decentralised confirmation of this from a number of different sources. The Chainlink project is built with this architecture in mind.

Chainlink Network
Figure 2: Chainlink network connecting different spheres of the internet

Chainlink Project

Chainlink is currently the industry leader in the Oracles development space so we need to cover some of the basic concepts of the project. Chainlink aims to connect not only the real world data to smart contracts. But also interconnect any blockchain to any other blockchain to create a distributed network of blockchains with access to real world data. If you think about this idea for a minute you’ll realize how much potential this project has.


Chainlink architecture consists of stack of smart contracts that are divided into two parts:

Off-Chain

Chainlinks off chain architecture consists of a network of oracle nodes connected to the Ethereum network. These nodes independently harvest responses to off-chain requests. Each individual response is aggregated via consensus mechanism into a global response that is returned to a requesting contract (USER-SC). 

 

Chainlink open source core implementation nodes which handle standard blockchain interactions, scheduling, and are connecting with common external resources. Node operators may choose to add software extensions, known as external adapters, that allow the operators to offer additional specialized off-chain services.

 

Chainlink nodes have already been deployed alongside both public blockchain and private networks in enterprise settings, enabling the nodes to run in a decentralized manner.

Chainlink Smart Contract Architecture
Figure 3: Chainlink Smart Contract Architecture
On-Chain

The on-chain smart contract stack is a piece of a Chainlink architecture that has it’s Oracles that are able to accept and process requests from the user. On-chain Oracle contract (CHAINLINK-SC) takes the user request for the off-chain data, the request is rooted to the appropriate smart contract which matches the request up with the correct off-chain data.


There are 3 contract types that match off-chain and on-chain data: aggregating contracts, order-matching contracts and reputation contracts.

 

An aggregating contract gathers information from the selected off-chain nodes and then delivers the best results to the contract requesting the data. The reputation contract determines that the oracle node is reputable and trustworthy. If so, the order-matching contract passes the requesting contract onto the corresponding oracle node depending on the data requested.

LINK token

The Chainlink network utilizes the LINK token to pay and incentives the node operators for their services ( eg. retrieving the off-chain data, formatting the data into blockchain readable format, off-chain computation,…).

 

In order for a smart contract on Ethereum network to use a Chainlink offline node they will need to pay using LINK tokens with prices being set by the node operator based on demand for the off-chain resources their “Chainlink” provides and the supply of similar resources. 

Chainlink conclusion

The above description of Chainlink may be too much to digest in a short article like this so if you are interested in a project on a deeper level visit their official website,: https://chain.link/

 

The most important takeaway about the project architecture is that it is set up in such a way that the off-chain data sources are decentralised. 

Decentralisation is a key component in most Blockchain project that helps to ensure  that the data provided is always available,  correct and complete. And if there are problems with the specific node this won’t affect the execution of a smart contract.

Other Oracle Projects

Top Oracle Projects
Figure 4: Top Oracle Projects

Above is the list of top Oracle projects. As you can see Chainlink currently has a major advantage.
But as you have learned in this article Oracle technology is integral to the future of the blockchain space and some of the smaller projects must have a bright future ahead.

Conclusion

With the increasing adoption and interest in smart contracts, there will be increasing demand for Oracles which allow these contracts to interact with other systems on the web and the physical world. Indeed, it looks likely that developers will design a simple uniform Oracle that will facilitate this communication with the outside world.

This can  truly propel the use case for smart contracts and decentralised blockchains. Anywhere from logistics to identity management, from property ownership to intellectual property, smart contracts with Oracles can provide a solution

Share this 

Facebook
Twitter
LinkedIn
Ozzak

Ozzak

Ozzak discovered blockchain technology in early 2017 and decided that this is exactly what he wants to do with his life. In 2018 he was accepted in the Computer Science course at University College Cork. He's now in his 3rd year working for Boinnex as a part of his internship. As you may imagine he's deeply passionate about everything blockchain. Ozzak's other interests include calisthenics, blues harp and Austrian economics. He also has an impressive collection of tarantula spiders.

Have any questions? Write them below

Sign up for our Newsletter

Receive daily updates directly in your favorite email.