Problem: bringing real world data on-chain.

Credit: Chainlink

Credit: Chainlink

Layers of aggregations

  1. Data source
  2. Node Operators level
  3. Oracle Network

image.png

Data source

Datasource comprises of price data aggregators that fetch prices from both centralized and decentralized sources. Example of such aggregators are CoinMarketCap and CoinGecko, like above. And the aggregators themselves fetch from CEX and DEX like Uniswap, Binance and Coinbase. Since this aggregators are web2 systems, there are most likely fetching the prices off-chain and delivering them off-chain as through API. They deliver a single price.

Price data Aggregators API reference

  1. https://www.coingecko.com/en/api,
  2. https://coinmarketcap.com/api/

Chainlink Node Operators

At this level the chainlink nodes fetch prices from these aggregators, fetching from a minimum of three and get the median price. Node operators within the network operate under a consensus with a leader, the prices peer to peer communicated to the leader which batches the signed report from each operator and sends it out to the aggregator contract.

“For Offchain Reporting aggregators, all nodes communicate using a peer to peer network. During the communication process, a lightweight consensus algorithm runs where each node reports its data observation and signs it. A single aggregate transaction is then transmitted, which saves a significant amount of gas.”

“The nodes attempt to transmit the final report to the aggregator contract according to a randomized schedule. The aggregator verifies that a quorum of nodes signed the report and exposes the median value to consumers as an answer with a block timestamp and a round ID.”