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

# Get protocol statistics for a given time range



## OpenAPI

````yaml /api-reference/data-api.json post /v1/protocols/stats
openapi: 3.0.0
info:
  title: Range Data API
  description: >-
    The Range Data API for crypto addresses, networks, transactions, and
    entities.
  version: 1.7.8
  contact: {}
servers:
  - url: https://api.range.org
    description: Range API Server
security:
  - Authorization: []
tags:
  - name: Address Information
    description: Get information about a crypto address.
  - name: Entity Information
    description: Get information about entities.
  - name: Network Information
    description: Get information about networks.
  - name: Protocols
    description: Get information about cross-chain protocols.
  - name: Token transfers
    description: Get information about token transfers.
paths:
  /v1/protocols/stats:
    post:
      tags:
        - Protocols
      summary: Get protocol statistics for a given time range
      operationId: getProtocolStats
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ProtocolStatsDto'
      responses:
        '200':
          description: >-
            Returns protocol statistics including transaction counts and
            denomination sums
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProtocolStatsResponseDto'
components:
  schemas:
    ProtocolStatsDto:
      type: object
      properties:
        beginTimestamp:
          type: string
          description: Start timestamp for the query range
          example: '2024-04-09T00:00:00Z'
        endTimestamp:
          type: string
          description: End timestamp for the query range
          example: '2024-04-10T00:00:00Z'
        protocol:
          type: string
          description: Protocol name to filter by
          example: interchain_payments
      required:
        - beginTimestamp
        - endTimestamp
        - protocol
    ProtocolStatsResponseDto:
      type: object
      properties:
        totalTransactions:
          type: number
          description: Total number of transactions
          example: 1234
        totalUsd:
          type: number
          description: Total amount for all denominations in USD
          example: 1000.5
        denomSums:
          description: Sum of amounts for each denomination
          type: array
          items:
            $ref: '#/components/schemas/DenomSumDto'
        timeRange:
          description: Time range of the query
          allOf:
            - $ref: '#/components/schemas/TimeRangeDto'
        protocol:
          type: string
          description: Protocol name
          example: interchain_payments
      required:
        - totalTransactions
        - totalUsd
        - denomSums
        - timeRange
        - protocol
    DenomSumDto:
      type: object
      properties:
        denom:
          type: string
          description: Denomination name
          example: uatom
        total:
          type: number
          description: Total amount for this denomination
          example: 1000.5
        totalUsd:
          type: number
          description: Total amount for this denomination in USD
          example: 1000.5
      required:
        - denom
        - total
        - totalUsd
    TimeRangeDto:
      type: object
      properties:
        start:
          type: string
          description: Start timestamp
          example: '2024-04-09T00:00:00Z'
        end:
          type: string
          description: End timestamp
          example: '2024-04-10T00:00:00Z'
      required:
        - start
        - end
  securitySchemes:
    Authorization:
      scheme: bearer
      bearerFormat: API Key
      description: 'Use Authorization: Bearer <api-key>'
      type: http

````