BinaryOracle Smart Contract Module in Bunzz

The BinayOracle module for a Binary Game product divides the time into Rounds and each round has its own price. It allows Admins (who are able to change the Writers) and Writers ( who are able to write prices for each Round).

You can access this Module and the code here: https://bit.ly/40qBr1v

How to Use

  1. Deploy smart contract via Bunzz. When deploying, the deployer will become both the Admin and Writer.
  2. Writers can call writePrice and writeBatchPrices functions to write Round prices.
  3. Users can call getRoundData and getLatestRoundData function to query the price data.

Functions

#WRITE

  • grantRole
  • renounceRole
  • revokeRole
  • setWriter
  • writeBatchPrices
  • writePrice

#READ

  • DEFAULT_ADMIN_ROLE
  • WRITER_ROLE
  • allRoundIds
  • genesisStarted
  • getLatestRoundData
  • getRoleAdmin
  • getRoundData
  • hasRole
  • isAdmin
  • isWriter
  • latestRoundData
  • roundLength
  • rounds
  • supportsInterface

You can access this Module and the code here: https://bit.ly/40qBr1v

If you still haven’t signed up to Bunzz, what are you waiting for?

Sign up here https://app.bunzz.dev/signup and get your smart contracts deployed in 5 minutes through our great GUI.

Share this article: