Phantasma Oracles

Lee
PhantasticPhantasma
3 min readSep 8, 2019

--

Phantasma is building a true one-stop ecosystem on the blockchain, however smart contracts cannot access data from outside their own network. The input of external information is sometimes still required. Phantasma Chain needs a correct & reliable source of information to connect off-chain feeds to smart contracts, this is why Phantasma has built their very own oracle support! Phantasma oracles allow smart contracts to read real world data and use it to fuel on-chain logic and calculations, while directly reducing the workload of the blockchain. The Phantasma built-in oracle support is available from main net launch day, together with our very own decentralized storage solution!

Oracles

The first-generation oracle systems work by having a small contract posting a request to fetch external data, then having a third party server listening to that, which fetches the data and pushes it back to a blockchain. This system gets the job done, however it is outdated and therefor a clunky and slow system. Phantasma brings all the power of next-generation oracles, which are fully integrated into the chain, which allows doing everything in a single step. The oracle data is also stored per block, allowing effortless verification of the chain contents. Phantasma’s oracle is purposely built for Phantasma’s ecosystem due to its needs for blockchain interoperability, price determination and third party developer support. Therefor, Phantasma oracle offers three different types of oracle.

Blockchain interoperability oracles

These oracles allow any Phantasma transactions to read blocks and transactions from all supported blockchains. Phantasma oracle automatically converts block and transaction data from other blockchains to Phantasma’s internal format which allows developers to fetch data from multiple blockchains and easily mix it with Phantasma dApps. The initial supported blockchain is NEO, with more blockchains to be added in the future.

Price oracles

As Phantasma Chain allows users to use multiple cryptocurrencies as a payment option due to Cosmic Swaps, it needs a feature to allow Phantasma smart contracts to obtain real time price data for tokens & coins supported within Phantasma’s ecosystem. Phantasma oracle is used to for this specific matter to make sure that all values are correctly processed and displayed.

Third party oracles

As Phantasma is an open source blockchain, it is only natural that Phantasma oracle is designed to be integrated by third party developers. These oracles are data feeds that can be created by anybody, which allows smart data to be available from a multitude of external sources (e.g. weather reports, government data, sport match results and more).

By integrating Phantasma’s built-in oracle, developers can easily build all kind of dApps that rely on reading external data. This makes it more attractive for third party developers to build on Phantasma as they do not have to worry about searching for such an external solution. This feature further proves that it is possible to build a true one-stop platform, without any third-party reliance, which reduces the necessity of needing multiple tokens for simple blockchain purposes.

For more information about Phantasma Chain:

Website: https://Phantasma.io/

Telegram Channel: https://t.me/phantasma_io

Telegram Announcement Channel: https://t.me/phantasma_announcements

Medium: https://medium.com/phantasticphantasma

Twitter: @phantasmachain

Reddit: https://www.reddit.com/r/phantasma

Discord: https://discord.gg/rYfajr

Instagram: https://www.instagram.com/phantasmachain/

Youtube: https://www.youtube.com/phantasmachain

--

--