> ## Documentation Index
> Fetch the complete documentation index at: https://chainstack-docs-polygon-erigon-trace-deprecation.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# eth_newFilter | Ronin

> Ronin API method eth_newFilter creates a new filter object for filtering logs that match specific criteria. Chainstack Ronin reference.

Ronin API method `eth_newFilter` creates a new filter object for filtering logs that match specific criteria. This is particularly useful for applications that need to listen for specific events on the Ronin blockchain.

## Parameters

* `fromBlock` (optional): The block number from which to start filtering. This can be a hexadecimal number or one of the strings "earliest", "latest" or "pending". In the provided example, "latest" is used.
* `address` (optional): The address of the contract to filter logs from. This can be a single address as a string or an array of addresses. The example uses "0x0b7007c13325c48911f73a2dad5fa5dcbf808adc".
* `topics` (optional): An array of topics used to filter logs. Each event signature generated by the contract will have a unique topic. The example filters logs with the topic "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef".

## Response

* `result` — the ID of the created filter. This ID can then be used with methods like `eth_getFilterChanges` or `eth_getFilterLogs` to retrieve the logs that match the filter.

<Warning>
  The filters created are stored on the blockchain client instance. The filter is automatically deleted if not polled within a certain time (5 minutes by default).
</Warning>

## Use case

Creating a filter is essential for dApps and services that need to monitor blockchain events efficiently. Instead of retrieving all events and filtering them client-side, `eth_newFilter` allows for specifying precise criteria, reducing the amount of data to process and improving responsiveness.


## OpenAPI

````yaml openapi/ronin_node_api/eth_newFilter.json POST /3997273fc956a67dc6982384500e669e
openapi: 3.0.0
info:
  title: eth_newFilter example
  version: 1.0.0
  description: >-
    This is an API example for eth_newFilter, a method to create a new filter
    object for monitoring log entries  matching the given criteria, using
    specified values.
servers:
  - url: https://ronin-mainnet.core.chainstack.com
security: []
paths:
  /3997273fc956a67dc6982384500e669e:
    post:
      tags:
        - Ethereum Operations
      summary: eth_newFilter
      operationId: newFilter
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                jsonrpc:
                  type: string
                  default: '2.0'
                method:
                  type: string
                  default: eth_newFilter
                id:
                  type: integer
                  default: 1
                params:
                  type: array
                  items:
                    type: object
                    properties:
                      fromBlock:
                        type: string
                        default: latest
                      address:
                        type: string
                        default: '0x0b7007c13325c48911f73a2dad5fa5dcbf808adc'
                      topics:
                        type: array
                        items:
                          type: string
                        default:
                          - >-
                            0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef
                  default:
                    - fromBlock: latest
                      address: '0x0b7007c13325c48911f73a2dad5fa5dcbf808adc'
                      topics:
                        - >-
                          0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef
      responses:
        '200':
          description: The ID of the created filter
          content:
            application/json:
              schema:
                type: object
                properties:
                  jsonrpc:
                    type: string
                  id:
                    type: integer
                  result:
                    type: string

````