rgb_list_transactions
Retrieve a list of on-chain Bitcoin transactions to track payment history and monitor network activity through the RGB Lightning Network MCP Server.
Instructions
List on-chain transactions
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/server.ts:137-150 (registration)Registration of the 'rgb_list_transactions' MCP tool with empty input schema and inline handler that lists on-chain transactions using rgbClient.listTransactions() and returns formatted JSON or error.server.tool( 'rgb_list_transactions', 'List on-chain transactions', {}, async ({}) => { try { const transactions = await rgbClient.listTransactions(); return { content: [{ type: 'text', text: JSON.stringify(transactions, null, 2) }] }; } catch (error) { const errorMessage = error instanceof Error ? error.message : String(error); return { content: [{ type: 'text', text: `Error: ${errorMessage}` }], isError: true }; } } );
- src/server.ts:141-149 (handler)Inline handler function executing the tool logic: calls rgbClient.listTransactions(), stringifies result as text content, handles errors.async ({}) => { try { const transactions = await rgbClient.listTransactions(); return { content: [{ type: 'text', text: JSON.stringify(transactions, null, 2) }] }; } catch (error) { const errorMessage = error instanceof Error ? error.message : String(error); return { content: [{ type: 'text', text: `Error: ${errorMessage}` }], isError: true }; } }
- src/rgb-client.ts:73-75 (helper)Supporting method in RGBApiClientWrapper class that wraps and calls the underlying SDK client.onchain.listTransactions() method.async listTransactions() { return await this.client.onchain.listTransactions(); }