get_largest_accounts
Retrieve the 20 largest Solana accounts by lamport balance using the Model Context Protocol Server for Solana Client. Access essential blockchain data for analysis or monitoring.
Instructions
Returns the 20 largest accounts, by lamport balance.
Returns: str: Largest accounts info in the format "Largest accounts: {accounts}"
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/server.py:189-199 (handler)The handler function for the 'get_largest_accounts' tool. It uses the Solana AsyncClient to fetch the 20 largest accounts by lamport balance from the mainnet-beta RPC and formats the result as a string.@mcp.tool() async def get_largest_accounts() -> str: """Returns the 20 largest accounts, by lamport balance. Returns: str: Largest accounts info in the format "Largest accounts: {accounts}" """ async with AsyncClient(rpc_url) as client: accounts = await client.get_largest_accounts() return f"Largest accounts: {accounts}"