Skip to main content
Glama

prepare_uniswap_v3_collect

DestructiveIdempotent

Harvest uncollected fees and tokens owed from a Uniswap V3 LP position by building an unsigned collect transaction. Requires ownership of the tokenId.

Instructions

Build an unsigned Uniswap V3 LP collect transaction — harvests every token the position is owed (decreased liquidity from prior prepare_uniswap_v3_decrease_liquidity calls + accrued swap fees) up to uint128.max per side. Hard-refuses when the tokenId is not owned by wallet. The protocol auto-settles uncollected fee growth into tokensOwed inside the call, so even a position with tokensOwed{0,1}=0 may receive tokens. recipient defaults to the wallet; pass an address to send the harvest elsewhere.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
walletYes
chainNoethereum
tokenIdYesERC-721 tokenId of the LP NFT to harvest fees + tokensOwed from. Must be owned by `wallet`.
recipientNoAddress to receive the harvested tokens. Default: wallet (the position owner).
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate destructiveHint=true and readOnlyHint=false. The description adds valuable behavioral context: hard-refuses if tokenId not owned, protocol auto-settles fee growth, and default recipient. No contradictions with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise and well-structured, with the main purpose front-loaded. Every sentence adds value without redundancy or fluff.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite no output schema, the description covers key behaviors, prerequisites, and parameters. It lacks explicit output format (unsigned transaction), but overall it is fairly complete for a complex DeFi tool. Minor gap in output description.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 50% with only tokenId and recipient described. The description adds meaning beyond schema by explaining wallet as owner that must hold tokenId, recipient defaults to wallet, and chain selection. This compensates for missing schema descriptions, though chain gets no extra detail.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool builds an unsigned Uniswap V3 LP collect transaction to harvest owed tokens, explicitly linking it to prior decrease liquidity calls and fees. It uses specific verbs and resource, and distinguishes from sibling tools like prepare_uniswap_v3_decrease_liquidity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explains when to use (to harvest owed tokens) and prerequisites (prior decrease liquidity calls). It mentions the ownership check and default recipient, providing clear context. It does not explicitly compare with alternatives like rebalance or swap, but given the sibling family, the usage is well-defined.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/szhygulin/vaultpilot-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server