Skip to content

Fee Model

Sweepster's fees are configuration, not hardcoded constants. Every quote flows through the Fee Policy Engine, which resolves the effective fee from layered rules.

Fee layers (highest precedence first)

LayerDescription
Minimum floorA minimum fee in token units applies regardless of other rules
Subscription waiverSubscribed users may receive a fee reduction
Promo campaignTime-boxed discount applied to a user segment
Builder overrideThe builder can set a per-route or per-token override
Token-tier overrideHigher-risk tokens (tier2, tier3) incur an additional fee
Base rateDefault protocol fee rate (basis points of amountIn)

Fee components

A resolved fee breakdown contains:

  • Protocol fee — Sweepster's share (in token units)
  • Builder fee — the builder's markup (in token units); 0 if no builder is attributed
  • TotalprotocolFee + builderFee (the value skimmed from the user)

The feeAmount field in the SweepOrder represents the protocol fee; builderFee is separate. Both are signed by the user as part of the order.

Token tiers

Tokens are classified by the Token Risk Engine:

TierRisk levelDefault fee modifier
tier1Low risk, deep liquidityBase rate
tier2Medium riskHigher base rate
tier3High risk / exoticHighest base rate

The tier field in the quote request is the caller-supplied tier hint. The orchestrator re-screens the token and may adjust it.

Builder markup

Builders can configure a markup in basis points up to their maxBuilderBps cap. The markup is additive on top of the protocol fee. Builders keep 100% of their markup.

See Builder Program — Overview for the full model.

Minimum fee

A minimum fee floor prevents the service from being uneconomical on micro-transfers. The floor is expressed in the canonical asset (e.g. USDC cents) and is applied after all other rules.

How fees are skimmed

Fees are skimmed in the _skimFees function in SweepSettlementBase, atomically as part of settlement. The skimmed amount is deducted from the canonical asset before delivery — the user receives amountIn - totalFee worth of tokenOut at destination (subject to swap slippage).

Non-custodial · Atomic · Audit + bug bounty planned before mainnet value.