Skip to main content
Glama

The agent's x402 spending wallet (address + balance)

x402_wallet
Read-only

Inspect a Solana wallet's address and live SOL and USDC balances, deriving it from the configured signer when no address is given. Use it before payments to confirm USDC is available; read-only.

Instructions

Show a Solana wallet's address and live SOL + USDC balance. With no address, derives the wallet from the configured signer (SOLANA_SECRET_KEY). Call this before pay_and_call to confirm there's USDC to spend. Read-only; never moves funds.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "x402_wallet"
  }
}

Input Schema

NameRequiredDescriptionDefault
addressNoBase58 Solana address to inspect. Omit to use the configured signer wallet.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.2.3
    • removedInput schema / additionalProperties
      Removed value: -false
  2. First observedv0.2.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and destructiveHint=false, so 'Read-only; never moves funds' largely restates them. The description does add genuinely new context: the balance is live (matching idempotentHint=false, since values shift between calls) and the default wallet is derived from the SOLANA_SECRET_KEY environment variable, which signals a configuration prerequisite. No contradiction 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?

Three short sentences: what it returns, the default-wallet rule, then the usage sequencing and safety note. Front-loaded with the outcome and zero filler.

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?

There is no output schema, and the description compensates by naming the returned fields (address, SOL, USDC). For a one-optional-parameter read tool with full annotation coverage, 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 coverage is 100% and the address parameter already documents 'omitting uses the configured signer wallet,' so the description's version of that rule is redundant. The only added value is naming SOLANA_SECRET_KEY as the concrete config source for the default wallet.

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?

States a specific verb+resource: shows a Solana wallet's address plus live SOL and USDC balance. The scope (single wallet lookup, chain + assets named) is precise enough that an agent won't confuse it with pay_and_call, find_services, or inspect_endpoint.

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?

Gives an explicit sequencing rule — call this before pay_and_call to confirm there's USDC to spend — which is real when-to-use guidance tied to a named sibling. It stops short of stating when not to use it (e.g. when a balance is already cached or when the caller just needs a quote), so it's clear but not exhaustive.

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