$TOKEN
Staking & claims
Stake the token and earn a share of protocol revenue in USDC. Staking and unstaking both take effect at once - no cooldown, no lock-up.
Stake
Stake from the app with a wallet signature; your stake shares in every distribution from then on. No vesting, no lock-up.
The app sends your signed Stake message to the relayer, which submits it as stakeBySig; direct calls to the staking contract are switched off. The token lets the staking contract move it without an approval, so there is no separate approval transaction. A session key cannot sign staking actions.
Unstake
Unstake the same way, with a wallet signature (unstakeBySig). Your TOKEN returns to your wallet at once, it stops earning, and rewards already credited stay claimable. There is no cooldown.
Claims
Rewards accrue per staked token through a global accumulator. Claim whenever you like (claimBySig): the claim moves your rewards, in USDC, from the staking contract’s balance on the Exchange to yours, from where you can trade with them or withdraw them.
To see your unclaimed rewards without a transaction, read pendingReward(address) on the staking contract. It includes only rewards that have already been distributed.
How rewards arrive
Rewards reach stakers in two steps:
- The Exchange collects the stakers’ share of every fee. Only the staking contract can call
pushStakerFeeson it, which forwards that share, plus any LP value above $10,000,000, to the staking contract’s balance. - A distribution then spreads whatever the staking contract newly received over the current stake. Distributing is reserved for the distributor keeper’s
distributecall and for signedDistributerequests submitted through the relayer; it always pushes the fees first.
Our keeper distributes every 30 seconds when at least $100 is waiting, so nobody has to think about it. While less than 1 TOKEN is staked in total, new rewards wait until there is enough stake to share them.
The math
Each distribution splits the newly received USDC across stakers in proportion to their stake at that moment: no boosts, no tiers, no lock-up multipliers. The contract keeps one number, the rewards per staked token since the start, scaled by 10^36; each account stores its stake and a reward debt. When an account stakes, unstakes or claims, the difference is settled into its credited rewards, rounding down, so the total credited never exceeds what was distributed.