Skip to main content
Glama
tywenk

Model Context Protocol Server for Solana Client

by tywenk

confirm_transaction

Verify the status of a Solana transaction using the specified signature. Confirm whether the transaction is finalized, confirmed, or processed for accurate on-chain activity tracking.

Instructions

Confirm the transaction identified by the specified signature.

Args: tx_sig (str): Transaction signature to confirm commitment (Optional[str]): Bank state to query ("finalized", "confirmed" or "processed")

Returns: str: Transaction confirmation status

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commitmentNo
tx_sigYes

Implementation Reference

  • The main handler function for the 'confirm_transaction' MCP tool. It is registered via the @mcp.tool() decorator and implements the logic to confirm a Solana transaction signature using the Solana AsyncClient, supporting optional commitment level.
    @mcp.tool()
    async def confirm_transaction(tx_sig: str, commitment: Optional[str] = None) -> str:
        """Confirm the transaction identified by the specified signature.
    
        Args:
            tx_sig (str): Transaction signature to confirm
            commitment (Optional[str]): Bank state to query ("finalized", "confirmed" or "processed")
    
        Returns:
            str: Transaction confirmation status
        """
        async with AsyncClient(rpc_url) as client:
            result = await client.confirm_transaction(
                Signature.from_string(tx_sig),
                Commitment(commitment) if commitment else None,
            )
            return f"Transaction confirmation: {result}"
Behavior2/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 of behavioral disclosure. While it mentions the tool confirms transactions and returns status, it doesn't explain what 'confirm' means operationally (e.g., does it wait for confirmation, check existing status, or trigger confirmation?), what permissions are needed, potential rate limits, or error conditions. For a tool with no annotations, this leaves significant behavioral gaps.

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 efficiently structured with a clear purpose statement followed by well-organized Arg and Return sections. Every sentence earns its place: the first sentence states the core purpose, and the subsequent sections provide essential parameter and return value information without redundancy. The formatting with clear section headers enhances readability.

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?

Given the tool has 2 parameters with 0% schema description coverage and no output schema, the description does a reasonable job explaining parameter semantics but leaves gaps in behavioral context. It doesn't explain what 'transaction confirmation status' means in practice (what values might be returned, what they signify), and with no annotations, it misses important operational details like error handling or performance characteristics. The description is adequate but incomplete for a tool that interacts with transaction states.

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?

The description adds meaningful context for both parameters beyond the schema. For 'tx_sig', it clarifies this is the 'transaction signature to confirm' (schema only shows title 'Tx Sig'). For 'commitment', it explains this is 'Bank state to query' and provides the valid values ('finalized', 'confirmed' or 'processed'), while the schema only shows 'Commitment' with no enum constraints. With 0% schema description coverage, the description compensates well by explaining parameter purposes and valid values.

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?

The description clearly states the tool's purpose: 'Confirm the transaction identified by the specified signature.' It specifies the verb ('confirm') and resource ('transaction'), but doesn't explicitly differentiate from sibling tools like 'get_transaction' or 'get_signature_statuses' which might provide similar transaction status information. The purpose is clear but lacks sibling distinction.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. With sibling tools like 'get_transaction', 'get_signature_statuses', and 'send_transaction' available, there's no indication of when 'confirm_transaction' is the appropriate choice. The description only states what the tool does, not when to use it.

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

Related 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/tywenk/mcp-sol'

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