POSTkaia_newFilter

Creates a filter to query logs matching the specified criteria and returns the filter ID. The filter ID is used with kaia_getFilterLogs and kaia_uninstallFilter.

Request Body
idintegerrequired
jsonrpcstringrequired
methodstringrequired
fromBlockstring

Use one of block number or block tag to specify the block.

  • Block number: Hexadecimal string (e.g. "0x1")
  • Block tag: Enum string (e.g. "latest", "earliest", "pending")
    • earliest: The oldest available block on the chain.
    • finalized: A recently finalized block that can no longer be changed. Primarily used in proof-of-stake (PoS) blockchains.
    • safe: A recent block considered safe by the network (immune to reorgs).
    • latest: The most recent block on the chain (may be subject to reorgs).
    • pending: The next block to be mined, including pending transactions in the mempool.

Block number represents the order of blocks in the chain. It is expressed as a hexadecimal string.

toBlockstring

Use one of block number or block tag to specify the block.

  • Block number: Hexadecimal string (e.g. "0x1")
  • Block tag: Enum string (e.g. "latest", "earliest", "pending")
    • earliest: The oldest available block on the chain.
    • finalized: A recently finalized block that can no longer be changed. Primarily used in proof-of-stake (PoS) blockchains.
    • safe: A recent block considered safe by the network (immune to reorgs).
    • latest: The most recent block on the chain (may be subject to reorgs).
    • pending: The next block to be mined, including pending transactions in the mempool.

Block number represents the order of blocks in the chain. It is expressed as a hexadecimal string.

addressstring[]

Enter addresses to filter as an array.

topicsstring[]

Topics is an array of topics for filtering transaction logs. Each topic is expressed as a 32-byte hexadecimal string.

Responses

응답 본문이 없습니다.

X-API-KEY
RequestCU18
cURL
curl -X POST "https://kaia-mainnet.nodit.io/" \
  -H "X-API-KEY: {YOUR_API_KEY}" \
  -H "Content-Type: application/json" \
  -d '{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "kaia_newFilter",
  "params": [
    {
      "fromBlock": "latest"
    }
  ]
}'
Response
Example · 200
"0x1a"