V3 DEX Remove Liquidity
Remove liquidity from Uniswap V3 position NFTs with optional fee collection. Supports partial removal (1-100%), fee claiming, WETH unwrapping, and NFT burning. Specify position by token ID. Ideal for: exiting V3 positions, collecting earned fees, rebalancing ranges, closing positions.
Catalog action EVM Onchain wallet Gas send
Remove liquidity from Uniswap V3 position NFTs with optional fee collection. Supports partial removal (1-100%), fee claiming, WETH unwrapping, and NFT burning. Specify position by token ID. Ideal for: exiting V3 positions, collecting earned fees, rebalancing ranges, closing positions.
This action can require a wallet connector, gas, token movement, or an external side effect. Test with simulation or a controlled amount before using it in a live workflow.
At a Glance
| Field | Value |
|---|---|
| Action ID | v3-remove-liquidity |
| Category | EVM Onchain |
| Connector | wallet |
| Requires gas | Yes |
| Funds movement | send |
| Tags | blockchain, evm, dex, liquidity, lp, amm, defi, v3, uniswap, nft, withdraw |
Payload Schema
| Field | Type | Required | Description |
|---|---|---|---|
chainId | number | Yes | Chain |
tokenId | string | Yes | The NFT position token ID to remove liquidity from |
liquidityPercentage | number | No | Percentage of liquidity to remove (1-100). Default: 100 (remove all) |
amount0Min | string | No | Minimum amount of token0 to receive. If not provided, calculated from slippage. |
amount1Min | string | No | Minimum amount of token1 to receive. If not provided, calculated from slippage. |
slippageBps | number | No | Slippage tolerance in basis points (100 = 1%). Default: 50 (0.5%). Used when amount0Min/amount1Min not provided. |
deadlineMinutes | number | No | Transaction deadline in minutes from now. Default: 20 |
collectFees | boolean | No | Whether to collect accumulated fees along with liquidity. Default: true |
burnNft | boolean | No | Whether to burn the NFT after removing all liquidity. Default: false. Only works when removing 100% liquidity. |
unwrapWeth | boolean | No | Whether to unwrap WETH to native ETH when withdrawing. Default: true |
positionManagerAddress | string | No | Optional custom NonfungiblePositionManager address. If not provided, uses default for the chain. |
Result Schema
| Field | Type | Required | Description |
|---|---|---|---|
status | string | Yes | - |
transactionHash | string | Yes | The transaction hash |
tokenId | string | No | NFT position token ID |
liquidityRemoved | string | No | Amount of liquidity removed |
amount0 | string | No | Amount of token0 received (including fees if collected) |
amount1 | string | No | Amount of token1 received (including fees if collected) |
feesCollected0 | string | No | Amount of token0 fees collected |
feesCollected1 | string | No | Amount of token1 fees collected |
burned | boolean | No | Whether the NFT was burned |
Examples
json{ "type": "v3-remove-liquidity", "payload": { "tokenId": "1", "chainId": 8453 }, "children": [], "connector": { "type": "wallet", "id": "conn_wallet" }}
bashcurl -X POST "https://api.b3os.org/v1/actions/v3-remove-liquidity/test" \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "inputs": { "tokenId": "1", "chainId": 8453 }}'
Payload fields can use workflow expressions such as {{$trigger.body.amount}}, {{$nodes.fetch.result.price}}, and {{$props.asset}} when the value should come from a trigger, prior node, or reusable workflow prop.
