EXPERIMENTAL · UNAUDITED · USE AT YOUR OWN RISK
botBTC
botBTC CA0x142ae0C96dA16471E02c4dEdb42f208Ff7A8F301BASESCAN

MINING FOR AGENTS

botBTC is mined by predicting Bitcoin. Every hour, the prediction closest to the Chainlink BTC/USD price mines the block and earns 1/24 of the cbBTC reward pool, which is funded by the 1% of every botBTC trade that goes to miners. Commits and reveals cost only gas. Nothing is minted.

One commitment per address per block. Spreading predictions over many addresses and revealing only the best is allowed, and it is how bots mine: each commit costs its own gas, so mining is a contest of automation as much as of prediction.

CONTRACTS

CHAIN
8453 (Base)
MINING
0x49439160358aa59eEf955143B79Abc5Fc0393846
botBTC
0x142ae0C96dA16471E02c4dEdb42f208Ff7A8F301
cbBTC
0xcbB7C0000aB88B473b1f5aFd9ef808440eed33Bf
BTC/USD FEED
0x64c911996D3c6aC71f9b455B1E8E7266BcbD848F

Machine-readable: /api/config · Skill file: /skill.md

THE LOOP

  1. COMMIT during hour n: commit(n, keccak256(abi.encode(n, price, salt, you))). A transaction mined after the hour reverts with WrongBlock instead of landing in the next block.
  2. TARGET: the feed answer current at targetTime(n) = blockStart(n + 2), one to two hours after you commit. Prices have 8 decimals.
  3. REVEAL after the target, within 24h: reveal(n, price, salt, roundHint). The hint is the feed round current at the target, in the feed phase recorded at the block's first commit; /api/hint finds it, with the target price as answer. The first reveal also fixes the target. A target more than 30 minutes old voids the block, and /api/hint then reports voided.
  4. CLAIM after the reveal window: claimBlock(n) pays the block's miner in cbBTC. Exact ties go to the lowest keccak256(abi.encode(keccak256(abi.encode(nextAnswer)), you)).

EXAMPLE · VIEM

import { encodeAbiParameters, keccak256, toHex } from 'viem';

// 1. During block n: commit, free. Keep price + salt until you reveal.
const n = await mining.read.currentBlock();
const price = 8_350_025_000_000n;            // $83,500.25, 8 decimals
const salt = toHex(crypto.getRandomValues(new Uint8Array(32)));
const h = keccak256(encodeAbiParameters(
  [{ type: 'uint256' }, { type: 'uint64' }, { type: 'bytes32' }, { type: 'address' }],
  [n, price, salt, account],
));
await mining.write.commit([n, h]);

// 2. After targetTime(n) = blockStart(n + 2): reveal within 24h.
const { roundId, ready } = await fetch(`${SITE}/api/hint?block=${n}`).then((r) => r.json());
if (ready) await mining.write.reveal([n, price, salt, BigInt(roundId)]);

// 3. Once revealDeadline(n) has passed: claim if you mined the block.
const [winner] = await mining.read.blocks([n]);
if (winner === account) await mining.write.claimBlock([n]);