What is an oracle


DeFi protocols need oracles: Without oracles, DeFi protocols cannot get all the data they need to function properly.

The tools used by DeFi are actually decentralized, and in order to keep it that way, the data they use cannot be provided by centralized sources that could falsify, tamper, modify, or hide information. Furthermore, the smart contracts on which they are based only exist on the blockchain and only have access to the data available on the blockchain itself.

An oracle is a good solution. DeFi protocol smart contracts use oracles as a source of data outside the blockchain, such as asset market prices, sports results, weather data, or anything else that is not available on the blockchain. information.

Therefore, oracles are considered a bridge between decentralized protocols and data external to the blockchain, which is why oracles are essential.

Since smart contracts cannot control the authenticity of data from outside the blockchain through oracles, this also brings new potential risks (especially when the data provided by oracles is critical to the operation of smart contracts). So the choice of oracles is critical, as the data feeds provided by oracles can be manipulated or not functioning properly, which can jeopardize the correct execution of smart contracts.

The following introduces the basic information of some mainstream oracle projects:

ChainLink (LINK)——Oracle leading project
How To Buy Chainlink In Canada (May 2022) | Yore Oyster

Chainlink is a decentralized oracle network designed to allow smart contracts to automate the transfer of data between blockchains and external systems in a highly secure and reliable manner. It uses a similar model to blockchain in that there is a decentralized network of independent entities (oracles) that can centrally retrieve data from multiple sources, aggregate it, and then deliver a single verified data point to a smart contract for Trigger its execution, removing any centralized points of failure.


1.Chainlink provides multiple layers of security beyond decentralization to ensure users can trust the oracle network

2.Chainlink's price reference data has been expanded to include commodities, foreign exchange rates, and indices. Chainlink, in conjunction with Synthetix, currently provides novel price data for sOIL, a synthetic digital asset tied to an unexpired crude oil price index. Being able to ensure that any fluctuations in the futures contract near the expiration date have minimal impact on the final price data that Chainlink generates and publishes on-chain.

3.Chainlink enables 77 smart contract use cases

4.Chainlink has three aggregation types: data sources, node operators, and oracle network aggregations.

a.Data Sources Chainlink Price Feeds exclusively pull data from advanced data aggregators, ensuring a high degree of tamper resistance and reliability.

b.Node Operators Node operators in the Chainlink Price Feed take source price data from multiple independent data aggregators and take the median (middle value) between them, reducing outliers and API downtime.

c.Oracle Network Aggregation

UMA (UMA)——Distributed Financial Contract Platform
UMA Crypto: What Is Uma Crypto And UMA Crypto Price Prediction

UMA's Data Verification Mechanism (DVM) oracle structure guarantees the economic security of smart contracts and oracle systems in a fully decentralized and permissionless blockchain environment.

UMA has two technologies:

  • Invaluable financial contract template for creating synthetic tokens
  • Data Verification Mechanism (DVM), Oracle Service

Financial contracts are designed to ensure that counterparties are properly collateralized without using on-chain prices. They can identify improper collateral by offering incentives to counterparties or third parties. A “Data Verification Mechanism” (DVM) can help verify that these positions are improperly collateralized. It complements financial contracts.

DVM does not provide prices through on-chain price feeds. It is only used to resolve liquidation disputes and settle synthetic token contracts at maturity.

In the event of a dispute, a price request is submitted to the DVM, which proposes to vote for UMA token holders to report the price of the asset at a specific timestamp. UMA token holders will refer to the UMIP of price identifiers to determine asset prices through off-chain price feeds and record asset prices through UMA’s Voter dApp. The DVM will then aggregate votes from UMA token holders to determine the final price of the asset at a given timestamp.

If the price returned by the DVM indicates that the disputing party is correct, the liquidator will lose its liquidation deposit and will receive the disputing party's reward. If the DVM believes that the liquidator is correct, the disputer will lose their dispute bond and the liquidator will be rewarded.

Augur (REP)—— Prediction Market Protocol
Augur Price (REP INR) | Augur Price in India Today & News (16th May 2022) -  NDTV Gadgets 360

is a free and open source (developed by Forecast Foundation, OU) prediction market or betting exchange protocol. Prediction markets allow participants to bet on the potential outcomes of future events by trading stocks at different prices. Taking advantage of the decentralized nature of Ethereum, Augur allows anyone to place bets on any publicly verifiable potential future event. Augur's oracle functionality injects information (truths about the real world) of market outcomes that occur onto the Ethereum blockchain. Oracles use an incentive-driven public reporting and dispute system to determine market outcomes.

Ethereum founder Vitalik Buterin is an advisor to the project.

Band Protocol (BAND)—— Scalable Decentralized Oracle

BandChain is a high-performance public blockchain where anyone can request API services on traditional networks. It's built on the Cosmos SDK, and Oracle's results on the BandChain blockchain can be sent to other blockchains with minimal latency via the Inter-Blockchain Communication Protocol (IBC) or via a custom-built one-way bridge.


1.Speed and Scalability: Serve large data requests to multiple public blockchains with minimal latency and high throughput. Expected response times are on the order of seconds.

2.Cross-chain compatibility: Data can be used by most public blockchains. Verification of the authenticity of data on the target blockchain must be efficient and trustless.

3.Data flexibility: The system is generic and able to support different methods of retrieving and aggregating data.

Tellor (TRB)—— Access to off-chain data can be uncensored
What is Tellor (TRB)? - AZCoin News

Tellor is an oracle system that provides the infrastructure for decentralized applications to query off-chain data by appropriately incentivizing miners to provide data. Tellor leverages cryptoeconomic incentives to reward miners for honest data submissions and punish bad actors through the issuance of Tellor Token Tributes (TRB) and a dispute mechanism.

TRB incentivizes miners to submit data using inflationary rewards and choose the type of data they update based on a “hint” assigned to each query. Participants holding TRB can add "hints" on specific data types to update, and the Tellor smart contract then groups the top five data types with the most funds every 5 minutes and solves PoW challenges for miners. The first five miners and five off-chain data points that provide PoW solutions will be rewarded with newly minted tokens + cumulative tips for specific data requests. In addition to the security provided by the PoW process, the main layer of security is to enable miners to participate in PoW through TRB deposits (as a deposit or a stake requirement). If data submitted by miners is successfully disputed by TRB holders, they risk losing that stake.

DOS Network (DOS)——a decentralized oracle service supporting multiple heterogeneous blockchains
DOS Network Official (@DOSNetwork) / Twitter

The DOS network is a decentralized oracle two-layer network that provides real-time off-chain data input and verifiable off-chain computing capabilities for multiple mainstream blockchains. It connects on-chain smart contracts with off-chain data sources and computing power, enabling more application scenarios for smart contracts. The DOS system architecture can be divided into two layers:

  • On-chain part: It consists of system contracts and management contracts deployed on the support chain, mainly including processing of oracle requests, verification of results, node registration, token mortgage, node status monitoring, payment and other functions. Developers and smart contracts on different chains can request oracle services through the unified interface provided by the system contract on the chain.
  • Off-chain part: A second-layer distributed peer-to-peer network composed of clients that implement the core protocol and run by third-party users (ie, node operators). The protocol client includes several important modules: event monitoring and chain adapter, distributed random number engine, cryptography and off-chain intra-group consensus, request/computing task processing, etc. The specific module included depends on the oracle machine provided by the user node Service type.

The DOS oracle network uses randomness to select oracle workgroups and nodes. Mainly based on Verifiable Random Equation (VRF) and Threshold Cryptography to generate safe, unpredictable, and publicly verifiable random numbers, avoiding various problems of the reputation system, making the network more decentralized, It is difficult for nodes to collude and will not be targeted, and more importantly, it is more fair and just for nodes.

DIA (DIA)——Validate and provide trusted financial data
DIA introduces governance token for open-source financial data platform »  CryptoNinjas

DIA oracle data resides in a single smart contract. This smart contract holds the mapping from index to asset name, price and (if applicable) supply data.

The DIA Oracle regularly provides updates to smart contracts. Each update also generates an event so that the latest update can be seen in Etherscan's events view.

API3(API3)——Decentralized APIs for Web 3.0
API3 Token

The goal of API3 is to allow APIs to meet the needs of Web 3.0 decentralization without the use of third-party intermediaries. API3 achieves this through dAPI. dAPI is a fully decentralized blockchain-native API built, managed, secured, and monetized by the API3 DAO.

API3 has four roles:

1.dAPPs:service users;

2.Pledgers: managers, guarantors, pledgers pledge API3 tokens to the pledge pool managed by API3, provide insurance money, and obtain the governance rights of API3 DAO and API subscription fee share;

3.API3 DAO: manage API sources, manage staking pools;

4.API Provider: Provides API data to API3 DAO

Workflow: Pledgers pledge API3 tokens to provide insurance funds for the pledge pool and obtain governance rights of API3 DAO. API3 DAO selects high-quality service providers among many API providers to enter the aggregator. The dAPP subscribes to the dAPI service, pays the subscription fee, obtains data or services, and the pledger obtains a share of the subscription fee. If there is a problem with the API data (fake or otherwise), the dAPP can get insurance claims from the staking pool, and the stakers pay the price.

Advantages API service providers directly act as oracles, which reduces the intermediary links to a certain extent, making data services smoother and the credibility of real-time API data. The DAO composed of pledgers provides and provides guarantees. Once a problem occurs, the API's Claims are available to users (dAPPs).

NEST Protocol(NEST))——Decentralized price oracle
What is the NEST Protocol (NEST)? The complete set of NEST cryptocurrencies  - CoinCu News

NEST Protocol is a decentralized price oracle network that solves the problem of price on-chain through a decentralized incentive scheme. The most special feature of the NEST oracle is that it can directly verify the authenticity of the data on the chain. Every submitted price is verified by the verifiers in the whole market, which is in line with the blockchain consensus mechanism and prevents wrong data on the chain. Generation, more timeliness and security. The well-known mainstream oracles like ChainLink rely on the reputation system - by verifying the credibility of the uploader to determine whether the provided data is true, if something goes wrong, you have to go back and punish the node.

In addition, it takes about five minutes for the NEST oracle to be verified by the verifiers in the whole market. Only the price data that has survived for five minutes will become the effective price of the block and be entered by the NEST oracle system. This alone cannot prevent a flash loan attack. operation, because in the event of a flash loan attack, the attacker needs to complete all operations within 13 seconds.

The NEST quotation oracle is based on the arbitrage game between quotation miners and validators, and adopts the method of bilateral asset quotation.

Take the USDT/ETH oracle track as an example:

Quoting miners need to transfer 30 ETH and USDT of the same value to the quotation contract as collateral for the quotation data to prove the authenticity of their quoted price. After 25 blocks of market verification, if no one comes to take a single arbitrage, it will prove to be a fair market price, and this price will be included in the NEST oracle system. If it is found that the quotation data has a market deviation, the validator can take a single arbitrage, and use double the asset size of ETH and USDT to quote the current market fair price to correct the wrong data. The authenticity of the price on the NEST oracle chain is guaranteed through this bilateral asset quotation.