getrawmempool returns only TXID (verbose off), what I'm doing is calling getrawtransaction for each transaction ID to get a transaction hex.

Bitcoin core doesn't support batch requests and each RPC call takes 0.06 sec, for ~ 5000 transactions, it takes 5 min which is so expensive. can I get mempool transactions as hex instantly?

2 Answers 2


Bitcoin core doesn't support batch requests

Yes it does. Bitcoin Core uses the follows the JSON-RPC Specification for batching requests. Just use that with a custom client of your choice to interact with the RPC server to get that information. python-bitcoinrpc makes this easy to do.


Are you sure you need Bitcoin Core and RPC calls for this task?

May be you need some tool for sniffing bitcoin network for all transactions. Have a look to this: https://github.com/sebicas/bitcoin-sniffer

This tool is very old. I am not sure that it works today. Take the main idea.

Another solution is implementing your own RPC-command. Something like "dumpwholemempool". I think it is not too difficult.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.