Closed donpdonp closed 3 years ago
You're right, the docs aren't totally clear. What this should say is an int block number as a hex string, in accordance with the official spec: https://eth.wiki/json-rpc/API#the-default-block-parameter. Try this for your payload:
{"jsonrpc":"2.0","method":"eth_getBalance",
"params": ["0xc94770007dda54cF92009BFF0dE90c06F603a09f", "0x2E0827"],"id":1}
(Note: you'll need archive access for a block that far back!)
wow yeah the docs should be amended to say what the second parameter really is. looks like this answers #194 as well. thanks!
Posting eth_getBalance to infura works as expected.
https://infura.io/docs/ethereum/json-rpc/eth-getBalance The docs say the second parameter is 'an integer block number, or the string "latest"'
When I specify a block
This error is thrown
I also tried the blocknumber as a string
"3016743"
just to see what would happen, and that throwsinvalid argument 1: hex string without 0x prefix
.whats going on here?