How Subsquid Query Nodes Can Supercharge Blockchain Oracles

Oracles are essential in the blockchain world for getting external data onto blockchains, but up to this point blockchain oracles have been fairly one-dimensional. They have very little flexibility, which greatly limits their use case when it comes to developing apps with great depth or variety. Subsquid nodes supercharge oracles and give them a new lease of life by bringing their data on-chain and enriching it with additional sources, allowing developers to dramatically extend functionality.

What are blockchain oracles?

The Cambridge Dictionary defines the word ‘oracle’ as “someone who knows a lot about a subject and can give good advice”, which gives you some idea of the services that blockchain oracles perform. In the cryptocurrency world, blockchain oracles provide data from primary or secondary sources, usually external in nature, which is fed into smart contracts and recorded on the blockchain.

Blockchain oracles come in two formats — software and hardware. Software oracles provide data from secondary sources, such as stock prices, the outcome of sporting events, and weather data, data they have not gathered themselves. Hardware oracles on the other hand collect primary information through monitoring equipment, such as weather stations, supply chain RFID tags, and GPS data, with Internet of Things devices also being great examples of hardware oracles.

Subsquid breathes new life into oracles

Oracles may be good at what they do, but they are expensive to operate and hard to customise. They also only allow the data they produce to be consumed off-chain, for example by web and mobile Dapps, whereas if this data could be brought on-chain it would present great opportunities for developers. For example, a Subsquid query node could calculate pricing of tokens on a decentralised exchange and average them to within a specific time window, something that oracles on their own cannot do. You could even go further and combine that price data with volume or other metrics, data which can then be used on-chain by DApps.

The traditional way in which data gets from the oracle to the blockchain is through a pluggable pallet (e.g. ChainLink pallet for Substrate). The external oracle data is then available via event data picked up by the Hydra Indexers and Processors:

A dedicated Subsquid Pallet overcomes this problem as it utilises Hydra-based Query Node data on-chain:

This gives a lot more flexibility for the end users, as the query node data can be enriched with aggregations and any other on-chain data, while preserving the integrity provided by the original oracle feeds. The Subsquid palette brings the flexibility of Hydra endpoints on-chain via on-chain workers.

If you would like more information on how Subsquid query nodes can supercharge blockchain oracles, head over to our Discord server for a chat with one of our helpful team members, or check out our website or Medium page for more information first.

Website, Twitter, Discord, Telegram, Subsocial, Reddit, Facebook, Insta



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store


We are building a data backbone for #Web3. APIs and analytics on 33 networks (and counting). &