Fees and staking

Understand 0.5.1 trading fees, fee destinations, membership, and VIP discounts.

This page describes the 0.5.1 development baseline (Pool v24, revision 2, source bcce667b). It does not establish a live deployment or application availability. Historical cohorts, including earlier v24 revisions, require their matching fee and staking contracts.

When fees are charged

A v24 pool charges a protocol fee when you open, close, or reduce a price position, and on direct liquidation.

ActionFee baseMarginal Xi adjustment
Open or mergeRequested gross collateralBalancing discount and an open-only worsening surcharge
Close or reduce leverageCanonical gross payoutBalancing discount, never a surcharge
LiquidationCanonical gross entitlementNo marginal adjustment

A negative close has no positive payout, so it charges no close fee.

Fee calculation

Each pool configures a base fee rate, optional Marginal Xi rates, and a maximum total rate:

final fee = min(
  discounted base fee - balancing discount + open-only worsening surcharge,
  protocol fee cap
)
  • The staking discount applies only to the base fee.
  • The balancing discount applies to the balancing slice of the already-discounted base fee.
  • The worsening surcharge is computed from the worsening slice of an open and is not reduced by either discount.
  • The base fee rate, worsening surcharge rate, and total cap are each bounded by 5%. The balancing discount rate is bounded by 100%.
  • The total cap cannot be lower than the base fee rate, so it can only truncate the surcharge.

When a pool enables the Marginal Xi model, it classifies each action's notional against one canonical checkpoint as balancing, worsening, or neutral. If the exact risk transition cannot be proven, the action is treated conservatively as worsening. This can remove a balancing discount but cannot add a surcharge to a close.

Your maxProtocolFee guard

Guarded opens, closes, and leverage reductions accept maxProtocolFee, an absolute amount of the collateral token. If the final fee exceeds your value, the action reverts with ProtocolFeeExceedsUserMaximum. It does not clamp the fee. A zero value means you accept no protocol fee.

The guard covers only the protocol trading fee, not keeper payments, liquidation incentives, oracle update costs, or gas. Permissionless liquidation provides no user fee cap.

Where fees go

In the 0.5.1 cohort, each collected fee is allocated among these destinations, subject to configuration and eligibility:

DestinationConditionPath
LP shareFee-sharing weight existsCredited to the pool LP fee reserve in collateral
Creator shareActive, eligible creator recipient configuredBooked externally, paid by flush
Referral shareValid referral binding for the tradeBooked externally, paid by flush
TreasuryAlwaysBooked externally, paid by flush

The compatibility field bountyReserveRate is fixed at zero: new trading fees do not fund a liquidation bounty reserve. Historical reserve rights follow their original cohort. Positive liquidation rewards use the target position's payable post-fee residual; see Liquidation.

Configuration bounds each share rate, requires the distributed rates to leave at least a 10% minimum treasury share, and defines no universal default split. The external shares are recorded at trade time and moved by a permissionless flush that is rejected during EmergencyPause. A misconfigured recipient makes the booking fail closed instead of silently rerouting.

The Safety Reserve is not part of this fee flow. When governance withdraws an approved Safety surplus, only the amount above the configured floor can move, and it goes to the pool's fixed treasury. It is not LP income.

Membership and VIP discounts

The 0.5.1 membership profile replaces the historical time-decaying vTIMU score with active staked principal. Pending deposits and principal in an exit request do not count toward VIP qualification. The supported VIP module reads that active balance and reduces only the base fee.

The current source profile specifies the following defaults, in whole membership-token units (18 decimals). These are reference parameters, not a claim that a token or VIP program is live:

VIP tierActive principalBase-fee reduction
VIP0Below 10,0000%
VIP110,0005%
VIP220,00010%
VIP330,00015%
VIP450,00020%
VIP5100,00030%
VIP6300,00040%
VIP71,000,00050%
VIP83,000,00065%
VIP910,000,00080%

A deployed VIP module seals its nine thresholds and rates in its constructor and has no tier setter; each tier is capped at 80%. Factory and pool policy changes use their separate delayed governance paths. Each pool also caps the discount it applies. An unavailable module or invalid rate falls back to the undiscounted base fee. Check the actual module, policy, pool cap, and quote before signing.

Membership staking flow

  1. Confirm the membership token and staking contract for the selected deployment, then approve the token and call stake or the supported stakeWithPermit path.
  2. New principal is pending for 24 hours. stateOf and balanceOf project matured pending principal as active; no separate activation transaction is needed. Adding another deposit restarts the delay for the combined pending amount, while already-active principal stays active.
  3. Call requestExit to move principal into an exit request. It consumes pending principal first, then active principal; the requested amount no longer qualifies for VIP discounts.
  4. After the request's 7-day cooldown, use claimExit or claimExits to receive the principal. Up to 32 exit requests can remain outstanding.

cancelExit returns the requested principal to pending status and restarts the 24-hour delay for the entire combined pending balance, including any existing pending deposit. Already-active principal is unaffected. Pausing new stakes also blocks cancellation, while exit requests and matured claims remain available subject to their own checks, including token activation and custody. Membership principal does not decay with time; the old vTIMU lock-duration model applies only to its historical contracts.

LP rewards

Opt-in fee-sharing liquidity earns the LP fee share from trading fees. Every liquidity lot also accrues trader-paid Funding, which is claimed separately. Neither flow removes trading risk, LP risk, or smart contract risk. See Price market liquidity and Rewards and fees.

On this page