Skip to main content
Glama
Agentic AQUA

Agentic AQUA

Official
by AquaWallet

lw_sweep

Sweep an entire L-BTC balance or a specified Liquid asset balance to one address, with fees deducted from inputs so the targeted wallet balance reaches zero.

Instructions

Sweep the entire L-BTC balance (or full balance of a specific Liquid asset) to one address. Fee is deducted from the inputs — leaves 0 sats of the targeted balance in the wallet. Use this whenever the user says 'send all', 'sweep', 'drain', 'empty wallet', or 'move everything' on Liquid. Asset sweep note: with asset_id set, the asset balance goes to 0 in one tx but L-BTC change may remain because the fee was paid in L-BTC — call lw_sweep again without asset_id to also empty L-BTC.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "wallet_name": "<wallet_name>",
      "address": "<address>"
    },
    "name": "lw_sweep"
  }
}

Input Schema

NameRequiredDescriptionDefault
addressYesDestination Liquid address
asset_idNoOptional asset ID (hex). Omit for an L-BTC sweep. Passing the L-BTC policy asset id is equivalent to omitting.
passwordNoPassword to decrypt mnemonic (if encrypted at rest)
wallet_nameYesName of the wallet
password_fileNoPath to a local file containing the wallet password; keeps the password out of the conversation. Do not combine with password.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

No annotations are provided, so the description carries the full burden. It discloses the key consequences of a mutation: the fee comes out of the inputs, the targeted balance is left at 0 sats, and asset sweeps may leave L-BTC change behind. It does not state permissions, confirmation needs, or irreversibility of the transfer explicitly.

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?

The definition is front-loaded: purpose and balance-zeroing effect come first, trigger phrases second, and the asset caveat last. It is dense but each sentence carries operational value, though the final asset-sweep sentence could be tightened.

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?

For a fund-moving tool with no annotations and no output schema, the description covers what gets drained, where fees come from, and how to complete an asset sweep. It stops short of stating prerequisites like an unlocked wallet or what the returned transaction reference looks like.

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%, so every parameter is already documented, and the schema itself covers the asset_id omission rule and password vs password_file exclusivity. The description adds only the behavioral meaning of asset_id (L-BTC change residue), which is helpful but marginal.

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 states a specific verb (sweep) and resource (entire L-BTC balance or full balance of a specific Liquid asset) and adds scope detail — fee taken from inputs, destination balance goes to zero — that separates it cleanly from lw_send and lw_send_asset.

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

Usage Guidelines5/5

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

It enumerates concrete user phrasings that should trigger this tool ('send all', 'sweep', 'drain', 'empty wallet', 'move everything') on Liquid, which is explicit routing guidance. It also gives a conditional follow-up rule: when sweeping an asset and L-BTC residue remains from the fee, call lw_sweep again without asset_id.

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