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

# List hot ranges

> List information about hot ranges. If a list of range IDs
is specified, only information about those ranges is returned.

Client must be logged in as a user with admin privileges.



## OpenAPI

````yaml /openapi/cluster-api-v2.json get /ranges/hot/
openapi: 3.0.0
info:
  description: >-
    REST API for querying information about CockroachDB cluster health, nodes,
    ranges,

    sessions, and other meta information. For additional details, see
    cockroachlabs.com/docs/stable/cluster-api.
  title: CockroachDB v2 API
  license:
    name: Business Source License
  version: '2.0'
  x-logo:
    url: https://www.cockroachlabs.com/docs/images/cockroachlabs-logo-170.png
    backgroundColor: '#FFFFFF'
    altText: Cockroach Labs logo
servers:
  - url: https://localhost/api/v2
  - url: http://localhost/api/v2
security: []
paths:
  /ranges/hot/:
    get:
      summary: List hot ranges
      description: |-
        List information about hot ranges. If a list of range IDs
        is specified, only information about those ranges is returned.

        Client must be logged in as a user with admin privileges.
      operationId: listHotRanges
      parameters:
        - description: >-
            ID of node to query, or `local` for local node. If unspecified, all
            nodes are queried.
          name: node_id
          in: query
          schema:
            type: integer
        - description: Maximum number of results to return in this call.
          name: limit
          in: query
          schema:
            type: integer
        - description: Continuation token for results after a past limited run.
          name: start
          in: query
          schema:
            type: string
      responses:
        '200':
          description: Hot ranges response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/hotRangesResponse'
      security:
        - api_session: []
      x-codeSamples:
        - lang: Shell + Curl
          source: |-
            curl --request GET \
              --url 'https://localhost/api/v2/ranges/hot/?node_id=SOME_INTEGER_VALUE&limit=SOME_INTEGER_VALUE&start=SOME_STRING_VALUE' \
              --header 'X-Cockroach-API-Session: REPLACE_KEY_VALUE'
components:
  schemas:
    hotRangesResponse:
      type: object
      title: Response struct for listHotRanges.
      properties:
        next:
          description: |-
            Continuation token for the next paginated call. Use as the `start`
            parameter.
          type: string
          x-go-name: Next
        ranges_by_node_id:
          type: object
          additionalProperties:
            type: array
            items:
              $ref: '#/components/schemas/rangeDescriptorInfo'
          x-go-name: RangesByNodeID
        response_error:
          type: array
          items:
            $ref: '#/components/schemas/responseError'
          x-go-name: Errors
      x-go-package: github.com/cockroachdb/cockroach/pkg/server
    rangeDescriptorInfo:
      description: |-
        Contains a subset of fields from the Cockroach-internal
        range descriptor that are safe to be returned from APIs.
      type: object
      properties:
        end_key:
          description: |-
            The resolved Cockroach-internal key that denotes the end of
            this range.
          type: array
          items:
            type: integer
            format: uint8
          x-go-name: EndKey
        queries_per_second:
          description: |-
            The number of queries per second this range is
            serving. Only set for hot ranges.
          type: number
          format: double
          x-go-name: QueriesPerSecond
        range_id:
          description: The integer ID of this range.
          type: integer
          format: int64
          x-go-name: RangeID
        start_key:
          description: |-
            The resolved Cockroach-internal key that denotes the start of
            this range.
          type: array
          items:
            type: integer
            format: uint8
          x-go-name: StartKey
        store_id:
          description: |-
            The ID of the store this hot range is on. Only set for hot
            ranges.
          type: integer
          format: int32
          x-go-name: StoreID
      x-go-package: github.com/cockroachdb/cockroach/pkg/server
    responseError:
      type: object
      properties:
        error_message:
          type: string
          x-go-name: ErrorMessage
        node_id:
          $ref: '#/components/schemas/NodeID'
      x-go-package: github.com/cockroachdb/cockroach/pkg/server
    NodeID:
      description: |-
        A custom type for a cockroach node ID. (not a raft node ID)
        0 is not a valid NodeID.
      type: integer
      format: int32
      x-go-package: github.com/cockroachdb/cockroach/pkg/roachpb
  securitySchemes:
    api_session:
      description: >-
        Token for logged-in REST session. Use `/login/` to log in and get a
        session token. For additional information, see
        cockroachlabs.com/docs/stable/cluster-api.
      type: apiKey
      name: X-Cockroach-API-Session
      in: header

````