Collect and Compound Fees
Trigger fee collection on an Instant Launch position and compound part of the fees back into it.
An Instant Launch position is held permanently by the FeeSplitter. Two permissionless actions apply to it: collecting fees from the pool and pushing each recipient its share, and increasing a position in its custody.
Collect Fees
collectFees collects the accrued fees of each position from the PoolManager and distributes them to the recipients. The splits are immutable, so the caller cannot redirect them.
Recipients that have a callback receive the token ID and the information about the share of the fees sent to them, so they can be attributed per position.
Compound Fees
The share of fees to be compounded accrues to a CompoundingClaimRecipient.
Any address implementing IClaimExecutor can call claim, which:
- transfers the full token and native amounts attributed to that position toÂ
msg.sender - calls
onClaimedback onÂmsg.sender - requires that the position's liquidity has grown by at least
minLiquidityIncrease, otherwise reverting withÂNotEnoughLiquidityAdded
Collect the position before compounding it. increaseLiquidity reverts with
UncollectedFees while fees are still pending, so a single transaction should
call collectFees before claim.
Caller tip
A call to claim transfers the caller all balances attributed with the position, while the liquidity it must add is fixed.
amounts(tokenId) returns what is currently claimable for a position (not including available fees inside the PoolManager); minLiquidityIncrease() returns the minimum liquidity units that the call must add