Collect fees

When you add liquidity within a valid price range, all transaction fees generated within this range will be distributed based on the proportional share of effective liquidity from all positions within the current range.

1. Retrieve the fee list

Method: sdk.Almm.getEarnedFeesLimit({ pool_id: string coin_a: string coin_b: string position_id: string }: AlmmCollectFeeParams )

Params

  • pool_id: The pool object ID.

  • position_id: Which position you want to query

  • coin_a: Coin A type.

  • coin_b: Coin B type.

2. Claim fees

Method: sdk.Almm.collectFees({ pool_id: string coin_a: string coin_b: string position_id: string }: AlmmCollectFeeParams )

Params

  • pool_id: The pool object ID.

  • position_id: Which position you want to query

  • coin_a: Coin A type.

  • coin_b: Coin B type.

Last updated