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

# ListMetricUsagesByMetricName



## OpenAPI

````yaml openapi/api_v1_state_openapi3_DOCUMENTATION_ONLY.json GET /api/v1/state/metric-usages-by-metric-name
openapi: 3.0.3
info:
  description: >

    The State API provides HTTP/JSON REST endpoints for accessing the runtime
    state

    of the Chronosphere system.


    Use this link to download the raw Swagger specification:

    <a href="/api/v1/state/swagger.json">/api/v1/state/swagger.json</a>
  title: State V1 API
  version: v1
servers:
  - url: https://{tenant}.chronosphere.io
    variables:
      tenant:
        default: tenant
        description: tenant ID assigned by the service provider
security:
  - ApiKeyAuth: []
tags:
  - name: StateV1
paths:
  /api/v1/state/metric-usages-by-metric-name:
    get:
      tags:
        - MetricUsagesByMetricName
      operationId: ListMetricUsagesByMetricName
      parameters:
        - description: >-
            Sets the preferred number of items to return per page. If set to
            `0`, the

            server will use its default value. Regardless of the value
            specified, clients

            must never assume how many items will be returned.
          in: query
          name: page.max_size
          schema:
            format: int64
            type: integer
        - description: >-
            An opaque page token that identifies which page the client should
            request.

            An empty value indicates the first page.
          in: query
          name: page.token
          schema:
            type: string
        - in: query
          name: order.ascending
          schema:
            type: boolean
        - in: query
          name: order.by
          schema:
            enum:
              - VALUABLE
              - DPPS
              - UTILITY
              - REFERENCES
              - EXECUTIONS
              - UNIQUE_VALUES
              - UNIQUE_USERS
            type: string
        - description: >-
            Controls the time range over which query executions are included in
            usages. Defaults to `2592000` (30 days).
          in: query
          name: lookback_secs
          schema:
            format: int32
            type: integer
        - description: Glob match string for filtering results by metric name.
          in: query
          name: metric_name_glob
          schema:
            type: string
        - description: >-
            If `true`, responses include the fields `reference_counts_by_type`
            and `query_execution_counts_by_type`. If `false`, these fields are
            returned empty.
          in: query
          name: include_counts_by_type
          schema:
            type: boolean
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/statev1ListMetricUsagesByMetricNameResponse
          description: A successful response.
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/apiError'
          description: An unexpected error response.
components:
  schemas:
    statev1ListMetricUsagesByMetricNameResponse:
      properties:
        page:
          $ref: '#/components/schemas/configv1PageResult'
        usages:
          items:
            $ref: '#/components/schemas/statev1MetricUsageByMetricName'
          type: array
      type: object
    apiError:
      properties:
        message:
          description: An error message describing what went wrong.
          type: string
      type: object
    configv1PageResult:
      properties:
        next_token:
          description: |-
            An opaque page token that identifies the next page of items that the
            client should request. An empty value indicates that there are no
            more items to return.
          type: string
      type: object
    statev1MetricUsageByMetricName:
      properties:
        dpps:
          format: double
          type: number
        metric_name:
          type: string
        usage:
          $ref: '#/components/schemas/statev1MetricUsage'
      type: object
    statev1MetricUsage:
      properties:
        query_execution_counts_by_type:
          $ref: '#/components/schemas/MetricUsageQueryExecutionCountsByType'
        reference_counts_by_type:
          $ref: '#/components/schemas/MetricUsageReferenceCountsByType'
        total_query_executions:
          format: int32
          type: integer
        total_references:
          format: int32
          type: integer
        total_unique_users:
          format: int32
          type: integer
        utility_score:
          format: double
          type: number
      type: object
    MetricUsageQueryExecutionCountsByType:
      properties:
        dashboard:
          format: int32
          type: integer
        explorer:
          format: int32
          type: integer
        external:
          format: int32
          type: integer
      type: object
    MetricUsageReferenceCountsByType:
      properties:
        aggregation_rules:
          format: int32
          type: integer
        dashboards:
          format: int32
          type: integer
        drop_rules:
          format: int32
          type: integer
        monitors:
          format: int32
          type: integer
        recording_rules:
          format: int32
          type: integer
      type: object
  securitySchemes:
    ApiKeyAuth:
      description: Chronosphere API token
      in: header
      name: API-Token
      type: apiKey

````