POST /api/alerting/rules/backfill/_find

Spaces method and path for this operation:

post /s/{space_id}/api/alerting/rules/backfill/_find

Refer to Spaces for more information.

Headers

  • kbn-xsrf string Required

    A required header to protect against CSRF attacks

Query parameters

  • end string

    The end date for filtering backfills.

  • page number

    The page number to return.

    Minimum value is 1. Default value is 1.

  • per_page number

    The number of backfills to return per page.

    Minimum value is 0. Default value is 10.

  • rule_ids string

    A comma-separated list of rule identifiers.

  • initiator string

    The initiator of the backfill, either user for manual backfills or system for automatic gap fills.

    Values are user or system.

  • start string

    The start date for filtering backfills.

  • sort_field string

    The field to sort backfills by.

    Values are createdAt or start.

  • sort_order string

    The sort order.

    Values are asc or desc.

Responses

  • 200 application/json

    Indicates a successful call.

    Hide response attributes Show response attributes object
    • data array[object] Required
      Hide data attributes Show data attributes object
      • created_at string Required
      • duration string Required
      • enabled boolean Required
      • end string
      • id string Required
      • initiator string Required

        Values are user or system.

      • initiator_id string
      • rule object Required

        Additional properties are NOT allowed.

        Hide rule attributes Show rule attributes object
        • api_key_created_by_user boolean | null
        • api_key_owner string | null Required
        • consumer string Required
        • created_at string Required
        • created_by string | null Required
        • enabled boolean Required
        • id string Required
        • name string Required
        • params object Required

          The parameters for the rule.

          Additional properties are allowed.

        • revision number Required
        • rule_type_id string Required
        • schedule object Required

          Additional properties are NOT allowed.

          Hide schedule attribute Show schedule attribute object
          • interval string Required
        • tags array[string] Required
        • updated_at string Required
        • updated_by string | null Required
      • schedule array[object] Required
        Hide schedule attributes Show schedule attributes object
        • interval string Required
        • run_at string Required
        • status string Required

          Values are complete, pending, running, error, or timeout.

      • space_id string Required
      • start string Required
      • status string Required

        Values are complete, pending, running, error, or timeout.

    • page number Required
    • per_page number Required
    • total number Required
  • 400

    Indicates an invalid schema or parameters.

  • 403

    Indicates that this call is forbidden.

POST /api/alerting/rules/backfill/_find
curl \
 --request POST 'https://<KIBANA_URL>/api/alerting/rules/backfill/_find' \
 --header "Authorization: $API_KEY" \
 --header "kbn-xsrf: true"
Response examples (200)
{
  "data": [
    {
      "id": "85bdf571-f4fb-4666-a8d2-e05e1220ebc6",
      "rule": {
        "id": "3583a470-74f6-11ed-9801-35303b735aef",
        "name": "my alert",
        "tags": [
          "cpu"
        ],
        "params": {
          "index": [
            "test-index"
          ],
          "aggType": "avg",
          "groupBy": "top",
          "aggField": "sheet.version",
          "termSize": 6,
          "termField": "name.keyword",
          "threshold": [
            1000
          ],
          "timeField": "@timestamp",
          "timeWindowSize": 5,
          "timeWindowUnit": "m",
          "thresholdComparator": ">"
        },
        "enabled": true,
        "consumer": "alerts",
        "revision": 0,
        "schedule": {
          "interval": "1m"
        },
        "created_at": "2022-12-05T23:40:33.132Z",
        "created_by": "elastic",
        "updated_at": "2022-12-05T23:40:33.132Z",
        "updated_by": "elastic",
        "rule_type_id": ".index-threshold",
        "api_key_owner": "elastic"
      },
      "start": "2024-01-01T00:00:00.000Z",
      "status": "pending",
      "enabled": true,
      "duration": "12h",
      "schedule": [
        {
          "run_at": "2024-01-01T12:00:00.000Z",
          "status": "pending",
          "interval": "12h"
        },
        {
          "run_at": "2024-01-02T00:00:00.000Z",
          "status": "pending",
          "interval": "12h"
        }
      ],
      "space_id": "default",
      "initiator": "user",
      "created_at": "2024-01-30T00:00:00.000Z"
    }
  ],
  "page": 1,
  "total": 1,
  "per_page": 10
}