Skip to content

Commit

Permalink
[DOCS] Get case status API (#128802)
Browse files Browse the repository at this point in the history
  • Loading branch information
lcawl authored Mar 30, 2022
1 parent ea54524 commit df8eb33
Show file tree
Hide file tree
Showing 2 changed files with 62 additions and 1 deletion.
3 changes: 2 additions & 1 deletion docs/api/cases.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ these APIs:
* <<cases-api-find-connectors>>
* {security-guide}/cases-api-get-case-activity.html[Get all case activity]
* <<cases-api-get-case>>
* <<cases-api-get-status>>
* <<cases-api-get-comments>>
* {security-guide}/cases-get-connector.html[Get current connector]
* {security-guide}/cases-api-get-reporters.html[Get reporters]
* {security-guide}/cases-api-get-status.html[Get status]
* {security-guide}/cases-api-get-tag.html[Get tags]
* {security-guide}/cases-api-push.html[Push case]
* {security-guide}/assign-connector.html[Set default Elastic Security UI connector]
Expand All @@ -37,6 +37,7 @@ include::cases/cases-api-find-cases.asciidoc[leveloffset=+1]
include::cases/cases-api-find-connectors.asciidoc[leveloffset=+1]
//GET
include::cases/cases-api-get-case.asciidoc[leveloffset=+1]
include::cases/cases-api-get-status.asciidoc[leveloffset=+1]
include::cases/cases-api-get-comments.asciidoc[leveloffset=+1]
//UPDATE
include::cases/cases-api-update.asciidoc[leveloffset=+1]
Expand Down
60 changes: 60 additions & 0 deletions docs/api/cases/cases-api-get-status.asciidoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
[[cases-api-get-status]]
== Get case status API
++++
<titleabbrev>Get case status</titleabbrev>
++++

Returns the number of cases that are open, closed, and in progress.

deprecated::[8.1.0]

=== Request

`GET <kibana host>:<port>/api/cases/status`

`GET <kibana host>:<port>/s/<space_id>/api/cases/status`

=== Prerequisite

You must have `read` privileges for the *Cases* feature in the *Management*,
*{observability}*, or *Security* section of the
<<kibana-feature-privileges,{kib} feature privileges>>, depending on the
`owner` of the cases you're seeking.

=== Path parameters

<space_id>::
(Optional, string) An identifier for the space. If it is not specified, the
default space is used.

=== Query parameters

`owner`::
(Optional, string or array of strings) A filter to limit the retrieved case
statistics to a specific set of applications. Valid values are: `cases`,
`observability`, and `securitySolution`. If this parameter is omitted, the
response contains all cases that the user has access to read.

=== Response code

`200`::
Indicates a successful call.

=== Example

[source,sh]
--------------------------------------------------
GET api/cases/status
--------------------------------------------------
// KIBANA

The API returns the following type of information:

[source,json]
--------------------------------------------------
{
"count_open_cases": 27,
"count_in_progress_cases": 50,
"count_closed_cases": 1198,
}
--------------------------------------------------

0 comments on commit df8eb33

Please sign in to comment.