is_connected
Check client connection status with the Solana blockchain using Model Context Protocol Server. Returns connection status in a simple format for quick verification.
Instructions
Health check to verify if the client is connected.
Returns: str: Connection status in the format "Connected: {connected}"
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/server.py:378-387 (handler)The handler function for the 'is_connected' MCP tool. It is decorated with @mcp.tool() for registration and implements the tool logic by creating an AsyncClient instance and calling its is_connected() method to check the connection status to the RPC endpoint.@mcp.tool() async def is_connected() -> str: """Health check to verify if the client is connected. Returns: str: Connection status in the format "Connected: {connected}" """ async with AsyncClient(rpc_url) as client: connected = await client.is_connected() return f"Connected: {connected}"