Skip to main content
Glama

Withdraw a position

build_vault_withdraw
Read-only

Withdraw a whole position: back as USDC (default; its WETH is swapped) or as both WETH and USDC, with its rewards as USDC (default) or AERO. A closed position's leftovers are collected instead. Returns unsigned transactions to sign in order (and as one EIP-5792 batch), simulated from the wallet, plus a sign_url for a human owner. Nothing is sent.

Input Schema

NameRequiredDescriptionDefault
vaultNoA Panda vault address from list_vaults. Optional: the open WETH/USDC vault when left out.
walletYesThe wallet on Base that will sign (and that owns the positions).
receiveNoUSDC (default) or BOTH (WETH and USDC, no swap).
rewardsNoRewards as USDC (default) or AERO.
token_idYesThe position id (token_id from get_wallet_positions).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior5/5

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

Even though annotations declare readOnlyHint=true, the description adds substantial context the annotations cannot: it returns unsigned transactions to sign in order, packaged as one EIP-5792 batch, simulated from the wallet, plus a sign_url for a human owner, and explicitly states 'Nothing is sent'. This explains why the readOnly hint is coherent for a build/withdraw tool and discloses return shape, batching, and simulation behavior.

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

Conciseness4/5

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

Three dense sentences with the core action front-loaded; the payout default, edge case, and return mechanics each earn their place. The third sentence is long but information-dense rather than padded.

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

Completeness5/5

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

With no output schema, the description compensates by describing the return value (ordered unsigned txs, EIP-5792 batch, simulated from wallet, sign_url) and by noting nothing is broadcast. Combined with 100% schema coverage and clear payout options, an agent has everything needed to invoke it correctly.

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

Parameters3/5

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

Schema description coverage is 100% and the enums are self-documenting, so the schema already carries the parameter burden. The description reinforces the defaults (USDC/USDC) and the swap consequence of receive=BOTH, but adds only marginal meaning beyond the schema text, so the baseline 3 is appropriate.

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

Purpose4/5

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

States a specific verb and resource ('Withdraw a whole position') and scopes it to a Panda vault position with USDC/WETH payout semantics. It is clearly distinguishable from partial-position siblings like build_vault_top_up or build_vault_move, but it never names the other withdraw builders (build_curated_vault_withdraw, build_old_vault_withdraw) it could be confused with.

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

Usage Guidelines3/5

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

Usage is implied by 'whole position' and the edge-case note that a closed position's leftovers are collected instead, which tells the agent this handles both open and closed cases. However, there is no explicit when-to-use vs. when-to-use-something-else routing against the many sibling withdraw builders.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources