Skip to main content
Glama

get_account_info

Retrieve detailed account information from the Solana blockchain by providing an account address. This tool enables users to access account data for wallet management and blockchain interactions.

Instructions

Get detailed account information

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYesAccount address

Implementation Reference

  • src/index.ts:212-224 (registration)
    Tool registration in the tools array, including name, description, and input schema for listing via ListToolsRequestSchema
    { name: "get_account_info", description: "Get detailed account information", inputSchema: { type: "object", properties: { address: { type: "string", description: "Account address" } }, required: ["address"] }
  • Input schema defining the required 'address' parameter for the tool
    inputSchema: { type: "object", properties: { address: { type: "string", description: "Account address" } }, required: ["address"]
  • The core handler function that executes the tool logic, fetching and returning Solana account information
    async function handleGetAccountInfo(args: any) { const { address } = args; ensureConnection(); const pubkey = new PublicKey(address); const accountInfo = await connection.getAccountInfo(pubkey); if (!accountInfo) { return { address, exists: false }; } return { address, exists: true, lamports: accountInfo.lamports, owner: accountInfo.owner.toString(), executable: accountInfo.executable, rentEpoch: accountInfo.rentEpoch, dataLength: accountInfo.data.length }; }
  • src/index.ts:1309-1310 (registration)
    Dispatcher case in the CallToolRequestSchema handler that routes calls to the specific handler function
    case "get_account_info": result = await handleGetAccountInfo(args);

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/ExpertVagabond/solana-mcp-server'

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