Skip to content

Commit fe5bf82

Browse files
author
Mostafa Farghaly
committed
update bitcoin rpc calls
1 parent 56362f1 commit fe5bf82

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

bitcoin/rpc.md

+6-2
Original file line numberDiff line numberDiff line change
@@ -119,13 +119,17 @@ kubectl port-forward bitcoin-node-0 8332
119119
In another terminal window call `getblockhash` JSON-RPC method to get the genesis block hash:
120120

121121
```bash
122-
curl -H "Content-Type: application/json" -d '{"id":1, "jsonrpc":"2.0", "method": "getblockhash", "params": [0]}' 0.0.0.0:8332
122+
curl --user "kotal:s3cr3t" --data-binary '{"jsonrpc": "1.0", "id": 1, "method": "getblockhash", "params": [0]}' -H 'content-type: text/plain;' http://0.0.0.0:8332
123123
```
124124

125125
You will get JSON result similar to the following:
126126

127127
```json
128-
{"result":"000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f","error":null,"id":"1"}
128+
{
129+
"result":"000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f",
130+
"error":null,
131+
"id":1
132+
}
129133
```
130134

131135
Finally you can delete the node by:

0 commit comments

Comments
 (0)