Smart Contracts

Using our contract infrastructure, developers can:

  • Analyze betting trends and access transparent odds, volume and game result data

  • Deploy a hedging contract for players to hedge parlays automatically

  • Develop a frontend on existing Betonchain contracts

  • Capture contract events to stream on social platforms

  • Deploy and fund our NFT voucher contracts to host risk-free bets for holders

  • And more!

Screen Shot from the Betonchain Node's Chainlink Operator UI

Child Bet Contracts

You can access a wallet's bets by calling the functions below. The structs referenced below areMoneyLineBetJoin, OverUnderBetJoin andPointSpreadBetJoin. For relevant events see the Events section.

NFT Vouchers

Anyone can deploy and fund our NFT Voucher contracts to host risk-free bets for a specified scope of holders. The vouchers are compatible with both ERC721 and ERC1155 contract types.

  • The vouchers can be updated by their deployer and optionally support an array of IDs that allow subsets of NFT holders to qualify.

  • Vouchers accept funding in USDC, USDT or DAI for distributing risk-free bets after they're placed by qualified users through the Betonchain protocol.

  • The amount to distribute per bet and the interval over which to do so are required parameters. For example, one can specify that up to 100 USDC should be distributed in risk-free bets every 24 hours until funding is depleted.

Please reach out on our Discord for more details on NFT Vouchers and assistance with configuration and deployment.

Events

The official DApp displays an event stream: https://betonchain.gg/activity

Examples

event RequestGameIdInit()

An event emitted when fulfillInitGame() executes successfully.

Parameter
Type
Description

requestId

bytes32 indexed

Request ID of the data request that was fulfilled

game_id

uint256

Game ID of the game for which data was initialized

event RequestGameIdOdds()

An event emitted when fulfillOdds() executes successfully.

Parameter
Type
Description

requestId

bytes32 indexed

Request ID of the data request that was fulfilled

game_id

uint256

Game ID of the game for which data was initialized

event RequestGameIdResults()

An event emitted when fulfillResults() executes successfully.

Parameter
Type
Description

requestId

bytes32 indexed

Request ID of the data request that was fulfilled

game_id

uint256

Game ID of the game for which data was initialized

event GameAdded()

An event emitted when _addGame() executes successfully.

Parameter
Type
Description

gameId

uint256

Game ID of the game that was added for betting

league

string

League of the game that was added for betting

Last updated

Was this helpful?