Skip to content

Commit 5c8545b

Browse files
Add mixhash to eth_getBlockByNumber and eth_getBlockByHash examples (#494)
* Update changelog link Signed-off-by: Tim Beiko <t.beiko23@gmail.com> * Add mixhash to eth_getBlockByNumber and eth_getBlockByHash Signed-off-by: Tim Beiko <t.beiko23@gmail.com> Co-authored-by: MadelineMurray <43356962+MadelineMurray@users.noreply.github.com>
1 parent 50edb18 commit 5c8545b

File tree

1 file changed

+39
-37
lines changed

1 file changed

+39
-37
lines changed

docs/Reference/API-Methods.md

Lines changed: 39 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -2340,13 +2340,13 @@ block.
23402340
=== "curl HTTP"
23412341

23422342
```bash
2343-
curl -X POST --data '{"jsonrpc":"2.0","method":"eth_getBlockByHash","params":["0x16b69965a5949262642cfb5e86368ddbbe57ab9f17d999174a65fd0e66580d8f", false],"id":53}' http://127.0.0.1:8545
2343+
curl -X POST --data '{"jsonrpc":"2.0","method":"eth_getBlockByHash","params":["0xd5f1812548be429cbdc6376b29611fc49e06f1359758c4ceaaa3b393e2239f9c", false],"id":53}' http://127.0.0.1:8545
23442344
```
23452345

23462346
=== "wscat WS"
23472347

23482348
```bash
2349-
{"jsonrpc":"2.0","method":"eth_getBlockByHash","params":["0x16b69965a5949262642cfb5e86368ddbbe57ab9f17d999174a65fd0e66580d8f", false],"id":53}
2349+
{"jsonrpc":"2.0","method":"eth_getBlockByHash","params":["0xd5f1812548be429cbdc6376b29611fc49e06f1359758c4ceaaa3b393e2239f9c", false],"id":53}
23502350
```
23512351

23522352
=== "JSON result"
@@ -2356,25 +2356,26 @@ block.
23562356
"jsonrpc" : "2.0",
23572357
"id" : 53,
23582358
"result" : {
2359-
"number" : "0x7",
2360-
"hash" : "0x16b69965a5949262642cfb5e86368ddbbe57ab9f17d999174a65fd0e66580d8f",
2361-
"parentHash" : "0xe9bd4b277983580ef0eabad6011891f8b6aff9381a78bd1c4faca374a48b3e09",
2362-
"nonce" : "0x46acb59e85b5bb6d",
2359+
"number" : "0x68b3",
2360+
"hash" : "0xd5f1812548be429cbdc6376b29611fc49e06f1359758c4ceaaa3b393e2239f9c",
2361+
"mixHash" : "0x24900fb3da77674a861c428429dce0762707ecb6052325bbd9b3c64e74b5af9d",
2362+
"parentHash" : "0x1f68ac259155e2f38211ddad0f0a15394d55417b185a93923e2abe71bb7a4d6d",
2363+
"nonce" : "0x378da40ff335b070",
23632364
"sha3Uncles" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
2364-
"logsBloom" : "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
2365-
"transactionsRoot" : "0x7aa0913c235f272eb6ed6ab74ba5a057e0a62c1c1d1dbccfd971221e6b6e83a3",
2366-
"stateRoot" : "0xfaf6520d6e3d24107a4309855593341ab87a1744dbb6eea4e709b92e9c9107ca",
2367-
"receiptsRoot" : "0x056b23fbba480696b65fe5a59b8f2148a1299103c4f57df839233af2cf4ca2d2",
2368-
"miner" : "0xfe3b557e8fb62b89f4916b721be55ceb828dbd73",
2369-
"difficulty" : "0x5",
2370-
"totalDifficulty" : "0x10023",
2371-
"extraData" : "0x",
2372-
"size" : "0x270",
2373-
"gasLimit" : "0x1000000",
2374-
"gasUsed" : "0x5208",
2375-
"timestamp" : "0x5bbbe99f",
2365+
"logsBloom" : "0x00000000000000100000004080000000000500000000000000020000100000000800001000000004000001000000000000000800040010000020100000000400000010000000000000000040000000000000040000000000000000000000000000000400002400000000000000000000000000000004000004000000000000840000000800000080010004000000001000000800000000000000000000000000000000000800000000000040000000020000000000000000000800000400000000000000000000000600000400000000002000000000000000000000004000000000000000100000000000000000000000000000000000040000900010000000",
2366+
"transactionsRoot" : "0x4d0c8e91e16bdff538c03211c5c73632ed054d00a7e210c0eb25146c20048126",
2367+
"stateRoot" : "0x91309efa7e42c1f137f31fe9edbe88ae087e6620d0d59031324da3e2f4f93233",
2368+
"receiptsRoot" : "0x68461ab700003503a305083630a8fb8d14927238f0bc8b6b3d246c0c64f21f4a",
2369+
"miner" : "0xb42b6c4a95406c78ff892d270ad20b22642e102d",
2370+
"difficulty" : "0x66e619a",
2371+
"totalDifficulty" : "0x1e875d746ae",
2372+
"extraData" : "0xd583010502846765746885676f312e37856c696e7578",
2373+
"size" : "0x334",
2374+
"gasLimit" : "0x47e7c4",
2375+
"gasUsed" : "0x37993",
2376+
"timestamp" : "0x5835c54d",
23762377
"uncles" : [ ],
2377-
"transactions" : [ "0x2cc6c94c21685b7e0f8ddabf277a5ccf98db157c62619cde8baea696a74ed18e" ]
2378+
"transactions" : [ "0xa0807e117a8dd124ab949f460f08c36c72b710188f01609595223b325e58e0fc", "0xeae6d797af50cb62a596ec3939114d63967c374fa57de9bc0f4e2b576ed6639d" ]
23782379
}
23792380
}
23802381
```
@@ -2466,13 +2467,13 @@ block.
24662467
=== "curl HTTP"
24672468

24682469
```bash
2469-
curl -X POST --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["0x64", true],"id":1}' http://127.0.0.1:8545
2470+
curl -X POST --data '{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["0x68B3", true],"id":1}' http://127.0.0.1:8545
24702471
```
24712472

24722473
=== "wscat WS"
24732474

24742475
```bash
2475-
{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["0x64", true],"id":1}
2476+
{"jsonrpc":"2.0","method":"eth_getBlockByNumber","params":["0x68B3", true],"id":1}
24762477
```
24772478

24782479
=== "JSON result"
@@ -2482,23 +2483,24 @@ block.
24822483
"jsonrpc" : "2.0",
24832484
"id" : 1,
24842485
"result" : {
2485-
"number" : "0x64",
2486-
"hash" : "0xdfe2e70d6c116a541101cecbb256d7402d62125f6ddc9b607d49edc989825c64",
2487-
"parentHash" : "0xdb10afd3efa45327eb284c83cc925bd9bd7966aea53067c1eebe0724d124ec1e",
2488-
"nonce" : "0x37129c7f29a9364b",
2486+
"number" : "0x68b3",
2487+
"hash" : "0xd5f1812548be429cbdc6376b29611fc49e06f1359758c4ceaaa3b393e2239f9c",
2488+
"mixHash" : "0x24900fb3da77674a861c428429dce0762707ecb6052325bbd9b3c64e74b5af9d",
2489+
"parentHash" : "0x1f68ac259155e2f38211ddad0f0a15394d55417b185a93923e2abe71bb7a4d6d",
2490+
"nonce" : "0x378da40ff335b070",
24892491
"sha3Uncles" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347",
2490-
"logsBloom" : "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
2491-
"transactionsRoot" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
2492-
"stateRoot" : "0x90c25f6d7fddeb31a6cc5668a6bba77adbadec705eb7aa5a51265c2d1e3bb7ac",
2493-
"receiptsRoot" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
2494-
"miner" : "0xbb7b8287f3f0a933474a79eae42cbca977791171",
2495-
"difficulty" : "0x42be722b6",
2496-
"totalDifficulty" : "0x19b5afdc486",
2497-
"extraData" : "0x476574682f4c5649562f76312e302e302f6c696e75782f676f312e342e32",
2498-
"size" : "0x21e",
2499-
"gasLimit" : "0x1388",
2500-
"gasUsed" : "0x0",
2501-
"timestamp" : "0x55ba43eb",
2492+
"logsBloom" : "0x00000000000000100000004080000000000500000000000000020000100000000800001000000004000001000000000000000800040010000020100000000400000010000000000000000040000000000000040000000000000000000000000000000400002400000000000000000000000000000004000004000000000000840000000800000080010004000000001000000800000000000000000000000000000000000800000000000040000000020000000000000000000800000400000000000000000000000600000400000000002000000000000000000000004000000000000000100000000000000000000000000000000000040000900010000000",
2493+
"transactionsRoot" : "0x4d0c8e91e16bdff538c03211c5c73632ed054d00a7e210c0eb25146c20048126",
2494+
"stateRoot" : "0x91309efa7e42c1f137f31fe9edbe88ae087e6620d0d59031324da3e2f4f93233",
2495+
"receiptsRoot" : "0x68461ab700003503a305083630a8fb8d14927238f0bc8b6b3d246c0c64f21f4a",
2496+
"miner" : "0xb42b6c4a95406c78ff892d270ad20b22642e102d",
2497+
"difficulty" : "0x66e619a",
2498+
"totalDifficulty" : "0x1e875d746ae",
2499+
"extraData" : "0xd583010502846765746885676f312e37856c696e7578",
2500+
"size" : "0x334",
2501+
"gasLimit" : "0x47e7c4",
2502+
"gasUsed" : "0x37993",
2503+
"timestamp" : "0x5835c54d",
25022504
"uncles" : [ ],
25032505
"transactions" : [ ]
25042506
}

0 commit comments

Comments
 (0)