> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chainstack.com/llms.txt
> Use this file to discover all available pages before exploring further.

# eth_getLogs | Base

Base API method `eth_getLogs` retrieves logs matching specific criteria, such as block range, address, and topics. This method is crucial for applications that need to fetch log data for analysis, display, or monitoring smart contract events.

The example track [USDC token transfers](https://basescan.org/address/0x833589fcd6edb6e08f4c7c32d4f71b54bda02913).

<Check>
  **Get your own node endpoint today**

  [Start for free](https://console.chainstack.com/) and get your app to production levels immediately. No credit card required.

  You can sign up with your GitHub, X, Google, or Microsoft account.
</Check>

## Parameters

* `filterObject` — an object containing filter options:
  * `fromBlock` — the starting block to search for logs. In this example, it's set to `"latest"`.
  * `address` — the contract address to fetch logs from.
  * `topics` — an array of topics to match against the logs.

## Response

* `result` — an array of log objects. Each log object contains details such as whether the log was removed (due to a chain reorganization), log index, transaction index, transaction hash, block hash, block number, address from which the log originated, data contained in the log, and topics associated with the log.

## Use case

The `eth_getLogs` method is essential for:

* DApps that require access to historical log data for analysis or display purposes.
* Services that monitor smart contract interactions over time, needing to retrieve all past events that match certain criteria.
* Analytical tools that process and visualize blockchain data based on logs from specific contracts or transactions.


## OpenAPI

````yaml /openapi/base_node_api/eth_getLogs.json POST /2fc1de7f08c0465f6a28e3c355e0cb14
openapi: 3.0.0
info:
  title: eth_getLogs example with specified values
  version: 1.0.0
  description: >-
    This is an API example for eth_getLogs, a method to retrieve logs matching
    given criteria.
servers:
  - url: https://base-mainnet.core.chainstack.com
security: []
paths:
  /2fc1de7f08c0465f6a28e3c355e0cb14:
    post:
      tags:
        - Ethereum Operations
      summary: eth_getLogs
      operationId: getLogs
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - jsonrpc
                - method
                - id
                - params
              properties:
                jsonrpc:
                  type: string
                  default: '2.0'
                method:
                  type: string
                  default: eth_getLogs
                id:
                  type: integer
                  default: 1
                params:
                  type: array
                  default:
                    - fromBlock: latest
                      address: '0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913'
                      topics:
                        - >-
                          0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef
                  items:
                    type: object
                    properties:
                      fromBlock:
                        type: string
                      address:
                        type: string
                      topics:
                        type: array
                        items:
                          type: string
      responses:
        '200':
          description: Logs matching the criteria
          content:
            application/json:
              schema:
                type: object
                properties:
                  jsonrpc:
                    type: string
                  id:
                    type: integer
                  result:
                    type: array
                    items:
                      type: object
                      properties:
                        removed:
                          type: boolean
                        logIndex:
                          type: string
                        transactionIndex:
                          type: string
                        transactionHash:
                          type: string
                        blockHash:
                          type: string
                        blockNumber:
                          type: string
                        address:
                          type: string
                        data:
                          type: string
                        topics:
                          type: array
                          items:
                            type: string

````