๐ฎ
Gaming API
Integrate BrainArk gaming tokens into your game โ real-time rewards, in-game currencies, NFT drops.
๐ Live Bonding Curve
Real on-chain data ยท refreshes every block
Reading coins from BrainArk chainโฆ
1
Launch a coin
Create a Gaming mode coin with up to 20% creator allocation. Get your token + curve addresses.
2
Register operator
Send your wallet address to BrainArk. We register you as an authorised operator on your curve.
3
Call the API
Your game server calls buyFor/sellFor on the bonding curve. Players receive tokens directly.
Use cases
โ๏ธ Battle rewards
Mint tokens to winners after each match
๐ Tournament prizes
Distribute tokens to leaderboard finishers
๐ Daily quests
Reward players who complete objectives
๐๏ธ In-game shop
Let players spend tokens for items and upgrades
๐ช NFT gating
Require token balance to access premium content
๐ Speculation
Players buy/sell โ price reflects game popularity
Code examples
The Gaming API is built directly into the BrainArk bonding curve contracts. Your game backend calls the smart contracts directly using ethers.js or viem โ no external servers or APIs required.
Key functions:
buyFor(player, minTokensOut)โ Buy tokens for a player. Send BAK as msg.value.sellFor(player, tokenAmount, minBakOut)โ Sell tokens on behalf of a player.currentPrice()โ Live spot price in BAK per token (18 decimals).realBakCollected()โ Total BAK raised on this curve.
Requirements:
- Your operator wallet must be registered by BrainArk admin
- Your operator wallet must hold BAK to fund buy transactions
- Players receive tokens directly in their own wallets (non-custodial)
๐ก๏ธ Anti-rugpull guarantees
โCreator receives 0 tokens directly at launch
โCreator allocation locked 18 months on-chain
โOnly registered operators can call buyFor/sellFor
โOnly BrainArk admin can register/revoke operators
โMinting permanently disabled after graduation
โAll fees go to protocol treasury, never to creator
๐ฌ
Get operator access
To register as a game operator, contact BrainArk with:
token address ยท operator wallet ยท game name/URL
token address ยท operator wallet ยท game name/URL