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

[DOCS] Get case status API #128802

Merged
merged 3 commits into from
Mar 30, 2022
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
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 @@ -35,6 +35,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]
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,
}
--------------------------------------------------