Skip to main content
Glama
kukapay

ethereum-validator-queue-mcp

get_validator_status

Retrieve real-time status, balance, and activation/exit details for any Ethereum validator using its public key to monitor staking participation.

Instructions

Get status for a specific Ethereum validator by public key.

Args:
    pubkey (str): The public key of the validator (48-byte hex string starting with '0x')

Returns:
    A string containing:
    - Validator public key
    - Current status (e.g., active_online, pending, exited)
    - Effective balance in ETH
    - Activation epoch (if applicable)
    - Exit epoch (if applicable)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pubkeyYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • main.py:70-100 (handler)
    The handler function for the 'get_validator_status' tool. It takes a validator public key, fetches status data from the beaconcha.in API, and returns formatted status information including status, balance, activation and exit epochs.
    @mcp.tool()
    async def get_validator_status(pubkey: str) -> str:
        """Get status for a specific Ethereum validator by public key.
        
        Args:
            pubkey (str): The public key of the validator (48-byte hex string starting with '0x')
        
        Returns:
            A string containing:
            - Validator public key
            - Current status (e.g., active_online, pending, exited)
            - Effective balance in ETH
            - Activation epoch (if applicable)
            - Exit epoch (if applicable)
        """
        async with httpx.AsyncClient() as client:
            try:
                response = await client.get(f"https://beaconcha.in/api/v1/validator/{pubkey}")
                response.raise_for_status()
                data = response.json()["data"]
                status = data.get("status", "unknown")
                balance = data.get("balance", 0) / 1e9 if data.get("balance") else 0
                return (
                    f"Validator {pubkey}:\n"
                    f"Status: {status}\n"
                    f"Effective Balance: {balance:.2f} ETH\n"
                    f"Activation Epoch: {data.get('activationepoch', 'N/A')}\n"
                    f"Exit Epoch: {data.get('exitepoch', 'N/A')}"
                )
            except Exception as e:
                return f"Error fetching validator status: {str(e)}"
  • main.py:70-70 (registration)
    The @mcp.tool() decorator registers the get_validator_status function as an MCP tool.
    @mcp.tool()
  • main.py:72-84 (schema)
    Docstring provides input schema (pubkey: str) and output description for the tool.
    """Get status for a specific Ethereum validator by public key.
    
    Args:
        pubkey (str): The public key of the validator (48-byte hex string starting with '0x')
    
    Returns:
        A string containing:
        - Validator public key
        - Current status (e.g., active_online, pending, exited)
        - Effective balance in ETH
        - Activation epoch (if applicable)
        - Exit epoch (if applicable)
    """
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It describes the return format in detail but doesn't mention error conditions, rate limits, authentication requirements, or whether this is a read-only operation. The description adds value by specifying the return structure but misses important behavioral context.

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 well-structured with clear sections for Args and Returns, and every sentence adds value. It could be slightly more concise by combining some return value descriptions, but overall it's efficiently organized.

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?

Given the tool has an output schema (though not shown), the description provides comprehensive return value details. For a single-parameter tool with no annotations, the description covers the core functionality well but could benefit from more behavioral context like error handling.

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 provides crucial semantic information about the pubkey parameter that isn't in the schema (0% coverage), specifying it must be a '48-byte hex string starting with '0x''. This adds significant value beyond the basic string type in the schema.

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 ('Get status') and target resource ('specific Ethereum validator by public key'), distinguishing it from sibling tools like get_activation_queue and get_exit_queue which handle different validator lifecycle aspects.

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 on when to use this tool versus alternatives or in what context. The description only states what it does, not when it's appropriate compared to sibling tools.

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/kukapay/ethereum-validator-queue-mcp'

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