Skip to content

Commit 87ebdaa

Browse files
[BUG] Example response in "Find Cases by Alert" topic is outdated (#1695)
1 parent dc59b29 commit 87ebdaa

File tree

1 file changed

+19
-10
lines changed

1 file changed

+19
-10
lines changed
Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,33 @@
11
[[cases-api-find-cases-by-alert]]
2-
=== Find Cases by Alert
2+
=== Find cases by alert
33

4-
Retrieves all case IDs that have a specific alert attached to the cases.
4+
Uses an alert ID (`alert id`) to retrieve the case IDs of any cases the alert is attached to.
55

6-
NOTE: Console supports only Elasticsearch APIs. Console doesn't allow interactions with {kib} APIs. You must use `curl` or another HTTP tool instead. For more information, refer to {kibana-ref}/console-kibana.html[Run {es} API requests].
6+
TIP: The case ID is identical to the case's saved object ID.
77

8-
NOTE: The case ID refers to the cases saved object ID field.
8+
NOTE: Console supports only Elasticsearch APIs. Console doesn't allow interactions with {kib} APIs. You must use `curl` or another HTTP tool instead. For more information, refer to {kibana-ref}/console-kibana.html[Run {es} API requests].
99

1010
==== Request URL
1111

12-
`GET <kibana host>:<port>/api/cases/alerts/<alert ID>`
12+
`GET <kibana host>:<port>/api/cases/alerts/<alert id>`
1313

1414
===== URL parts
1515

16-
The URL must include the `alert ID` of the alert that you are interested in find the associated cases it is attached to.
16+
The URL must include the alert ID, which is used to retrieve any cases the alert is attached to.
1717

1818
===== URL query parameters
1919

2020
[width="100%",options="header"]
2121
|==============================================
2222
|Name |Type |Description |Required
2323

24-
|`owner` |String or String[] |A filter to limit the retrieved case IDs to a specific set of applications. If this parameter is omitted, the response will contain all case IDs that the user has access to read. |No
24+
|`owner` |String or String[] |A filter to limit the retrieved case IDs to a specific set of applications. If you omit this parameter, the response will contain every case ID that the user has `read` access to. |No
2525

2626
|==============================================
2727

2828
===== Example request
2929

30-
Returns all case IDs with the alert `293f1bc0-74f6-11ea-b83a-553aecdb28b6` attached to them:
30+
Returns case IDs with the alert ID `293f1bc0-74f6-11ea-b83a-553aecdb28b6` attached to them:
3131

3232
[source,sh]
3333
--------------------------------------------------
@@ -42,11 +42,20 @@ GET api/cases/alerts/293f1bc0-74f6-11ea-b83a-553aecdb28b6
4242

4343
==== Response payload
4444

45-
A JSON array listing the retrieved case IDs.
45+
A JSON array containing any case IDs associated with the specified alert. Case titles are also retrieved.
4646

4747
===== Example response
4848

4949
[source,json]
5050
--------------------------------------------------
51-
["8af6ac20-74f6-11ea-b83a-553aecdb28b6", "a18b38a0-71b0-11ea-a0b2-c51ea50a58e2"]
51+
[
52+
{
53+
"id": "8af6ac20-74f6-11ea-b83a-553aecdb28b6",
54+
"title": "Test 1"
55+
},
56+
{
57+
"id": "a18b38a0-71b0-11ea-a0b2-c51ea50a58e2",
58+
"title": "Test 2"
59+
}
60+
]
5261
--------------------------------------------------

0 commit comments

Comments
 (0)