Getting Started Guide

LiquidHarmony Oracles Getting Started

  _      _             _     _ _    _                                           ____                 _           
 | |    (_)           (_)   | | |  | |                                         / __ \               | |          
 | |     _  __ _ _   _ _  __| | |__| | __ _ _ __ _ __ ___   ___  _ __  _   _  | |  | |_ __ __ _  ___| | ___  ___ 
 | |    | |/ _` | | | | |/ _` |  __  |/ _` | '__| '_ ` _ \ / _ \| '_ \| | | | | |  | | '__/ _` |/ __| |/ _ \/ __|
 | |____| | (_| | |_| | | (_| | |  | | (_| | |  | | | | | | (_) | | | | |_| | | |__| | | | (_| | (__| |  __/\__ \
 |______|_|\__, |\__,_|_|\__,_|_|  |_|\__,_|_|  |_| |_| |_|\___/|_| |_|\__, |  \____/|_|  \__,_|\___|_|\___||___/
              | |                                                       __/ |                                    
              |_|                                                      |___/                                     

LiquidHarmony includes all oracle related logic from the DAPP Network. This includes things like http fetches, IBC and XIBC fetches, vCPU and more. The full list of options can be explored in the oracles directory of the repo: https://github.com/liquidapps-io/zeus-sdk/tree/master/boxes/groups/oracles

The DAPP Network offers the ability to fetch information using DAPP Service Providers (DSPs). A developer may choose as many or as few oracles to use in fetching data points from the internet. If a developer wishes to prevent a scenario where all oracles have an incentive to return false information, the developer may run a DSP themselves and set the threshold of acceptance for the information to all parties. Another great place to understand the service is in the unit tests within each sub directory.

The price feed example uses LiquidHarmony web oracles and the LiquidScheduler to periodically update a price on chain only when the new price is more or less than 1% of the last updated price, conserving CPU by only running actions when necessary. See here

Prerequisites

The DAPP Network currently supports the following oracle requests:

  • HTTP(S) Get

  • HTTP(S) Post

  • HTTP(S)+JSON Get

  • HTTP(S)+JSON Post

  • Nodeos History Get

  • IBC Block Fetch - (Mainnet, BOS, Telos, Kylin, Worbli, Jungle, Meetone)

  • Oracle XIBC - read for foreign chain (Ethereum, Tron, Cardano, Ripple, Bitcoin, Litecoin, Bitcoin Cash)

  • Wolfram Alpha

  • Random Number

  • Stockfish - chess engine AI

  • SQL

Unbox Oracle DAPP Service box

This box contains the oracle smart contract libraries, DSP node logic, unit tests, and everything else needed to get started integrating / testing the DAPP Network oracles in your smart contract.

mkdir oracle-dapp-service; cd oracle-dapp-service
# npm install -g @liquidapps/zeus-cmd
zeus box create
zeus unbox oracle-dapp-service
zeus test -c

Last updated