<p>Yes, this is supported. As specified by JSON-RPC 2.0, you can send in an array of requests, and receive an array of solutions.</p>

CC BY-SA 3.0
2015-07-09T13:31:10.333Z
2015-07-09T13:31:10.333Z
Pieter Wuille
<p>Am currently sending RPC calls to bitcoind in Python3 in series using JSON:</p>

<pre><code>import json, requests

def pull(command, foo):
    headers = {'content-type': 'application/json'}
    payload = json.dumps({"method": command, "params": [foo], "jsonrpc": "2.0"})
    response = requests.get(serverURL, headers=headers, data=payload)

    return(response.json()['result'])
</code></pre>

<p>Ex:</p>

<pre><code>pull('getblock', BLOCKHASH)
</code></pre>

<p>and hope to improve call speeds by doing batch RPC calls.</p>

<p>Is this possible and how so?</p>

<bitcoind><json-rpc><python>
Does bitcoind accept batch RPC calls?
SLee
# Does bitcoind accept batch RPC calls?

(Asked by: username_0 on 2015-07-09)

Am currently sending RPC calls to bitcoind in Python3 in series using JSON:

```
import json, requests

def pull(command, foo):
    headers = {'content-type': 'application/json'}
    payload = json.dumps({"method": command, "params": [foo], "jsonrpc": "2.0"})
    response = requests.get(serverURL, headers=headers, data=payload)

    return(response.json()['result'])

```

Ex:

```
pull('getblock', BLOCKHASH)

```

and hope to improve call speeds by doing batch RPC calls.

Is this possible and how so?

**Tags:** bitcoind, json-rpc, python


---

## 1 answers

### Answer by username_1 on 2015-07-09. Score: 10

Yes, this is supported. As specified by JSON-RPC 2.0, you can send in an array of requests, and receive an array of solutions.


---

