L0vdL0vd

eth_getFilterLogs

Returns every log that matches a log filter's criteria, not just the new ones.

curl https://eth.l0vdinfra.com/YOUR_KEY \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"jsonrpc":"2.0","id":1,"method":"eth_getFilterLogs","params":["0x03000000000000007c9413727849684b"]}'

响应示例

{
  "jsonrpc": "2.0",
  "id": 1,
  "result": []
}
参数与您的端点

参数

filterIdstring必填
ID returned by eth_newFilter or eth_newBlockFilter.

返回值

array All matching log objects.

addressstring
Contract that emitted the log.
topicsarray
Up to four indexed topics; topic 0 is the event signature hash.
datastring
Non-indexed event arguments, ABI-encoded.
blockNumberstring
Block number, hex.
transactionHashstring
Hash of the transaction that emitted the log.
logIndexstring
Position of the log in the block, hex.
removedboolean
true if the log was removed by a reorg.

适用场景

Read every log that matches a filter's criteria, for example right after creating it with a fromBlock.

如何解读结果

Array of log objects, same as eth_getLogs.

提示

  • Large ranges behave like eth_getLogs and can hit result limits; keep fromBlock recent.

相关方法