Skip to main content
Glama
alexandresanlim

Mempool MCP Server

get-address-txs-mempool

Retrieve pending Bitcoin transactions for a specific address from the mempool to monitor unconfirmed activity.

Instructions

Returns mempool transactions for an address

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
addressYesThe address to get mempool txs for

Implementation Reference

  • Registers the MCP tool 'get-address-txs-mempool' including input schema (address: string) and a thin handler that calls AddressService.getAddressTxsMempool and returns formatted text content.
    private registerGetAddressTxsMempoolHandler(): void {
      this.server.tool(
        "get-address-txs-mempool",
        "Returns mempool transactions for an address",
        {
          address: z.string().describe("The address to get mempool txs for"),
        },
        async ({ address }) => {
          const text = await this.addressService.getAddressTxsMempool({ address });
          return { content: [{ type: "text", text }] };
        }
      );
    }
  • Executes the core logic for retrieving and formatting mempool transactions for the given address using the request service.
    async getAddressTxsMempool({ address }: IAddressParameter): Promise<string> {
      const data = await this.requestService.getAddressTxsMempool({ address });
      return formatResponse<IAddressTxResponse[]>(
        "Address Mempool Transactions",
        data
      );
    }
  • Performs the actual API request to fetch mempool transactions from the backend endpoint `/address/{address}/txs/mempool`.
    async getAddressTxsMempool({ address }: { address: string }): Promise<IAddressTxResponse[] | null> {
      return this.client.makeRequest<IAddressTxResponse[]>(`address/${address}/txs/mempool`);
    }

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/alexandresanlim/mempool-mcp-server'

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