Fee Types
- LP Fee: Paid by traders to liquidity providers in the asset being swapped in.
- Host Fee: Optional fee paid in Asset B when a pool is created with a
hostNamespace. - Integrator Fee: Optional fee charged at swap time by integrators, paid in Asset B.
All fees for hosts and integrators are assessed and accrued strictly in Asset B of the pool. LP fees are accrued in the asset that the trader provides for the swap. Withdrawals for hosts and integrators are also only in Asset B.
Configuration
- LP Fee: Set per pool via
lpFeeRateBps. - Host Fee: Set per pool via
totalHostFeeRateBpswhen using ahostNamespace.- Hosts register a
minFeeBps; pools using that namespace must settotalHostFeeRateBps >= minFeeBps. - Default split of host fees: Flashnet 60%, Host 40%.
- Hosts register a
- Integrator Fee: Set per swap via
integratorFeeRateBpsand optionalintegratorPublicKey.- Sharing rule: if
integratorFeeRateBps≤ 30 BPS, 0% is shared with Flashnet; above 30 BPS, 30% of the integrator fee is shared with Flashnet.
- Sharing rule: if
Accrual
- Per Trade: Fees are computed and accrued on each swap.
- Asset B Only: Fees accrue only in Asset B.
- Real-Time Updates: Accruals update immediately with executions.
Querying Accrued Fees
Withdrawing Fees (Asset B Only)
Hosts
Integrators
Best Practices
- Surface net amounts in your UI: amounts shown in simulations and executions are already post‑fee.
- Host compliance: Ensure
totalHostFeeRateBpsmeets the host’sminFeeBpswhen using a namespace. - Integrator fee disclosure: Display
integratorFeeRateBpstransparently to users.