LLMs.txt: agent-readable Markdown index of this site at /llms.txt
POSTDecrease an LP position

Decrease an LP position

Decreases liquidity in an existing position by a specified percentage. The server derives all position state (liquidity, fees, ticks) from on-chain data. Supports V2 (by token pair), V3, and V4 (by NFT token ID). If simulateTransaction is set to true, the response will include the gas fee.

npx skills add uniswap/uniswap-ai --skill liquidity-planner

Plan LP positions with deep links. Works with Claude Code, Cursor, and other AI coding tools.

Authorization

x-api-keystringrequiredheader
Playground key
You're using a shared playground keyCreate a free account and get your own API keys from the dashboard.
Get your keys

Body

application/json
walletAddressstringrequired
chainIdenumrequireddefault:1
1105613013714319632448018684217432646635042845310143421614222043114570735914481457777777713018453211155111

The unique ID of the blockchain. For a list of supported chains see the FAQ.

protocolenumrequired
V2V3V4

The protocol of the pool.

token0Addressstringrequired
token1Addressstringrequired
nftTokenIdstring

The NFT token ID for V3/V4 positions. Not required for V2.

liquidityPercentageToDecreaseintegerrequired

The percentage of liquidity to remove (1-100).

slippageTolerancenumber

Slippage tolerance as a decimal (e.g., 0.5 for 0.5%).

deadlineinteger

Unix timestamp after which the transaction will revert.

simulateTransactionboolean

If true, the response will include the gas fee.

withdrawAsWethboolean

If true, native tokens will be withdrawn as WETH instead of unwrapping to ETH.

urgencyenum
NORMALFASTURGENT

The urgency level for gas price estimation. Higher urgency results in higher gas price and faster transaction inclusion. Defaults to URGENT if not provided.

Response

Decrease position successful.

requestIdstringrequired

A unique ID for the request.

token0objectrequired

A token with its address and amount, used in LP operations.

token1objectrequired

A token with its address and amount, used in LP operations.

decreaseobjectrequired
gasFeestring

The total estimated gas cost of this transaction (eg. gasLimit multiplied by maxFeePerGas) in the base unit of the chain.