Contract calls
Read the active chain and addresses from Contracts and status. Use the state-commitment proxy for every call.
Useful reads
| Call | Result |
|---|---|
commitment() | Finalized state root, data root, sequence, action sequence, and forced-inbox cursor |
assetToken() | USDG held by the escrow |
settlementSigner() | Signer that authorizes state transitions |
protocolFeeAccount() | Account that owns accrued protocol fees |
rulesHash() | Economic and state-rule version accepted by the contract |
finalizedRulesHash() | Rule version used by the latest finalized root |
paused() | Whether new deposits and normal withdrawals are paused |
exitChallengePeriod() | Delay before an unchallenged forced exit can finalize |
forcedInboxCount() | Number of queued deposit and exit actions |
reservedExitAssets() | USDG reserved for active forced exits |
exitRequests(account) | Current forced-exit claim for an account |
claimedWithdrawals(nullifier) | Whether a withdrawal has already executed |
Account shares, credit, bets, and results are ordered offchain. Read them through the authenticated settlement API.
Deposit
Approve the USDG asset, then call:
queueDeposit(uint128 assets, address account)Confirm DepositQueued, then submit its transaction hash through the authenticated deposit API.
The ordered deposit mints shares. A direct token transfer does not.
Normal withdrawal
Use POST /api/play/settlement/withdrawals. The root wallet signs authorization version 3. The
message binds account, receiver, assets, maximum shares, nonce, deadline, target chain ID, and
state-commitment address.
The service calculates the credit-first share split and submits submitCommitmentAndWithdraw.
Verify WithdrawalFinalized and the exact receiver amount.
Forced exit
Obtain current proofs and call:
requestForcedExit(
AccountLeaf accountLeaf,
SystemLeaf systemLeaf,
address receiver,
bytes32[] accountProof,
bytes32[] systemProof
)After the challenge period, finalize the exact stored request:
finalizeForcedExit(
address account,
address receiver,
uint64 accountNonce,
uint64 inboxIndex
)A newer settlement-signed receipt can challenge a stale request. Verify the request and finalized events, including credit, share assets, shares, sequence, nonce, and inbox indexes. A transaction hash by itself is not proof of the transfer.