Skip to content

Commit

Permalink
[Fleet] Fix missing item in output openapi specs (elastic#168938)
Browse files Browse the repository at this point in the history
Fixes elastic#167181

## Summary
Fix of Fleet openapi specs: `item` was mistakenly removed in the
responses of these two endpoints:
- GET /outputs/{outputId}
- PUT /outputs/{outputId}

Adding back the missing fields to align the actual behavior with the
docs.

### Checklist

- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
  • Loading branch information
criamico authored Oct 16, 2023
1 parent 3c4a597 commit 5c42b9f
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 6 deletions.
14 changes: 12 additions & 2 deletions x-pack/plugins/fleet/common/openapi/bundled.json
Original file line number Diff line number Diff line change
Expand Up @@ -4573,7 +4573,12 @@
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/output_create_request"
"type": "object",
"properties": {
"item": {
"$ref": "#/components/schemas/output_create_request"
}
}
}
}
}
Expand Down Expand Up @@ -4650,7 +4655,12 @@
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/output_update_request"
"type": "object",
"properties": {
"item": {
"$ref": "#/components/schemas/output_update_request"
}
}
}
}
}
Expand Down
10 changes: 8 additions & 2 deletions x-pack/plugins/fleet/common/openapi/bundled.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2853,7 +2853,10 @@ paths:
content:
application/json:
schema:
$ref: '#/components/schemas/output_create_request'
type: object
properties:
item:
$ref: '#/components/schemas/output_create_request'
'400':
$ref: '#/components/responses/error'
operationId: get-output
Expand Down Expand Up @@ -2900,7 +2903,10 @@ paths:
content:
application/json:
schema:
$ref: '#/components/schemas/output_update_request'
type: object
properties:
item:
$ref: '#/components/schemas/output_update_request'
'400':
$ref: '#/components/responses/error'
parameters:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@ get:
content:
application/json:
schema:
$ref: ../components/schemas/output_create_request.yaml
type: object
properties:
item:
$ref: ../components/schemas/output_create_request.yaml
'400':
$ref: ../components/responses/error.yaml
operationId: get-output
Expand Down Expand Up @@ -55,7 +58,10 @@ put:
content:
application/json:
schema:
$ref: ../components/schemas/output_update_request.yaml
type: object
properties:
item:
$ref: ../components/schemas/output_update_request.yaml
'400':
$ref: ../components/responses/error.yaml
parameters:
Expand Down

0 comments on commit 5c42b9f

Please sign in to comment.