Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix alerting API docs w/ new terminology #95457

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 28 additions & 28 deletions docs/api/alerting.asciidoc
Original file line number Diff line number Diff line change
@@ -1,47 +1,47 @@
[[rules-api]]
== Rules APIs
[[alerting-apis]]
== Alerting APIs

The following APIs are available for managing {kib} rules.
The following APIs are available for {kib} alerting.

* <<rules-create-api, Create rule API>> to create a rule
* <<create-rule-api, Create rule API>> to create a rule

* <<rules-update-api, Update rule API>> to update the attributes for existing rules
* <<update-rule-api, Update rule API>> to update the attributes for existing rules

* <<rules-get-api, Get rule API>> to retrieve a single rule by ID
* <<get-rule-api, Get rule API>> to retrieve a single rule by ID

* <<rules-delete-api, Delete rule API>> to permanently remove a rule
* <<delete-rule-api, Delete rule API>> to permanently remove a rule

* <<rules-find-api, Find rules API>> to retrieve a paginated set of rules by condition
* <<find-rules-api, Find rules API>> to retrieve a paginated set of rules by condition

* <<alerting-list-rule-types-api, List alerting rule types API>> to retrieve a list of rule types
* <<list-rule-types-api, List rule types API>> to retrieve a list of rule types

* <<rules-enable-api, Enable rule API>> to enable a single rule by ID
* <<enable-rule-api, Enable rule API>> to enable a single rule by ID

* <<rules-disable-api, Disable rule API>> to disable a single rule by ID
* <<disable-rule-api, Disable rule API>> to disable a single rule by ID

* <<rules-mute-api, Mute alert API>> to mute alert for a single rule by ID
* <<mute-alert-api, Mute alert API>> to mute alert for a single rule by ID

* <<rules-unmute-api, Unmute alert API>> to unmute alert for a single rule by ID
* <<unmute-alert-api, Unmute alert API>> to unmute alert for a single rule by ID

* <<rules-mute-all-api, Mute all alerts API>> to mute all alerts for a single rule by ID
* <<mute-all-alerts-api, Mute all alerts API>> to mute all alerts for a single rule by ID

* <<rules-unmute-all-api, Unmute all alerts API>> to unmute all alerts for a single rule by ID
* <<unmute-all-alerts-api, Unmute all alerts API>> to unmute all alerts for a single rule by ID

* <<alerting-health-api, Get Alerting framework health API>> to retrieve the health of the Alerting framework
* <<get-alerting-framework-health-api, Get Alerting framework health API>> to retrieve the health of the Alerting framework

For deprecated APIs, refer to <<alerts-legacy-apis>>.
For deprecated APIs, refer to <<alerts-api>>.

include::alerting/create.asciidoc[]
include::alerting/update.asciidoc[]
include::alerting/get.asciidoc[]
include::alerting/delete.asciidoc[]
include::alerting/find.asciidoc[]
include::alerting/create_rule.asciidoc[]
include::alerting/update_rule.asciidoc[]
include::alerting/get_rules.asciidoc[]
include::alerting/delete_rule.asciidoc[]
include::alerting/find_rules.asciidoc[]
include::alerting/list_rule_types.asciidoc[]
include::alerting/enable.asciidoc[]
include::alerting/disable.asciidoc[]
include::alerting/mute_all.asciidoc[]
include::alerting/mute.asciidoc[]
include::alerting/unmute_all.asciidoc[]
include::alerting/unmute.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[]
include::alerting/unmute_alert.asciidoc[]
include::alerting/health.asciidoc[]
include::alerting/legacy/index.asciidoc[]
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
[[rules-create-api]]
[[create-rule-api]]
=== Create rule API
++++
<titleabbrev>Create rule</titleabbrev>
++++

Create {kib} rules.

[[rules-create-api-request]]
[[create-rule-api-request]]
==== Request

`POST <kibana host>:<port>/api/alerting/rule/<id>`

`POST <kibana host>:<port>/s/<space_id>/api/alerting/rule/<id>`

[[rules-create-api-path-params]]
[[create-rule-api-path-params]]
==== Path parameters

`<id>`::
Expand All @@ -22,7 +22,7 @@ Create {kib} rules.
`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[rules-create-api-request-body]]
[[create-rule-api-request-body]]
==== Request body

`name`::
Expand Down Expand Up @@ -80,13 +80,13 @@ There are plans to support multiple other schedule formats in the near future.
=====


[[rules-create-api-request-codes]]
[[create-rule-api-request-codes]]
==== Response code

`200`::
Indicates a successful call.

[[rules-create-api-example]]
[[create-rule-api-example]]
==== Example

[source,sh]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[[rules-delete-api]]
[[delete-rule-api]]
=== Delete rule API
++++
<titleabbrev>Delete rule</titleabbrev>
Expand All @@ -8,14 +8,14 @@ Permanently remove a rule.

WARNING: Once you delete a rule, you cannot recover it.

[[rules-delete-api-request]]
[[delete-rule-api-request]]
==== Request

`DELETE <kibana host>:<port>/api/alerting/rule/<id>`

`DELETE <kibana host>:<port>/s/<space_id>/api/alerting/rule/<id>`

[[rules-delete-api-path-params]]
[[delete-rule-api-path-params]]
==== Path parameters

`id`::
Expand All @@ -24,7 +24,7 @@ WARNING: Once you delete a rule, you cannot recover it.
`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[rules-delete-api-response-codes]]
[[delete-rule-api-response-codes]]
==== Response code

`200`::
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
[[rules-disable-api]]
[[disable-rule-api]]
=== Disable rule API
++++
<titleabbrev>Disable rule</titleabbrev>
++++

Disable a rule.

[[rules-disable-api-request]]
[[disable-rule-api-request]]
==== Request

`POST <kibana host>:<port>/api/alerting/rule/<id>/_disable`

`POST <kibana host>:<port>/s/<space_id>/api/alerting/rule/<id>/_disable`

[[rules-disable-api-path-params]]
[[disable-rule-api-path-params]]
==== Path parameters

`id`::
Expand All @@ -22,7 +22,7 @@ Disable a rule.
`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[rules-disable-api-response-codes]]
[[disable-rule-api-response-codes]]
==== Response code

`200`::
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
[[rules-enable-api]]
[[enable-rule-api]]
=== Enable rule API
++++
<titleabbrev>Enable rule</titleabbrev>
++++

Enable a rule.

[[rules-enable-api-request]]
[[enable-rule-api-request]]
==== Request

`POST <kibana host>:<port>/api/alerting/rule/<id>/_enable`

`POST <kibana host>:<port>/s/<space_id>/api/alerting/rule/<id>/_enable`

[[rules-enable-api-path-params]]
[[enable-rule-api-path-params]]
==== Path parameters

`id`::
Expand All @@ -22,7 +22,7 @@ Enable a rule.
`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[rules-enable-api-response-codes]]
[[enable-rule-api-response-codes]]
==== Response code

`200`::
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[[rules-find-api]]
[[find-rules-api]]
=== Find rules API
++++
<titleabbrev>Find rules</titleabbrev>
Expand All @@ -9,20 +9,20 @@ Retrieve a paginated set of rules based on condition.
NOTE: As rules change in {kib}, the results on each page of the response also
change. Use the find API for traditional paginated results, but avoid using it to export large amounts of data.

[[rules-find-api-request]]
[[find-rules-api-request]]
==== Request

`GET <kibana host>:<port>/api/alerting/rules/_find`

`GET <kibana host>:<port>/s/<space_id>/api/alerting/rules/_find`

[[rules-find-api-path-params]]
[[find-rules-api-path-params]]
==== Path parameters

`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[rules-find-api-query-params]]
[[find-rules-api-query-params]]
==== Query Parameters

NOTE: Rule `params` are stored as a {ref}/flattened.html[flattened field type] and analyzed as keywords.
Expand Down Expand Up @@ -59,7 +59,7 @@ NOTE: Rule `params` are stored as a {ref}/flattened.html[flattened field type] a
It should look like savedObjectType.attributes.title: "myTitle". However, If you used a direct attribute of a saved object, such as `updatedAt`,
you will have to define your filter, for example, savedObjectType.updatedAt > 2018-12-22.

[[rules-find-api-request-codes]]
[[find-rules-api-request-codes]]
==== Response code

`200`::
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
[[rules-get-api]]
[[get-rule-api]]
=== Get rule API
++++
<titleabbrev>Get rule</titleabbrev>
++++

Retrieve a rule by ID.

[[rules-get-api-request]]
[[get-rule-api-request]]
==== Request

`GET <kibana host>:<port>/api/alerting/rule/<id>`

`GET <kibana host>:<port>/s/<space_id>/api/alerting/rule/<id>`

[[rules-get-api-params]]
[[get-rule-api-params]]
==== Path parameters

`id`::
Expand All @@ -22,13 +22,13 @@ Retrieve a rule by ID.
`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[rules-get-api-codes]]
[[get-rule-api-codes]]
==== Response code

`200`::
Indicates a successful call.

[[rules-get-api-example]]
[[get-rule-api-example]]
==== Example

Retrieve the rule object with the ID `41893910-6bca-11eb-9e0d-85d233e3ee35`:
Expand Down
10 changes: 5 additions & 5 deletions docs/api/alerting/health.asciidoc
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
[[alerting-health-api]]
[[get-alerting-framework-health-api]]
=== Get Alerting framework health API
++++
<titleabbrev>Get Alerting framework health</titleabbrev>
++++

Retrieve the health status of the Alerting framework.

[[alerting-health-api-request]]
[[get-alerting-framework-health-api-request]]
==== Request

`GET <kibana host>:<port>/api/alerting/_health`

`GET <kibana host>:<port>/s/<space_id>/api/alerting/_health`

[[alerting-health-api-params]]
[[get-alerting-framework-health-api-params]]
==== Path parameters

`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[alerting-health-api-codes]]
[[get-alerting-framework-health-api-codes]]
==== Response code

`200`::
Indicates a successful call.

[[alerting-health-api-example]]
[[get-alerting-framework-health-api-example]]
==== Example

Retrieve the health status of the Alerting framework:
Expand Down
14 changes: 7 additions & 7 deletions docs/api/alerting/legacy/create.asciidoc
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
[[alerts-legacy-api-create]]
[[alerts-api-create]]
=== Legacy create alert API
++++
<titleabbrev>Legacy create alert</titleabbrev>
++++

deprecated::[7.13.0]

Please use the <<rules-create-api>> instead.
Use the <<create-rule-api>> instead.

Create {kib} alerts.

[[alerts-legacy-api-create-request]]
[[alerts-api-create-request]]
==== Request

`POST <kibana host>:<port>/api/alerts/alert/<id>`

`POST <kibana host>:<port>/s/<space_id>/api/alerts/alert/<id>`

[[alerts-legacy-api-create-path-params]]
[[alerts-api-create-path-params]]
==== Path parameters

`<id>`::
Expand All @@ -26,7 +26,7 @@ Create {kib} alerts.
`space_id`::
(Optional, string) An identifier for the space. If `space_id` is not provided in the URL, the default space is used.

[[alerts-legacy-api-create-request-body]]
[[alerts-api-create-request-body]]
==== Request body

`name`::
Expand Down Expand Up @@ -87,13 +87,13 @@ There are plans to support multiple other schedule formats in the near future.
=====


[[alerts-legacy-api-create-request-codes]]
[[alerts-api-create-request-codes]]
==== Response code

`200`::
Indicates a successful call.

[[alerts-legacy-api-create-example]]
[[alerts-api-create-example]]
==== Example

[source,sh]
Expand Down
Loading