Understanding Chainlink in 5 minutes

Understand ChainLink in five minutes

ChainLink is a decentralized oracle network, it enables smart contracts that live on the blockchain to access real-world data. LINK is the platform’s native token, its primary use is to pay for services on the network. To quickly understand ChainLink’s benefits and how it works, we need to break down some fundamental concepts of decentralized finance (DeFi) and how they interconnect. Let’s begin with smart contracts.

What is a smart contract?

Smart contracts are a set of pre-programmed instructions and agreements that live on-chain. They will check if certain conditions are met, and if so automatically execute actions. A deflationary token is a good example: if an amount of token is transferred, then a percentage will be destroyed. Because the token’s smart contract code exists on a blockchain, it will never change. As a result, it guarantees that if the parameters of the agreement happen then the action will execute. This is one of the reasons why you find DeFi protocols described as being trustless.

What is a smart contract? ChainLink explained
Blockchain is trustless!

A problem arises when a smart contract’s agreement depends on data that lives off-chain. How should the smart contract connect to outside information in a way that cannot be manipulated? And how can data be presented in a way that a blockchain understands? This is why and where oracles appear.

What is an oracle?

You can think of an oracle like middleware. It sources data from the real world in a way that is accessible to smart contracts on the blockchain and back again. For example, a DeFi protocol providing a way to tokenize stock markets needs to know the USD value of said stocks. However, this poses new challenges for the protocol: its smart contracts may be secure but if the pricing feed is untrustworthy or faulty then it means nothing. As a result, centralized oracles nullify the benefits of any on-blockchain smart contract.

The current state of oracles

We find many projects working to crack the Oracle problem: Chainlink, Tellor, Kylin Network, Dia, Orai Chain – the list goes on! However, many teams still elect to run their centralized services to retrieve data for their applications. Mostly because many of the decentralized oracle networks are not cost-effective. As it stands, fetching critical data in a trustless manner for DeFi and Web3 products does not have the perceived best solution.

Chainlink aggregates data from multiple oracles, along with factors for ranking them. Additionally, oracles can stake their results for complete transparency.

Understanding Chainlink in 5 minutes

Understanding Chainlink boils down to comprehending the protocol consists of three main contracts to complete its core functions:

  1. Reputation contract.
  2. Order-matching contract.
  3. Aggregating contract.

Reputation Contract

All the oracles that offer their services for data sourcing through Chainlink are tracked via the reputation contract. This is a way to track the performance of oracles, enabling users to assess their reliability and usefulness. Essentially, the higher an oracle’s reputation then the more work there will be available its Chainlink node. Furthermore, a non-existent or bad reputation can be resolved by staking a higher amount of LINK.

Here are some of the main factors for ranking an oracle:

  • Availability (uptime).
  • The validity of data.
  • Average response time.
  • The total number of assigned, accepted, and completed requests.
  • The total amount of penalties.
  • Amount of LINK staked.

Order Matching Contract

As its name suggests, the order-matching contract is responsible for assigning demands to data suppliers. In a decentralized manner, it will evaluate the buyer’s request such as the number of oracles needed and level of reputation. And then it will match the order with the appropriate oracles.

Aggregating Contract

This smart contract will collect all of the data fetched by the oracles, and averages it. In this way, the result of a request is never down to just one oracle’s response. The buyer of the given data receives a weighted aggregate result, thus ensuring that the data is reliable and valid.

Understanding Chainlink in 5 minutes: LINK token model.

The primary use case for LINK token is through staking as holders stake tokens to assess an oracles reliability and earn rewards. Additionally, oracles receive payment in LINK for providing their services. There is also a penalty function to slash oracles that provide incorrect data. As a result, slashed tokens are also distributed amongst all oracles with a high reputation (who provide reliable and correct data.)

There is a total supply of 1 billion LINK tokens:

  1. Roughly 35% of the total amount is in circulation.
  2. 35% distributes through staking fees.
  3. The remaining 30% is a founders or team share.

What about governance?

The platform does not feature any inbuilt governance for community voting. Meaning the current oracle network is administered by the Chainlink team. However, it’s important to note that the ecosystem is built by independent oracles that are launched and controlled by their owners.

Summary: the go-to service for DeFi price feeds

Hope you have enjoyed understanding Chainlink decentralized oracle network. To summarize, Chainlink currently provides the largest collection of tamperproof, on-chain pricing feeds. This pricing feeds power some of the biggest dApps on Ethereum such as Loopring, Aave, 1inchExchange, Value DeFi, bZx Protocol, and more. 

It would be fair to say that DeFi developers are flocking to Chainlink for integrating external data requests into their applications. It enables the creation of smart contracts that are more advanced and reliable. And is arguably the easiest and most efficient oracle for developers to integrate. Therefore, Chainlink will only grow as the DeFi economy rises in importance!