Skip to main content
Glama
botwallet-co

BotWallet MCP Server

botwallet_confirm_withdrawal

Complete approved USDC withdrawals on Solana by performing FROST threshold signing to authorize on-chain transactions using the transaction ID from previous approval events.

Instructions

Complete a withdrawal that was previously approved by the owner. Performs FROST threshold signing to authorize the on-chain transaction.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
transaction_idYesTransaction ID from the withdrawal or approval event

Implementation Reference

  • Handler function for 'botwallet_confirm_withdrawal' which triggers the FROST signing process for an approved withdrawal.
    async handler(args, ctx) {
      try {
        if (!ctx.config.hasSeed || !ctx.config.walletName) {
          return noSeedError('confirm withdrawal (FROST signing)');
        }
    
        const { transaction_id } = args as { transaction_id: string };
    
        const confirmResult = await ctx.sdk.confirmWithdrawal({ withdrawal_id: transaction_id });
        if (!confirmResult.message) {
          return formatToolError(new Error(
            'Withdrawal may have expired or already been completed. Check status with botwallet_get_withdrawal.'
          ));
        }
    
        const mnemonic = loadSeed(ctx.config.walletName);
        const signResult = await frostSignAndSubmit(
          ctx.sdk,
          mnemonic,
          transaction_id,
          confirmResult.message,
        );
    
        return formatResult({
          withdrawn: true,
          ...signResult,
        });
      } catch (e) {
        return formatToolError(e);
      }
    },
  • Input schema definition for the 'botwallet_confirm_withdrawal' tool.
    inputSchema: z.object({
      transaction_id: z.string().describe('Transaction ID from the withdrawal or approval event'),
    }),
  • Registration of 'botwallet_confirm_withdrawal' (as 'confirmWithdrawal') within the withdrawalTools array.
    export const withdrawalTools: ToolDefinition[] = [
      withdraw,
      confirmWithdrawal,
      getWithdrawal,
    ];
Behavior3/5

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

With no annotations provided, the description carries full burden. It discloses key behavioral traits: it's a write operation ('Complete'), requires prior approval, and involves 'FROST threshold signing' for on-chain authorization. However, it lacks details on permissions needed, rate limits, error conditions, or what 'complete' entails operationally (e.g., irreversible transaction).

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?

Two sentences with zero waste: the first states purpose and prerequisite, the second adds technical context (FROST signing). Every word earns its place, and key information is front-loaded.

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

Completeness3/5

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

For a mutation tool with no annotations and no output schema, the description is moderately complete. It covers purpose, prerequisite, and technical mechanism but lacks details on permissions, side effects, return values, or error handling. Given the complexity (cryptographic signing operation), more behavioral context would be beneficial.

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 the schema fully documents the 'transaction_id' parameter. The description adds no additional parameter semantics beyond implying it comes from 'withdrawal or approval event,' which is already covered by the schema's description. Baseline 3 is appropriate as the schema does the heavy lifting.

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 specific action ('Complete a withdrawal') and resource ('withdrawal that was previously approved by the owner'), distinguishing it from siblings like 'botwallet_withdraw' (initiate withdrawal) and 'botwallet_get_withdrawal' (retrieve withdrawal info). It provides the exact verb and scope needed for agent understanding.

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 explicitly states when to use this tool: for withdrawals 'previously approved by the owner,' implying it should not be used for initiating new withdrawals or checking approval status (handled by siblings like 'botwallet_withdraw' and 'botwallet_approval_status'). However, it doesn't explicitly name alternatives or state when-not-to-use scenarios beyond the prerequisite.

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/botwallet-co/mcp'

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