@gala-chain/chaincode ∙ API
API > collect
Function: collect()
collect(
ctx
,dto
):Promise
\<UserBalanceResDto
>
Parameters
▪ ctx: GalaChainContext
GalaChainContext – The execution context providing access to the GalaChain environment.
▪ dto: CollectDto
Position details (pool information, tickUpper, tickLower).
Returns
UserBalanceResDto
Dev
The collect function allows a user to claim and withdraw accrued fee tokens from a specific liquidity position in a Uniswap V3 pool within the GalaChain ecosystem. It retrieves earned fees based on the user's position details and transfers them to the user's account.