Skip to main content
Glama

zetrix_get_transaction_history

Retrieve completed transaction records from the Zetrix blockchain using transaction hash or block sequence number to verify and analyze transaction history.

Instructions

Get completed transaction records

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
hashNoTransaction hash (optional)
ledgerSeqNoBlock sequence number (optional)

Implementation Reference

  • Core implementation of the getTransactionHistory method in ZetrixClient. Makes an HTTP GET request to the Zetrix RPC endpoint '/getTransactionHistory' with optional hash and ledgerSeq parameters, handles errors, and returns the result.
    async getTransactionHistory(hash?: string, ledgerSeq?: number): Promise<any> { try { const params: any = {}; if (hash) params.hash = hash; if (ledgerSeq) params.ledger_seq = ledgerSeq; const response = await this.client.get("/getTransactionHistory", { params, }); if (response.data.error_code !== 0) { throw new Error( response.data.error_desc || `API Error: ${response.data.error_code}` ); } return response.data.result; } catch (error) { if (axios.isAxiosError(error)) { throw new Error(`Failed to get transaction history: ${error.message}`); } throw error; } }
  • Tool schema definition including name, description, and input schema for 'zetrix_get_transaction_history' used in MCP tools list.
    { name: "zetrix_get_transaction_history", description: "Get completed transaction records", inputSchema: { type: "object", properties: { hash: { type: "string", description: "Transaction hash (optional)", }, ledgerSeq: { type: "number", description: "Block sequence number (optional)", }, }, }, },
  • MCP server handler case for 'zetrix_get_transaction_history' tool. Extracts arguments, calls ZetrixClient.getTransactionHistory, and formats response as MCP content.
    case "zetrix_get_transaction_history": { const result = await zetrixClient.getTransactionHistory( args?.hash as string | undefined, args?.ledgerSeq as number | undefined ); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; }

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/Zetrix-Chain/zetrix-mcp-server'

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