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

# Get Transaction Logs

> Get all logs emitted by a specific transaction



## OpenAPI

````yaml GET /api/v1/customer/{chain}/transactions/{tx_hash}/logs
openapi: 3.1.0
info:
  title: SonarX EVM API - Logs
  description: Query event logs emitted by smart contracts on EVM-compatible networks.
  version: 1.0.0
servers:
  - url: https://api-gateway.sonarx.com
    description: Production API
security:
  - apiKey: []
tags:
  - name: Logs
    description: Query event logs emitted by smart contracts
paths:
  /api/v1/customer/{chain}/transactions/{tx_hash}/logs:
    get:
      tags:
        - Logs
      summary: Get Transaction Logs
      description: Get all logs (events) emitted by a specific transaction.
      operationId: getTransactionLogs
      parameters:
        - $ref: '#/components/parameters/ChainPath'
        - name: tx_hash
          in: path
          description: Transaction hash (66 character hex string starting with 0x)
          required: true
          schema:
            type: string
            pattern: ^0x[a-fA-F0-9]{64}$
            example: '0x00dcc066aad65ae4f10c0fc4ec1fac5d3693c12c01d98a9f6a87448be9b26200'
        - $ref: '#/components/parameters/Limit'
        - $ref: '#/components/parameters/Offset'
      responses:
        '200':
          description: Transaction logs
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransactionLogsResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '500':
          $ref: '#/components/responses/InternalError'
components:
  parameters:
    ChainPath:
      name: chain
      in: path
      description: The blockchain network to query
      required: true
      schema:
        type: string
        enum:
          - polygon
        example: polygon
    Limit:
      name: limit
      in: query
      description: Maximum number of results (1-50)
      required: false
      schema:
        type: integer
        minimum: 1
        maximum: 50
        default: 10
    Offset:
      name: offset
      in: query
      description: Number of results to skip for pagination
      required: false
      schema:
        type: integer
        minimum: 0
        default: 0
  schemas:
    TransactionLogsResponse:
      type: object
      properties:
        transaction_hash:
          type: string
        offset:
          type: integer
        limit:
          type: integer
        result:
          type: array
          items:
            $ref: '#/components/schemas/Log'
        count:
          type: integer
      example:
        transaction_hash: '0x0063079708b5fab44762765a01c17ab2754ebc15cb9ecd0e14fcbbd520452c27'
        offset: 0
        limit: 10
        result:
          - block_number: 81911103
            timestamp: 1768942178
            datetime: '2026-01-20T20:49:38'
            transaction_hash: '0x0063079708b5fab44762765a01c17ab2754ebc15cb9ecd0e14fcbbd520452c27'
            transaction_index: 80
            transaction_from: '0xb63c1246a11edc1e784c39ab95295e4180c5071b'
            transaction_to: '0x9ead30c8518a19f0b493eea1bd5af8fcc5fd4ba2'
            log_index: 551
            address: '0x0000000000000000000000000000000000001010'
            data: >-
              0x000000000000000000000000000000000000000000000000000000174876e80000000000000000000000000000000000000000000000000000000c67112d1f4c00000000000000000000000000000000000000000000000137a7592d6717ce5800000000000000000000000000000000000000000000000000000c4fc8b6374c00000000000000000000000000000000000000000000000137a75944af8eb658
            topics:
              - >-
                0xe6497e3ee548a3372136af2fcb0696db31fc6cf20260707645068bd3fe97f3c4
              - >-
                0x0000000000000000000000000000000000000000000000000000000000001010
              - >-
                0x000000000000000000000000b63c1246a11edc1e784c39ab95295e4180c5071b
              - >-
                0x0000000000000000000000009ead30c8518a19f0b493eea1bd5af8fcc5fd4ba2
            topic1: '0xe6497e3ee548a3372136af2fcb0696db31fc6cf20260707645068bd3fe97f3c4'
            topic2: '0x0000000000000000000000000000000000000000000000000000000000001010'
            topic3: '0x000000000000000000000000b63c1246a11edc1e784c39ab95295e4180c5071b'
            topic4: '0x0000000000000000000000009ead30c8518a19f0b493eea1bd5af8fcc5fd4ba2'
            version: 0
        count: 2
    Log:
      type: object
      properties:
        block_number:
          type: integer
          description: Block number
        timestamp:
          type: integer
          description: Unix timestamp
        datetime:
          type: string
          format: date-time
        transaction_hash:
          type: string
          description: Transaction hash that emitted this log
        transaction_index:
          type: integer
        transaction_from:
          type: string
          description: Transaction sender
        transaction_to:
          type: string
          description: Transaction recipient
        log_index:
          type: integer
          description: Index of the log within the transaction
        address:
          type: string
          description: Contract address that emitted this log
        data:
          type: string
          description: Non-indexed event data
        topics:
          type: array
          items:
            type: string
          description: Indexed event topics
        topic1:
          type: string
          description: First topic (event signature hash)
        topic2:
          type: string
          nullable: true
        topic3:
          type: string
          nullable: true
        topic4:
          type: string
          nullable: true
        version:
          type: integer
      example:
        block_number: 81901160
        timestamp: 1768922292
        datetime: '2026-01-20T15:18:12'
        transaction_hash: '0x00dcc066aad65ae4f10c0fc4ec1fac5d3693c12c01d98a9f6a87448be9b26200'
        transaction_index: 66
        transaction_from: '0xef56899ed9b6b4f3b8d0ea4eb7cec948705c8d2c'
        transaction_to: '0x3c499c542cef5e3811e1192ce70d8cc03d5c3359'
        log_index: 366
        address: '0x3c499c542cef5e3811e1192ce70d8cc03d5c3359'
        data: '0x000000000000000000000000000000000000000000000000000000000050df20'
        topics:
          - '0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef'
          - '0x000000000000000000000000ef56899ed9b6b4f3b8d0ea4eb7cec948705c8d2c'
          - '0x0000000000000000000000003cb9cc9869a65db10f47fd40fb977331cc7e3c9b'
        topic1: '0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef'
        topic2: '0x000000000000000000000000ef56899ed9b6b4f3b8d0ea4eb7cec948705c8d2c'
        topic3: '0x0000000000000000000000003cb9cc9869a65db10f47fd40fb977331cc7e3c9b'
        topic4: null
        version: 0
    ErrorResponse:
      type: object
      properties:
        detail:
          type: string
      required:
        - detail
  responses:
    BadRequest:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    NotFound:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    InternalError:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: apikey
      description: API key for authentication

````