Path parameters
-
id
string Required The identifier for the rule.
Responses
-
200 application/json
Indicates a successful call.
Hide response attributes Show response attributes object
-
actions
array[object] Required Hide actions attributes Show actions attributes object
-
alerts_filter
object Defines a period that limits whether the action runs.
Additional properties are NOT allowed.
Hide alerts_filter attributes Show alerts_filter attributes object
-
query
object Additional properties are NOT allowed.
Hide query attributes Show query attributes object
-
dsl
string A filter written in Elasticsearch Query Domain Specific Language (DSL).
-
filters
array[object] Required A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the
kbn-es-query
package.Hide filters attributes Show filters attributes object
-
$state
object Additional properties are NOT allowed.
Hide $state attribute Show $state attribute object
-
store
string Required A filter can be either specific to an application context or applied globally.
Values are
appState
orglobalState
.
-
-
meta
object Required Additional properties are allowed.
-
query
object Additional properties are allowed.
-
-
kql
string Required A filter written in Kibana Query Language (KQL).
-
-
timeframe
object Additional properties are NOT allowed.
Hide timeframe attributes Show timeframe attributes object
-
days
array[integer] Required Defines the days of the week that the action can run, represented as an array of numbers. For example,
1
represents Monday. An empty array is equivalent to specifying all the days of the week.Values are
1
,2
,3
,4
,5
,6
, or7
. -
hours
object Required Additional properties are NOT allowed.
-
timezone
string Required The ISO time zone for the
hours
values. Values such asUTC
andUTC+1
also work but lack built-in daylight savings time support and are not recommended.
-
-
-
connector_type_id
string Required The type of connector. This property appears in responses but cannot be set in requests.
-
frequency
object Additional properties are NOT allowed.
Hide frequency attributes Show frequency attributes object
-
notify_when
string Required Indicates how often alerts generate actions. Valid values include:
onActionGroupChange
: Actions run when the alert status changes;onActiveAlert
: Actions run when the alert becomes active and at each check interval while the rule conditions are met;onThrottleInterval
: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specifynotify_when
at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.Values are
onActionGroupChange
,onActiveAlert
, oronThrottleInterval
. -
summary
boolean Required Indicates whether the action is a summary.
-
throttle
string | null Required The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.
-
-
group
string The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to
default
. -
id
string Required The identifier for the connector saved object.
-
params
object Required The parameters for the action, which are sent to the connector. The
params
are handled as Mustache templates and passed a default set of context.Additional properties are allowed.
-
use_alert_data_for_template
boolean Indicates whether to use alert data as a template.
-
uuid
string A universally unique identifier (UUID) for the action.
-
-
active_snoozes
array[string] List of active snoozes for the rule.
-
alert_delay
object Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.
Additional properties are NOT allowed.
Hide alert_delay attribute Show alert_delay attribute object
-
active
number Required The number of consecutive runs that must meet the rule conditions.
-
-
api_key_created_by_user
boolean | null Indicates whether the API key that is associated with the rule was created by the user.
-
api_key_owner
string | null Required The owner of the API key that is associated with the rule and used to run background tasks.
-
artifacts
object Additional properties are NOT allowed.
Hide artifacts attributes Show artifacts attributes object
-
dashboards
array[object] Hide dashboards attribute Show dashboards attribute object
-
id
string Required
-
-
investigation_guide
object Additional properties are NOT allowed.
Hide investigation_guide attribute Show investigation_guide attribute object
-
blob
string Required User-created content that describes alert causes and remdiation.
-
-
-
consumer
string Required The name of the application or feature that owns the rule. For example:
alerts
,apm
,discover
,infrastructure
,logs
,metrics
,ml
,monitoring
,securitySolution
,siem
,stackAlerts
, oruptime
. -
created_at
string Required The date and time that the rule was created.
-
created_by
string | null Required The identifier for the user that created the rule.
-
enabled
boolean Required Indicates whether you want to run the rule on an interval basis after it is created.
-
execution_status
object Required Additional properties are NOT allowed.
Hide execution_status attributes Show execution_status attributes object
-
error
object Additional properties are NOT allowed.
-
last_duration
number Duration of last execution of the rule.
-
last_execution_date
string Required The date and time when rule was executed last.
-
status
string Required Status of rule execution.
Values are
ok
,active
,error
,warning
,pending
, orunknown
. -
warning
object Additional properties are NOT allowed.
-
-
flapping
object | null When flapping detection is turned on, alerts that switch quickly between active and recovered states are identified as “flapping” and notifications are reduced.
Additional properties are NOT allowed.
Hide flapping attributes Show flapping attributes object | null
-
look_back_window
number Required The minimum number of runs in which the threshold must be met.
Minimum value is
2
, maximum value is20
. -
status_change_threshold
number Required The minimum number of times an alert must switch states in the look back window.
Minimum value is
2
, maximum value is20
.
-
-
id
string Required The identifier for the rule.
-
is_snoozed_until
string | null The date when the rule will no longer be snoozed.
-
last_run
object | null Additional properties are NOT allowed.
Hide last_run attributes Show last_run attributes object | null
-
alerts_count
object Required Additional properties are NOT allowed.
Hide alerts_count attributes Show alerts_count attributes object
-
outcome
string Required Outcome of last run of the rule. Value could be succeeded, warning or failed.
Values are
succeeded
,warning
, orfailed
. -
outcome_msg
array[string] | null Outcome message generated during last rule run.
-
outcome_order
number Order of the outcome.
-
warning
string | null Warning of last rule execution.
Values are
read
,decrypt
,execute
,unknown
,license
,timeout
,disabled
,validate
,maxExecutableActions
,maxAlerts
,maxQueuedActions
, orruleExecution
.
-
-
mapped_params
object Additional properties are allowed.
-
monitoring
object Monitoring details of the rule.
Additional properties are NOT allowed.
Hide monitoring attribute Show monitoring attribute object
-
run
object Required Rule run details.
Additional properties are NOT allowed.
Hide run attributes Show run attributes object
-
calculated_metrics
object Required Calculation of different percentiles and success ratio.
Additional properties are NOT allowed.
Hide calculated_metrics attributes Show calculated_metrics attributes object
-
p50
number -
p95
number -
p99
number -
success_ratio
number Required
-
-
history
array[object] Required History of the rule run.
Hide history attributes Show history attributes object
-
last_run
object Required Additional properties are NOT allowed.
Hide last_run attributes Show last_run attributes object
-
metrics
object Required Additional properties are NOT allowed.
Hide metrics attributes Show metrics attributes object
-
duration
number Duration of most recent rule run.
-
gap_duration_s
number | null Duration in seconds of rule run gap.
-
gap_range
object | null Additional properties are NOT allowed.
-
total_alerts_created
number | null Total number of alerts created during last rule run.
-
total_alerts_detected
number | null Total number of alerts detected during last rule run.
-
total_indexing_duration_ms
number | null Total time spent indexing documents during last rule run in milliseconds.
-
total_search_duration_ms
number | null Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.
-
-
timestamp
string Required Time of the most recent rule run.
-
-
-
-
mute_all
boolean Required Indicates whether all alerts are muted.
-
muted_alert_ids
array[string] Required List of identifiers of muted alerts.
-
name
string Required The name of the rule.
-
next_run
string | null Date and time of the next run of the rule.
-
notify_when
string | null Indicates how often alerts generate actions. Valid values include:
onActionGroupChange
: Actions run when the alert status changes;onActiveAlert
: Actions run when the alert becomes active and at each check interval while the rule conditions are met;onThrottleInterval
: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specifynotify_when
at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.Values are
onActionGroupChange
,onActiveAlert
, oronThrottleInterval
. -
params
object Required The parameters for the rule.
Additional properties are allowed.
-
revision
number Required The rule revision number.
-
rule_type_id
string Required The rule type identifier.
-
running
boolean | null Indicates whether the rule is running.
-
schedule
object Required Additional properties are NOT allowed.
Hide schedule attribute Show schedule attribute object
-
interval
string Required The interval is specified in seconds, minutes, hours, or days.
-
-
scheduled_task_id
string Identifier of the scheduled task.
-
snooze_schedule
array[object] Hide snooze_schedule attributes Show snooze_schedule attributes object
-
duration
number Required Duration of the rule snooze schedule.
-
id
string Identifier of the rule snooze schedule.
-
rRule
object Required Additional properties are NOT allowed.
Hide rRule attributes Show rRule attributes object
-
byhour
array[number] | null Indicates hours of the day to recur.
-
byminute
array[number] | null Indicates minutes of the hour to recur.
-
bymonth
array[number] | null Indicates months of the year that this rule should recur.
-
bymonthday
array[number] | null Indicates the days of the month to recur.
-
bysecond
array[number] | null Indicates seconds of the day to recur.
-
bysetpos
array[number] | null A positive or negative integer affecting the nth day of the month. For example, -2 combined with
byweekday
of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just usebyweekday
. -
byweekday
array[string | number] | null Indicates the days of the week to recur or else nth-day-of-month strings. For example, "+2TU" second Tuesday of month, "-1FR" last Friday of the month, which are internally converted to a
byweekday/bysetpos
combination. -
byweekno
array[number] | null Indicates number of the week hours to recur.
-
byyearday
array[number] | null Indicates the days of the year that this rule should recur.
-
count
number Number of times the rule should recur until it stops.
-
dtstart
string Required Rule start date in Coordinated Universal Time (UTC).
-
freq
integer Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.
Values are
0
,1
,2
,3
,4
,5
, or6
. -
interval
number Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.
-
tzid
string Required Indicates timezone abbreviation.
-
until
string Recur the rule until this date.
-
wkst
string Indicates the start of week, defaults to Monday.
Values are
MO
,TU
,WE
,TH
,FR
,SA
, orSU
.
-
-
skipRecurrences
array[string] Skips recurrence of rule on this date.
-
-
tags
array[string] Required The tags for the rule.
-
throttle
string | null Deprecated Deprecated in 8.13.0. Use the
throttle
property in the actionfrequency
object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values. -
updated_at
string Required The date and time that the rule was updated most recently.
-
updated_by
string | null Required The identifier for the user that updated this rule most recently.
-
view_in_app_relative_url
string | null Relative URL to view rule in the app.
-
-
Indicates an invalid schema or parameters.
-
Indicates that this call is forbidden.
-
Indicates a rule with the given ID does not exist.
curl \
--request GET 'https://<KIBANA_URL>/api/alerting/rule/{id}' \
--header "Authorization: $API_KEY"