Blockchain Smart Contracts and Off-Chain Oracles

The Chain link project is a decentralized oracle that connects blockchain smart contracts to off-chain data resources. The network provides both a data protocol and the infrastructure to enable off-chain oracles that are fully compatible with existing blockchain applications. This approach is a new and powerful way to allow smart contracts to access real-world data that would otherwise be unavailable through public or private blockchain networks.

What are oracles in smart contracts?

The resulting connection between off-chain data and blockchain applications opens up many new use cases and business functions for hybrid smart contracts that combine on-chain and off-chain functionality. These hybrid smart contracts can use off-chain oracles to connect to off-chain information stores and other external services such as payments and event processing.

To use the Chainlink oracle service, a user submits a request contract that specifies what kind of off-chain data they want to use. This triggers three subcontracts: a reputation contract, an order-matching contract and an aggregating contract. The reputation contract analyzes oracle service providers’ performance metrics and track records to select the most trustworthy oracles. The order-matching contract delivers the requesting contract to oracles that offer the requested data, while the aggregating contract collects the oracles’ responses and combines them into a single answer for the requesting contract.

Oracle service providers are incentivized to provide accurate data by being paid in LINK tokens whenever their services are used. This staking system also ensures that the network is always functioning at peak performance by punishing oracles who deliver inaccurate data or fail to complete their contractual obligations.