user95976: I'm trying to figure out how to use bitcoin-cli effectively to request a list of 50 blocks.
As far as I am aware, bitcoin-cli getblock list  does not work. Also how to best extract information out of the getblock output.

user48884: You cannot as there currently no way in Bitcoin Core's RPC to get multiple blocks with one command. You will have to issue multiple getblock commands. If you use a JSON-RPC client programmatically, you can use JSON-RPC's batched requests in order to have to only send one JSON-RPC request to execute multiple RPCs and get the results back in one response.
As for how to extract the information, you will need a JSON parser to extract the information. You can use verbosity level 2 in order to get the transactions decoded as well instead of just their txids.

95976: <p>I'm trying to figure out how to use <code>bitcoin-cli</code> effectively to request a list of 50 blocks.</p>

<p>As far as I am aware, <code>bitcoin-cli getblock</code> list  does not work. Also how to best extract information out of the <code>getblock</code> output.</p>
 48884: <p>You cannot as there currently no way in Bitcoin Core's RPC to get multiple blocks with one command. You will have to issue multiple <code>getblock</code> commands. If you use a JSON-RPC client programmatically, you can use JSON-RPC's batched requests in order to have to only send one JSON-RPC request to execute multiple RPCs and get the results back in one response.</p>

<p>As for how to extract the information, you will need a JSON parser to extract the information. You can use verbosity level 2 in order to get the transactions decoded as well instead of just their txids.</p>
