Stake
The stake contract is deployed at the $REQUIEM token address with tools/deploy.sh stake and wired once into the Feeds contract (setStake). Two payments reach it: the protocol share of every final round, in USDC, which Feeds approves and hands over through notifyUSDC(amount) when anyone calls pushProtocol(), and the stakers' share of every slash or lost dispute bond, in HYPE, which the Court sends as a plain transfer from pushProtocol(address(0)).
How a payment is shared
- Each payment is booked in the block it arrives, pro rata to the bonded balances of that block, through one running index per asset. There is no payout window: what you are owed rises the moment a payment lands.
- A bond earns from the next payment after it is made; it never shares a payment that arrived before it.
- The remainder of each division is carried into the next payment, so rounding never loses or doubles income; each account's figure rounds down.
- A payment that arrives while nothing is bonded waits in its asset's pot and is booked by the next payment in that asset, or by anyone calling
bookParked()once something is bonded.
Bond, unbond, collect
bond(amount)after approving $REQUIEM. A bonded balance is 0 or at least the minimum bond (1,000 $REQUIEM by default).collect()sends everything owed, USDC and HYPE, at any time.owed(account)reads it.beginUnbond(amount)moves tokens to the account's unbonding slot. They stop earning at once and can be withdrawn withwithdrawUnbonded()seven days after the latest request: a second request joins the slot and restarts the seven days. What stays bonded must be 0 or at least the minimum.rebond()puts the whole unbonding slot back into the bonded balance at any time; it earns again from the next payment.positionOf(account)returns the bonded balance, the unbonding slot and the time it can be withdrawn.
The stake contract has no owner and no sweep: only a bonder moves its tokens and its income. It assumes plain ERC-20 behaviour for $REQUIEM and USDC. Unbonding tokens earn nothing and stay withdrawable only by their owner. The app's Back the network page runs every call above from a browser wallet.