> ## 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.

# ListEvents



## OpenAPI

````yaml openapi/api_v1_data_openapi3_DOCUMENTATION_ONLY.json GET /api/v1/data/events
openapi: 3.0.3
info:
  description: |

    The Data API provides HTTP/JSON REST endpoints for reading and writing data
    to the Chronosphere system.

    Use this link to download the raw Swagger specification:
    <a href="/api/v1/data/swagger.json">/api/v1/data/swagger.json</a>
  title: Data 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: DataV1
paths:
  /api/v1/data/events:
    get:
      tags:
        - DataV1
      operationId: ListEvents
      parameters:
        - description: >-
            Only events which happened_at after this time will be returned. If
            set, happened_before must also be set.

            If no time range is set, defaults to 1 hour ago.
          in: query
          name: happened_after
          schema:
            format: date-time
            type: string
        - description: >-
            Only events which happened_at before this will be returned. If set,
            happened_after must also be set.

            If no time range is set, defaults to now.
          in: query
          name: happened_before
          schema:
            format: date-time
            type: string
        - description: >-
            A query string specifying the query.

            The query supports the following operators:  `(=, =~, !=, !~, AND,
            OR)`

            The query supports nesting using parentheses, and also searching for
            label values by using a dot operator.

            The query supports using either `'` or `"` for identifying strings


            Example queries:

            `type = "my-type"`

            `type="my-type"`

            `type != 'my-type' AND source !~ "my-source|my-other-source"`

            `type =~ "my-type|my-other-type" OR (source != "my-source" AND
            labels.cluster =~ "my-cluster")`
          in: query
          name: query
          schema:
            type: string
        - 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
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/datav1ListEventsResponse'
          description: A successful response.
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/googlerpcStatus'
          description: An unexpected error response.
components:
  schemas:
    datav1ListEventsResponse:
      properties:
        events:
          items:
            $ref: '#/components/schemas/datav1Event'
          type: array
        page:
          $ref: '#/components/schemas/configv1PageResult'
      type: object
    googlerpcStatus:
      properties:
        code:
          format: int32
          type: integer
        details:
          items:
            $ref: '#/components/schemas/protobufAny'
          type: array
        message:
          type: string
      type: object
    datav1Event:
      properties:
        category:
          description: >-
            Change Event categories are case sensitive. Each of the listed
            categories are

            lowercase and must be queried in all lowercase. For example,
            `"category":

            "alerts"` is valid, but `"category": "Alerts"` is invalid.


            Chronosphere Support can add and remove custom categories upon
            request.

            Because categories are case sensitive, custom categories must be
            queried using

            the same case they were created. For example, if you create a
            category called

            `INGEST`, any queries in Changes Explorer must use `INGEST` in all
            uppercase

            as the category to query.
          title: |-
            The category the event belongs to. Must be one of these categories:
             * `alerts`
             * `broadcasts`
             * `chronosphere`
             * `deploys`
             * `feature_flags`
             * `infrastructure`
             * `third_party`
          type: string
        happened_at:
          description: >-
            The time the event occurred. Must be between 24 hours in the past or
            24 hours

            in the future. Defaults to `now` if not specified.
          format: date-time
          type: string
        id:
          description: Unique identifier for the change event.
          readOnly: true
          type: string
        labels:
          additionalProperties:
            type: string
          description: >-
            Map of queryable labels, which are user-supplied key/value pairs
            associated

            with the event.
             * Max labels: 200 per event
             * Max key length: 200 characters
             * Max value length: 5,000 characters
          type: object
        payload_json:
          description: >-
            A string-escaped representation of the original event in JSON
            format. You can

            set only `payload_json` or `payload_object`. This field is not
            queryable. Max

            length: 100,000 characters.
          type: string
        payload_object:
          description: >-
            The JSON payload, if the original event was in key/value format. You
            can set

            only `payload_json` or `payload_object`. Max length: 100,000
            characters.

            This field is input only.
          type: object
        source:
          description: |-
            Identifies where the data originated, in cases where a change to the
            instrumentation or integration is needed. Max length: 50 characters.
          type: string
        title:
          description: >-
            A short description of the event that occurred, such as a commit
            message of

            a code deploy. Max length: 100 characters.
          type: string
        type:
          description: >-
            The event type, which is used to group and differentiate events
            within a

            `category` or `source`.
          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
    protobufAny:
      additionalProperties: {}
      properties:
        '@type':
          type: string
      type: object
  securitySchemes:
    ApiKeyAuth:
      description: Chronosphere API token
      in: header
      name: API-Token
      type: apiKey

````