diff --git a/docs/api-generated/README.md b/docs/api-generated/README.md new file mode 100644 index 0000000000000..4ce033e47ea0b --- /dev/null +++ b/docs/api-generated/README.md @@ -0,0 +1,36 @@ +# OpenAPI (Experimental) + +Open API specifications (OAS) exist in JSON or YAML format for some Kibana features, +though they are experimental and may be incomplete or change later. + +A preview of the API specifications can be added to the Kibana Guide by using +the following process: + +. Install [OpenAPI Generator](https://openapi-generator.tech/docs/installation), +or a similar tool that can generate HTML output from OAS. + +. Optionally validate the specifications by using the commands listed in the appropriate readmes. + +. 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/ml/common/openapi/ml_apis_v3.yaml -o ~/kibana/docs/api-generated/machine-learning -t ~/kibana/docs/api-generated/template + ``` + +. Rename the output files. For example: + ``` + mv ~/kibana/docs/api-generated/cases/index.html case-apis-passthru.asciidoc + mv ~/kibana/docs/api-generated/machine-learning/index.html ml-apis-passthru.adoc + ``` + +. If you're creating a new set of API output, you will need to have a page that incorporates the output by using passthrough blocks. For more information, refer to [Asciidoctor docs](https://docs.asciidoctor.org/asciidoc/latest/pass/pass-block/) + +. Verify the output by building the Kibana documentation. At this time, the output is added as a technical preview in the appendix. + +## Known issues + +- Some OAS 3.0 features such as `anyOf`, `oneOf`, and `allOf` might not display properly in the preview. These are on the [Short-term roadmap](https://openapi-generator.tech/docs/roadmap/) at this time. + + diff --git a/docs/api-generated/cases/case-apis-passthru.asciidoc b/docs/api-generated/cases/case-apis-passthru.asciidoc new file mode 100644 index 0000000000000..2a07283aa98e0 --- /dev/null +++ b/docs/api-generated/cases/case-apis-passthru.asciidoc @@ -0,0 +1,827 @@ +//// +This content is generated from the open API specification. +Any modifications made to this file will be overwritten. +//// + +++++ +
post /s/{spaceId}/api/cases/{caseId}/comments
delete /s/{spaceId}/api/cases/{caseId}/comments
get /s/{spaceId}/api/cases/{caseId}/comments
patch /s/{spaceId}/api/cases/{caseId}/comments
post /s/{spaceId}/api/cases/{caseId}/comments
all
privileges for the Cases feature in the Management, Observability, or Security section of the Kibana feature privileges, depending on the owner of the case you're creating./s/
and the identifier are omitted from the path, the default space is used. default: null application/json
{
+ "owner" : "cases",
+ "totalComment" : 0,
+ "settings" : {
+ "syncAlerts" : true
+ },
+ "totalAlerts" : 0,
+ "closed_at" : "2000-01-23T04:56:07.000+00:00",
+ "comments" : [ null, null ],
+ "created_at" : "2022-05-13T09:16:17.416Z",
+ "description" : "A case description.",
+ "title" : "Case title 1",
+ "created_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "version" : "WzUzMiwxXQ==",
+ "closed_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "tags" : [ "tag-1" ],
+ "duration" : 120,
+ "connector" : {
+ "name" : "none",
+ "id" : "none",
+ "fields" : {
+ "destIp" : "destIp",
+ "severity" : "severity",
+ "parent" : "parent",
+ "impact" : "impact",
+ "malwareUrl" : "malwareUrl",
+ "priority" : "priority",
+ "issueTypes" : [ 0.8008281904610115, 0.8008281904610115 ],
+ "issueType" : "issueType",
+ "sourceIp" : "sourceIp",
+ "urgency" : "urgency",
+ "malwareHash" : "malwareHash",
+ "caseId" : "caseId",
+ "severityCode" : 6.027456183070403,
+ "category" : "category",
+ "subcategory" : "subcategory"
+ },
+ "type" : ".none"
+ },
+ "updated_at" : "2000-01-23T04:56:07.000+00:00",
+ "updated_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "id" : "66b9aa00-94fa-11ea-9f74-e7e108796192",
+ "external_service" : {
+ "external_title" : "external_title",
+ "pushed_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "external_url" : "external_url",
+ "pushed_at" : "2000-01-23T04:56:07.000+00:00",
+ "connector_id" : "connector_id",
+ "external_id" : "external_id",
+ "connector_name" : "connector_name"
+ }
+}
+
+ application/json
delete /s/{spaceId}/api/cases/{caseId}/comments
all
privileges for the Cases feature in the Management, Observability, or Security section of the Kibana feature privileges, depending on the owner of the cases you're deleting./s/
and the identifier are omitted from the path, the default space is used. default: null get /s/{spaceId}/api/cases/{caseId}/comments
read
privileges for the Cases feature in the Management, Observability, or Security section of the Kibana feature privileges, depending on the owner of the cases with the comments you're seeking./s/
and the identifier are omitted from the path, the default space is used. default: null {
+ "owner" : "cases",
+ "totalComment" : 0,
+ "settings" : {
+ "syncAlerts" : true
+ },
+ "totalAlerts" : 0,
+ "closed_at" : "2000-01-23T04:56:07.000+00:00",
+ "comments" : [ null, null ],
+ "created_at" : "2022-05-13T09:16:17.416Z",
+ "description" : "A case description.",
+ "title" : "Case title 1",
+ "created_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "version" : "WzUzMiwxXQ==",
+ "closed_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "tags" : [ "tag-1" ],
+ "duration" : 120,
+ "connector" : {
+ "name" : "none",
+ "id" : "none",
+ "fields" : {
+ "destIp" : "destIp",
+ "severity" : "severity",
+ "parent" : "parent",
+ "impact" : "impact",
+ "malwareUrl" : "malwareUrl",
+ "priority" : "priority",
+ "issueTypes" : [ 0.8008281904610115, 0.8008281904610115 ],
+ "issueType" : "issueType",
+ "sourceIp" : "sourceIp",
+ "urgency" : "urgency",
+ "malwareHash" : "malwareHash",
+ "caseId" : "caseId",
+ "severityCode" : 6.027456183070403,
+ "category" : "category",
+ "subcategory" : "subcategory"
+ },
+ "type" : ".none"
+ },
+ "updated_at" : "2000-01-23T04:56:07.000+00:00",
+ "updated_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "id" : "66b9aa00-94fa-11ea-9f74-e7e108796192",
+ "external_service" : {
+ "external_title" : "external_title",
+ "pushed_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "external_url" : "external_url",
+ "pushed_at" : "2000-01-23T04:56:07.000+00:00",
+ "connector_id" : "connector_id",
+ "external_id" : "external_id",
+ "connector_name" : "connector_name"
+ }
+}
+
+ application/json
patch /s/{spaceId}/api/cases/{caseId}/comments
all
privileges for the Cases feature in the Management, Observability, or Security section of the Kibana feature privileges, depending on the owner of the case you're updating. NOTE: You cannot change the comment type or the owner of a comment./s/
and the identifier are omitted from the path, the default space is used. default: null application/json
{
+ "owner" : "cases",
+ "totalComment" : 0,
+ "settings" : {
+ "syncAlerts" : true
+ },
+ "totalAlerts" : 0,
+ "closed_at" : "2000-01-23T04:56:07.000+00:00",
+ "comments" : [ null, null ],
+ "created_at" : "2022-05-13T09:16:17.416Z",
+ "description" : "A case description.",
+ "title" : "Case title 1",
+ "created_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "version" : "WzUzMiwxXQ==",
+ "closed_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "tags" : [ "tag-1" ],
+ "duration" : 120,
+ "connector" : {
+ "name" : "none",
+ "id" : "none",
+ "fields" : {
+ "destIp" : "destIp",
+ "severity" : "severity",
+ "parent" : "parent",
+ "impact" : "impact",
+ "malwareUrl" : "malwareUrl",
+ "priority" : "priority",
+ "issueTypes" : [ 0.8008281904610115, 0.8008281904610115 ],
+ "issueType" : "issueType",
+ "sourceIp" : "sourceIp",
+ "urgency" : "urgency",
+ "malwareHash" : "malwareHash",
+ "caseId" : "caseId",
+ "severityCode" : 6.027456183070403,
+ "category" : "category",
+ "subcategory" : "subcategory"
+ },
+ "type" : ".none"
+ },
+ "updated_at" : "2000-01-23T04:56:07.000+00:00",
+ "updated_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "id" : "66b9aa00-94fa-11ea-9f74-e7e108796192",
+ "external_service" : {
+ "external_title" : "external_title",
+ "pushed_by" : {
+ "full_name" : "full_name",
+ "profile_uid" : "u_J41Oh6L9ki-Vo2tOogS8WRTENzhHurGtRc87NgEAlkc_0",
+ "email" : "email",
+ "username" : "elastic"
+ },
+ "external_url" : "external_url",
+ "pushed_at" : "2000-01-23T04:56:07.000+00:00",
+ "connector_id" : "connector_id",
+ "external_id" : "external_id",
+ "connector_name" : "connector_name"
+ }
+}
+
+ application/json
Case_response_properties_for_comments_inner
- Case_response_properties_for_connectors
- Case response properties for connectorsadd_alert_comment_request_properties
- Add case comment request properties for alertsadd_case_comment_request
- Add case comment requestadd_user_comment_request_properties
- Add case comment request properties for user commentsalert_comment_response_properties
- Add case comment response properties for alertsalert_comment_response_properties_created_by
- alert_comment_response_properties_pushed_by
- alert_comment_response_properties_rule
- alert_identifiers
- Alert identifiersalert_indices
- Alert indicescase_response_closed_by_properties
- Case response properties for closed_bycase_response_connector_field_properties
- Case response properties for connector fieldscase_response_created_by_properties
- Case response properties for created_bycase_response_properties
- Case response propertiescase_response_pushed_by_properties
- Case response properties for pushed_bycase_response_updated_by_properties
- Case response properties for updated_byconnector_types
- external_service
- owners
- rule
- Alerting rulesettings
- severity_property
- status
- update_alert_comment_request_properties
- Update case comment request properties for alertsupdate_case_comment_request
- Update case comment requestupdate_user_comment_request_properties
- Update case comment request properties for user commentsuser_comment_response_properties
- Case response properties for user commentsCase_response_properties_for_comments_inner
- UpCase_response_properties_for_connectors
- Case response properties for connectors Upadd_alert_comment_request_properties
- Add case comment request properties for alerts Upadd_case_comment_request
- Add case comment request Upadd_user_comment_request_properties
- Add case comment request properties for user comments Upalert_comment_response_properties
- Add case comment response properties for alerts Upalert_identifiers
- Alert identifiers Uptype
is alert
. If it is an array, index
must also be an array with the same length or number of elements. This functionality is in technical preview and may be changed or removed in a future release. Elastic will apply best effort to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.alert_indices
- Alert indices Uptype
is alert
. If it is an array, alertId
must also be an array with the same length or number of elements. This functionality is in technical preview and may be changed or removed in a future release. Elastic will apply best effort to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.case_response_connector_field_properties
- Case response properties for connector fields Upcase_response_properties
- Case response properties Upexternal_service
- Upowners
- Uprule
- Alerting rule Uptype
is alert
. This functionality is in technical preview and may be changed or removed in a future release. Elastic will apply best effort to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.settings
- Upupdate_alert_comment_request_properties
- Update case comment request properties for alerts Upupdate_case_comment_request
- Update case comment request Upupdate_user_comment_request_properties
- Update case comment request properties for user comments Upuser_comment_response_properties
- Case response properties for user comments Up