eth_newFilter

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Parameters

OBJECT - The filter object

Object NameRequiredTypeDetail
address❌String/ArrayAddress or a list of addresses from which logs should originate.
fromBlock❌StringA hex code of an integer that represents the block number, "latest", "pending", or "earliest".
toBlock❌StringA hex code of an integer that represents the block number, "latest", "pending", or "earliest".
topics❌ArrayArray of 32 Bytes DATA topics. Topics are order-dependent.
"params": [
  {
    "fromBlock": "0xDC7F79",
    "toBlock": "0xDC7F7B",
    "address": "0xea674fdde714fd979de3edf0f56aa9716b898ec8",
    "topics": [
      "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef"
    ]
  }  
]
📘

Specifying topic filters:
Topics are order-dependent. A transaction with a log with topics [A, B] will be matched by the following topic filters:

  • [] - anything
  • [A] - A in first position (and anything after)
  • [null, B] - anything in first position AND B in second position (and anything after)
  • [A, B] - A in first position AND B in second position (and anything after
  • [[A, B], [A, B]] - (A OR B) in first position AND (A OR B) in second position (and anything after)

Result

A hex code of an integer that represents the newly created filter ID.

Example

Request

curl <your-endpoint> \
    -X POST \
    -H "Content-Type: application/json" \
    -d '{"jsonrpc":"2.0","method":"eth_newFilter","params":[{"fromBlock": "0xDC7F79","toBlock": "0xDC7F7B","address": "0xea674fdde714fd979de3edf0f56aa9716b898ec8","topics": ["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef"]}],"id":0}'

Return

{
    "id": 0,
    "jsonrpc": "2.0",
    "result": "0x62c0479d0f17f56ceaf72a569d23dcba"
}
Path Params
string
required
Defaults to 2a784342279147889d308a2fa28cdbeb
Body Params
string
Defaults to {"jsonrpc":"2.0","method":"eth_getProof","params":["0x5ecddc1ac099074ae965d140a7c62bd71b7fc80a",["0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"],"latest"],"id":1}
Responses

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json