get_first_available_block
Retrieve the slot of the lowest confirmed block available on the Solana blockchain using the Model Context Protocol Server for Solana Client.
Instructions
Returns the slot of the lowest confirmed block available.
Returns: str: First available block information
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/server.py:470-479 (handler)The handler function for the MCP tool 'get_first_available_block'. Decorated with @mcp.tool() for automatic registration and schema inference from signature and docstring. It creates an AsyncClient to the Solana RPC, calls get_first_available_block(), and returns a formatted string result.@mcp.tool() async def get_first_available_block() -> str: """Returns the slot of the lowest confirmed block available. Returns: str: First available block information """ async with AsyncClient(rpc_url) as client: block = await client.get_first_available_block() return f"First available block: {block}"