Skip to main content
Glama
armorwallet
by armorwallet

unstake_transaction

Process an unstake transaction using a provided request container, generating a swap transaction request as the output. Facilitates blockchain operations by enabling unstaking actions within the Armor Crypto MCP server.

Instructions

Execute an unstake transaction.

Expects a UnstakeTransactionRequestContainer, returns a SwapTransactionRequestContainer.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
unstake_transaction_requestsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
swap_transaction_requestsYes

Implementation Reference

  • MCP tool handler for 'unstake_transaction'. Decorated with @mcp.tool() for automatic registration in FastMCP server. Calls armor_client.unstake_transaction to execute the unstake via API, handles auth check and errors.
    @mcp.tool()
    async def unstake_transaction(unstake_transaction_requests: UnstakeTransactionRequestContainer) -> SwapTransactionRequestContainer:
        """
        Execute an unstake transaction.
        
        Expects a UnstakeTransactionRequestContainer, returns a SwapTransactionRequestContainer.
        """
        if not armor_client:
            return [{"error": "Not logged in"}]
        try:
            result: SwapTransactionRequestContainer = await armor_client.unstake_transaction(unstake_transaction_requests)
            return result
        except Exception as e:
            return [{"error": str(e)}]
  • Input Pydantic model container for the unstake_transaction tool, holding a list of UnstakeTransactionRequest.
    class UnstakeTransactionRequestContainer(BaseModel):
        unstake_transaction_requests: List[UnstakeTransactionRequest]
  • Inner Pydantic model for individual unstake transaction request, containing the quote transaction_id obtained from prior unstake_quote tool call.
    class UnstakeTransactionRequest(BaseModel):
        transaction_id: str = Field(description="unique id of the generated unstake quote")
  • ArmorWalletAPIClient helper method invoked by the MCP handler. Prepares payload from requests and performs POST API call to /transactions/swap/ to execute the unstake transaction.
    async def unstake_transaction(self, data: UnstakeTransactionRequestContainer) -> UnstakeTransactionRequestContainer:
        """Execute the unstake transactions."""
        payload = data.model_dump(exclude_none=True)['unstake_transaction_requests']
        return await self._api_call("POST", "transactions/swap/", payload)
  • @mcp.tool() decorator on the handler function registers 'unstake_transaction' as an MCP tool in the FastMCP server.
    @mcp.tool()
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It mentions execution and the input/output containers but doesn't describe side effects (e.g., funds movement, blockchain interaction), permissions required, error conditions, or transaction finality. 'Execute' implies a write operation, but no safety or consequence details are provided.

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 description is brief (two sentences) and front-loaded with the core purpose. However, the second sentence about input/output types could be more informative. There's no wasted text, but it borders on under-specification.

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

Completeness2/5

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

For a transaction execution tool with no annotations, 0% schema description coverage, and complex financial operations implied by sibling tools, the description is inadequate. It doesn't explain what 'unstake' means, the consequences of execution, error handling, or relationship to quote tools. The output schema exists but doesn't compensate for missing behavioral context.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate. It names the input and output container types but provides no semantic explanation of what 'UnstakeTransactionRequestContainer' contains or what 'transaction_id' represents. The description adds minimal value beyond what's inferable from the schema structure.

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

Purpose3/5

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

The description states 'Execute an unstake transaction' which provides a clear verb ('Execute') and resource ('unstake transaction'), but it doesn't differentiate from sibling tools like 'unstake_quote' or explain what 'unstake' means in this context. It's somewhat vague about the specific action being performed.

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?

No guidance is provided about when to use this tool versus alternatives like 'unstake_quote' or 'stake_transaction'. The description doesn't mention prerequisites, sequencing, or appropriate contexts for invoking this tool.

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/armorwallet/armor-crypto-mcp'

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