Skip to content

Commit

Permalink
[DOCS] Automate docs for create/update/delete case APIs (#142929)
Browse files Browse the repository at this point in the history
  • Loading branch information
lcawl authored Oct 18, 2022
1 parent 493741a commit f92c76c
Show file tree
Hide file tree
Showing 23 changed files with 2,485 additions and 556 deletions.
2 changes: 1 addition & 1 deletion docs/api-generated/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ or a similar tool that can generate HTML output from OAS.
. Generate HTML output. For example:

```
openapi-generator-cli generate -g html -i ~/kibana/x-pack/plugins/cases/docs/openapi/entrypoint.yaml -o ~/kibana/docs/api-generated/cases -t ~/kibana/docs/api-generated/template
openapi-generator-cli generate -g html -i ~/kibana/x-pack/plugins/cases/docs/openapi/bundled.yaml -o ~/kibana/docs/api-generated/cases -t ~/kibana/docs/api-generated/template
openapi-generator-cli generate -g html -i ~/kibana/x-pack/plugins/ml/common/openapi/ml_apis_v3.yaml -o ~/kibana/docs/api-generated/machine-learning -t ~/kibana/docs/api-generated/template
```
Expand Down
560 changes: 466 additions & 94 deletions docs/api-generated/cases/case-apis-passthru.asciidoc

Large diffs are not rendered by default.

10 changes: 8 additions & 2 deletions docs/api/cases/cases-api-create.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@

Creates a case.

[NOTE]
====
For the most up-to-date API details, refer to the
{kib-repo}/tree/{branch}/x-pack/plugins/cases/docs/openapi[open API specification]. For a preview, check out <<case-apis>>.
====

=== {api-request-title}

`POST <kibana host>:<port>/api/cases`
Expand Down Expand Up @@ -45,10 +51,10 @@ specify `null` as its value.
For {ibm-r} connectors, specify:

`issueTypes`:::
(Required, array of numbers) The type of the incident.
(Required, array of strings) The type of the incident.

`severityCode`:::
(Required, number) The severity code of the incident.
(Required, string) The severity code of the incident.

For {jira} connectors, specify:

Expand Down
6 changes: 6 additions & 0 deletions docs/api/cases/cases-api-delete-cases.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@

Deletes one or more cases.

[NOTE]
====
For the most up-to-date API details, refer to the
{kib-repo}/tree/{branch}/x-pack/plugins/cases/docs/openapi[open API specification]. For a preview, check out <<case-apis>>.
====

=== {api-request-title}

`DELETE <kibana host>:<port>/api/cases?ids=["<case ID1>","<case ID2>"]`
Expand Down
10 changes: 8 additions & 2 deletions docs/api/cases/cases-api-update.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@

Updates one or more cases.

[NOTE]
====
For the most up-to-date API details, refer to the
{kib-repo}/tree/{branch}/x-pack/plugins/cases/docs/openapi[open API specification]. For a preview, check out <<case-apis>>.
====

=== {api-request-title}

`PATCH <kibana host>:<port>/api/cases`
Expand Down Expand Up @@ -51,10 +57,10 @@ connector, specify `null`. If you want to omit any individual field, specify
For {ibm-r} connectors, specify:
`issueTypes`:::
(Required, array of numbers) The issue types of the issue.
(Required, array of strings) The issue types of the issue.
`severityCode`:::
(Required, number) The severity code of the issue.
(Required, string) The severity code of the issue.
For {jira} connectors, specify:
Expand Down
Loading

0 comments on commit f92c76c

Please sign in to comment.