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

[OAS] Migrate case APIs to v3.1.0 #171593

Merged
merged 6 commits into from
Nov 24, 2023
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
2,140 changes: 1,485 additions & 655 deletions x-pack/plugins/cases/docs/openapi/bundled.json

Large diffs are not rendered by default.

1,594 changes: 1,001 additions & 593 deletions x-pack/plugins/cases/docs/openapi/bundled.yaml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ description: An identifier for the alert.
required: true
schema:
type: string
example: 09f0c261e39e36351d75995b78bb83673774d1bc2cca9df2d15f0e5c0a99a540
examples:
- 09f0c261e39e36351d75995b78bb83673774d1bc2cca9df2d15f0e5c0a99a540
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ description: The identifier for the case. To retrieve case IDs, use the find cas
required: true
schema:
type: string
example: 9c235210-6834-11ea-a78c-6ffb38a34414
examples:
- 9c235210-6834-11ea-a78c-6ffb38a34414
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ schema:
items:
type: string
maxItems: 100
example: my-category
examples:
- [ my-category ]
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ description: >
required: true
schema:
type: string
example: '71ec1870-725b-11ea-a0b2-c51ea50a58e2'
examples:
- '71ec1870-725b-11ea-a0b2-c51ea50a58e2'
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ description: An identifier for the configuration.
required: true
schema:
type: string
example: 3297a0f0-b5ec-11ec-b141-0fdb20a7f9a9
examples:
- 3297a0f0-b5ec-11ec-b141-0fdb20a7f9a9
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ description: An identifier for the connector. To retrieve connector IDs, use the
required: true
schema:
type: string
example: abed3a70-71bd-11ea-a0b2-c51ea50a58e2
examples:
- abed3a70-71bd-11ea-a0b2-c51ea50a58e2
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ description: he default operator to use for the simple_query_string.
schema:
type: string
default: OR
example: OR
examples:
- OR
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ description: >
The date must be specified as a KQL data range or date match expression.
schema:
type: string
example: now-1d
examples:
- now-1d
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ schema:
type: string
minItems: 1
maxItems: 100
example: d4e7abb0-b462-11ec-9a8d-698504725a43
examples:
- [ d4e7abb0-b462-11ec-9a8d-698504725a43 ]
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ schema:
- type: array
items:
$ref: '../schemas/owners.yaml'
example: cases
examples:
- [ cases ]
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@ required: false
schema:
type: integer
default: 1
examples:
- 1
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ schema:
items:
type: string
maxItems: 100
example: elastic
examples:
- [ elastic ]
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,5 @@ schema:
- status
- severity
default: createdAt
example: updatedAt
examples:
- updatedAt
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,5 @@ description: An identifier for the space. If `/s/` and the identifier are omitte
required: true
schema:
type: string
example: default
examples:
- default
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ schema:
- closed
- in-progress
- open
example: open
examples:
- open
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@ schema:
items:
type: string
maxItems: 100
example: tag-1
examples:
- [ tag-1 ]
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ description: >
The date must be specified as a KQL data range or date match expression.
schema:
type: string
example: now+1d
examples:
- now+1d
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@ schema:
- tags
- title
- user
example: create_case
examples:
- [ create_case ]
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ title: Unsuccessful cases API response
properties:
error:
type: string
example: Unauthorized
examples:
- Unauthorized
message:
type: string
statusCode:
type: integer
example: 401
examples:
- 401
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@ enum:
- status
- settings
- severity
example: create_case
examples:
- create_case
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ enum:
- delete
- push_to_service
- update
example: create
examples:
- create
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ properties:
type:
description: The type of comment.
type: string
example: alert
examples:
- alert
enum:
- alert
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@ properties:
description: The new comment. It is required only when `type` is `user`.
type: string
maxLength: 30000
example: A new comment.
examples:
- A new comment.
owner:
$ref: 'owners.yaml'
type:
type: string
description: The type of comment.
example: user
examples:
- user
enum:
- user
required:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,13 @@ properties:
type: array
items:
type: string
example: a6e12ac4-7bce-457b-84f6-d7ce8deb8446
examples:
- a6e12ac4-7bce-457b-84f6-d7ce8deb8446
created_at:
type: string
format: date-time
example: 2023-11-06T19:29:38.424Z
examples:
- 2023-11-06T19:29:38.424Z
created_by:
type: object
required:
Expand All @@ -22,44 +24,52 @@ properties:
$ref: 'user_properties.yaml'
id:
type: string
example: 73362370-ab1a-11ec-985f-97e55adae8b9
examples:
- 73362370-ab1a-11ec-985f-97e55adae8b9
index:
type: array
items:
type: string
example: .internal.alerts-security.alerts-default-000001
examples:
- .internal.alerts-security.alerts-default-000001
owner:
$ref: 'owners.yaml'
pushed_at:
type: string
type:
- "string"
- "null"
format: date-time
example: null
nullable: true
examples:
- null
pushed_by:
type: object
type:
- "object"
- "null"
required:
- email
- full_name
- username
properties:
$ref: 'user_properties.yaml'
nullable: true
rule:
type: object
properties:
$ref: 'rule_properties.yaml'
type:
type: string
example: alert
examples:
- alert
enum:
- alert
updated_at:
type: string
type:
- "string"
- "null"
format: date-time
nullable: true
updated_by:
type: object
nullable: true
type:
- "object"
- "null"
required:
- email
- full_name
Expand All @@ -68,4 +78,5 @@ properties:
$ref: 'user_properties.yaml'
version:
type: string
example: WzMwNDgsMV0=
examples:
- WzMwNDgsMV0=
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@ oneOf:
type: string
maxItems: 1000
x-technical-preview: true
example: 6b24c4dc44bc720cfc92797f3d61fff952f2b2627db1fb4f8cc49f4530c4ff42
examples:
- 6b24c4dc44bc720cfc92797f3d61fff952f2b2627db1fb4f8cc49f4530c4ff42
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
type: array
type:
- "array"
- "null"
description: An array containing users that are assigned to the case.
maxItems: 10
nullable: true
items:
type: object
required:
Expand All @@ -10,4 +11,5 @@ items:
uid:
type: string
description: A unique identifier for the user profile. These identifiers can be found by using the suggest user profile API.
example: u_0wpfV1MqYDaXzLtRVY-gLMrddKDEmfz51Fszhj7hWC8_0
examples:
- u_0wpfV1MqYDaXzLtRVY-gLMrddKDEmfz51Fszhj7hWC8_0
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
fields:
description: The fields specified in the case configuration are not used and are not propagated to individual cases, therefore it is recommended to set it to `null`.
nullable: true
type: object
type:
- "object"
- "null"
id:
description: The identifier for the connector. If you do not want a default connector, use `none`. To retrieve connector IDs, use the find connectors API.
type: string
example: none
examples:
- none
name:
description: The name of the connector. If you do not want a default connector, use `none`. To retrieve connector names, use the find connectors API.
type: string
example: none
examples:
- none
type:
$ref: 'connector_types.yaml'
Loading
Loading