mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
[DOCS] Adds prerequisites to enable and disable rule APIs (#135369)
This commit is contained in:
parent
1685eca469
commit
3911c7e63f
3 changed files with 39 additions and 24 deletions
|
@ -33,13 +33,13 @@ For deprecated APIs, refer to <<alerts-api>>.
|
|||
|
||||
include::alerting/create_rule.asciidoc[leveloffset=+1]
|
||||
include::alerting/delete_rule.asciidoc[leveloffset=+1]
|
||||
include::alerting/disable_rule.asciidoc[leveloffset=+1]
|
||||
include::alerting/enable_rule.asciidoc[leveloffset=+1]
|
||||
include::alerting/find_rules.asciidoc[leveloffset=+1]
|
||||
include::alerting/health.asciidoc[leveloffset=+1]
|
||||
include::alerting/get_rules.asciidoc[leveloffset=+1]
|
||||
include::alerting/update_rule.asciidoc[leveloffset=+1]
|
||||
include::alerting/list_rule_types.asciidoc[]
|
||||
include::alerting/enable_rule.asciidoc[]
|
||||
include::alerting/disable_rule.asciidoc[]
|
||||
include::alerting/mute_all_alerts.asciidoc[]
|
||||
include::alerting/mute_alert.asciidoc[]
|
||||
include::alerting/unmute_all_alerts.asciidoc[]
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
[[disable-rule-api]]
|
||||
=== Disable rule API
|
||||
== Disable rule API
|
||||
++++
|
||||
<titleabbrev>Disable rule</titleabbrev>
|
||||
++++
|
||||
|
@ -7,33 +7,41 @@
|
|||
Disable a rule.
|
||||
|
||||
[[disable-rule-api-request]]
|
||||
==== Request
|
||||
=== {api-request-title}
|
||||
|
||||
`POST <kibana host>:<port>/api/alerting/rule/<id>/_disable`
|
||||
|
||||
`POST <kibana host>:<port>/s/<space_id>/api/alerting/rule/<id>/_disable`
|
||||
|
||||
|
||||
=== {api-prereq-title}
|
||||
|
||||
You must have `all` privileges for the appropriate {kib} features, depending on
|
||||
the `consumer` and `rule_type_id` of the rules you're disabling. For example,
|
||||
the *Management* > *Stack Rules* feature, *Analytics* > *Discover* and *{ml-app}*
|
||||
features, *{observability}*, and *Security* features. For more details, refer to
|
||||
<<kibana-feature-privileges>>.
|
||||
|
||||
[[disable-rule-api-path-params]]
|
||||
==== Path parameters
|
||||
=== {api-path-parms-title}
|
||||
|
||||
`id`::
|
||||
(Required, string) The ID of the rule that you want to disable.
|
||||
(Required, string) The ID of the rule that you want to disable.
|
||||
|
||||
`space_id`::
|
||||
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.
|
||||
(Optional, string) An identifier for the space. If `space_id` is not provided in
|
||||
the URL, the default space is used.
|
||||
|
||||
[[disable-rule-api-response-codes]]
|
||||
==== Response code
|
||||
=== {api-response-codes-title}
|
||||
|
||||
`200`::
|
||||
Indicates a successful call.
|
||||
Indicates a successful call.
|
||||
|
||||
==== Example
|
||||
|
||||
Disable a rule with ID:
|
||||
=== {api-examples-title}
|
||||
|
||||
[source,sh]
|
||||
--------------------------------------------------
|
||||
$ curl -X POST api/alerting/rule/41893910-6bca-11eb-9e0d-85d233e3ee35/_disable
|
||||
POST api/alerting/rule/41893910-6bca-11eb-9e0d-85d233e3ee35/_disable
|
||||
--------------------------------------------------
|
||||
// KIBANA
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
[[enable-rule-api]]
|
||||
=== Enable rule API
|
||||
== Enable rule API
|
||||
++++
|
||||
<titleabbrev>Enable rule</titleabbrev>
|
||||
++++
|
||||
|
@ -9,33 +9,40 @@ Enable a rule.
|
|||
WARNING: This API supports <<token-api-authentication>> only.
|
||||
|
||||
[[enable-rule-api-request]]
|
||||
==== Request
|
||||
=== {api-request-title}
|
||||
|
||||
`POST <kibana host>:<port>/api/alerting/rule/<id>/_enable`
|
||||
|
||||
`POST <kibana host>:<port>/s/<space_id>/api/alerting/rule/<id>/_enable`
|
||||
|
||||
=== {api-prereq-title}
|
||||
|
||||
You must have `all` privileges for the appropriate {kib} features, depending on
|
||||
the `consumer` and `rule_type_id` of the rules you're enabling. For example, the
|
||||
*Management* > *Stack Rules* feature, *Analytics* > *Discover* and *{ml-app}*
|
||||
features, *{observability}*, and *Security* features. For more details, refer to
|
||||
<<kibana-feature-privileges>>.
|
||||
|
||||
[[enable-rule-api-path-params]]
|
||||
==== Path parameters
|
||||
=== {api-path-parms-title}
|
||||
|
||||
`id`::
|
||||
(Required, string) The ID of the rule that you want to enable.
|
||||
(Required, string) The ID of the rule that you want to enable.
|
||||
|
||||
`space_id`::
|
||||
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.
|
||||
(Optional, string) An identifier for the space. If `space_id` is not provided in
|
||||
the URL, the default space is used.
|
||||
|
||||
[[enable-rule-api-response-codes]]
|
||||
==== Response code
|
||||
=== {api-response-codes-title}
|
||||
|
||||
`200`::
|
||||
Indicates a successful call.
|
||||
Indicates a successful call.
|
||||
|
||||
==== Example
|
||||
|
||||
Enable a rule with ID:
|
||||
=== {api-examples-title}
|
||||
|
||||
[source,sh]
|
||||
--------------------------------------------------
|
||||
$ curl -X POST api/alerting/rule/41893910-6bca-11eb-9e0d-85d233e3ee35/_enable
|
||||
POST api/alerting/rule/41893910-6bca-11eb-9e0d-85d233e3ee35/_enable
|
||||
--------------------------------------------------
|
||||
// KIBANA
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue