Contract directory
Explore deployed game, ledger and settlement contracts and verify onchain records.
Actions and states
How do I participate?
Connect your wallet, fund your platform balance, choose numbers and confirm your purchase.
When can I claim?
After results are confirmed and prizes settled, claim winnings in your account.
What happens during a dispute?
The round awaits UMA resolution. A countdown ending does not confirm the result.
What are public records?
The result sources, draw transactions and settlement records for a round.
Protocol core 7
- Unified ledgerunifiedLedger
0x43E2283904353aC423650BC2b736FC806be9516b- Stablecoin reservestablecoinReserve
0x7f5161E273A47C6a1B2d24C6230E2D3aB8574b7d- Game registrygameRegistry
0x9Bf6BD63C1CC85A67A57614d333CB52c541B2b4B- Protocol revenue routerprotocolRevenueRouter
0x8e74486bE60fc555a89b1C573757183F6A1179fF- DAT revenue vaultdatRevenueVault
0x4F5d087e54259dD92e9799C53061AB56492A5D57- Lotto3D DAT vaultdatRevenueVault3d
0x4F5d087e54259dD92e9799C53061AB56492A5D57- World Lotto DAT vaultdatRevenueVaultUma
0x626905828250708A1Bb1AB53db12f5bE9EDE0a78
Game assets 2
Lotto3D 3
- Treasurytreasury
0x943dA9335700E2c0974fB0BF1c641f7b76d70d3f- VRF adaptervrfAdapter
0x7021b6a1bcE1dD7e6a75B96b29E99BB4C5E35973
World Lotto 4
- Roundsrounds
0xABf75A2C7BA0c3a094f409CEE7D24351ff64d81C- Treasurytreasury
0xab630f0a11da4a3bc77767d44035A18738a61F15- Settlementsettlement
0x98Bd9e458bB2489e45Fb82E223668f1589aB4E99- Oracle adapteroracleAdapter
0xb713426B0b3ec390714843F1cf99b8136BE1f6Eb
External dependencies & governance 1
Oracle and governance addresses referenced by this deployment.
- Chainlink VRF coordinatorcoordinator
0xec0Ed46f36576541C75739E915ADbCb3DE24bD77
Read full technical documentation
Deployment facts
The address table on this page is informational and links to the configured block explorer. The chain remains authoritative for bytecode, state, permissions, and transaction outcomes.
Signing boundary
- The frontend requests wallet signatures for user actions; it does not receive or store private keys.
- Automation workers may submit protocol maintenance transactions, but their identities and permissions are separate from a user's wallet.
- Never sign a transaction after switching to a network that does not match the deployment shown here.
ABI and SDK contract
The public package @wf-protocol/contract-sdk exports the active deployment, typed address map, generated ABIs, and helpers for constructing readContract/writeContract descriptors. The ABI files are generated from the contract build; integrations should pin the package version and deploymentId together.
import { contractAddresses, getContractDescriptor } from "@wf-protocol/contract-sdk";
import { lotto3dGameAbi } from "@wf-protocol/contract-sdk/abis";
const descriptor = getContractDescriptor("lotto3dGame");
// descriptor.address, descriptor.abi, descriptor.chainId, descriptor.deploymentId
console.log(contractAddresses.lotto3dGame, lotto3dGameAbi);Unified ledger and reserve interfaces
Standalone UnifiedLedgerV4 has no V2/V3 purchase or operator-allowance entry points. Only StablecoinReserve credits or debits liability. Purchases debit the authorized owner; protocol accounts can transfer only their own balance. New deployments require fresh addresses, not upgrades of inherited Ledger storage.
| Contract | Function | Mutability | Caller / purpose |
|---|---|---|---|
| UnifiedLedgerV4 | balanceOf(address) | view | Read a user's USD balance |
| UnifiedLedgerV4 | executePurchaseV4 / executePurchaseWithAuthorizationV4 | write | Direct or EIP-712 authorized purchase |
| UnifiedLedgerV4 | protocolTransfer(address,uint256) | write | Protocol account transfers its own balance |
| UnifiedLedgerV4 | fundProtocolAccount(address,uint256,bytes) | write | Atomic treasury funding; receiver validates the funder |
| StablecoinReserve | deposit(address,uint256,uint256,uint256,uint256,uint256,bytes) | write | User deposits a whitelisted token with EIP-712 authorization |
| StablecoinReserve | withdraw(address,uint256,uint256,address) | write | User burns USD and receives a supported token |
Game entry and claim interfaces
The entry points above describe standalone V4. For delegated purchases use Ledger.executePurchaseWithAuthorizationV4 with the owner's EIP-712 signature. Read the round state, quote the purchase, and simulate against the matching ABI before requesting a wallet transaction.
| Game | Entry | Claim / refund | Proof |
|---|---|---|---|
| Lotto3D | Ledger.executePurchaseV4(request, purchaseData) | game.claim(ticketId); game.refundTicket(ticketId) | Chainlink VRF |
| World Lotto | Ledger.executePurchaseV4(request, purchaseData) | settlement.claim(ticketId); rounds.refundTicket(ticketId) | UMA optimistic assertion |
| BTC 5M | Outside the standalone V4 release | No standalone V4 integration | See feature status above |
BTC 5M condition market contracts
BTC 5M is outside the standalone V4 release and is not enabled by local-v4. Its archived CTF, collateral adapter and exchange interfaces must not be used with the standalone Ledger. Enabling it requires a separate contract and service integration review.
| Contract | Purpose | User boundary |
|---|---|---|
| WFConditionalTokens | Prepare condition, split/merge, report payouts, redeem | ERC-1155 approval and user redemption |
| BtcMarketFactory | UTC-aligned market creation and status | Read market snapshot |
| Btc5mOracle | Verified BTC/USD result or void | Read result/evidence hash |
| WusdMarketCollateralAdapter | Ledger operator escrow and release | One-time USD operator approval |
| WFExchange | Signed order validation and matching | EIP-712 order signature |
Events for reconciliation
Indexers derive their rows from contract events. A production integration should retain the transaction hash, block number, log index, and deploymentId so a row can be rebuilt from the chain. Do not use an indexer-generated id as a substitute for the onchain event identity.
| Domain | Authoritative events |
|---|---|
| Ledger / Reserve | PurchaseExecutedV4, ReserveCredit, ReserveDebit, BalanceTransferred, Deposited, Withdrawn |
| Lotto3D | RoundCreated, TicketPurchased, RoundSettled, PrizeClaimed, TicketRefunded |
| World Lotto | DrawAssertionRequested, DrawAssertionResolved, DrawSubmitted, SettlementPosted, PrizeClaimed, TicketRefunded |
| BTC 5M | Outside the standalone V4 release |
Reverts and simulation
Decode custom errors from the matching ABI instead of parsing human-readable RPC strings. Standalone V4 purchase errors include InsufficientBalance, InvalidPurchaseNonce, InvalidPurchaseSignature, PurchaseExpired, GameNotActive, PurchaseDataHashMismatch, and WfOrderAlreadyUsed.
const { request } = await publicClient.simulateContract({
...getContractDescriptor("lotto3dGame"),
functionName: "claim",
args: [ticketId],
account: userAddress,
});
await walletClient.writeContract(request);