Skip to main content
Glama

get_transaction

Retrieve detailed transaction information from the Solana blockchain using a transaction signature to verify and analyze on-chain activity.

Instructions

Get transaction details by signature

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
signatureYesTransaction signature

Implementation Reference

  • The handler function that executes the get_transaction tool logic by fetching transaction details from the Solana RPC using connection.getTransaction.
    async function handleGetTransaction(args: any) { const { signature } = args; ensureConnection(); const transaction = await connection.getTransaction(signature, { commitment: "confirmed", maxSupportedTransactionVersion: 0 }); if (!transaction) { throw new Error("Transaction not found"); } return { signature, slot: transaction.slot, blockTime: transaction.blockTime, fee: transaction.meta?.fee, success: transaction.meta?.err ? false : true, error: transaction.meta?.err }; }
  • The tool schema definition including name, description, and inputSchema for validating the 'signature' parameter.
    { name: "get_transaction", description: "Get transaction details by signature", inputSchema: { type: "object", properties: { signature: { type: "string", description: "Transaction signature" } }, required: ["signature"] } },
  • src/index.ts:1312-1314 (registration)
    The switch case registration that dispatches calls to the get_transaction handler function.
    case "get_transaction": result = await handleGetTransaction(args); break;

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