{
"id": 1,
"jsonrpc": "2.0",
"method": "eth_getLogs",
"params": [{
"fromBlock": "0x1",
"toBlock": "latest",
"address": "0xa0b86a33e6776e1e627e5c82df4c0cf77b8bb0c9"
}]
}
{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"removed": false,
"logIndex": "0x1",
"transactionIndex": "0x0",
"transactionHash": "0xdf829c5a142f1fccd7d8216c5785ac562ff41e2dcfdf5785ac562ff41e2dcf",
"blockHash": "0x8216c5785ac562ff41e2dcfdf5785ac562ff41e2dcfdf829c5a142f1fccd7d",
"blockNumber": "0x1b4",
"address": "0x16c5785ac562ff41e2dcfdf829c5a142f1fccd7d",
"data": "0x0000000000000000000000000000000000000000000000000000000000000000",
"topics": [
"0x59ebeb90bc63057b6515673c3ecf9438e5058bca0f92585014eced636878c9a5"
]
}
]
}
Get an array of all logs matching a given filter object
{
"id": 1,
"jsonrpc": "2.0",
"method": "eth_getLogs",
"params": [{
"fromBlock": "0x1",
"toBlock": "latest",
"address": "0xa0b86a33e6776e1e627e5c82df4c0cf77b8bb0c9"
}]
}
{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"removed": false,
"logIndex": "0x1",
"transactionIndex": "0x0",
"transactionHash": "0xdf829c5a142f1fccd7d8216c5785ac562ff41e2dcfdf5785ac562ff41e2dcf",
"blockHash": "0x8216c5785ac562ff41e2dcfdf5785ac562ff41e2dcfdf829c5a142f1fccd7d",
"blockNumber": "0x1b4",
"address": "0x16c5785ac562ff41e2dcfdf829c5a142f1fccd7d",
"data": "0x0000000000000000000000000000000000000000000000000000000000000000",
"topics": [
"0x59ebeb90bc63057b6515673c3ecf9438e5058bca0f92585014eced636878c9a5"
]
}
]
}
Show Filter object properties
Show Log object properties
{
"id": 1,
"jsonrpc": "2.0",
"method": "eth_getLogs",
"params": [{
"fromBlock": "0x1",
"toBlock": "latest",
"address": "0xa0b86a33e6776e1e627e5c82df4c0cf77b8bb0c9"
}]
}
{
"id": 1,
"jsonrpc": "2.0",
"result": [
{
"removed": false,
"logIndex": "0x1",
"transactionIndex": "0x0",
"transactionHash": "0xdf829c5a142f1fccd7d8216c5785ac562ff41e2dcfdf5785ac562ff41e2dcf",
"blockHash": "0x8216c5785ac562ff41e2dcfdf5785ac562ff41e2dcfdf829c5a142f1fccd7d",
"blockNumber": "0x1b4",
"address": "0x16c5785ac562ff41e2dcfdf829c5a142f1fccd7d",
"data": "0x0000000000000000000000000000000000000000000000000000000000000000",
"topics": [
"0x59ebeb90bc63057b6515673c3ecf9438e5058bca0f92585014eced636878c9a5"
]
}
]
}
Code | Message | Description |
---|---|---|
-32602 | Invalid filter parameters | The filter object contains invalid parameters |
-32005 | Limit exceeded | The filter matches too many logs |
4100 | Requested method not supported | The method is not supported by the wallet |
Was this page helpful?