Referrals
How referral codes and bindings work, and how referral rewards are computed on-chain and claimed.
Timu has an on-chain referral registry that records who referred whom. The registry itself is attribution only: it never moves funds and pays no reward directly. In v24 pools, referral rewards are also computed on-chain from the fee policy and held in a claimable vault.
Referral codes
A referrer registers a unique code. A code is one-time and immutable per referrer: you cannot change your code once registered, and each code string can be claimed by only one referrer.
Binding to a referrer
A referee binds to a code, which records the referrer for that account. You can also bind a code for an account you own. Owned-account binding is limited to the canonical v24 margin account: the registry verifies its canonical creation record and requires the caller to match the recorded owner. Self-referral checks also reject a referrer with the same beneficial owner, including another canonical account owned by that person.
Bindings are not permanent. You can change or clear your referral later, with a few rules:
- Each change starts a cooldown before you can change again (a configurable period, capped at 365 days).
- Re-binding to the exact same referrer and code is rejected as a no-op.
- The registry records each change with its timing, so fee attribution knows which referrer was active for which period.
How referral rewards work on-chain
When a v24 pool charges a trading fee, the pool's FeePolicyV24 decomposes the fee on-chain using the configured referralShareRate and the trader's current registry binding. The referrer's share is booked to the pool's fee ledger, and a permissionless flushProtocolFees transfers booked referral shares to the deployment's ReferralRewardVaultV24.
The referrer then claims accumulated rewards from the vault. A claim smaller than the vault's configured minimum for that token is rejected, so small rewards accumulate until they clear the threshold.
Reward availability depends on the pool's fee configuration. A pool or deployment with a zero referralShareRate books no referral share, and bindings alone do not create rewards.
What the registry does not do
The registry holds no funds and never transfers tokens. It also never decides reward rates; the fee policy configuration does. If a deployment does not wire a pool's fees to the referral vault, no on-chain reward accrues from bindings alone.