diff --git a/oas_docs/bundle.json b/oas_docs/bundle.json index 1bf61ba293cb..a0469257cacd 100644 --- a/oas_docs/bundle.json +++ b/oas_docs/bundle.json @@ -344,10 +344,10 @@ }, "openapi": "3.0.0", "paths": { - "/api/actions/connector/{id}": { - "delete": { - "description": "WARNING: When you delete a connector, it cannot be recovered.", - "operationId": "delete-actions-connector-id", + "/api/actions": { + "get": { + "deprecated": true, + "operationId": "get-actions", "parameters": [ { "description": "The version of the API to use", @@ -360,39 +360,19 @@ ], "type": "string" } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "An identifier for the connector.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } } ], - "responses": { - "204": { - "description": "Indicates a successful call." - } - }, - "summary": "Delete a connector", + "responses": {}, + "summary": "Get all connectors", "tags": [ "connectors" ] - }, - "get": { - "operationId": "get-actions-connector-id", + } + }, + "/api/actions/action": { + "post": { + "deprecated": true, + "operationId": "post-actions-action", "parameters": [ { "description": "The version of the API to use", @@ -407,15 +387,50 @@ } }, { - "description": "An identifier for the connector.", - "in": "path", - "name": "id", + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", "required": true, "schema": { + "example": "true", "type": "string" } } ], + "requestBody": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "actionTypeId": { + "description": "The connector type identifier.", + "type": "string" + }, + "config": { + "additionalProperties": {}, + "default": {}, + "type": "object" + }, + "name": { + "description": "The display name for the connector.", + "type": "string" + }, + "secrets": { + "additionalProperties": {}, + "default": {}, + "type": "object" + } + }, + "required": [ + "name", + "actionTypeId" + ], + "type": "object" + } + } + } + }, "responses": { "200": { "content": { @@ -471,13 +486,17 @@ "description": "Indicates a successful call." } }, - "summary": "Get connector information", + "summary": "Create a connector", "tags": [ "connectors" ] - }, - "post": { - "operationId": "post-actions-connector-id", + } + }, + "/api/actions/action/{id}": { + "delete": { + "deprecated": true, + "description": "WARNING: When you delete a connector, it cannot be recovered.", + "operationId": "delete-actions-action-id", "parameters": [ { "description": "The version of the API to use", @@ -505,46 +524,48 @@ "description": "An identifier for the connector.", "in": "path", "name": "id", - "required": false, + "required": true, "schema": { "type": "string" } } ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "config": { - "additionalProperties": {}, - "default": {}, - "type": "object" - }, - "connector_type_id": { - "description": "The type of connector.", - "type": "string" - }, - "name": { - "description": "The display name for the connector.", - "type": "string" - }, - "secrets": { - "additionalProperties": {}, - "default": {}, - "type": "object" - } - }, - "required": [ - "name", - "connector_type_id" - ], - "type": "object" - } - } + "responses": { + "204": { + "description": "Indicates a successful call." } }, + "summary": "Delete a connector", + "tags": [ + "connectors" + ] + }, + "get": { + "deprecated": true, + "operationId": "get-actions-action-id", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "An identifier for the connector.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + } + } + ], "responses": { "200": { "content": { @@ -600,13 +621,14 @@ "description": "Indicates a successful call." } }, - "summary": "Create a connector", + "summary": "Get connector information", "tags": [ "connectors" ] }, "put": { - "operationId": "put-actions-connector-id", + "deprecated": true, + "operationId": "put-actions-action-id", "parameters": [ { "description": "The version of the API to use", @@ -652,7 +674,6 @@ "type": "object" }, "name": { - "description": "The display name for the connector.", "type": "string" }, "secrets": { @@ -730,10 +751,10 @@ ] } }, - "/api/actions/connector/{id}/_execute": { + "/api/actions/action/{id}/_execute": { "post": { - "description": "You can use this API to test an action that involves interaction with Kibana services or integrations with third-party systems.", - "operationId": "post-actions-connector-id-execute", + "deprecated": true, + "operationId": "post-actions-action-id-execute", "parameters": [ { "description": "The version of the API to use", @@ -847,67 +868,10 @@ ] } }, - "/api/actions/connector_types": { - "get": { - "description": "You do not need any Kibana feature privileges to run this API.", - "operationId": "get-actions-connector-types", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A filter to limit the retrieved connector types to those that support a specific feature (such as alerting or cases).", - "in": "query", - "name": "feature_id", - "required": false, - "schema": { - "type": "string" - } - } - ], - "responses": {}, - "summary": "Get connector types", - "tags": [ - "connectors" - ] - } - }, - "/api/actions/connectors": { - "get": { - "operationId": "get-actions-connectors", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": {}, - "summary": "Get all connectors", - "tags": [ - "connectors" - ] - } - }, - "/api/alerting/rule/{id}": { + "/api/actions/connector/{id}": { "delete": { - "operationId": "delete-alerting-rule-id", + "description": "WARNING: When you delete a connector, it cannot be recovered.", + "operationId": "delete-actions-connector-id", "parameters": [ { "description": "The version of the API to use", @@ -932,7 +896,7 @@ } }, { - "description": "The identifier for the rule.", + "description": "An identifier for the connector.", "in": "path", "name": "id", "required": true, @@ -944,24 +908,15 @@ "responses": { "204": { "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." } }, - "summary": "Delete a rule", + "summary": "Delete a connector", "tags": [ - "alerting" + "connectors" ] }, "get": { - "operationId": "get-alerting-rule-id", + "operationId": "get-actions-connector-id", "parameters": [ { "description": "The version of the API to use", @@ -976,7 +931,7 @@ } }, { - "description": "The identifier for the rule.", + "description": "An identifier for the connector.", "in": "path", "name": "id", "required": true, @@ -992,33732 +947,516 @@ "schema": { "additionalProperties": false, "properties": { - "actions": { - "items": { - "additionalProperties": false, - "properties": { - "alerts_filter": { - "additionalProperties": false, - "description": "Defines a period that limits whether the action runs.", - "properties": { - "query": { - "additionalProperties": false, - "properties": { - "dsl": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", - "type": "string" - }, - "filters": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", - "items": { - "additionalProperties": false, - "properties": { - "$state": { - "additionalProperties": false, - "properties": { - "store": { - "description": "A filter can be either specific to an application context or applied globally.", - "enum": [ - "appState", - "globalState" - ], - "type": "string" - } - }, - "required": [ - "store" - ], - "type": "object" - }, - "meta": { - "additionalProperties": {}, - "type": "object" - }, - "query": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "meta" - ], - "type": "object" - }, - "type": "array" - }, - "kql": { - "description": "A filter written in Kibana Query Language (KQL).", - "type": "string" - } - }, - "required": [ - "kql", - "filters" - ], - "type": "object" - }, - "timeframe": { - "additionalProperties": false, - "properties": { - "days": { - "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", - "items": { - "enum": [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 - ], - "type": "integer" - }, - "type": "array" - }, - "hours": { - "additionalProperties": false, - "properties": { - "end": { - "description": "The end of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - }, - "start": { - "description": "The start of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - } - }, - "required": [ - "start", - "end" - ], - "type": "object" - }, - "timezone": { - "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", - "type": "string" - } - }, - "required": [ - "days", - "hours", - "timezone" - ], - "type": "object" - } - }, - "type": "object" - }, - "connector_type_id": { - "description": "The type of connector. This property appears in responses but cannot be set in requests.", - "type": "string" - }, - "frequency": { - "additionalProperties": false, - "properties": { - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "type": "string" - }, - "summary": { - "description": "Indicates whether the action is a summary.", - "type": "boolean" - }, - "throttle": { - "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "summary", - "notify_when", - "throttle" - ], - "type": "object" - }, - "group": { - "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", - "type": "string" - }, - "id": { - "description": "The identifier for the connector saved object.", - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", - "type": "object" - }, - "use_alert_data_for_template": { - "description": "Indicates whether to use alert data as a template.", - "type": "boolean" - }, - "uuid": { - "description": "A universally unique identifier (UUID) for the action.", - "type": "string" - } - }, - "required": [ - "id", - "connector_type_id", - "params" - ], - "type": "object" - }, - "type": "array" - }, - "active_snoozes": { - "items": { - "description": "List of active snoozes for the rule.", - "type": "string" - }, - "type": "array" - }, - "alert_delay": { - "additionalProperties": false, - "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", - "properties": { - "active": { - "description": "The number of consecutive runs that must meet the rule conditions.", - "type": "number" - } - }, - "required": [ - "active" - ], + "config": { + "additionalProperties": {}, "type": "object" }, - "api_key_created_by_user": { - "description": "Indicates whether the API key that is associated with the rule was created by the user.", - "nullable": true, - "type": "boolean" - }, - "api_key_owner": { - "description": "The owner of the API key that is associated with the rule and used to run background tasks.", - "nullable": true, + "connector_type_id": { + "description": "The connector type identifier.", "type": "string" }, - "consumer": { - "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", + "id": { + "description": "The identifier for the connector.", "type": "string" }, - "created_at": { - "description": "The date and time that the rule was created.", - "type": "string" + "is_deprecated": { + "description": "Indicates whether the connector is deprecated.", + "type": "boolean" }, - "created_by": { - "description": "The identifier for the user that created the rule.", - "nullable": true, - "type": "string" + "is_missing_secrets": { + "description": "Indicates whether the connector is missing secrets.", + "type": "boolean" }, - "enabled": { - "description": "Indicates whether you want to run the rule on an interval basis after it is created.", + "is_preconfigured": { + "description": "Indicates whether the connector is preconfigured. If true, the `config` and `is_missing_secrets` properties are omitted from the response. ", "type": "boolean" }, - "execution_status": { - "additionalProperties": false, - "properties": { - "error": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Error message.", - "type": "string" - }, - "reason": { - "description": "Reason for error.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - }, - "last_duration": { - "description": "Duration of last execution of the rule.", - "type": "number" - }, - "last_execution_date": { - "description": "The date and time when rule was executed last.", - "type": "string" - }, - "status": { - "description": "Status of rule execution.", - "enum": [ - "ok", - "active", - "error", - "warning", - "pending", - "unknown" - ], - "type": "string" - }, - "warning": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Warning message.", - "type": "string" - }, - "reason": { - "description": "Reason for warning.", - "enum": [ - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - } - }, - "required": [ - "status", - "last_execution_date" - ], - "type": "object" - }, - "flapping": { - "additionalProperties": false, - "nullable": true, - "properties": { - "look_back_window": { - "maximum": 20, - "minimum": 2, - "type": "number" - }, - "status_change_threshold": { - "maximum": 20, - "minimum": 2, - "type": "number" - } - }, - "required": [ - "look_back_window", - "status_change_threshold" - ], - "type": "object" - }, - "id": { - "description": "The identifier for the rule.", - "type": "string" + "is_system_action": { + "description": "Indicates whether the connector is used for system actions.", + "type": "boolean" }, - "is_snoozed_until": { - "description": "The date when the rule will no longer be snoozed.", - "nullable": true, + "name": { + "description": " The name of the rule.", "type": "string" - }, - "last_run": { - "additionalProperties": false, - "nullable": true, - "properties": { - "alerts_count": { - "additionalProperties": false, - "properties": { - "active": { - "description": "Number of active alerts during last run.", - "nullable": true, - "type": "number" - }, - "ignored": { - "description": "Number of ignored alerts during last run.", - "nullable": true, - "type": "number" - }, - "new": { - "description": "Number of new alerts during last run.", - "nullable": true, - "type": "number" - }, - "recovered": { - "description": "Number of recovered alerts during last run.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "outcome_msg": { - "items": { - "description": "Outcome message generated during last rule run.", - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "outcome_order": { - "description": "Order of the outcome.", - "type": "number" - }, - "warning": { - "description": "Warning of last rule execution.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate", - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "nullable": true, - "type": "string" - } - }, - "required": [ - "outcome", - "alerts_count" - ], - "type": "object" - }, - "mapped_params": { - "additionalProperties": {}, - "type": "object" - }, - "monitoring": { - "additionalProperties": false, - "description": "Monitoring details of the rule.", - "properties": { - "run": { - "additionalProperties": false, - "description": "Rule run details.", - "properties": { - "calculated_metrics": { - "additionalProperties": false, - "description": "Calculation of different percentiles and success ratio.", - "properties": { - "p50": { - "type": "number" - }, - "p95": { - "type": "number" - }, - "p99": { - "type": "number" - }, - "success_ratio": { - "type": "number" - } - }, - "required": [ - "success_ratio" - ], - "type": "object" - }, - "history": { - "description": "History of the rule run.", - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule run.", - "type": "number" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "success": { - "description": "Indicates whether the rule run was successful.", - "type": "boolean" - }, - "timestamp": { - "description": "Time of rule run.", - "type": "number" - } - }, - "required": [ - "success", - "timestamp" - ], - "type": "object" - }, - "type": "array" - }, - "last_run": { - "additionalProperties": false, - "properties": { - "metrics": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of most recent rule run.", - "type": "number" - }, - "gap_duration_s": { - "description": "Duration in seconds of rule run gap.", - "nullable": true, - "type": "number" - }, - "total_alerts_created": { - "description": "Total number of alerts created during last rule run.", - "nullable": true, - "type": "number" - }, - "total_alerts_detected": { - "description": "Total number of alerts detected during last rule run.", - "nullable": true, - "type": "number" - }, - "total_indexing_duration_ms": { - "description": "Total time spent indexing documents during last rule run in milliseconds.", - "nullable": true, - "type": "number" - }, - "total_search_duration_ms": { - "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "timestamp": { - "description": "Time of the most recent rule run.", - "type": "string" - } - }, - "required": [ - "timestamp", - "metrics" - ], - "type": "object" - } - }, - "required": [ - "history", - "calculated_metrics", - "last_run" - ], - "type": "object" - } - }, - "required": [ - "run" - ], - "type": "object" - }, - "mute_all": { - "description": "Indicates whether all alerts are muted.", - "type": "boolean" - }, - "muted_alert_ids": { - "items": { - "description": "List of identifiers of muted alerts. ", - "type": "string" - }, - "type": "array" - }, - "name": { - "description": " The name of the rule.", - "type": "string" - }, - "next_run": { - "description": "Date and time of the next run of the rule.", - "nullable": true, - "type": "string" - }, - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "nullable": true, - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the rule.", - "type": "object" - }, - "revision": { - "description": "The rule revision number.", - "type": "number" - }, - "rule_type_id": { - "description": "The rule type identifier.", - "type": "string" - }, - "running": { - "description": "Indicates whether the rule is running.", - "nullable": true, - "type": "boolean" - }, - "schedule": { - "additionalProperties": false, - "properties": { - "interval": { - "description": "The interval is specified in seconds, minutes, hours, or days.", - "type": "string" - } - }, - "required": [ - "interval" - ], - "type": "object" - }, - "scheduled_task_id": { - "description": "Identifier of the scheduled task.", - "type": "string" - }, - "snooze_schedule": { - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule snooze schedule.", - "type": "number" - }, - "id": { - "description": "Identifier of the rule snooze schedule.", - "type": "string" - }, - "rRule": { - "additionalProperties": false, - "properties": { - "byhour": { - "items": { - "description": "Indicates hours of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byminute": { - "items": { - "description": "Indicates minutes of the hour to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonth": { - "items": { - "description": "Indicates months of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonthday": { - "items": { - "description": "Indicates the days of the month to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysecond": { - "items": { - "description": "Indicates seconds of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysetpos": { - "items": { - "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byweekday": { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ], - "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." - }, - "nullable": true, - "type": "array" - }, - "byweekno": { - "items": { - "description": "Indicates number of the week hours to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byyearday": { - "items": { - "description": "Indicates the days of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "count": { - "description": "Number of times the rule should recur until it stops.", - "type": "number" - }, - "dtstart": { - "description": "Rule start date in Coordinated Universal Time (UTC).", - "type": "string" - }, - "freq": { - "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", - "enum": [ - 0, - 1, - 2, - 3, - 4, - 5, - 6 - ], - "type": "integer" - }, - "interval": { - "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", - "type": "number" - }, - "tzid": { - "description": "Indicates timezone abbreviation.", - "type": "string" - }, - "until": { - "description": "Recur the rule until this date.", - "type": "string" - }, - "wkst": { - "description": "Indicates the start of week, defaults to Monday.", - "enum": [ - "MO", - "TU", - "WE", - "TH", - "FR", - "SA", - "SU" - ], - "type": "string" - } - }, - "required": [ - "dtstart", - "tzid" - ], - "type": "object" - }, - "skipRecurrences": { - "items": { - "description": "Skips recurrence of rule on this date.", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "duration", - "rRule" - ], - "type": "object" - }, - "type": "array" - }, - "tags": { - "items": { - "description": "The tags for the rule.", - "type": "string" - }, - "type": "array" - }, - "throttle": { - "deprecated": true, - "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - }, - "updated_at": { - "description": "The date and time that the rule was updated most recently.", - "type": "string" - }, - "updated_by": { - "description": "The identifier for the user that updated this rule most recently.", - "nullable": true, - "type": "string" - }, - "view_in_app_relative_url": { - "description": "Relative URL to view rule in the app.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "enabled", - "name", - "tags", - "rule_type_id", - "consumer", - "schedule", - "actions", - "params", - "created_by", - "updated_by", - "created_at", - "updated_at", - "api_key_owner", - "mute_all", - "muted_alert_ids", - "execution_status", - "revision" - ], - "type": "object" - } - } - }, - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." - } - }, - "summary": "Get rule details", - "tags": [ - "alerting" - ] - }, - "post": { - "operationId": "post-alerting-rule-id", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule. If it is omitted, an ID is randomly generated.", - "in": "path", - "name": "id", - "required": false, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actions": { - "default": [], - "items": { - "additionalProperties": false, - "description": "An action that runs under defined conditions.", - "properties": { - "alerts_filter": { - "additionalProperties": false, - "description": "Conditions that affect whether the action runs. If you specify multiple conditions, all conditions must be met for the action to run. For example, if an alert occurs within the specified time frame and matches the query, the action runs.", - "properties": { - "query": { - "additionalProperties": false, - "properties": { - "dsl": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", - "type": "string" - }, - "filters": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", - "items": { - "additionalProperties": false, - "properties": { - "$state": { - "additionalProperties": false, - "properties": { - "store": { - "description": "A filter can be either specific to an application context or applied globally.", - "enum": [ - "appState", - "globalState" - ], - "type": "string" - } - }, - "required": [ - "store" - ], - "type": "object" - }, - "meta": { - "additionalProperties": {}, - "type": "object" - }, - "query": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "meta" - ], - "type": "object" - }, - "type": "array" - }, - "kql": { - "description": "A filter written in Kibana Query Language (KQL).", - "type": "string" - } - }, - "required": [ - "kql", - "filters" - ], - "type": "object" - }, - "timeframe": { - "additionalProperties": false, - "description": "Defines a period that limits whether the action runs.", - "properties": { - "days": { - "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", - "items": { - "enum": [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 - ], - "type": "integer" - }, - "type": "array" - }, - "hours": { - "additionalProperties": false, - "description": "Defines the range of time in a day that the action can run. If the `start` value is `00:00` and the `end` value is `24:00`, actions be generated all day.", - "properties": { - "end": { - "description": "The end of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - }, - "start": { - "description": "The start of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - } - }, - "required": [ - "start", - "end" - ], - "type": "object" - }, - "timezone": { - "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", - "type": "string" - } - }, - "required": [ - "days", - "hours", - "timezone" - ], - "type": "object" - } - }, - "type": "object" - }, - "frequency": { - "additionalProperties": false, - "properties": { - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "type": "string" - }, - "summary": { - "description": "Indicates whether the action is a summary.", - "type": "boolean" - }, - "throttle": { - "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if `notify_when` is set to `onThrottleInterval`. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "summary", - "notify_when", - "throttle" - ], - "type": "object" - }, - "group": { - "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", - "type": "string" - }, - "id": { - "description": "The identifier for the connector saved object.", - "type": "string" - }, - "params": { - "additionalProperties": {}, - "default": {}, - "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", - "type": "object" - }, - "use_alert_data_for_template": { - "description": "Indicates whether to use alert data as a template.", - "type": "boolean" - }, - "uuid": { - "description": "A universally unique identifier (UUID) for the action.", - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "alert_delay": { - "additionalProperties": false, - "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", - "properties": { - "active": { - "description": "The number of consecutive runs that must meet the rule conditions.", - "type": "number" - } - }, - "required": [ - "active" - ], - "type": "object" - }, - "consumer": { - "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", - "type": "string" - }, - "enabled": { - "default": true, - "description": "Indicates whether you want to run the rule on an interval basis after it is created.", - "type": "boolean" - }, - "flapping": { - "additionalProperties": false, - "nullable": true, - "properties": { - "look_back_window": { - "maximum": 20, - "minimum": 2, - "type": "number" - }, - "status_change_threshold": { - "maximum": 20, - "minimum": 2, - "type": "number" - } - }, - "required": [ - "look_back_window", - "status_change_threshold" - ], - "type": "object" - }, - "name": { - "description": "The name of the rule. While this name does not have to be unique, a distinctive name can help you identify a rule.", - "type": "string" - }, - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "nullable": true, - "type": "string" - }, - "params": { - "additionalProperties": {}, - "default": {}, - "description": "The parameters for the rule.", - "type": "object" - }, - "rule_type_id": { - "description": "The rule type identifier.", - "type": "string" - }, - "schedule": { - "additionalProperties": false, - "description": "The check interval, which specifies how frequently the rule conditions are checked.", - "properties": { - "interval": { - "description": "The interval is specified in seconds, minutes, hours, or days.", - "type": "string" - } - }, - "required": [ - "interval" - ], - "type": "object" - }, - "tags": { - "default": [], - "description": "The tags for the rule.", - "items": { - "type": "string" - }, - "type": "array" - }, - "throttle": { - "description": "Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "name", - "rule_type_id", - "consumer", - "schedule" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actions": { - "items": { - "additionalProperties": false, - "properties": { - "alerts_filter": { - "additionalProperties": false, - "description": "Defines a period that limits whether the action runs.", - "properties": { - "query": { - "additionalProperties": false, - "properties": { - "dsl": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", - "type": "string" - }, - "filters": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", - "items": { - "additionalProperties": false, - "properties": { - "$state": { - "additionalProperties": false, - "properties": { - "store": { - "description": "A filter can be either specific to an application context or applied globally.", - "enum": [ - "appState", - "globalState" - ], - "type": "string" - } - }, - "required": [ - "store" - ], - "type": "object" - }, - "meta": { - "additionalProperties": {}, - "type": "object" - }, - "query": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "meta" - ], - "type": "object" - }, - "type": "array" - }, - "kql": { - "description": "A filter written in Kibana Query Language (KQL).", - "type": "string" - } - }, - "required": [ - "kql", - "filters" - ], - "type": "object" - }, - "timeframe": { - "additionalProperties": false, - "properties": { - "days": { - "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", - "items": { - "enum": [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 - ], - "type": "integer" - }, - "type": "array" - }, - "hours": { - "additionalProperties": false, - "properties": { - "end": { - "description": "The end of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - }, - "start": { - "description": "The start of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - } - }, - "required": [ - "start", - "end" - ], - "type": "object" - }, - "timezone": { - "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", - "type": "string" - } - }, - "required": [ - "days", - "hours", - "timezone" - ], - "type": "object" - } - }, - "type": "object" - }, - "connector_type_id": { - "description": "The type of connector. This property appears in responses but cannot be set in requests.", - "type": "string" - }, - "frequency": { - "additionalProperties": false, - "properties": { - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "type": "string" - }, - "summary": { - "description": "Indicates whether the action is a summary.", - "type": "boolean" - }, - "throttle": { - "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "summary", - "notify_when", - "throttle" - ], - "type": "object" - }, - "group": { - "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", - "type": "string" - }, - "id": { - "description": "The identifier for the connector saved object.", - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", - "type": "object" - }, - "use_alert_data_for_template": { - "description": "Indicates whether to use alert data as a template.", - "type": "boolean" - }, - "uuid": { - "description": "A universally unique identifier (UUID) for the action.", - "type": "string" - } - }, - "required": [ - "id", - "connector_type_id", - "params" - ], - "type": "object" - }, - "type": "array" - }, - "active_snoozes": { - "items": { - "description": "List of active snoozes for the rule.", - "type": "string" - }, - "type": "array" - }, - "alert_delay": { - "additionalProperties": false, - "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", - "properties": { - "active": { - "description": "The number of consecutive runs that must meet the rule conditions.", - "type": "number" - } - }, - "required": [ - "active" - ], - "type": "object" - }, - "api_key_created_by_user": { - "description": "Indicates whether the API key that is associated with the rule was created by the user.", - "nullable": true, - "type": "boolean" - }, - "api_key_owner": { - "description": "The owner of the API key that is associated with the rule and used to run background tasks.", - "nullable": true, - "type": "string" - }, - "consumer": { - "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", - "type": "string" - }, - "created_at": { - "description": "The date and time that the rule was created.", - "type": "string" - }, - "created_by": { - "description": "The identifier for the user that created the rule.", - "nullable": true, - "type": "string" - }, - "enabled": { - "description": "Indicates whether you want to run the rule on an interval basis after it is created.", - "type": "boolean" - }, - "execution_status": { - "additionalProperties": false, - "properties": { - "error": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Error message.", - "type": "string" - }, - "reason": { - "description": "Reason for error.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - }, - "last_duration": { - "description": "Duration of last execution of the rule.", - "type": "number" - }, - "last_execution_date": { - "description": "The date and time when rule was executed last.", - "type": "string" - }, - "status": { - "description": "Status of rule execution.", - "enum": [ - "ok", - "active", - "error", - "warning", - "pending", - "unknown" - ], - "type": "string" - }, - "warning": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Warning message.", - "type": "string" - }, - "reason": { - "description": "Reason for warning.", - "enum": [ - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - } - }, - "required": [ - "status", - "last_execution_date" - ], - "type": "object" - }, - "flapping": { - "additionalProperties": false, - "nullable": true, - "properties": { - "look_back_window": { - "maximum": 20, - "minimum": 2, - "type": "number" - }, - "status_change_threshold": { - "maximum": 20, - "minimum": 2, - "type": "number" - } - }, - "required": [ - "look_back_window", - "status_change_threshold" - ], - "type": "object" - }, - "id": { - "description": "The identifier for the rule.", - "type": "string" - }, - "is_snoozed_until": { - "description": "The date when the rule will no longer be snoozed.", - "nullable": true, - "type": "string" - }, - "last_run": { - "additionalProperties": false, - "nullable": true, - "properties": { - "alerts_count": { - "additionalProperties": false, - "properties": { - "active": { - "description": "Number of active alerts during last run.", - "nullable": true, - "type": "number" - }, - "ignored": { - "description": "Number of ignored alerts during last run.", - "nullable": true, - "type": "number" - }, - "new": { - "description": "Number of new alerts during last run.", - "nullable": true, - "type": "number" - }, - "recovered": { - "description": "Number of recovered alerts during last run.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "outcome_msg": { - "items": { - "description": "Outcome message generated during last rule run.", - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "outcome_order": { - "description": "Order of the outcome.", - "type": "number" - }, - "warning": { - "description": "Warning of last rule execution.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate", - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "nullable": true, - "type": "string" - } - }, - "required": [ - "outcome", - "alerts_count" - ], - "type": "object" - }, - "mapped_params": { - "additionalProperties": {}, - "type": "object" - }, - "monitoring": { - "additionalProperties": false, - "description": "Monitoring details of the rule.", - "properties": { - "run": { - "additionalProperties": false, - "description": "Rule run details.", - "properties": { - "calculated_metrics": { - "additionalProperties": false, - "description": "Calculation of different percentiles and success ratio.", - "properties": { - "p50": { - "type": "number" - }, - "p95": { - "type": "number" - }, - "p99": { - "type": "number" - }, - "success_ratio": { - "type": "number" - } - }, - "required": [ - "success_ratio" - ], - "type": "object" - }, - "history": { - "description": "History of the rule run.", - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule run.", - "type": "number" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "success": { - "description": "Indicates whether the rule run was successful.", - "type": "boolean" - }, - "timestamp": { - "description": "Time of rule run.", - "type": "number" - } - }, - "required": [ - "success", - "timestamp" - ], - "type": "object" - }, - "type": "array" - }, - "last_run": { - "additionalProperties": false, - "properties": { - "metrics": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of most recent rule run.", - "type": "number" - }, - "gap_duration_s": { - "description": "Duration in seconds of rule run gap.", - "nullable": true, - "type": "number" - }, - "total_alerts_created": { - "description": "Total number of alerts created during last rule run.", - "nullable": true, - "type": "number" - }, - "total_alerts_detected": { - "description": "Total number of alerts detected during last rule run.", - "nullable": true, - "type": "number" - }, - "total_indexing_duration_ms": { - "description": "Total time spent indexing documents during last rule run in milliseconds.", - "nullable": true, - "type": "number" - }, - "total_search_duration_ms": { - "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "timestamp": { - "description": "Time of the most recent rule run.", - "type": "string" - } - }, - "required": [ - "timestamp", - "metrics" - ], - "type": "object" - } - }, - "required": [ - "history", - "calculated_metrics", - "last_run" - ], - "type": "object" - } - }, - "required": [ - "run" - ], - "type": "object" - }, - "mute_all": { - "description": "Indicates whether all alerts are muted.", - "type": "boolean" - }, - "muted_alert_ids": { - "items": { - "description": "List of identifiers of muted alerts. ", - "type": "string" - }, - "type": "array" - }, - "name": { - "description": " The name of the rule.", - "type": "string" - }, - "next_run": { - "description": "Date and time of the next run of the rule.", - "nullable": true, - "type": "string" - }, - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "nullable": true, - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the rule.", - "type": "object" - }, - "revision": { - "description": "The rule revision number.", - "type": "number" - }, - "rule_type_id": { - "description": "The rule type identifier.", - "type": "string" - }, - "running": { - "description": "Indicates whether the rule is running.", - "nullable": true, - "type": "boolean" - }, - "schedule": { - "additionalProperties": false, - "properties": { - "interval": { - "description": "The interval is specified in seconds, minutes, hours, or days.", - "type": "string" - } - }, - "required": [ - "interval" - ], - "type": "object" - }, - "scheduled_task_id": { - "description": "Identifier of the scheduled task.", - "type": "string" - }, - "snooze_schedule": { - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule snooze schedule.", - "type": "number" - }, - "id": { - "description": "Identifier of the rule snooze schedule.", - "type": "string" - }, - "rRule": { - "additionalProperties": false, - "properties": { - "byhour": { - "items": { - "description": "Indicates hours of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byminute": { - "items": { - "description": "Indicates minutes of the hour to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonth": { - "items": { - "description": "Indicates months of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonthday": { - "items": { - "description": "Indicates the days of the month to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysecond": { - "items": { - "description": "Indicates seconds of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysetpos": { - "items": { - "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byweekday": { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ], - "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." - }, - "nullable": true, - "type": "array" - }, - "byweekno": { - "items": { - "description": "Indicates number of the week hours to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byyearday": { - "items": { - "description": "Indicates the days of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "count": { - "description": "Number of times the rule should recur until it stops.", - "type": "number" - }, - "dtstart": { - "description": "Rule start date in Coordinated Universal Time (UTC).", - "type": "string" - }, - "freq": { - "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", - "enum": [ - 0, - 1, - 2, - 3, - 4, - 5, - 6 - ], - "type": "integer" - }, - "interval": { - "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", - "type": "number" - }, - "tzid": { - "description": "Indicates timezone abbreviation.", - "type": "string" - }, - "until": { - "description": "Recur the rule until this date.", - "type": "string" - }, - "wkst": { - "description": "Indicates the start of week, defaults to Monday.", - "enum": [ - "MO", - "TU", - "WE", - "TH", - "FR", - "SA", - "SU" - ], - "type": "string" - } - }, - "required": [ - "dtstart", - "tzid" - ], - "type": "object" - }, - "skipRecurrences": { - "items": { - "description": "Skips recurrence of rule on this date.", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "duration", - "rRule" - ], - "type": "object" - }, - "type": "array" - }, - "tags": { - "items": { - "description": "The tags for the rule.", - "type": "string" - }, - "type": "array" - }, - "throttle": { - "deprecated": true, - "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - }, - "updated_at": { - "description": "The date and time that the rule was updated most recently.", - "type": "string" - }, - "updated_by": { - "description": "The identifier for the user that updated this rule most recently.", - "nullable": true, - "type": "string" - }, - "view_in_app_relative_url": { - "description": "Relative URL to view rule in the app.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "enabled", - "name", - "tags", - "rule_type_id", - "consumer", - "schedule", - "actions", - "params", - "created_by", - "updated_by", - "created_at", - "updated_at", - "api_key_owner", - "mute_all", - "muted_alert_ids", - "execution_status", - "revision" - ], - "type": "object" - } - } - }, - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "409": { - "description": "Indicates that the rule id is already in use." - } - }, - "summary": "Create a rule", - "tags": [ - "alerting" - ] - }, - "put": { - "operationId": "put-alerting-rule-id", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actions": { - "default": [], - "items": { - "additionalProperties": false, - "description": "An action that runs under defined conditions.", - "properties": { - "alerts_filter": { - "additionalProperties": false, - "properties": { - "query": { - "additionalProperties": false, - "properties": { - "dsl": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", - "type": "string" - }, - "filters": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", - "items": { - "additionalProperties": false, - "properties": { - "$state": { - "additionalProperties": false, - "properties": { - "store": { - "description": "A filter can be either specific to an application context or applied globally.", - "enum": [ - "appState", - "globalState" - ], - "type": "string" - } - }, - "required": [ - "store" - ], - "type": "object" - }, - "meta": { - "additionalProperties": {}, - "type": "object" - }, - "query": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "meta" - ], - "type": "object" - }, - "type": "array" - }, - "kql": { - "description": "A filter written in Kibana Query Language (KQL).", - "type": "string" - } - }, - "required": [ - "kql", - "filters" - ], - "type": "object" - }, - "timeframe": { - "additionalProperties": false, - "description": "Defines a period that limits whether the action runs.", - "properties": { - "days": { - "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", - "items": { - "enum": [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 - ], - "type": "integer" - }, - "type": "array" - }, - "hours": { - "additionalProperties": false, - "description": "Defines the range of time in a day that the action can run. If the `start` value is `00:00` and the `end` value is `24:00`, actions be generated all day.", - "properties": { - "end": { - "description": "The end of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - }, - "start": { - "description": "The start of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - } - }, - "required": [ - "start", - "end" - ], - "type": "object" - }, - "timezone": { - "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", - "type": "string" - } - }, - "required": [ - "days", - "hours", - "timezone" - ], - "type": "object" - } - }, - "type": "object" - }, - "frequency": { - "additionalProperties": false, - "properties": { - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "type": "string" - }, - "summary": { - "description": "Indicates whether the action is a summary.", - "type": "boolean" - }, - "throttle": { - "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if `notify_when` is set to `onThrottleInterval`. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "summary", - "notify_when", - "throttle" - ], - "type": "object" - }, - "group": { - "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", - "type": "string" - }, - "id": { - "description": "The identifier for the connector saved object.", - "type": "string" - }, - "params": { - "additionalProperties": {}, - "default": {}, - "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", - "type": "object" - }, - "use_alert_data_for_template": { - "description": "Indicates whether to use alert data as a template.", - "type": "boolean" - }, - "uuid": { - "description": "A universally unique identifier (UUID) for the action.", - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "alert_delay": { - "additionalProperties": false, - "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", - "properties": { - "active": { - "description": "The number of consecutive runs that must meet the rule conditions.", - "type": "number" - } - }, - "required": [ - "active" - ], - "type": "object" - }, - "flapping": { - "additionalProperties": false, - "nullable": true, - "properties": { - "look_back_window": { - "maximum": 20, - "minimum": 2, - "type": "number" - }, - "status_change_threshold": { - "maximum": 20, - "minimum": 2, - "type": "number" - } - }, - "required": [ - "look_back_window", - "status_change_threshold" - ], - "type": "object" - }, - "name": { - "description": "The name of the rule. While this name does not have to be unique, a distinctive name can help you identify a rule.", - "type": "string" - }, - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "nullable": true, - "type": "string" - }, - "params": { - "additionalProperties": {}, - "default": {}, - "description": "The parameters for the rule.", - "type": "object" - }, - "schedule": { - "additionalProperties": false, - "properties": { - "interval": { - "description": "The interval is specified in seconds, minutes, hours, or days.", - "type": "string" - } - }, - "required": [ - "interval" - ], - "type": "object" - }, - "tags": { - "default": [], - "items": { - "description": "The tags for the rule.", - "type": "string" - }, - "type": "array" - }, - "throttle": { - "description": "Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "name", - "schedule" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actions": { - "items": { - "additionalProperties": false, - "properties": { - "alerts_filter": { - "additionalProperties": false, - "description": "Defines a period that limits whether the action runs.", - "properties": { - "query": { - "additionalProperties": false, - "properties": { - "dsl": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", - "type": "string" - }, - "filters": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", - "items": { - "additionalProperties": false, - "properties": { - "$state": { - "additionalProperties": false, - "properties": { - "store": { - "description": "A filter can be either specific to an application context or applied globally.", - "enum": [ - "appState", - "globalState" - ], - "type": "string" - } - }, - "required": [ - "store" - ], - "type": "object" - }, - "meta": { - "additionalProperties": {}, - "type": "object" - }, - "query": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "meta" - ], - "type": "object" - }, - "type": "array" - }, - "kql": { - "description": "A filter written in Kibana Query Language (KQL).", - "type": "string" - } - }, - "required": [ - "kql", - "filters" - ], - "type": "object" - }, - "timeframe": { - "additionalProperties": false, - "properties": { - "days": { - "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", - "items": { - "enum": [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 - ], - "type": "integer" - }, - "type": "array" - }, - "hours": { - "additionalProperties": false, - "properties": { - "end": { - "description": "The end of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - }, - "start": { - "description": "The start of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - } - }, - "required": [ - "start", - "end" - ], - "type": "object" - }, - "timezone": { - "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", - "type": "string" - } - }, - "required": [ - "days", - "hours", - "timezone" - ], - "type": "object" - } - }, - "type": "object" - }, - "connector_type_id": { - "description": "The type of connector. This property appears in responses but cannot be set in requests.", - "type": "string" - }, - "frequency": { - "additionalProperties": false, - "properties": { - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "type": "string" - }, - "summary": { - "description": "Indicates whether the action is a summary.", - "type": "boolean" - }, - "throttle": { - "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "summary", - "notify_when", - "throttle" - ], - "type": "object" - }, - "group": { - "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", - "type": "string" - }, - "id": { - "description": "The identifier for the connector saved object.", - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", - "type": "object" - }, - "use_alert_data_for_template": { - "description": "Indicates whether to use alert data as a template.", - "type": "boolean" - }, - "uuid": { - "description": "A universally unique identifier (UUID) for the action.", - "type": "string" - } - }, - "required": [ - "id", - "connector_type_id", - "params" - ], - "type": "object" - }, - "type": "array" - }, - "active_snoozes": { - "items": { - "description": "List of active snoozes for the rule.", - "type": "string" - }, - "type": "array" - }, - "alert_delay": { - "additionalProperties": false, - "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", - "properties": { - "active": { - "description": "The number of consecutive runs that must meet the rule conditions.", - "type": "number" - } - }, - "required": [ - "active" - ], - "type": "object" - }, - "api_key_created_by_user": { - "description": "Indicates whether the API key that is associated with the rule was created by the user.", - "nullable": true, - "type": "boolean" - }, - "api_key_owner": { - "description": "The owner of the API key that is associated with the rule and used to run background tasks.", - "nullable": true, - "type": "string" - }, - "consumer": { - "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", - "type": "string" - }, - "created_at": { - "description": "The date and time that the rule was created.", - "type": "string" - }, - "created_by": { - "description": "The identifier for the user that created the rule.", - "nullable": true, - "type": "string" - }, - "enabled": { - "description": "Indicates whether you want to run the rule on an interval basis after it is created.", - "type": "boolean" - }, - "execution_status": { - "additionalProperties": false, - "properties": { - "error": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Error message.", - "type": "string" - }, - "reason": { - "description": "Reason for error.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - }, - "last_duration": { - "description": "Duration of last execution of the rule.", - "type": "number" - }, - "last_execution_date": { - "description": "The date and time when rule was executed last.", - "type": "string" - }, - "status": { - "description": "Status of rule execution.", - "enum": [ - "ok", - "active", - "error", - "warning", - "pending", - "unknown" - ], - "type": "string" - }, - "warning": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Warning message.", - "type": "string" - }, - "reason": { - "description": "Reason for warning.", - "enum": [ - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - } - }, - "required": [ - "status", - "last_execution_date" - ], - "type": "object" - }, - "flapping": { - "additionalProperties": false, - "nullable": true, - "properties": { - "look_back_window": { - "maximum": 20, - "minimum": 2, - "type": "number" - }, - "status_change_threshold": { - "maximum": 20, - "minimum": 2, - "type": "number" - } - }, - "required": [ - "look_back_window", - "status_change_threshold" - ], - "type": "object" - }, - "id": { - "description": "The identifier for the rule.", - "type": "string" - }, - "is_snoozed_until": { - "description": "The date when the rule will no longer be snoozed.", - "nullable": true, - "type": "string" - }, - "last_run": { - "additionalProperties": false, - "nullable": true, - "properties": { - "alerts_count": { - "additionalProperties": false, - "properties": { - "active": { - "description": "Number of active alerts during last run.", - "nullable": true, - "type": "number" - }, - "ignored": { - "description": "Number of ignored alerts during last run.", - "nullable": true, - "type": "number" - }, - "new": { - "description": "Number of new alerts during last run.", - "nullable": true, - "type": "number" - }, - "recovered": { - "description": "Number of recovered alerts during last run.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "outcome_msg": { - "items": { - "description": "Outcome message generated during last rule run.", - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "outcome_order": { - "description": "Order of the outcome.", - "type": "number" - }, - "warning": { - "description": "Warning of last rule execution.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate", - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "nullable": true, - "type": "string" - } - }, - "required": [ - "outcome", - "alerts_count" - ], - "type": "object" - }, - "mapped_params": { - "additionalProperties": {}, - "type": "object" - }, - "monitoring": { - "additionalProperties": false, - "description": "Monitoring details of the rule.", - "properties": { - "run": { - "additionalProperties": false, - "description": "Rule run details.", - "properties": { - "calculated_metrics": { - "additionalProperties": false, - "description": "Calculation of different percentiles and success ratio.", - "properties": { - "p50": { - "type": "number" - }, - "p95": { - "type": "number" - }, - "p99": { - "type": "number" - }, - "success_ratio": { - "type": "number" - } - }, - "required": [ - "success_ratio" - ], - "type": "object" - }, - "history": { - "description": "History of the rule run.", - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule run.", - "type": "number" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "success": { - "description": "Indicates whether the rule run was successful.", - "type": "boolean" - }, - "timestamp": { - "description": "Time of rule run.", - "type": "number" - } - }, - "required": [ - "success", - "timestamp" - ], - "type": "object" - }, - "type": "array" - }, - "last_run": { - "additionalProperties": false, - "properties": { - "metrics": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of most recent rule run.", - "type": "number" - }, - "gap_duration_s": { - "description": "Duration in seconds of rule run gap.", - "nullable": true, - "type": "number" - }, - "total_alerts_created": { - "description": "Total number of alerts created during last rule run.", - "nullable": true, - "type": "number" - }, - "total_alerts_detected": { - "description": "Total number of alerts detected during last rule run.", - "nullable": true, - "type": "number" - }, - "total_indexing_duration_ms": { - "description": "Total time spent indexing documents during last rule run in milliseconds.", - "nullable": true, - "type": "number" - }, - "total_search_duration_ms": { - "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "timestamp": { - "description": "Time of the most recent rule run.", - "type": "string" - } - }, - "required": [ - "timestamp", - "metrics" - ], - "type": "object" - } - }, - "required": [ - "history", - "calculated_metrics", - "last_run" - ], - "type": "object" - } - }, - "required": [ - "run" - ], - "type": "object" - }, - "mute_all": { - "description": "Indicates whether all alerts are muted.", - "type": "boolean" - }, - "muted_alert_ids": { - "items": { - "description": "List of identifiers of muted alerts. ", - "type": "string" - }, - "type": "array" - }, - "name": { - "description": " The name of the rule.", - "type": "string" - }, - "next_run": { - "description": "Date and time of the next run of the rule.", - "nullable": true, - "type": "string" - }, - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "nullable": true, - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the rule.", - "type": "object" - }, - "revision": { - "description": "The rule revision number.", - "type": "number" - }, - "rule_type_id": { - "description": "The rule type identifier.", - "type": "string" - }, - "running": { - "description": "Indicates whether the rule is running.", - "nullable": true, - "type": "boolean" - }, - "schedule": { - "additionalProperties": false, - "properties": { - "interval": { - "description": "The interval is specified in seconds, minutes, hours, or days.", - "type": "string" - } - }, - "required": [ - "interval" - ], - "type": "object" - }, - "scheduled_task_id": { - "description": "Identifier of the scheduled task.", - "type": "string" - }, - "snooze_schedule": { - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule snooze schedule.", - "type": "number" - }, - "id": { - "description": "Identifier of the rule snooze schedule.", - "type": "string" - }, - "rRule": { - "additionalProperties": false, - "properties": { - "byhour": { - "items": { - "description": "Indicates hours of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byminute": { - "items": { - "description": "Indicates minutes of the hour to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonth": { - "items": { - "description": "Indicates months of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonthday": { - "items": { - "description": "Indicates the days of the month to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysecond": { - "items": { - "description": "Indicates seconds of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysetpos": { - "items": { - "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byweekday": { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ], - "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." - }, - "nullable": true, - "type": "array" - }, - "byweekno": { - "items": { - "description": "Indicates number of the week hours to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byyearday": { - "items": { - "description": "Indicates the days of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "count": { - "description": "Number of times the rule should recur until it stops.", - "type": "number" - }, - "dtstart": { - "description": "Rule start date in Coordinated Universal Time (UTC).", - "type": "string" - }, - "freq": { - "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", - "enum": [ - 0, - 1, - 2, - 3, - 4, - 5, - 6 - ], - "type": "integer" - }, - "interval": { - "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", - "type": "number" - }, - "tzid": { - "description": "Indicates timezone abbreviation.", - "type": "string" - }, - "until": { - "description": "Recur the rule until this date.", - "type": "string" - }, - "wkst": { - "description": "Indicates the start of week, defaults to Monday.", - "enum": [ - "MO", - "TU", - "WE", - "TH", - "FR", - "SA", - "SU" - ], - "type": "string" - } - }, - "required": [ - "dtstart", - "tzid" - ], - "type": "object" - }, - "skipRecurrences": { - "items": { - "description": "Skips recurrence of rule on this date.", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "duration", - "rRule" - ], - "type": "object" - }, - "type": "array" - }, - "tags": { - "items": { - "description": "The tags for the rule.", - "type": "string" - }, - "type": "array" - }, - "throttle": { - "deprecated": true, - "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - }, - "updated_at": { - "description": "The date and time that the rule was updated most recently.", - "type": "string" - }, - "updated_by": { - "description": "The identifier for the user that updated this rule most recently.", - "nullable": true, - "type": "string" - }, - "view_in_app_relative_url": { - "description": "Relative URL to view rule in the app.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "enabled", - "name", - "tags", - "rule_type_id", - "consumer", - "schedule", - "actions", - "params", - "created_by", - "updated_by", - "created_at", - "updated_at", - "api_key_owner", - "mute_all", - "muted_alert_ids", - "execution_status", - "revision" - ], - "type": "object" - } - } - }, - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." - }, - "409": { - "description": "Indicates that the rule has already been updated by another user." - } - }, - "summary": "Update a rule", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rule/{id}/_disable": { - "post": { - "operationId": "post-alerting-rule-id-disable", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "untrack": { - "description": "Defines whether this rule's alerts should be untracked.", - "type": "boolean" - } - }, - "type": "object", - "x-oas-optional": true - } - } - } - }, - "responses": { - "204": { - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." - } - }, - "summary": "Disable a rule", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rule/{id}/_enable": { - "post": { - "operationId": "post-alerting-rule-id-enable", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." - } - }, - "summary": "Enable a rule", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rule/{id}/_mute_all": { - "post": { - "operationId": "post-alerting-rule-id-mute-all", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." - } - }, - "summary": "Mute all alerts", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rule/{id}/_unmute_all": { - "post": { - "operationId": "post-alerting-rule-id-unmute-all", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." - } - }, - "summary": "Unmute all alerts", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rule/{id}/_update_api_key": { - "post": { - "operationId": "post-alerting-rule-id-update-api-key", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule with the given ID does not exist." - }, - "409": { - "description": "Indicates that the rule has already been updated by another user." - } - }, - "summary": "Update the API key for a rule", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rule/{rule_id}/alert/{alert_id}/_mute": { - "post": { - "operationId": "post-alerting-rule-rule-id-alert-alert-id-mute", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "rule_id", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The identifier for the alert.", - "in": "path", - "name": "alert_id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule or alert with the given ID does not exist." - } - }, - "summary": "Mute an alert", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rule/{rule_id}/alert/{alert_id}/_unmute": { - "post": { - "operationId": "post-alerting-rule-rule-id-alert-alert-id-unmute", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "description": "The identifier for the rule.", - "in": "path", - "name": "rule_id", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The identifier for the alert.", - "in": "path", - "name": "alert_id", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - }, - "404": { - "description": "Indicates a rule or alert with the given ID does not exist." - } - }, - "summary": "Unmute an alert", - "tags": [ - "alerting" - ] - } - }, - "/api/alerting/rules/_find": { - "get": { - "operationId": "get-alerting-rules-find", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "The number of rules to return per page.", - "in": "query", - "name": "per_page", - "required": false, - "schema": { - "default": 10, - "minimum": 0, - "type": "number" - } - }, - { - "description": "The page number to return.", - "in": "query", - "name": "page", - "required": false, - "schema": { - "default": 1, - "minimum": 1, - "type": "number" - } - }, - { - "description": "An Elasticsearch simple_query_string query that filters the objects in the response.", - "in": "query", - "name": "search", - "required": false, - "schema": { - "type": "string" - } - }, - { - "description": "The default operator to use for the simple_query_string.", - "in": "query", - "name": "default_search_operator", - "required": false, - "schema": { - "default": "OR", - "enum": [ - "OR", - "AND" - ], - "type": "string" - } - }, - { - "description": "The fields to perform the simple_query_string parsed query against.", - "in": "query", - "name": "search_fields", - "required": false, - "schema": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - } - }, - { - "description": "Determines which field is used to sort the results. The field must exist in the `attributes` key of the response.", - "in": "query", - "name": "sort_field", - "required": false, - "schema": { - "type": "string" - } - }, - { - "description": "Determines the sort order.", - "in": "query", - "name": "sort_order", - "required": false, - "schema": { - "enum": [ - "asc", - "desc" - ], - "type": "string" - } - }, - { - "description": "Filters the rules that have a relation with the reference objects with a specific type and identifier.", - "in": "query", - "name": "has_reference", - "required": false, - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "id": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "type", - "id" - ], - "type": "object" - } - }, - { - "in": "query", - "name": "fields", - "required": false, - "schema": { - "items": { - "description": "The fields to return in the `attributes` key of the response.", - "type": "string" - }, - "type": "array" - } - }, - { - "description": "A KQL string that you filter with an attribute from your saved object. It should look like `savedObjectType.attributes.title: \"myTitle\"`. However, if you used a direct attribute of a saved object, such as `updatedAt`, you must define your filter, for example, `savedObjectType.updatedAt > 2018-12-22`.", - "in": "query", - "name": "filter", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "filter_consumers", - "required": false, - "schema": { - "items": { - "description": "List of consumers to filter.", - "type": "string" - }, - "type": "array" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actions": { - "items": { - "additionalProperties": false, - "properties": { - "alerts_filter": { - "additionalProperties": false, - "description": "Defines a period that limits whether the action runs.", - "properties": { - "query": { - "additionalProperties": false, - "properties": { - "dsl": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", - "type": "string" - }, - "filters": { - "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", - "items": { - "additionalProperties": false, - "properties": { - "$state": { - "additionalProperties": false, - "properties": { - "store": { - "description": "A filter can be either specific to an application context or applied globally.", - "enum": [ - "appState", - "globalState" - ], - "type": "string" - } - }, - "required": [ - "store" - ], - "type": "object" - }, - "meta": { - "additionalProperties": {}, - "type": "object" - }, - "query": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "meta" - ], - "type": "object" - }, - "type": "array" - }, - "kql": { - "description": "A filter written in Kibana Query Language (KQL).", - "type": "string" - } - }, - "required": [ - "kql", - "filters" - ], - "type": "object" - }, - "timeframe": { - "additionalProperties": false, - "properties": { - "days": { - "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", - "items": { - "enum": [ - 1, - 2, - 3, - 4, - 5, - 6, - 7 - ], - "type": "integer" - }, - "type": "array" - }, - "hours": { - "additionalProperties": false, - "properties": { - "end": { - "description": "The end of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - }, - "start": { - "description": "The start of the time frame in 24-hour notation (`hh:mm`).", - "type": "string" - } - }, - "required": [ - "start", - "end" - ], - "type": "object" - }, - "timezone": { - "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", - "type": "string" - } - }, - "required": [ - "days", - "hours", - "timezone" - ], - "type": "object" - } - }, - "type": "object" - }, - "connector_type_id": { - "description": "The type of connector. This property appears in responses but cannot be set in requests.", - "type": "string" - }, - "frequency": { - "additionalProperties": false, - "properties": { - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "type": "string" - }, - "summary": { - "description": "Indicates whether the action is a summary.", - "type": "boolean" - }, - "throttle": { - "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "summary", - "notify_when", - "throttle" - ], - "type": "object" - }, - "group": { - "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", - "type": "string" - }, - "id": { - "description": "The identifier for the connector saved object.", - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", - "type": "object" - }, - "use_alert_data_for_template": { - "description": "Indicates whether to use alert data as a template.", - "type": "boolean" - }, - "uuid": { - "description": "A universally unique identifier (UUID) for the action.", - "type": "string" - } - }, - "required": [ - "id", - "connector_type_id", - "params" - ], - "type": "object" - }, - "type": "array" - }, - "active_snoozes": { - "items": { - "description": "List of active snoozes for the rule.", - "type": "string" - }, - "type": "array" - }, - "alert_delay": { - "additionalProperties": false, - "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", - "properties": { - "active": { - "description": "The number of consecutive runs that must meet the rule conditions.", - "type": "number" - } - }, - "required": [ - "active" - ], - "type": "object" - }, - "api_key_created_by_user": { - "description": "Indicates whether the API key that is associated with the rule was created by the user.", - "nullable": true, - "type": "boolean" - }, - "api_key_owner": { - "description": "The owner of the API key that is associated with the rule and used to run background tasks.", - "nullable": true, - "type": "string" - }, - "consumer": { - "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", - "type": "string" - }, - "created_at": { - "description": "The date and time that the rule was created.", - "type": "string" - }, - "created_by": { - "description": "The identifier for the user that created the rule.", - "nullable": true, - "type": "string" - }, - "enabled": { - "description": "Indicates whether you want to run the rule on an interval basis after it is created.", - "type": "boolean" - }, - "execution_status": { - "additionalProperties": false, - "properties": { - "error": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Error message.", - "type": "string" - }, - "reason": { - "description": "Reason for error.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - }, - "last_duration": { - "description": "Duration of last execution of the rule.", - "type": "number" - }, - "last_execution_date": { - "description": "The date and time when rule was executed last.", - "type": "string" - }, - "status": { - "description": "Status of rule execution.", - "enum": [ - "ok", - "active", - "error", - "warning", - "pending", - "unknown" - ], - "type": "string" - }, - "warning": { - "additionalProperties": false, - "properties": { - "message": { - "description": "Warning message.", - "type": "string" - }, - "reason": { - "description": "Reason for warning.", - "enum": [ - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "type": "string" - } - }, - "required": [ - "reason", - "message" - ], - "type": "object" - } - }, - "required": [ - "status", - "last_execution_date" - ], - "type": "object" - }, - "flapping": { - "additionalProperties": false, - "nullable": true, - "properties": { - "look_back_window": { - "maximum": 20, - "minimum": 2, - "type": "number" - }, - "status_change_threshold": { - "maximum": 20, - "minimum": 2, - "type": "number" - } - }, - "required": [ - "look_back_window", - "status_change_threshold" - ], - "type": "object" - }, - "id": { - "description": "The identifier for the rule.", - "type": "string" - }, - "is_snoozed_until": { - "description": "The date when the rule will no longer be snoozed.", - "nullable": true, - "type": "string" - }, - "last_run": { - "additionalProperties": false, - "nullable": true, - "properties": { - "alerts_count": { - "additionalProperties": false, - "properties": { - "active": { - "description": "Number of active alerts during last run.", - "nullable": true, - "type": "number" - }, - "ignored": { - "description": "Number of ignored alerts during last run.", - "nullable": true, - "type": "number" - }, - "new": { - "description": "Number of new alerts during last run.", - "nullable": true, - "type": "number" - }, - "recovered": { - "description": "Number of recovered alerts during last run.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "outcome_msg": { - "items": { - "description": "Outcome message generated during last rule run.", - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "outcome_order": { - "description": "Order of the outcome.", - "type": "number" - }, - "warning": { - "description": "Warning of last rule execution.", - "enum": [ - "read", - "decrypt", - "execute", - "unknown", - "license", - "timeout", - "disabled", - "validate", - "maxExecutableActions", - "maxAlerts", - "maxQueuedActions", - "ruleExecution" - ], - "nullable": true, - "type": "string" - } - }, - "required": [ - "outcome", - "alerts_count" - ], - "type": "object" - }, - "mapped_params": { - "additionalProperties": {}, - "type": "object" - }, - "monitoring": { - "additionalProperties": false, - "description": "Monitoring details of the rule.", - "properties": { - "run": { - "additionalProperties": false, - "description": "Rule run details.", - "properties": { - "calculated_metrics": { - "additionalProperties": false, - "description": "Calculation of different percentiles and success ratio.", - "properties": { - "p50": { - "type": "number" - }, - "p95": { - "type": "number" - }, - "p99": { - "type": "number" - }, - "success_ratio": { - "type": "number" - } - }, - "required": [ - "success_ratio" - ], - "type": "object" - }, - "history": { - "description": "History of the rule run.", - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule run.", - "type": "number" - }, - "outcome": { - "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", - "enum": [ - "succeeded", - "warning", - "failed" - ], - "type": "string" - }, - "success": { - "description": "Indicates whether the rule run was successful.", - "type": "boolean" - }, - "timestamp": { - "description": "Time of rule run.", - "type": "number" - } - }, - "required": [ - "success", - "timestamp" - ], - "type": "object" - }, - "type": "array" - }, - "last_run": { - "additionalProperties": false, - "properties": { - "metrics": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of most recent rule run.", - "type": "number" - }, - "gap_duration_s": { - "description": "Duration in seconds of rule run gap.", - "nullable": true, - "type": "number" - }, - "total_alerts_created": { - "description": "Total number of alerts created during last rule run.", - "nullable": true, - "type": "number" - }, - "total_alerts_detected": { - "description": "Total number of alerts detected during last rule run.", - "nullable": true, - "type": "number" - }, - "total_indexing_duration_ms": { - "description": "Total time spent indexing documents during last rule run in milliseconds.", - "nullable": true, - "type": "number" - }, - "total_search_duration_ms": { - "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", - "nullable": true, - "type": "number" - } - }, - "type": "object" - }, - "timestamp": { - "description": "Time of the most recent rule run.", - "type": "string" - } - }, - "required": [ - "timestamp", - "metrics" - ], - "type": "object" - } - }, - "required": [ - "history", - "calculated_metrics", - "last_run" - ], - "type": "object" - } - }, - "required": [ - "run" - ], - "type": "object" - }, - "mute_all": { - "description": "Indicates whether all alerts are muted.", - "type": "boolean" - }, - "muted_alert_ids": { - "items": { - "description": "List of identifiers of muted alerts. ", - "type": "string" - }, - "type": "array" - }, - "name": { - "description": " The name of the rule.", - "type": "string" - }, - "next_run": { - "description": "Date and time of the next run of the rule.", - "nullable": true, - "type": "string" - }, - "notify_when": { - "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "enum": [ - "onActionGroupChange", - "onActiveAlert", - "onThrottleInterval" - ], - "nullable": true, - "type": "string" - }, - "params": { - "additionalProperties": {}, - "description": "The parameters for the rule.", - "type": "object" - }, - "revision": { - "description": "The rule revision number.", - "type": "number" - }, - "rule_type_id": { - "description": "The rule type identifier.", - "type": "string" - }, - "running": { - "description": "Indicates whether the rule is running.", - "nullable": true, - "type": "boolean" - }, - "schedule": { - "additionalProperties": false, - "properties": { - "interval": { - "description": "The interval is specified in seconds, minutes, hours, or days.", - "type": "string" - } - }, - "required": [ - "interval" - ], - "type": "object" - }, - "scheduled_task_id": { - "description": "Identifier of the scheduled task.", - "type": "string" - }, - "snooze_schedule": { - "items": { - "additionalProperties": false, - "properties": { - "duration": { - "description": "Duration of the rule snooze schedule.", - "type": "number" - }, - "id": { - "description": "Identifier of the rule snooze schedule.", - "type": "string" - }, - "rRule": { - "additionalProperties": false, - "properties": { - "byhour": { - "items": { - "description": "Indicates hours of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byminute": { - "items": { - "description": "Indicates minutes of the hour to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonth": { - "items": { - "description": "Indicates months of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bymonthday": { - "items": { - "description": "Indicates the days of the month to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysecond": { - "items": { - "description": "Indicates seconds of the day to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "bysetpos": { - "items": { - "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byweekday": { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ], - "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." - }, - "nullable": true, - "type": "array" - }, - "byweekno": { - "items": { - "description": "Indicates number of the week hours to recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "byyearday": { - "items": { - "description": "Indicates the days of the year that this rule should recur.", - "type": "number" - }, - "nullable": true, - "type": "array" - }, - "count": { - "description": "Number of times the rule should recur until it stops.", - "type": "number" - }, - "dtstart": { - "description": "Rule start date in Coordinated Universal Time (UTC).", - "type": "string" - }, - "freq": { - "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", - "enum": [ - 0, - 1, - 2, - 3, - 4, - 5, - 6 - ], - "type": "integer" - }, - "interval": { - "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", - "type": "number" - }, - "tzid": { - "description": "Indicates timezone abbreviation.", - "type": "string" - }, - "until": { - "description": "Recur the rule until this date.", - "type": "string" - }, - "wkst": { - "description": "Indicates the start of week, defaults to Monday.", - "enum": [ - "MO", - "TU", - "WE", - "TH", - "FR", - "SA", - "SU" - ], - "type": "string" - } - }, - "required": [ - "dtstart", - "tzid" - ], - "type": "object" - }, - "skipRecurrences": { - "items": { - "description": "Skips recurrence of rule on this date.", - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "duration", - "rRule" - ], - "type": "object" - }, - "type": "array" - }, - "tags": { - "items": { - "description": "The tags for the rule.", - "type": "string" - }, - "type": "array" - }, - "throttle": { - "deprecated": true, - "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", - "nullable": true, - "type": "string" - }, - "updated_at": { - "description": "The date and time that the rule was updated most recently.", - "type": "string" - }, - "updated_by": { - "description": "The identifier for the user that updated this rule most recently.", - "nullable": true, - "type": "string" - }, - "view_in_app_relative_url": { - "description": "Relative URL to view rule in the app.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "enabled", - "name", - "tags", - "rule_type_id", - "consumer", - "schedule", - "actions", - "params", - "created_by", - "updated_by", - "created_at", - "updated_at", - "api_key_owner", - "mute_all", - "muted_alert_ids", - "execution_status", - "revision" - ], - "type": "object" - } - } - }, - "description": "Indicates a successful call." - }, - "400": { - "description": "Indicates an invalid schema or parameters." - }, - "403": { - "description": "Indicates that this call is forbidden." - } - }, - "summary": "Get information about rules", - "tags": [ - "alerting" - ] - } - }, - "/api/fleet/agent-status": { - "get": { - "operationId": "get-fleet-agent-status-2", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "policyId", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "policyIds", - "required": false, - "schema": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "deprecated": true, - "type": "string" - } - } - ], - "responses": {}, - "summary": "", - "tags": [] - } - }, - "/api/fleet/agent_download_sources": { - "get": { - "description": "List agent binary download sources", - "operationId": "get-fleet-agent-download-sources", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "host": { - "format": "uri", - "type": "string" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "description": "The ID of the proxy to use for this download source. See the proxies API for more information.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host" - ], - "type": "object" - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent binary download sources" - ] - }, - "post": { - "description": "Create agent binary download source", - "operationId": "post-fleet-agent-download-sources", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "host": { - "format": "uri", - "type": "string" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "description": "The ID of the proxy to use for this download source. See the proxies API for more information.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "name", - "host" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "host": { - "format": "uri", - "type": "string" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "description": "The ID of the proxy to use for this download source. See the proxies API for more information.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent binary download sources" - ] - } - }, - "/api/fleet/agent_download_sources/{sourceId}": { - "delete": { - "description": "Delete agent binary download source by ID", - "operationId": "delete-fleet-agent-download-sources-sourceid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "sourceId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent binary download sources" - ] - }, - "get": { - "description": "Get agent binary download source by ID", - "operationId": "get-fleet-agent-download-sources-sourceid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "sourceId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "host": { - "format": "uri", - "type": "string" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "description": "The ID of the proxy to use for this download source. See the proxies API for more information.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent binary download sources" - ] - }, - "put": { - "description": "Update agent binary download source by ID", - "operationId": "put-fleet-agent-download-sources-sourceid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "sourceId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "host": { - "format": "uri", - "type": "string" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "description": "The ID of the proxy to use for this download source. See the proxies API for more information.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "name", - "host" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "host": { - "format": "uri", - "type": "string" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "description": "The ID of the proxy to use for this download source. See the proxies API for more information.", - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent binary download sources" - ] - } - }, - "/api/fleet/agent_policies": { - "get": { - "description": "List agent policies", - "operationId": "get-fleet-agent-policies", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "page", - "required": false, - "schema": { - "type": "number" - } - }, - { - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "type": "number" - } - }, - { - "in": "query", - "name": "sortField", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "sortOrder", - "required": false, - "schema": { - "enum": [ - "desc", - "asc" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "showUpgradeable", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "type": "string" - } - }, - { - "description": "use withAgentCount instead", - "in": "query", - "name": "noAgentCount", - "required": false, - "schema": { - "deprecated": true, - "type": "boolean" - } - }, - { - "description": "get policies with agent count", - "in": "query", - "name": "withAgentCount", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "description": "get full policies with package policies populated", - "in": "query", - "name": "full", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "agents": { - "type": "number" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "is_protected": { - "description": "Indicates whether the agent policy has tamper protection enabled. Default false.", - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "package_policies": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "description": "This field is present only when retrieving a single agent policy, or when retrieving a list of agent policies with the ?full=true parameter", - "items": { - "additionalProperties": false, - "properties": { - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - } - ] - }, - "revision": { - "type": "number" - }, - "schema_version": { - "type": "string" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "status": { - "enum": [ - "active", - "inactive" - ], - "type": "string" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - }, - "unprivileged_agents": { - "type": "number" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "name", - "namespace", - "is_managed", - "is_protected", - "status", - "updated_at", - "updated_by", - "revision" - ], - "type": "object" - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - }, - "post": { - "description": "Create an agent policy", - "operationId": "post-fleet-agent-policies", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "query", - "name": "sys_monitoring", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "force": { - "type": "boolean" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_protected": { - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - } - }, - "required": [ - "name", - "namespace" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "agents": { - "type": "number" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "is_protected": { - "description": "Indicates whether the agent policy has tamper protection enabled. Default false.", - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "package_policies": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "description": "This field is present only when retrieving a single agent policy, or when retrieving a list of agent policies with the ?full=true parameter", - "items": { - "additionalProperties": false, - "properties": { - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - } - ] - }, - "revision": { - "type": "number" - }, - "schema_version": { - "type": "string" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "status": { - "enum": [ - "active", - "inactive" - ], - "type": "string" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - }, - "unprivileged_agents": { - "type": "number" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "name", - "namespace", - "is_managed", - "is_protected", - "status", - "updated_at", - "updated_by", - "revision" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/_bulk_get": { - "post": { - "description": "Bulk get agent policies", - "operationId": "post-fleet-agent-policies-bulk-get", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "full": { - "description": "get full policies with package policies populated", - "type": "boolean" - }, - "ids": { - "description": "list of package policy ids", - "items": { - "type": "string" - }, - "type": "array" - }, - "ignoreMissing": { - "type": "boolean" - } - }, - "required": [ - "ids" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "agents": { - "type": "number" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "is_protected": { - "description": "Indicates whether the agent policy has tamper protection enabled. Default false.", - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "package_policies": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "description": "This field is present only when retrieving a single agent policy, or when retrieving a list of agent policies with the ?full=true parameter", - "items": { - "additionalProperties": false, - "properties": { - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - } - ] - }, - "revision": { - "type": "number" - }, - "schema_version": { - "type": "string" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "status": { - "enum": [ - "active", - "inactive" - ], - "type": "string" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - }, - "unprivileged_agents": { - "type": "number" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "name", - "namespace", - "is_managed", - "is_protected", - "status", - "updated_at", - "updated_by", - "revision" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/delete": { - "post": { - "description": "Delete agent policy by ID", - "operationId": "post-fleet-agent-policies-delete", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "agentPolicyId": { - "type": "string" - }, - "force": { - "description": "bypass validation checks that can prevent agent policy deletion", - "type": "boolean" - } - }, - "required": [ - "agentPolicyId" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "id", - "name" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/outputs": { - "post": { - "description": "Get list of outputs associated with agent policies", - "operationId": "post-fleet-agent-policies-outputs", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "ids": { - "description": "list of package policy ids", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "ids" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "agentPolicyId": { - "type": "string" - }, - "data": { - "additionalProperties": false, - "properties": { - "integrations": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "integrationPolicyName": { - "type": "string" - }, - "name": { - "type": "string" - }, - "pkgName": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "output": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "id", - "name" - ], - "type": "object" - } - }, - "required": [ - "output" - ], - "type": "object" - }, - "monitoring": { - "additionalProperties": false, - "properties": { - "output": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "id", - "name" - ], - "type": "object" - } - }, - "required": [ - "output" - ], - "type": "object" - } - }, - "required": [ - "monitoring", - "data" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/{agentPolicyId}": { - "get": { - "description": "Get an agent policy by ID", - "operationId": "get-fleet-agent-policies-agentpolicyid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "agentPolicyId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "agents": { - "type": "number" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "is_protected": { - "description": "Indicates whether the agent policy has tamper protection enabled. Default false.", - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "package_policies": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "description": "This field is present only when retrieving a single agent policy, or when retrieving a list of agent policies with the ?full=true parameter", - "items": { - "additionalProperties": false, - "properties": { - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - } - ] - }, - "revision": { - "type": "number" - }, - "schema_version": { - "type": "string" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "status": { - "enum": [ - "active", - "inactive" - ], - "type": "string" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - }, - "unprivileged_agents": { - "type": "number" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "name", - "namespace", - "is_managed", - "is_protected", - "status", - "updated_at", - "updated_by", - "revision" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - }, - "put": { - "description": "Update an agent policy by ID", - "operationId": "put-fleet-agent-policies-agentpolicyid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentPolicyId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "force": { - "type": "boolean" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_protected": { - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - } - }, - "required": [ - "name", - "namespace" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "agents": { - "type": "number" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "is_protected": { - "description": "Indicates whether the agent policy has tamper protection enabled. Default false.", - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "package_policies": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "description": "This field is present only when retrieving a single agent policy, or when retrieving a list of agent policies with the ?full=true parameter", - "items": { - "additionalProperties": false, - "properties": { - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - } - ] - }, - "revision": { - "type": "number" - }, - "schema_version": { - "type": "string" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "status": { - "enum": [ - "active", - "inactive" - ], - "type": "string" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - }, - "unprivileged_agents": { - "type": "number" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "name", - "namespace", - "is_managed", - "is_protected", - "status", - "updated_at", - "updated_by", - "revision" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/{agentPolicyId}/copy": { - "post": { - "description": "Copy an agent policy by ID", - "operationId": "post-fleet-agent-policies-agentpolicyid-copy", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentPolicyId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "description": { - "type": "string" - }, - "name": { - "minLength": 1, - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "advanced_settings": { - "additionalProperties": false, - "properties": { - "agent_download_target_directory": { - "nullable": true - }, - "agent_download_timeout": { - "default": "2h", - "nullable": true - }, - "agent_limits_go_max_procs": { - "nullable": true - }, - "agent_logging_level": { - "default": "info", - "nullable": true - }, - "agent_logging_metrics_period": { - "default": "30s", - "nullable": true - } - }, - "type": "object" - }, - "agent_features": { - "items": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "agents": { - "type": "number" - }, - "data_output_id": { - "nullable": true, - "type": "string" - }, - "description": { - "type": "string" - }, - "download_source_id": { - "nullable": true, - "type": "string" - }, - "fleet_server_host_id": { - "nullable": true, - "type": "string" - }, - "global_data_tags": { - "description": "User defined data tags that are added to all of the inputs. The values can be strings or numbers.", - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "value": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "has_fleet_server": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inactivity_timeout": { - "default": 1209600, - "minimum": 0, - "type": "number" - }, - "is_default": { - "type": "boolean" - }, - "is_default_fleet_server": { - "type": "boolean" - }, - "is_managed": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "is_protected": { - "description": "Indicates whether the agent policy has tamper protection enabled. Default false.", - "type": "boolean" - }, - "keep_monitoring_alive": { - "default": false, - "description": "When set to true, monitoring will be enabled but logs/metrics collection will be disabled", - "nullable": true, - "type": "boolean" - }, - "monitoring_diagnostics": { - "additionalProperties": false, - "properties": { - "limit": { - "additionalProperties": false, - "properties": { - "burst": { - "type": "number" - }, - "interval": { - "type": "string" - } - }, - "type": "object" - }, - "uploader": { - "additionalProperties": false, - "properties": { - "init_dur": { - "type": "string" - }, - "max_dur": { - "type": "string" - }, - "max_retries": { - "type": "number" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "monitoring_enabled": { - "items": { - "enum": [ - "logs", - "metrics", - "traces" - ], - "type": "string" - }, - "type": "array" - }, - "monitoring_http": { - "additionalProperties": false, - "properties": { - "buffer": { - "additionalProperties": false, - "properties": { - "enabled": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "host": { - "type": "string" - }, - "port": { - "maximum": 65353, - "minimum": 0, - "type": "number" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "monitoring_output_id": { - "nullable": true, - "type": "string" - }, - "monitoring_pprof_enabled": { - "type": "boolean" - }, - "name": { - "minLength": 1, - "type": "string" - }, - "namespace": { - "minLength": 1, - "type": "string" - }, - "overrides": { - "additionalProperties": {}, - "description": "Override settings that are defined in the agent policy. Input settings cannot be overridden. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "type": "object" - }, - "package_policies": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "description": "This field is present only when retrieving a single agent policy, or when retrieving a list of agent policies with the ?full=true parameter", - "items": { - "additionalProperties": false, - "properties": { - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - } - ] - }, - "revision": { - "type": "number" - }, - "schema_version": { - "type": "string" - }, - "space_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "status": { - "enum": [ - "active", - "inactive" - ], - "type": "string" - }, - "supports_agentless": { - "default": false, - "description": "Indicates whether the agent policy supports agentless integrations.", - "nullable": true, - "type": "boolean" - }, - "unenroll_timeout": { - "minimum": 0, - "type": "number" - }, - "unprivileged_agents": { - "type": "number" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "name", - "namespace", - "is_managed", - "is_protected", - "status", - "updated_at", - "updated_by", - "revision" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/{agentPolicyId}/download": { - "get": { - "description": "Download an agent policy by ID", - "operationId": "get-fleet-agent-policies-agentpolicyid-download", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "agentPolicyId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "download", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "standalone", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "kubernetes", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/{agentPolicyId}/full": { - "get": { - "description": "Get a full agent policy by ID", - "operationId": "get-fleet-agent-policies-agentpolicyid-full", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "agentPolicyId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "download", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "standalone", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "kubernetes", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "anyOf": [ - { - "type": "string" - }, - { - "additionalProperties": false, - "properties": { - "agent": { - "additionalProperties": false, - "properties": { - "download": { - "additionalProperties": false, - "properties": { - "sourceURI": { - "type": "string" - } - }, - "required": [ - "sourceURI" - ], - "type": "object" - }, - "features": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - } - }, - "required": [ - "enabled" - ], - "type": "object" - }, - "type": "object" - }, - "monitoring": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "logs": { - "type": "boolean" - }, - "metrics": { - "type": "boolean" - }, - "namespace": { - "type": "string" - }, - "traces": { - "type": "boolean" - }, - "use_output": { - "type": "string" - } - }, - "required": [ - "enabled", - "metrics", - "logs", - "traces" - ], - "type": "object" - }, - "protection": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" - }, - "signing_key": { - "type": "string" - }, - "uninstall_token_hash": { - "type": "string" - } - }, - "required": [ - "enabled", - "uninstall_token_hash", - "signing_key" - ], - "type": "object" - } - }, - "required": [ - "monitoring", - "download", - "features" - ], - "type": "object" - }, - "fleet": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "hosts": { - "items": { - "type": "string" - }, - "type": "array" - }, - "proxy_headers": {}, - "proxy_url": { - "type": "string" - }, - "ssl": { - "additionalProperties": false, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "renegotiation": { - "type": "string" - }, - "verification_mode": { - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ - "hosts", - "proxy_headers" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "kibana": { - "additionalProperties": false, - "properties": { - "hosts": { - "items": { - "type": "string" - }, - "type": "array" - }, - "path": { - "type": "string" - }, - "protocol": { - "type": "string" - } - }, - "required": [ - "hosts", - "protocol" - ], - "type": "object" - } - }, - "required": [ - "kibana" - ], - "type": "object" - } - ] - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "additionalProperties": true, - "properties": { - "namespace": { - "type": "string" - } - }, - "required": [ - "namespace" - ], - "type": "object" - }, - "id": { - "type": "string" - }, - "meta": { - "additionalProperties": true, - "properties": { - "package": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - } - }, - "type": "object" - }, - "name": { - "type": "string" - }, - "package_policy_id": { - "type": "string" - }, - "processors": { - "items": { - "additionalProperties": true, - "properties": { - "add_fields": { - "additionalProperties": true, - "properties": { - "fields": { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - }, - "type": "object" - }, - "target": { - "type": "string" - } - }, - "required": [ - "target", - "fields" - ], - "type": "object" - } - }, - "required": [ - "add_fields" - ], - "type": "object" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "streams": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "additionalProperties": true, - "properties": { - "dataset": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset" - ], - "type": "object" - }, - "id": { - "type": "string" - } - }, - "required": [ - "id", - "data_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "use_output": { - "type": "string" - } - }, - "required": [ - "id", - "name", - "revision", - "type", - "data_stream", - "use_output", - "package_policy_id" - ], - "type": "object" - }, - "type": "array" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "output_permissions": { - "additionalProperties": { - "additionalProperties": {}, - "type": "object" - }, - "type": "object" - }, - "outputs": { - "additionalProperties": { - "additionalProperties": true, - "properties": { - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "type": "string" - }, - "type": "array" - }, - "proxy_headers": {}, - "proxy_url": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "type", - "proxy_headers" - ], - "type": "object" - }, - "type": "object" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "signed": { - "additionalProperties": false, - "properties": { - "data": { - "type": "string" - }, - "signature": { - "type": "string" - } - }, - "required": [ - "data", - "signature" - ], - "type": "object" - } - }, - "required": [ - "id", - "outputs", - "inputs" - ], - "type": "object" - } - ] - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_policies/{agentPolicyId}/outputs": { - "get": { - "description": "Get list of outputs associated with agent policy by policy id", - "operationId": "get-fleet-agent-policies-agentpolicyid-outputs", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "agentPolicyId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "agentPolicyId": { - "type": "string" - }, - "data": { - "additionalProperties": false, - "properties": { - "integrations": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "integrationPolicyName": { - "type": "string" - }, - "name": { - "type": "string" - }, - "pkgName": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "output": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "id", - "name" - ], - "type": "object" - } - }, - "required": [ - "output" - ], - "type": "object" - }, - "monitoring": { - "additionalProperties": false, - "properties": { - "output": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "id", - "name" - ], - "type": "object" - } - }, - "required": [ - "output" - ], - "type": "object" - } - }, - "required": [ - "monitoring", - "data" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/agent_status": { - "get": { - "description": "Get agent status summary", - "operationId": "get-fleet-agent-status", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "policyId", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "policyIds", - "required": false, - "schema": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "deprecated": true, - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "results": { - "additionalProperties": false, - "properties": { - "active": { - "type": "number" - }, - "all": { - "type": "number" - }, - "error": { - "type": "number" - }, - "events": { - "type": "number" - }, - "inactive": { - "type": "number" - }, - "offline": { - "type": "number" - }, - "online": { - "type": "number" - }, - "other": { - "type": "number" - }, - "total": { - "deprecated": true, - "type": "number" - }, - "unenrolled": { - "type": "number" - }, - "updating": { - "type": "number" - } - }, - "required": [ - "events", - "total", - "online", - "error", - "offline", - "other", - "updating", - "inactive", - "unenrolled", - "all", - "active" - ], - "type": "object" - } - }, - "required": [ - "results" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent status" - ] - } - }, - "/api/fleet/agent_status/data": { - "get": { - "description": "Get incoming agent data", - "operationId": "get-fleet-agent-status-data", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "agentsIds", - "required": true, - "schema": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - } - }, - { - "in": "query", - "name": "previewData", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "dataPreview": { - "items": {}, - "type": "array" - }, - "items": { - "items": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "data": { - "type": "boolean" - } - }, - "required": [ - "data" - ], - "type": "object" - }, - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items", - "dataPreview" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents": { - "get": { - "description": "List agents", - "operationId": "get-fleet-agents", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "page", - "required": false, - "schema": { - "default": 1, - "type": "number" - } - }, - { - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "default": 20, - "type": "number" - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "showInactive", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - }, - { - "in": "query", - "name": "withMetrics", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - }, - { - "in": "query", - "name": "showUpgradeable", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - }, - { - "in": "query", - "name": "getStatusSummary", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - }, - { - "in": "query", - "name": "sortField", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "sortOrder", - "required": false, - "schema": { - "enum": [ - "asc", - "desc" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "access_api_key": { - "type": "string" - }, - "access_api_key_id": { - "type": "string" - }, - "active": { - "type": "boolean" - }, - "agent": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "version" - ], - "type": "object" - }, - "components": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "type": "string" - }, - "units": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "payload": { - "additionalProperties": {}, - "type": "object" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "enum": [ - "input", - "output" - ], - "type": "string" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key": { - "type": "string" - }, - "default_api_key_history": { - "items": { - "additionalProperties": false, - "deprecated": true, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key_id": { - "type": "string" - }, - "enrolled_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "last_checkin": { - "type": "string" - }, - "last_checkin_message": { - "type": "string" - }, - "last_checkin_status": { - "enum": [ - "error", - "online", - "degraded", - "updating", - "starting" - ], - "type": "string" - }, - "local_metadata": { - "additionalProperties": {}, - "type": "object" - }, - "metrics": { - "additionalProperties": false, - "properties": { - "cpu_avg": { - "type": "number" - }, - "memory_size_byte_avg": { - "type": "number" - } - }, - "type": "object" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "outputs": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "api_key_id": { - "type": "string" - }, - "to_retire_api_key_ids": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - } - }, - "required": [ - "api_key_id", - "type" - ], - "type": "object" - }, - "type": "object" - }, - "packages": { - "items": { - "type": "string" - }, - "type": "array" - }, - "policy_id": { - "type": "string" - }, - "policy_revision": { - "nullable": true, - "type": "number" - }, - "sort": { - "items": { - "anyOf": [ - { - "type": "number" - }, - { - "type": "string" - }, - { - "enum": [], - "nullable": true - } - ] - }, - "type": "array" - }, - "status": { - "enum": [ - "offline", - "error", - "online", - "inactive", - "enrolling", - "unenrolling", - "unenrolled", - "updating", - "degraded" - ], - "type": "string" - }, - "tags": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "enum": [ - "PERMANENT", - "EPHEMERAL", - "TEMPORARY" - ], - "type": "string" - }, - "unenrolled_at": { - "type": "string" - }, - "unenrollment_started_at": { - "type": "string" - }, - "unhealthy_reason": { - "items": { - "enum": [ - "input", - "output", - "other" - ], - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "upgrade_details": { - "additionalProperties": false, - "properties": { - "action_id": { - "type": "string" - }, - "metadata": { - "additionalProperties": false, - "properties": { - "download_percent": { - "type": "number" - }, - "download_rate": { - "type": "number" - }, - "error_msg": { - "type": "string" - }, - "failed_state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "retry_error_msg": { - "type": "string" - }, - "retry_until": { - "type": "string" - }, - "scheduled_at": { - "type": "string" - } - }, - "type": "object" - }, - "state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "target_version", - "action_id", - "state" - ], - "type": "object" - }, - "upgrade_started_at": { - "nullable": true, - "type": "string" - }, - "upgraded_at": { - "nullable": true, - "type": "string" - }, - "user_provided_metadata": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "id", - "packages", - "type", - "active", - "enrolled_at", - "local_metadata" - ], - "type": "object" - }, - "type": "array" - }, - "list": { - "deprecated": true, - "items": { - "additionalProperties": false, - "properties": { - "access_api_key": { - "type": "string" - }, - "access_api_key_id": { - "type": "string" - }, - "active": { - "type": "boolean" - }, - "agent": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "version" - ], - "type": "object" - }, - "components": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "type": "string" - }, - "units": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "payload": { - "additionalProperties": {}, - "type": "object" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "enum": [ - "input", - "output" - ], - "type": "string" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key": { - "type": "string" - }, - "default_api_key_history": { - "items": { - "additionalProperties": false, - "deprecated": true, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key_id": { - "type": "string" - }, - "enrolled_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "last_checkin": { - "type": "string" - }, - "last_checkin_message": { - "type": "string" - }, - "last_checkin_status": { - "enum": [ - "error", - "online", - "degraded", - "updating", - "starting" - ], - "type": "string" - }, - "local_metadata": { - "additionalProperties": {}, - "type": "object" - }, - "metrics": { - "additionalProperties": false, - "properties": { - "cpu_avg": { - "type": "number" - }, - "memory_size_byte_avg": { - "type": "number" - } - }, - "type": "object" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "outputs": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "api_key_id": { - "type": "string" - }, - "to_retire_api_key_ids": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - } - }, - "required": [ - "api_key_id", - "type" - ], - "type": "object" - }, - "type": "object" - }, - "packages": { - "items": { - "type": "string" - }, - "type": "array" - }, - "policy_id": { - "type": "string" - }, - "policy_revision": { - "nullable": true, - "type": "number" - }, - "sort": { - "items": { - "anyOf": [ - { - "type": "number" - }, - { - "type": "string" - }, - { - "enum": [], - "nullable": true - } - ] - }, - "type": "array" - }, - "status": { - "enum": [ - "offline", - "error", - "online", - "inactive", - "enrolling", - "unenrolling", - "unenrolled", - "updating", - "degraded" - ], - "type": "string" - }, - "tags": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "enum": [ - "PERMANENT", - "EPHEMERAL", - "TEMPORARY" - ], - "type": "string" - }, - "unenrolled_at": { - "type": "string" - }, - "unenrollment_started_at": { - "type": "string" - }, - "unhealthy_reason": { - "items": { - "enum": [ - "input", - "output", - "other" - ], - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "upgrade_details": { - "additionalProperties": false, - "properties": { - "action_id": { - "type": "string" - }, - "metadata": { - "additionalProperties": false, - "properties": { - "download_percent": { - "type": "number" - }, - "download_rate": { - "type": "number" - }, - "error_msg": { - "type": "string" - }, - "failed_state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "retry_error_msg": { - "type": "string" - }, - "retry_until": { - "type": "string" - }, - "scheduled_at": { - "type": "string" - } - }, - "type": "object" - }, - "state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "target_version", - "action_id", - "state" - ], - "type": "object" - }, - "upgrade_started_at": { - "nullable": true, - "type": "string" - }, - "upgraded_at": { - "nullable": true, - "type": "string" - }, - "user_provided_metadata": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "id", - "packages", - "type", - "active", - "enrolled_at", - "local_metadata" - ], - "type": "object" - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "statusSummary": { - "additionalProperties": { - "type": "number" - }, - "type": "object" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - }, - "post": { - "description": "List agents by action ids", - "operationId": "post-fleet-agents", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actionIds": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "actionIds" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents/action_status": { - "get": { - "description": "Get agent action status", - "operationId": "get-fleet-agents-action-status", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "page", - "required": false, - "schema": { - "default": 0, - "type": "number" - } - }, - { - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "default": 20, - "type": "number" - } - }, - { - "in": "query", - "name": "date", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "latest", - "required": false, - "schema": { - "type": "number" - } - }, - { - "in": "query", - "name": "errorSize", - "required": false, - "schema": { - "default": 5, - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - }, - "cancellationTime": { - "type": "string" - }, - "completionTime": { - "type": "string" - }, - "creationTime": { - "description": "creation time of action", - "type": "string" - }, - "expiration": { - "type": "string" - }, - "hasRolloutPeriod": { - "type": "boolean" - }, - "latestErrors": { - "items": { - "additionalProperties": false, - "description": "latest errors that happened when the agents executed the action", - "properties": { - "agentId": { - "type": "string" - }, - "error": { - "type": "string" - }, - "hostname": { - "type": "string" - }, - "timestamp": { - "type": "string" - } - }, - "required": [ - "agentId", - "error", - "timestamp" - ], - "type": "object" - }, - "type": "array" - }, - "nbAgentsAck": { - "description": "number of agents that acknowledged the action", - "type": "number" - }, - "nbAgentsActionCreated": { - "description": "number of agents included in action from kibana", - "type": "number" - }, - "nbAgentsActioned": { - "description": "number of agents actioned", - "type": "number" - }, - "nbAgentsFailed": { - "description": "number of agents that failed to execute the action", - "type": "number" - }, - "newPolicyId": { - "description": "new policy id (POLICY_REASSIGN action)", - "type": "string" - }, - "policyId": { - "description": "policy id (POLICY_CHANGE action)", - "type": "string" - }, - "revision": { - "description": "new policy revision (POLICY_CHANGE action)", - "type": "number" - }, - "startTime": { - "description": "start time of action (scheduled actions)", - "type": "string" - }, - "status": { - "enum": [ - "COMPLETE", - "EXPIRED", - "CANCELLED", - "FAILED", - "IN_PROGRESS", - "ROLLOUT_PASSED" - ], - "type": "string" - }, - "type": { - "enum": [ - "UPGRADE", - "UNENROLL", - "SETTINGS", - "POLICY_REASSIGN", - "CANCEL", - "FORCE_UNENROLL", - "REQUEST_DIAGNOSTICS", - "UPDATE_TAGS", - "POLICY_CHANGE", - "INPUT_ACTION" - ], - "type": "string" - }, - "version": { - "description": "agent version number (UPGRADE action)", - "type": "string" - } - }, - "required": [ - "actionId", - "nbAgentsActionCreated", - "nbAgentsAck", - "nbAgentsFailed", - "type", - "nbAgentsActioned", - "status", - "creationTime" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/actions/{actionId}/cancel": { - "post": { - "description": "Cancel agent action", - "operationId": "post-fleet-agents-actions-actionid-cancel", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "actionId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "ack_data": {}, - "agents": { - "items": { - "type": "string" - }, - "type": "array" - }, - "created_at": { - "type": "string" - }, - "data": {}, - "expiration": { - "type": "string" - }, - "id": { - "type": "string" - }, - "minimum_execution_duration": { - "type": "number" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "rollout_duration_seconds": { - "type": "number" - }, - "sent_at": { - "type": "string" - }, - "source_uri": { - "type": "string" - }, - "start_time": { - "type": "string" - }, - "total": { - "type": "number" - }, - "type": { - "type": "string" - } - }, - "required": [ - "id", - "type", - "data", - "created_at", - "ack_data", - "agents" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/available_versions": { - "get": { - "description": "Get available agent versions", - "operationId": "get-fleet-agents-available-versions", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents/bulk_reassign": { - "post": { - "description": "Bulk reassign agents", - "operationId": "post-fleet-agents-bulk-reassign", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "agents": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - }, - "batchSize": { - "type": "number" - }, - "includeInactive": { - "default": false, - "type": "boolean" - }, - "policy_id": { - "type": "string" - } - }, - "required": [ - "policy_id", - "agents" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - } - }, - "required": [ - "actionId" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/bulk_request_diagnostics": { - "post": { - "description": "Bulk request diagnostics from agents", - "operationId": "post-fleet-agents-bulk-request-diagnostics", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "additional_metrics": { - "items": { - "enum": [ - "CPU" - ], - "type": "string" - }, - "type": "array" - }, - "agents": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - }, - "batchSize": { - "type": "number" - } - }, - "required": [ - "agents" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - } - }, - "required": [ - "actionId" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/bulk_unenroll": { - "post": { - "description": "Bulk unenroll agents", - "operationId": "post-fleet-agents-bulk-unenroll", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "agents": { - "anyOf": [ - { - "items": { - "description": "KQL query string, leave empty to action all agents", - "type": "string" - }, - "type": "array" - }, - { - "description": "list of agent IDs", - "type": "string" - } - ] - }, - "batchSize": { - "type": "number" - }, - "force": { - "description": "Unenrolls hosted agents too", - "type": "boolean" - }, - "includeInactive": { - "description": "When passing agents by KQL query, unenrolls inactive agents too", - "type": "boolean" - }, - "revoke": { - "description": "Revokes API keys of agents", - "type": "boolean" - } - }, - "required": [ - "agents" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - } - }, - "required": [ - "actionId" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/bulk_update_agent_tags": { - "post": { - "description": "Bulk update agent tags", - "operationId": "post-fleet-agents-bulk-update-agent-tags", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "agents": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - }, - "batchSize": { - "type": "number" - }, - "includeInactive": { - "default": false, - "type": "boolean" - }, - "tagsToAdd": { - "items": { - "type": "string" - }, - "type": "array" - }, - "tagsToRemove": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "agents" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - } - }, - "required": [ - "actionId" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/bulk_upgrade": { - "post": { - "description": "Bulk upgrade agents", - "operationId": "post-fleet-agents-bulk-upgrade", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "agents": { - "anyOf": [ - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "type": "string" - } - ] - }, - "batchSize": { - "type": "number" - }, - "force": { - "type": "boolean" - }, - "includeInactive": { - "default": false, - "type": "boolean" - }, - "rollout_duration_seconds": { - "minimum": 600, - "type": "number" - }, - "skipRateLimitCheck": { - "type": "boolean" - }, - "source_uri": { - "type": "string" - }, - "start_time": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "agents", - "version" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - } - }, - "required": [ - "actionId" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/files/{fileId}": { - "delete": { - "description": "Delete file uploaded by agent", - "operationId": "delete-fleet-agents-files-fileid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "fileId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "deleted": { - "type": "boolean" - }, - "id": { - "type": "string" - } - }, - "required": [ - "id", - "deleted" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents/files/{fileId}/{fileName}": { - "get": { - "description": "Get file uploaded by agent", - "operationId": "get-fleet-agents-files-fileid-filename", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "fileId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "fileName", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents/setup": { - "get": { - "description": "Get agent setup info", - "operationId": "get-fleet-agents-setup", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "A summary of the agent setup status. `isReady` indicates whether the setup is ready. If the setup is not ready, `missing_requirements` lists which requirements are missing.", - "properties": { - "isReady": { - "type": "boolean" - }, - "is_secrets_storage_enabled": { - "type": "boolean" - }, - "is_space_awareness_enabled": { - "type": "boolean" - }, - "missing_optional_features": { - "items": { - "enum": [ - "encrypted_saved_object_encryption_key_required" - ], - "type": "string" - }, - "type": "array" - }, - "missing_requirements": { - "items": { - "enum": [ - "security_required", - "tls_required", - "api_keys", - "fleet_admin_user", - "fleet_server" - ], - "type": "string" - }, - "type": "array" - }, - "package_verification_key_id": { - "type": "string" - } - }, - "required": [ - "isReady", - "missing_requirements", - "missing_optional_features" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - }, - "post": { - "description": "Initiate agent setup", - "operationId": "post-fleet-agents-setup", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "A summary of the result of Fleet's `setup` lifecycle. If `isInitialized` is true, Fleet is ready to accept agent enrollment. `nonFatalErrors` may include useful insight into non-blocking issues with Fleet setup.", - "properties": { - "isInitialized": { - "type": "boolean" - }, - "nonFatalErrors": { - "items": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "isInitialized", - "nonFatalErrors" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents/tags": { - "get": { - "description": "List agent tags", - "operationId": "get-fleet-agents-tags", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "showInactive", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents/{agentId}": { - "delete": { - "description": "Delete agent by ID", - "operationId": "delete-fleet-agents-agentid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "action": { - "enum": [ - "deleted" - ], - "type": "string" - } - }, - "required": [ - "action" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - }, - "get": { - "description": "Get agent by ID", - "operationId": "get-fleet-agents-agentid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "withMetrics", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "access_api_key": { - "type": "string" - }, - "access_api_key_id": { - "type": "string" - }, - "active": { - "type": "boolean" - }, - "agent": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "version" - ], - "type": "object" - }, - "components": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "type": "string" - }, - "units": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "payload": { - "additionalProperties": {}, - "type": "object" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "enum": [ - "input", - "output" - ], - "type": "string" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key": { - "type": "string" - }, - "default_api_key_history": { - "items": { - "additionalProperties": false, - "deprecated": true, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key_id": { - "type": "string" - }, - "enrolled_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "last_checkin": { - "type": "string" - }, - "last_checkin_message": { - "type": "string" - }, - "last_checkin_status": { - "enum": [ - "error", - "online", - "degraded", - "updating", - "starting" - ], - "type": "string" - }, - "local_metadata": { - "additionalProperties": {}, - "type": "object" - }, - "metrics": { - "additionalProperties": false, - "properties": { - "cpu_avg": { - "type": "number" - }, - "memory_size_byte_avg": { - "type": "number" - } - }, - "type": "object" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "outputs": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "api_key_id": { - "type": "string" - }, - "to_retire_api_key_ids": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - } - }, - "required": [ - "api_key_id", - "type" - ], - "type": "object" - }, - "type": "object" - }, - "packages": { - "items": { - "type": "string" - }, - "type": "array" - }, - "policy_id": { - "type": "string" - }, - "policy_revision": { - "nullable": true, - "type": "number" - }, - "sort": { - "items": { - "anyOf": [ - { - "type": "number" - }, - { - "type": "string" - }, - { - "enum": [], - "nullable": true - } - ] - }, - "type": "array" - }, - "status": { - "enum": [ - "offline", - "error", - "online", - "inactive", - "enrolling", - "unenrolling", - "unenrolled", - "updating", - "degraded" - ], - "type": "string" - }, - "tags": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "enum": [ - "PERMANENT", - "EPHEMERAL", - "TEMPORARY" - ], - "type": "string" - }, - "unenrolled_at": { - "type": "string" - }, - "unenrollment_started_at": { - "type": "string" - }, - "unhealthy_reason": { - "items": { - "enum": [ - "input", - "output", - "other" - ], - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "upgrade_details": { - "additionalProperties": false, - "properties": { - "action_id": { - "type": "string" - }, - "metadata": { - "additionalProperties": false, - "properties": { - "download_percent": { - "type": "number" - }, - "download_rate": { - "type": "number" - }, - "error_msg": { - "type": "string" - }, - "failed_state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "retry_error_msg": { - "type": "string" - }, - "retry_until": { - "type": "string" - }, - "scheduled_at": { - "type": "string" - } - }, - "type": "object" - }, - "state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "target_version", - "action_id", - "state" - ], - "type": "object" - }, - "upgrade_started_at": { - "nullable": true, - "type": "string" - }, - "upgraded_at": { - "nullable": true, - "type": "string" - }, - "user_provided_metadata": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "id", - "packages", - "type", - "active", - "enrolled_at", - "local_metadata" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - }, - "put": { - "description": "Update agent by ID", - "operationId": "put-fleet-agents-agentid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "tags": { - "items": { - "type": "string" - }, - "type": "array" - }, - "user_provided_metadata": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "access_api_key": { - "type": "string" - }, - "access_api_key_id": { - "type": "string" - }, - "active": { - "type": "boolean" - }, - "agent": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "version" - ], - "type": "object" - }, - "components": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "type": "string" - }, - "units": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "message": { - "type": "string" - }, - "payload": { - "additionalProperties": {}, - "type": "object" - }, - "status": { - "enum": [ - "STARTING", - "CONFIGURING", - "HEALTHY", - "DEGRADED", - "FAILED", - "STOPPING", - "STOPPED" - ], - "type": "string" - }, - "type": { - "enum": [ - "input", - "output" - ], - "type": "string" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "id", - "type", - "status", - "message" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key": { - "type": "string" - }, - "default_api_key_history": { - "items": { - "additionalProperties": false, - "deprecated": true, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "default_api_key_id": { - "type": "string" - }, - "enrolled_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "last_checkin": { - "type": "string" - }, - "last_checkin_message": { - "type": "string" - }, - "last_checkin_status": { - "enum": [ - "error", - "online", - "degraded", - "updating", - "starting" - ], - "type": "string" - }, - "local_metadata": { - "additionalProperties": {}, - "type": "object" - }, - "metrics": { - "additionalProperties": false, - "properties": { - "cpu_avg": { - "type": "number" - }, - "memory_size_byte_avg": { - "type": "number" - } - }, - "type": "object" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "outputs": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "api_key_id": { - "type": "string" - }, - "to_retire_api_key_ids": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "retired_at": { - "type": "string" - } - }, - "required": [ - "id", - "retired_at" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - } - }, - "required": [ - "api_key_id", - "type" - ], - "type": "object" - }, - "type": "object" - }, - "packages": { - "items": { - "type": "string" - }, - "type": "array" - }, - "policy_id": { - "type": "string" - }, - "policy_revision": { - "nullable": true, - "type": "number" - }, - "sort": { - "items": { - "anyOf": [ - { - "type": "number" - }, - { - "type": "string" - }, - { - "enum": [], - "nullable": true - } - ] - }, - "type": "array" - }, - "status": { - "enum": [ - "offline", - "error", - "online", - "inactive", - "enrolling", - "unenrolling", - "unenrolled", - "updating", - "degraded" - ], - "type": "string" - }, - "tags": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "enum": [ - "PERMANENT", - "EPHEMERAL", - "TEMPORARY" - ], - "type": "string" - }, - "unenrolled_at": { - "type": "string" - }, - "unenrollment_started_at": { - "type": "string" - }, - "unhealthy_reason": { - "items": { - "enum": [ - "input", - "output", - "other" - ], - "type": "string" - }, - "nullable": true, - "type": "array" - }, - "upgrade_details": { - "additionalProperties": false, - "properties": { - "action_id": { - "type": "string" - }, - "metadata": { - "additionalProperties": false, - "properties": { - "download_percent": { - "type": "number" - }, - "download_rate": { - "type": "number" - }, - "error_msg": { - "type": "string" - }, - "failed_state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "retry_error_msg": { - "type": "string" - }, - "retry_until": { - "type": "string" - }, - "scheduled_at": { - "type": "string" - } - }, - "type": "object" - }, - "state": { - "enum": [ - "UPG_REQUESTED", - "UPG_SCHEDULED", - "UPG_DOWNLOADING", - "UPG_EXTRACTING", - "UPG_REPLACING", - "UPG_RESTARTING", - "UPG_FAILED", - "UPG_WATCHING", - "UPG_ROLLBACK" - ], - "type": "string" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "target_version", - "action_id", - "state" - ], - "type": "object" - }, - "upgrade_started_at": { - "nullable": true, - "type": "string" - }, - "upgraded_at": { - "nullable": true, - "type": "string" - }, - "user_provided_metadata": { - "additionalProperties": {}, - "type": "object" - } - }, - "required": [ - "id", - "packages", - "type", - "active", - "enrolled_at", - "local_metadata" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/agents/{agentId}/actions": { - "post": { - "description": "Create agent action", - "operationId": "post-fleet-agents-agentid-actions", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "action": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "ack_data": {}, - "data": {}, - "type": { - "enum": [ - "UNENROLL", - "UPGRADE", - "POLICY_REASSIGN" - ], - "type": "string" - } - }, - "required": [ - "type", - "data", - "ack_data" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "data": { - "additionalProperties": false, - "properties": { - "log_level": { - "enum": [ - "debug", - "info", - "warning", - "error" - ], - "nullable": true, - "type": "string" - } - }, - "required": [ - "log_level" - ], - "type": "object" - }, - "type": { - "enum": [ - "SETTINGS" - ], - "type": "string" - } - }, - "required": [ - "type", - "data" - ], - "type": "object" - } - ] - } - }, - "required": [ - "action" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "ack_data": {}, - "agents": { - "items": { - "type": "string" - }, - "type": "array" - }, - "created_at": { - "type": "string" - }, - "data": {}, - "expiration": { - "type": "string" - }, - "id": { - "type": "string" - }, - "minimum_execution_duration": { - "type": "number" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "rollout_duration_seconds": { - "type": "number" - }, - "sent_at": { - "type": "string" - }, - "source_uri": { - "type": "string" - }, - "start_time": { - "type": "string" - }, - "total": { - "type": "number" - }, - "type": { - "type": "string" - } - }, - "required": [ - "id", - "type", - "data", - "created_at", - "ack_data", - "agents" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/{agentId}/reassign": { - "post": { - "description": "Reassign agent", - "operationId": "post-fleet-agents-agentid-reassign", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "policy_id": { - "type": "string" - } - }, - "required": [ - "policy_id" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": {}, - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - }, - "put": { - "operationId": "put-fleet-agents-agentid-reassign", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "policy_id": { - "type": "string" - } - }, - "required": [ - "policy_id" - ], - "type": "object" - } - } - } - }, - "responses": {}, - "summary": "", - "tags": [] - } - }, - "/api/fleet/agents/{agentId}/request_diagnostics": { - "post": { - "description": "Request agent diagnostics", - "operationId": "post-fleet-agents-agentid-request-diagnostics", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "additional_metrics": { - "items": { - "enum": [ - "CPU" - ], - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - } - }, - "required": [ - "actionId" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/{agentId}/unenroll": { - "post": { - "description": "Unenroll agent", - "operationId": "post-fleet-agents-agentid-unenroll", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "force": { - "type": "boolean" - }, - "revoke": { - "type": "boolean" - } - }, - "type": "object" - } - } - } - }, - "responses": {}, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/{agentId}/upgrade": { - "post": { - "description": "Upgrade agent", - "operationId": "post-fleet-agents-agentid-upgrade", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "force": { - "type": "boolean" - }, - "skipRateLimitCheck": { - "type": "boolean" - }, - "source_uri": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "version" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": {}, - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent actions" - ] - } - }, - "/api/fleet/agents/{agentId}/uploads": { - "get": { - "description": "List agent uploads", - "operationId": "get-fleet-agents-agentid-uploads", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "agentId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "actionId": { - "type": "string" - }, - "createTime": { - "type": "string" - }, - "error": { - "type": "string" - }, - "filePath": { - "type": "string" - }, - "id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "status": { - "enum": [ - "READY", - "AWAITING_UPLOAD", - "DELETED", - "EXPIRED", - "IN_PROGRESS", - "FAILED" - ], - "type": "string" - } - }, - "required": [ - "id", - "name", - "filePath", - "createTime", - "status", - "actionId" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agents" - ] - } - }, - "/api/fleet/check-permissions": { - "get": { - "description": "Check permissions", - "operationId": "get-fleet-check-permissions", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "fleetServerSetup", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "error": { - "enum": [ - "MISSING_SECURITY", - "MISSING_PRIVILEGES", - "MISSING_FLEET_SERVER_SETUP_PRIVILEGES" - ], - "type": "string" - }, - "success": { - "type": "boolean" - } - }, - "required": [ - "success" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet internals" - ] - } - }, - "/api/fleet/data_streams": { - "get": { - "description": "List data streams", - "operationId": "get-fleet-data-streams", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "data_streams": { - "items": { - "additionalProperties": false, - "properties": { - "dashboards": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "title": { - "type": "string" - } - }, - "required": [ - "id", - "title" - ], - "type": "object" - }, - "type": "array" - }, - "dataset": { - "type": "string" - }, - "index": { - "type": "string" - }, - "last_activity_ms": { - "type": "number" - }, - "namespace": { - "type": "string" - }, - "package": { - "type": "string" - }, - "package_version": { - "type": "string" - }, - "serviceDetails": { - "additionalProperties": false, - "nullable": true, - "properties": { - "environment": { - "type": "string" - }, - "serviceName": { - "type": "string" - } - }, - "required": [ - "environment", - "serviceName" - ], - "type": "object" - }, - "size_in_bytes": { - "type": "number" - }, - "size_in_bytes_formatted": { - "anyOf": [ - { - "type": "number" - }, - { - "type": "string" - } - ] - }, - "type": { - "type": "string" - } - }, - "required": [ - "index", - "dataset", - "namespace", - "type", - "package", - "package_version", - "last_activity_ms", - "size_in_bytes", - "size_in_bytes_formatted", - "dashboards", - "serviceDetails" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "data_streams" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Data streams" - ] - } - }, - "/api/fleet/enrollment-api-keys": { - "get": { - "operationId": "get-fleet-enrollment-api-keys-2", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "page", - "required": false, - "schema": { - "default": 1, - "type": "number" - } - }, - { - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "default": 20, - "type": "number" - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "type": "string" - } - } - ], - "responses": {}, - "summary": "", - "tags": [] - }, - "post": { - "operationId": "post-fleet-enrollment-api-keys-2", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "expiration": { - "type": "string" - }, - "name": { - "type": "string" - }, - "policy_id": { - "type": "string" - } - }, - "required": [ - "policy_id" - ], - "type": "object" - } - } - } - }, - "responses": {}, - "summary": "", - "tags": [] - } - }, - "/api/fleet/enrollment-api-keys/{keyId}": { - "delete": { - "operationId": "delete-fleet-enrollment-api-keys-keyid-2", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "keyId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": {}, - "summary": "", - "tags": [] - }, - "get": { - "operationId": "get-fleet-enrollment-api-keys-keyid-2", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "keyId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": {}, - "summary": "", - "tags": [] - } - }, - "/api/fleet/enrollment_api_keys": { - "get": { - "description": "List enrollment API keys", - "operationId": "get-fleet-enrollment-api-keys", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "page", - "required": false, - "schema": { - "default": 1, - "type": "number" - } - }, - { - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "default": 20, - "type": "number" - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "active": { - "description": "When false, the enrollment API key is revoked and cannot be used for enrolling Elastic Agents.", - "type": "boolean" - }, - "api_key": { - "description": "The enrollment API key (token) used for enrolling Elastic Agents.", - "type": "string" - }, - "api_key_id": { - "description": "The ID of the API key in the Security API.", - "type": "string" - }, - "created_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "name": { - "description": "The name of the enrollment API key.", - "type": "string" - }, - "policy_id": { - "description": "The ID of the agent policy the Elastic Agent will be enrolled in.", - "type": "string" - } - }, - "required": [ - "id", - "api_key_id", - "api_key", - "active", - "created_at" - ], - "type": "object" - }, - "type": "array" - }, - "list": { - "deprecated": true, - "items": { - "additionalProperties": false, - "properties": { - "active": { - "description": "When false, the enrollment API key is revoked and cannot be used for enrolling Elastic Agents.", - "type": "boolean" - }, - "api_key": { - "description": "The enrollment API key (token) used for enrolling Elastic Agents.", - "type": "string" - }, - "api_key_id": { - "description": "The ID of the API key in the Security API.", - "type": "string" - }, - "created_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "name": { - "description": "The name of the enrollment API key.", - "type": "string" - }, - "policy_id": { - "description": "The ID of the agent policy the Elastic Agent will be enrolled in.", - "type": "string" - } - }, - "required": [ - "id", - "api_key_id", - "api_key", - "active", - "created_at" - ], - "type": "object" - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage", - "list" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet enrollment API keys" - ] - }, - "post": { - "description": "Create enrollment API key", - "operationId": "post-fleet-enrollment-api-keys", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "expiration": { - "type": "string" - }, - "name": { - "type": "string" - }, - "policy_id": { - "type": "string" - } - }, - "required": [ - "policy_id" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "action": { - "enum": [ - "created" - ], - "type": "string" - }, - "item": { - "additionalProperties": false, - "properties": { - "active": { - "description": "When false, the enrollment API key is revoked and cannot be used for enrolling Elastic Agents.", - "type": "boolean" - }, - "api_key": { - "description": "The enrollment API key (token) used for enrolling Elastic Agents.", - "type": "string" - }, - "api_key_id": { - "description": "The ID of the API key in the Security API.", - "type": "string" - }, - "created_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "name": { - "description": "The name of the enrollment API key.", - "type": "string" - }, - "policy_id": { - "description": "The ID of the agent policy the Elastic Agent will be enrolled in.", - "type": "string" - } - }, - "required": [ - "id", - "api_key_id", - "api_key", - "active", - "created_at" - ], - "type": "object" - } - }, - "required": [ - "item", - "action" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet enrollment API keys" - ] - } - }, - "/api/fleet/enrollment_api_keys/{keyId}": { - "delete": { - "description": "Revoke enrollment API key by ID by marking it as inactive", - "operationId": "delete-fleet-enrollment-api-keys-keyid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "keyId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "action": { - "enum": [ - "deleted" - ], - "type": "string" - } - }, - "required": [ - "action" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet enrollment API keys" - ] - }, - "get": { - "description": "Get enrollment API key by ID", - "operationId": "get-fleet-enrollment-api-keys-keyid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "keyId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "active": { - "description": "When false, the enrollment API key is revoked and cannot be used for enrolling Elastic Agents.", - "type": "boolean" - }, - "api_key": { - "description": "The enrollment API key (token) used for enrolling Elastic Agents.", - "type": "string" - }, - "api_key_id": { - "description": "The ID of the API key in the Security API.", - "type": "string" - }, - "created_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "name": { - "description": "The name of the enrollment API key.", - "type": "string" - }, - "policy_id": { - "description": "The ID of the agent policy the Elastic Agent will be enrolled in.", - "type": "string" - } - }, - "required": [ - "id", - "api_key_id", - "api_key", - "active", - "created_at" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet enrollment API keys" - ] - } - }, - "/api/fleet/epm/bulk_assets": { - "post": { - "description": "Bulk get assets", - "operationId": "post-fleet-epm-bulk-assets", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "assetIds": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "assetIds" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "appLink": { - "type": "string" - }, - "attributes": { - "additionalProperties": false, - "properties": { - "description": { - "type": "string" - }, - "service": { - "type": "string" - }, - "title": { - "type": "string" - } - }, - "type": "object" - }, - "id": { - "type": "string" - }, - "type": { - "type": "string" - }, - "updatedAt": { - "type": "string" - } - }, - "required": [ - "id", - "type", - "attributes" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/categories": { - "get": { - "description": "List package categories", - "operationId": "get-fleet-epm-categories", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "experimental", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "include_policy_templates", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "count": { - "type": "number" - }, - "id": { - "type": "string" - }, - "parent_id": { - "type": "string" - }, - "parent_title": { - "type": "string" - }, - "title": { - "type": "string" - } - }, - "required": [ - "id", - "title", - "count" - ], - "type": "object" - }, - "type": "array" - }, - "response": { - "items": { - "additionalProperties": false, - "deprecated": true, - "properties": { - "count": { - "type": "number" - }, - "id": { - "type": "string" - }, - "parent_id": { - "type": "string" - }, - "parent_title": { - "type": "string" - }, - "title": { - "type": "string" - } - }, - "required": [ - "id", - "title", - "count" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/custom_integrations": { - "post": { - "description": "Create custom integration", - "operationId": "post-fleet-epm-custom-integrations", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "datasets": { - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "type": { - "enum": [ - "logs", - "metrics", - "traces", - "synthetics", - "profiling" - ], - "type": "string" - } - }, - "required": [ - "name", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "force": { - "type": "boolean" - }, - "integrationName": { - "type": "string" - } - }, - "required": [ - "integrationName", - "datasets" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "_meta": { - "additionalProperties": false, - "properties": { - "install_source": { - "type": "string" - } - }, - "required": [ - "install_source" - ], - "type": "object" - }, - "items": { - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "response": { - "deprecated": true, - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - } - }, - "required": [ - "items", - "_meta" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/data_streams": { - "get": { - "description": "List data streams", - "operationId": "get-fleet-epm-data-streams", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "type", - "required": false, - "schema": { - "enum": [ - "logs", - "metrics", - "traces", - "synthetics", - "profiling" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "datasetQuery", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "sortOrder", - "required": false, - "schema": { - "default": "asc", - "enum": [ - "asc", - "desc" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "uncategorisedOnly", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Data streams" - ] - } - }, - "/api/fleet/epm/packages": { - "get": { - "description": "List packages", - "operationId": "get-fleet-epm-packages", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "category", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "experimental", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "excludeInstallStatus", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": true, - "properties": { - "categories": { - "items": { - "type": "string" - }, - "type": "array" - }, - "conditions": { - "additionalProperties": true, - "properties": { - "elastic": { - "additionalProperties": true, - "properties": { - "capabilities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "subscription": { - "type": "string" - } - }, - "type": "object" - }, - "kibana": { - "additionalProperties": true, - "properties": { - "version": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "data_streams": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "description": { - "type": "string" - }, - "discovery": { - "additionalProperties": true, - "properties": { - "fields": { - "items": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "download": { - "type": "string" - }, - "format_version": { - "type": "string" - }, - "icons": { - "items": { - "additionalProperties": true, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "id": { - "type": "string" - }, - "installationInfo": { - "additionalProperties": true, - "properties": { - "additional_spaces_installed_kibana": { - "additionalProperties": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "type": "object" - }, - "created_at": { - "type": "string" - }, - "experimental_data_stream_features": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": true, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "install_format_schema_version": { - "type": "string" - }, - "install_source": { - "enum": [ - "registry", - "upload", - "bundled", - "custom" - ], - "type": "string" - }, - "install_status": { - "enum": [ - "installed", - "installing", - "install_failed" - ], - "type": "string" - }, - "installed_es": { - "items": { - "additionalProperties": true, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana_space_id": { - "type": "string" - }, - "latest_executed_state": { - "additionalProperties": true, - "properties": { - "error": { - "type": "string" - }, - "name": { - "type": "string" - }, - "started_at": { - "type": "string" - } - }, - "required": [ - "name", - "started_at" - ], - "type": "object" - }, - "latest_install_failed_attempts": { - "items": { - "additionalProperties": true, - "properties": { - "created_at": { - "type": "string" - }, - "error": { - "additionalProperties": true, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - }, - "stack": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "created_at", - "target_version", - "error" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "type": "string" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "updated_at": { - "type": "string" - }, - "verification_key_id": { - "nullable": true, - "type": "string" - }, - "verification_status": { - "enum": [ - "unverified", - "verified", - "unknown" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "type", - "installed_kibana", - "installed_es", - "name", - "version", - "install_status", - "install_source", - "verification_status" - ], - "type": "object" - }, - "integration": { - "type": "string" - }, - "internal": { - "type": "boolean" - }, - "latestVersion": { - "type": "string" - }, - "name": { - "type": "string" - }, - "owner": { - "additionalProperties": true, - "properties": { - "github": { - "type": "string" - }, - "type": { - "enum": [ - "elastic", - "partner", - "community" - ], - "type": "string" - } - }, - "type": "object" - }, - "path": { - "type": "string" - }, - "policy_templates": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "readme": { - "type": "string" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "savedObject": {}, - "signature_path": { - "type": "string" - }, - "source": { - "additionalProperties": true, - "properties": { - "license": { - "type": "string" - } - }, - "required": [ - "license" - ], - "type": "object" - }, - "status": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "enum": [ - "integration", - "input", - "content" - ], - "type": "string" - }, - "vars": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "version": { - "type": "string" - } - }, - "required": [ - "savedObject", - "name", - "version", - "title", - "id" - ], - "type": "object" - }, - "type": "array" - }, - "response": { - "items": { - "additionalProperties": true, - "deprecated": true, - "properties": { - "categories": { - "items": { - "type": "string" - }, - "type": "array" - }, - "conditions": { - "additionalProperties": true, - "properties": { - "elastic": { - "additionalProperties": true, - "properties": { - "capabilities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "subscription": { - "type": "string" - } - }, - "type": "object" - }, - "kibana": { - "additionalProperties": true, - "properties": { - "version": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "data_streams": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "description": { - "type": "string" - }, - "discovery": { - "additionalProperties": true, - "properties": { - "fields": { - "items": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "download": { - "type": "string" - }, - "format_version": { - "type": "string" - }, - "icons": { - "items": { - "additionalProperties": true, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "id": { - "type": "string" - }, - "installationInfo": { - "additionalProperties": true, - "properties": { - "additional_spaces_installed_kibana": { - "additionalProperties": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "type": "object" - }, - "created_at": { - "type": "string" - }, - "experimental_data_stream_features": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": true, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "install_format_schema_version": { - "type": "string" - }, - "install_source": { - "enum": [ - "registry", - "upload", - "bundled", - "custom" - ], - "type": "string" - }, - "install_status": { - "enum": [ - "installed", - "installing", - "install_failed" - ], - "type": "string" - }, - "installed_es": { - "items": { - "additionalProperties": true, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana_space_id": { - "type": "string" - }, - "latest_executed_state": { - "additionalProperties": true, - "properties": { - "error": { - "type": "string" - }, - "name": { - "type": "string" - }, - "started_at": { - "type": "string" - } - }, - "required": [ - "name", - "started_at" - ], - "type": "object" - }, - "latest_install_failed_attempts": { - "items": { - "additionalProperties": true, - "properties": { - "created_at": { - "type": "string" - }, - "error": { - "additionalProperties": true, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - }, - "stack": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "created_at", - "target_version", - "error" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "type": "string" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "updated_at": { - "type": "string" - }, - "verification_key_id": { - "nullable": true, - "type": "string" - }, - "verification_status": { - "enum": [ - "unverified", - "verified", - "unknown" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "type", - "installed_kibana", - "installed_es", - "name", - "version", - "install_status", - "install_source", - "verification_status" - ], - "type": "object" - }, - "integration": { - "type": "string" - }, - "internal": { - "type": "boolean" - }, - "latestVersion": { - "type": "string" - }, - "name": { - "type": "string" - }, - "owner": { - "additionalProperties": true, - "properties": { - "github": { - "type": "string" - }, - "type": { - "enum": [ - "elastic", - "partner", - "community" - ], - "type": "string" - } - }, - "type": "object" - }, - "path": { - "type": "string" - }, - "policy_templates": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "readme": { - "type": "string" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "savedObject": {}, - "signature_path": { - "type": "string" - }, - "source": { - "additionalProperties": true, - "properties": { - "license": { - "type": "string" - } - }, - "required": [ - "license" - ], - "type": "object" - }, - "status": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "enum": [ - "integration", - "input", - "content" - ], - "type": "string" - }, - "vars": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "version": { - "type": "string" - } - }, - "required": [ - "savedObject", - "name", - "version", - "title", - "id" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - }, - "post": { - "description": "Install package by upload", - "operationId": "post-fleet-epm-packages", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "query", - "name": "ignoreMappingUpdateErrors", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - }, - { - "in": "query", - "name": "skipDataStreamRollover", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "requestBody": { - "content": { - "application/gzip; application/zip; Elastic-Api-Version=2023-10-31": { - "schema": { - "format": "binary", - "type": "string" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/gzip; application/zip; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "_meta": { - "additionalProperties": false, - "properties": { - "install_source": { - "type": "string" - } - }, - "required": [ - "install_source" - ], - "type": "object" - }, - "items": { - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "response": { - "deprecated": true, - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - } - }, - "required": [ - "items", - "_meta" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/gzip; application/zip; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/_bulk": { - "post": { - "description": "Bulk install packages", - "operationId": "post-fleet-epm-packages-bulk", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "force": { - "default": false, - "type": "boolean" - }, - "packages": { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "prerelease": { - "type": "boolean" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - } - ] - }, - "minItems": 1, - "type": "array" - } - }, - "required": [ - "packages" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "result": { - "additionalProperties": false, - "properties": { - "assets": { - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "error": {}, - "installSource": { - "type": "string" - }, - "installType": { - "type": "string" - }, - "status": { - "enum": [ - "installed", - "already_installed" - ], - "type": "string" - } - }, - "required": [ - "error", - "installType" - ], - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "version", - "result" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "error": { - "anyOf": [ - { - "type": "string" - }, - {} - ] - }, - "name": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "name", - "statusCode", - "error" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "response": { - "deprecated": true, - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "result": { - "additionalProperties": false, - "properties": { - "assets": { - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "error": {}, - "installSource": { - "type": "string" - }, - "installType": { - "type": "string" - }, - "status": { - "enum": [ - "installed", - "already_installed" - ], - "type": "string" - } - }, - "required": [ - "error", - "installType" - ], - "type": "object" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "version", - "result" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "error": { - "anyOf": [ - { - "type": "string" - }, - {} - ] - }, - "name": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "name", - "statusCode", - "error" - ], - "type": "object" - } - ] - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/installed": { - "get": { - "description": "Get installed packages", - "operationId": "get-fleet-epm-packages-installed", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "dataStreamType", - "required": false, - "schema": { - "enum": [ - "logs", - "metrics", - "traces", - "synthetics", - "profiling" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "showOnlyActiveDataStreams", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "nameQuery", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "searchAfter", - "required": false, - "schema": { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - }, - "type": "array" - } - }, - { - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "default": 15, - "type": "number" - } - }, - { - "in": "query", - "name": "sortOrder", - "required": false, - "schema": { - "default": "asc", - "enum": [ - "asc", - "desc" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "dataStreams": { - "items": { - "additionalProperties": false, - "properties": { - "name": { - "type": "string" - }, - "title": { - "type": "string" - } - }, - "required": [ - "name", - "title" - ], - "type": "object" - }, - "type": "array" - }, - "description": { - "type": "string" - }, - "icons": { - "items": { - "additionalProperties": false, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "type": "string" - }, - "status": { - "type": "string" - }, - "title": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "version", - "status", - "dataStreams" - ], - "type": "object" - }, - "type": "array" - }, - "searchAfter": { - "items": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - }, - { - "type": "boolean" - }, - { - "enum": [], - "nullable": true - }, - {} - ] - }, - "type": "array" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/limited": { - "get": { - "description": "Get limited package list", - "operationId": "get-fleet-epm-packages-limited", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "type": "string" - }, - "type": "array" - }, - "response": { - "deprecated": true, - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/{pkgName}/stats": { - "get": { - "description": "Get package stats", - "operationId": "get-fleet-epm-packages-pkgname-stats", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "response": { - "additionalProperties": false, - "properties": { - "agent_policy_count": { - "type": "number" - } - }, - "required": [ - "agent_policy_count" - ], - "type": "object" - } - }, - "required": [ - "response" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/{pkgName}/{pkgVersion}": { - "delete": { - "description": "Delete package", - "operationId": "delete-fleet-epm-packages-pkgname-pkgversion", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "pkgVersion", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "force", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "force": { - "type": "boolean" - } - }, - "required": [ - "force" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "response": { - "deprecated": true, - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - }, - "get": { - "description": "Get package", - "operationId": "get-fleet-epm-packages-pkgname-pkgversion", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "pkgVersion", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "ignoreUnverified", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "full", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "withMetadata", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": true, - "properties": { - "agent": { - "additionalProperties": false, - "properties": { - "privileges": { - "additionalProperties": false, - "properties": { - "root": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "asset_tags": { - "items": { - "additionalProperties": false, - "properties": { - "asset_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "asset_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "text": { - "type": "string" - } - }, - "required": [ - "text" - ], - "type": "object" - }, - "type": "array" - }, - "assets": { - "additionalProperties": {}, - "type": "object" - }, - "categories": { - "items": { - "type": "string" - }, - "type": "array" - }, - "conditions": { - "additionalProperties": true, - "properties": { - "elastic": { - "additionalProperties": true, - "properties": { - "capabilities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "subscription": { - "type": "string" - } - }, - "type": "object" - }, - "kibana": { - "additionalProperties": true, - "properties": { - "version": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "data_streams": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "description": { - "type": "string" - }, - "discovery": { - "additionalProperties": true, - "properties": { - "fields": { - "items": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "download": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": {}, - "type": "object" - }, - "format_version": { - "type": "string" - }, - "icons": { - "items": { - "additionalProperties": true, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "installationInfo": { - "additionalProperties": true, - "properties": { - "additional_spaces_installed_kibana": { - "additionalProperties": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "type": "object" - }, - "created_at": { - "type": "string" - }, - "experimental_data_stream_features": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": true, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "install_format_schema_version": { - "type": "string" - }, - "install_source": { - "enum": [ - "registry", - "upload", - "bundled", - "custom" - ], - "type": "string" - }, - "install_status": { - "enum": [ - "installed", - "installing", - "install_failed" - ], - "type": "string" - }, - "installed_es": { - "items": { - "additionalProperties": true, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana_space_id": { - "type": "string" - }, - "latest_executed_state": { - "additionalProperties": true, - "properties": { - "error": { - "type": "string" - }, - "name": { - "type": "string" - }, - "started_at": { - "type": "string" - } - }, - "required": [ - "name", - "started_at" - ], - "type": "object" - }, - "latest_install_failed_attempts": { - "items": { - "additionalProperties": true, - "properties": { - "created_at": { - "type": "string" - }, - "error": { - "additionalProperties": true, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - }, - "stack": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "created_at", - "target_version", - "error" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "type": "string" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "updated_at": { - "type": "string" - }, - "verification_key_id": { - "nullable": true, - "type": "string" - }, - "verification_status": { - "enum": [ - "unverified", - "verified", - "unknown" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "type", - "installed_kibana", - "installed_es", - "name", - "version", - "install_status", - "install_source", - "verification_status" - ], - "type": "object" - }, - "internal": { - "type": "boolean" - }, - "keepPoliciesUpToDate": { - "type": "boolean" - }, - "latestVersion": { - "type": "string" - }, - "license": { - "type": "string" - }, - "licensePath": { - "type": "string" - }, - "name": { - "type": "string" - }, - "notice": { - "type": "string" - }, - "owner": { - "additionalProperties": true, - "properties": { - "github": { - "type": "string" - }, - "type": { - "enum": [ - "elastic", - "partner", - "community" - ], - "type": "string" - } - }, - "type": "object" - }, - "path": { - "type": "string" - }, - "policy_templates": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "readme": { - "type": "string" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "savedObject": {}, - "screenshots": { - "items": { - "additionalProperties": false, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "signature_path": { - "type": "string" - }, - "source": { - "additionalProperties": true, - "properties": { - "license": { - "type": "string" - } - }, - "required": [ - "license" - ], - "type": "object" - }, - "status": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "enum": [ - "integration", - "input", - "content" - ], - "type": "string" - }, - "vars": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "version": { - "type": "string" - } - }, - "required": [ - "savedObject", - "name", - "version", - "title", - "assets" - ], - "type": "object" - }, - "metadata": { - "additionalProperties": false, - "properties": { - "has_policies": { - "type": "boolean" - } - }, - "required": [ - "has_policies" - ], - "type": "object" - }, - "response": { - "additionalProperties": true, - "deprecated": true, - "properties": { - "agent": { - "additionalProperties": false, - "properties": { - "privileges": { - "additionalProperties": false, - "properties": { - "root": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "asset_tags": { - "items": { - "additionalProperties": false, - "properties": { - "asset_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "asset_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "text": { - "type": "string" - } - }, - "required": [ - "text" - ], - "type": "object" - }, - "type": "array" - }, - "assets": { - "additionalProperties": {}, - "type": "object" - }, - "categories": { - "items": { - "type": "string" - }, - "type": "array" - }, - "conditions": { - "additionalProperties": true, - "properties": { - "elastic": { - "additionalProperties": true, - "properties": { - "capabilities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "subscription": { - "type": "string" - } - }, - "type": "object" - }, - "kibana": { - "additionalProperties": true, - "properties": { - "version": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "data_streams": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "description": { - "type": "string" - }, - "discovery": { - "additionalProperties": true, - "properties": { - "fields": { - "items": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "download": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": {}, - "type": "object" - }, - "format_version": { - "type": "string" - }, - "icons": { - "items": { - "additionalProperties": true, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "installationInfo": { - "additionalProperties": true, - "properties": { - "additional_spaces_installed_kibana": { - "additionalProperties": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "type": "object" - }, - "created_at": { - "type": "string" - }, - "experimental_data_stream_features": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": true, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "install_format_schema_version": { - "type": "string" - }, - "install_source": { - "enum": [ - "registry", - "upload", - "bundled", - "custom" - ], - "type": "string" - }, - "install_status": { - "enum": [ - "installed", - "installing", - "install_failed" - ], - "type": "string" - }, - "installed_es": { - "items": { - "additionalProperties": true, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana_space_id": { - "type": "string" - }, - "latest_executed_state": { - "additionalProperties": true, - "properties": { - "error": { - "type": "string" - }, - "name": { - "type": "string" - }, - "started_at": { - "type": "string" - } - }, - "required": [ - "name", - "started_at" - ], - "type": "object" - }, - "latest_install_failed_attempts": { - "items": { - "additionalProperties": true, - "properties": { - "created_at": { - "type": "string" - }, - "error": { - "additionalProperties": true, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - }, - "stack": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "created_at", - "target_version", - "error" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "type": "string" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "updated_at": { - "type": "string" - }, - "verification_key_id": { - "nullable": true, - "type": "string" - }, - "verification_status": { - "enum": [ - "unverified", - "verified", - "unknown" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "type", - "installed_kibana", - "installed_es", - "name", - "version", - "install_status", - "install_source", - "verification_status" - ], - "type": "object" - }, - "internal": { - "type": "boolean" - }, - "keepPoliciesUpToDate": { - "type": "boolean" - }, - "latestVersion": { - "type": "string" - }, - "license": { - "type": "string" - }, - "licensePath": { - "type": "string" - }, - "name": { - "type": "string" - }, - "notice": { - "type": "string" - }, - "owner": { - "additionalProperties": true, - "properties": { - "github": { - "type": "string" - }, - "type": { - "enum": [ - "elastic", - "partner", - "community" - ], - "type": "string" - } - }, - "type": "object" - }, - "path": { - "type": "string" - }, - "policy_templates": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "readme": { - "type": "string" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "savedObject": {}, - "screenshots": { - "items": { - "additionalProperties": false, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "signature_path": { - "type": "string" - }, - "source": { - "additionalProperties": true, - "properties": { - "license": { - "type": "string" - } - }, - "required": [ - "license" - ], - "type": "object" - }, - "status": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "enum": [ - "integration", - "input", - "content" - ], - "type": "string" - }, - "vars": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "version": { - "type": "string" - } - }, - "required": [ - "savedObject", - "name", - "version", - "title", - "assets" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - }, - "post": { - "description": "Install package from registry", - "operationId": "post-fleet-epm-packages-pkgname-pkgversion", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "pkgVersion", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "ignoreMappingUpdateErrors", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - }, - { - "in": "query", - "name": "skipDataStreamRollover", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "force": { - "default": false, - "type": "boolean" - }, - "ignore_constraints": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "_meta": { - "additionalProperties": false, - "properties": { - "install_source": { - "type": "string" - } - }, - "required": [ - "install_source" - ], - "type": "object" - }, - "items": { - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "response": { - "deprecated": true, - "items": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - } - ] - }, - "type": "array" - } - }, - "required": [ - "items", - "_meta" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - }, - "put": { - "description": "Update package settings", - "operationId": "put-fleet-epm-packages-pkgname-pkgversion", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "pkgVersion", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "keepPoliciesUpToDate": { - "type": "boolean" - } - }, - "required": [ - "keepPoliciesUpToDate" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": true, - "properties": { - "agent": { - "additionalProperties": false, - "properties": { - "privileges": { - "additionalProperties": false, - "properties": { - "root": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "asset_tags": { - "items": { - "additionalProperties": false, - "properties": { - "asset_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "asset_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "text": { - "type": "string" - } - }, - "required": [ - "text" - ], - "type": "object" - }, - "type": "array" - }, - "assets": { - "additionalProperties": {}, - "type": "object" - }, - "categories": { - "items": { - "type": "string" - }, - "type": "array" - }, - "conditions": { - "additionalProperties": true, - "properties": { - "elastic": { - "additionalProperties": true, - "properties": { - "capabilities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "subscription": { - "type": "string" - } - }, - "type": "object" - }, - "kibana": { - "additionalProperties": true, - "properties": { - "version": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "data_streams": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "description": { - "type": "string" - }, - "discovery": { - "additionalProperties": true, - "properties": { - "fields": { - "items": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "download": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": {}, - "type": "object" - }, - "format_version": { - "type": "string" - }, - "icons": { - "items": { - "additionalProperties": true, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "installationInfo": { - "additionalProperties": true, - "properties": { - "additional_spaces_installed_kibana": { - "additionalProperties": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "type": "object" - }, - "created_at": { - "type": "string" - }, - "experimental_data_stream_features": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": true, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "install_format_schema_version": { - "type": "string" - }, - "install_source": { - "enum": [ - "registry", - "upload", - "bundled", - "custom" - ], - "type": "string" - }, - "install_status": { - "enum": [ - "installed", - "installing", - "install_failed" - ], - "type": "string" - }, - "installed_es": { - "items": { - "additionalProperties": true, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana_space_id": { - "type": "string" - }, - "latest_executed_state": { - "additionalProperties": true, - "properties": { - "error": { - "type": "string" - }, - "name": { - "type": "string" - }, - "started_at": { - "type": "string" - } - }, - "required": [ - "name", - "started_at" - ], - "type": "object" - }, - "latest_install_failed_attempts": { - "items": { - "additionalProperties": true, - "properties": { - "created_at": { - "type": "string" - }, - "error": { - "additionalProperties": true, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - }, - "stack": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "created_at", - "target_version", - "error" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "type": "string" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "updated_at": { - "type": "string" - }, - "verification_key_id": { - "nullable": true, - "type": "string" - }, - "verification_status": { - "enum": [ - "unverified", - "verified", - "unknown" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "type", - "installed_kibana", - "installed_es", - "name", - "version", - "install_status", - "install_source", - "verification_status" - ], - "type": "object" - }, - "internal": { - "type": "boolean" - }, - "keepPoliciesUpToDate": { - "type": "boolean" - }, - "latestVersion": { - "type": "string" - }, - "license": { - "type": "string" - }, - "licensePath": { - "type": "string" - }, - "name": { - "type": "string" - }, - "notice": { - "type": "string" - }, - "owner": { - "additionalProperties": true, - "properties": { - "github": { - "type": "string" - }, - "type": { - "enum": [ - "elastic", - "partner", - "community" - ], - "type": "string" - } - }, - "type": "object" - }, - "path": { - "type": "string" - }, - "policy_templates": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "readme": { - "type": "string" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "savedObject": {}, - "screenshots": { - "items": { - "additionalProperties": false, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "signature_path": { - "type": "string" - }, - "source": { - "additionalProperties": true, - "properties": { - "license": { - "type": "string" - } - }, - "required": [ - "license" - ], - "type": "object" - }, - "status": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "enum": [ - "integration", - "input", - "content" - ], - "type": "string" - }, - "vars": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "version": { - "type": "string" - } - }, - "required": [ - "savedObject", - "name", - "version", - "title", - "assets" - ], - "type": "object" - }, - "response": { - "additionalProperties": true, - "deprecated": true, - "properties": { - "agent": { - "additionalProperties": false, - "properties": { - "privileges": { - "additionalProperties": false, - "properties": { - "root": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "asset_tags": { - "items": { - "additionalProperties": false, - "properties": { - "asset_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "asset_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "text": { - "type": "string" - } - }, - "required": [ - "text" - ], - "type": "object" - }, - "type": "array" - }, - "assets": { - "additionalProperties": {}, - "type": "object" - }, - "categories": { - "items": { - "type": "string" - }, - "type": "array" - }, - "conditions": { - "additionalProperties": true, - "properties": { - "elastic": { - "additionalProperties": true, - "properties": { - "capabilities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "subscription": { - "type": "string" - } - }, - "type": "object" - }, - "kibana": { - "additionalProperties": true, - "properties": { - "version": { - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "data_streams": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "description": { - "type": "string" - }, - "discovery": { - "additionalProperties": true, - "properties": { - "fields": { - "items": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - } - }, - "required": [ - "name" - ], - "type": "object" - }, - "type": "array" - } - }, - "type": "object" - }, - "download": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": {}, - "type": "object" - }, - "format_version": { - "type": "string" - }, - "icons": { - "items": { - "additionalProperties": true, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "installationInfo": { - "additionalProperties": true, - "properties": { - "additional_spaces_installed_kibana": { - "additionalProperties": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "type": "object" - }, - "created_at": { - "type": "string" - }, - "experimental_data_stream_features": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": true, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "install_format_schema_version": { - "type": "string" - }, - "install_source": { - "enum": [ - "registry", - "upload", - "bundled", - "custom" - ], - "type": "string" - }, - "install_status": { - "enum": [ - "installed", - "installing", - "install_failed" - ], - "type": "string" - }, - "installed_es": { - "items": { - "additionalProperties": true, - "properties": { - "deferred": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "type": { - "enum": [ - "index", - "index_template", - "component_template", - "ingest_pipeline", - "ilm_policy", - "data_stream_ilm_policy", - "transform", - "ml_model" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana": { - "items": { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - }, - "originId": { - "type": "string" - }, - "type": { - "enum": [ - "dashboard", - "lens", - "visualization", - "search", - "index-pattern", - "map", - "ml-module", - "security-rule", - "csp-rule-template", - "osquery-pack-asset", - "osquery-saved-query", - "tag" - ], - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - }, - "installed_kibana_space_id": { - "type": "string" - }, - "latest_executed_state": { - "additionalProperties": true, - "properties": { - "error": { - "type": "string" - }, - "name": { - "type": "string" - }, - "started_at": { - "type": "string" - } - }, - "required": [ - "name", - "started_at" - ], - "type": "object" - }, - "latest_install_failed_attempts": { - "items": { - "additionalProperties": true, - "properties": { - "created_at": { - "type": "string" - }, - "error": { - "additionalProperties": true, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - }, - "stack": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" - }, - "target_version": { - "type": "string" - } - }, - "required": [ - "created_at", - "target_version", - "error" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "type": "string" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "updated_at": { - "type": "string" - }, - "verification_key_id": { - "nullable": true, - "type": "string" - }, - "verification_status": { - "enum": [ - "unverified", - "verified", - "unknown" - ], - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "type", - "installed_kibana", - "installed_es", - "name", - "version", - "install_status", - "install_source", - "verification_status" - ], - "type": "object" - }, - "internal": { - "type": "boolean" - }, - "keepPoliciesUpToDate": { - "type": "boolean" - }, - "latestVersion": { - "type": "string" - }, - "license": { - "type": "string" - }, - "licensePath": { - "type": "string" - }, - "name": { - "type": "string" - }, - "notice": { - "type": "string" - }, - "owner": { - "additionalProperties": true, - "properties": { - "github": { - "type": "string" - }, - "type": { - "enum": [ - "elastic", - "partner", - "community" - ], - "type": "string" - } - }, - "type": "object" - }, - "path": { - "type": "string" - }, - "policy_templates": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "readme": { - "type": "string" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "savedObject": {}, - "screenshots": { - "items": { - "additionalProperties": false, - "properties": { - "dark_mode": { - "type": "boolean" - }, - "path": { - "type": "string" - }, - "size": { - "type": "string" - }, - "src": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "src" - ], - "type": "object" - }, - "type": "array" - }, - "signature_path": { - "type": "string" - }, - "source": { - "additionalProperties": true, - "properties": { - "license": { - "type": "string" - } - }, - "required": [ - "license" - ], - "type": "object" - }, - "status": { - "type": "string" - }, - "title": { - "type": "string" - }, - "type": { - "enum": [ - "integration", - "input", - "content" - ], - "type": "string" - }, - "vars": { - "items": { - "additionalProperties": {}, - "type": "object" - }, - "type": "array" - }, - "version": { - "type": "string" - } - }, - "required": [ - "savedObject", - "name", - "version", - "title", - "assets" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/{pkgName}/{pkgVersion}/transforms/authorize": { - "post": { - "description": "Authorize transforms", - "operationId": "post-fleet-epm-packages-pkgname-pkgversion-transforms-authorize", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "pkgVersion", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "transforms": { - "items": { - "additionalProperties": false, - "properties": { - "transformId": { - "type": "string" - } - }, - "required": [ - "transformId" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "transforms" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "items": { - "additionalProperties": false, - "properties": { - "error": { - "nullable": true - }, - "success": { - "type": "boolean" - }, - "transformId": { - "type": "string" - } - }, - "required": [ - "transformId", - "success", - "error" - ], - "type": "object" - }, - "type": "array" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath*}": { - "get": { - "description": "Get package file", - "operationId": "get-fleet-epm-packages-pkgname-pkgversion-filepath", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "pkgVersion", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "filePath", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": {} - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/packages/{pkgkey}": { - "delete": { - "operationId": "delete-fleet-epm-packages-pkgkey", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "pkgkey", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "force": { - "type": "boolean" - } - }, - "required": [ - "force" - ], - "type": "object" - } - } - } - }, - "responses": {}, - "summary": "", - "tags": [] - }, - "get": { - "operationId": "get-fleet-epm-packages-pkgkey", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "pkgkey", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "ignoreUnverified", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "full", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "withMetadata", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "responses": {}, - "summary": "", - "tags": [] - }, - "post": { - "operationId": "post-fleet-epm-packages-pkgkey", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "pkgkey", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "ignoreMappingUpdateErrors", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - }, - { - "in": "query", - "name": "skipDataStreamRollover", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "force": { - "type": "boolean" - } - }, - "required": [ - "force" - ], - "type": "object" - } - } - } - }, - "responses": {}, - "summary": "", - "tags": [] - }, - "put": { - "operationId": "put-fleet-epm-packages-pkgkey", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "pkgkey", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "keepPoliciesUpToDate": { - "type": "boolean" - } - }, - "required": [ - "keepPoliciesUpToDate" - ], - "type": "object" - } - } - } - }, - "responses": {}, - "summary": "", - "tags": [] - } - }, - "/api/fleet/epm/templates/{pkgName}/{pkgVersion}/inputs": { - "get": { - "description": "Get inputs template", - "operationId": "get-fleet-epm-templates-pkgname-pkgversion-inputs", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "pkgName", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "path", - "name": "pkgVersion", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "default": "json", - "enum": [ - "json", - "yml", - "yaml" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "prerelease", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "ignoreUnverified", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "anyOf": [ - { - "type": "string" - }, - { - "additionalProperties": false, - "properties": { - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "additionalProperties": true, - "properties": { - "dataset": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset" - ], - "type": "object" - }, - "id": { - "type": "string" - } - }, - "required": [ - "id", - "data_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - } - }, - "required": [ - "id", - "type" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "inputs" - ], - "type": "object" - } - ] - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/epm/verification_key_id": { - "get": { - "description": "Get a package signature verification key ID", - "operationId": "get-fleet-epm-verification-key-id", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "id": { - "nullable": true, - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Package Manager (EPM)" - ] - } - }, - "/api/fleet/fleet_server_hosts": { - "get": { - "description": "List Fleet Server hosts", - "operationId": "get-fleet-fleet-server-hosts", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "host_urls": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host_urls" - ], - "type": "object" - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet Server hosts" - ] - }, - "post": { - "description": "Create Fleet Server host", - "operationId": "post-fleet-fleet-server-hosts", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "host_urls": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - } - }, - "required": [ - "name", - "host_urls" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "host_urls": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host_urls" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet Server hosts" - ] - } - }, - "/api/fleet/fleet_server_hosts/{itemId}": { - "delete": { - "description": "Delete Fleet Server host by ID", - "operationId": "delete-fleet-fleet-server-hosts-itemid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "itemId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet Server hosts" - ] - }, - "get": { - "description": "Get Fleet Server host by ID", - "operationId": "get-fleet-fleet-server-hosts-itemid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "itemId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "host_urls": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host_urls" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet Server hosts" - ] - }, - "put": { - "description": "Update Fleet Server host by ID", - "operationId": "put-fleet-fleet-server-hosts-itemid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "itemId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "host_urls": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "is_default": { - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - } - }, - "required": [ - "proxy_id" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "host_urls": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - } - }, - "required": [ - "id", - "name", - "host_urls" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet Server hosts" - ] - } - }, - "/api/fleet/health_check": { - "post": { - "description": "Check Fleet Server health", - "operationId": "post-fleet-health-check", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "host": { - "format": "uri", - "type": "string" - }, - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "host": { - "deprecated": true, - "type": "string" - }, - "host_id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "status": { - "type": "string" - } - }, - "required": [ - "status" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet internals" - ] - } - }, - "/api/fleet/kubernetes": { - "get": { - "description": "Get full K8s agent manifest", - "operationId": "get-fleet-kubernetes", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "download", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "fleetServer", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "enrolToken", - "required": false, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "type": "string" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/kubernetes/download": { - "get": { - "operationId": "get-fleet-kubernetes-download", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "download", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "fleetServer", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "enrolToken", - "required": false, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "type": "string" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Elastic Agent policies" - ] - } - }, - "/api/fleet/logstash_api_keys": { - "post": { - "description": "Generate Logstash API key", - "operationId": "post-fleet-logstash-api-keys", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "api_key": { - "type": "string" - } - }, - "required": [ - "api_key" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet outputs" - ] - } - }, - "/api/fleet/message_signing_service/rotate_key_pair": { - "post": { - "description": "Rotate fleet message signing key pair", - "operationId": "post-fleet-message-signing-service-rotate-key-pair", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "query", - "name": "acknowledge", - "required": false, - "schema": { - "default": false, - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "500": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Message Signing Service" - ] - } - }, - "/api/fleet/outputs": { - "get": { - "description": "List outputs", - "operationId": "get-fleet-outputs", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "service_token": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - }, - "service_token": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "remote_elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "logstash" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "auth_type": { - "enum": [ - "none", - "user_pass", - "ssl", - "kerberos" - ], - "type": "string" - }, - "broker_timeout": { - "type": "number" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "client_id": { - "type": "string" - }, - "compression": { - "enum": [ - "gzip", - "snappy", - "lz4", - "none" - ], - "type": "string" - }, - "compression_level": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "number" - }, - { - "not": {} - } - ] - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "connection_type": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "enum": [ - "plaintext", - "encryption" - ], - "type": "string" - }, - { - "not": {} - } - ] - }, - "hash": { - "additionalProperties": true, - "properties": { - "hash": { - "type": "string" - }, - "random": { - "type": "boolean" - } - }, - "type": "object" - }, - "headers": { - "items": { - "additionalProperties": true, - "properties": { - "key": { - "type": "string" - }, - "value": { - "type": "string" - } - }, - "required": [ - "key", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "key": { - "type": "string" - }, - "name": { - "type": "string" - }, - "partition": { - "enum": [ - "random", - "round_robin", - "hash" - ], - "type": "string" - }, - "password": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "not": {} - }, - { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - } - ] - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "random": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "required_acks": { - "enum": [ - 1, - 0, - -1 - ], - "type": "integer" - }, - "round_robin": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "sasl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "mechanism": { - "enum": [ - "PLAIN", - "SCRAM-SHA-256", - "SCRAM-SHA-512" - ], - "type": "string" - } - }, - "type": "object" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "password": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - }, - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "key" - ], - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "timeout": { - "type": "number" - }, - "topic": { - "type": "string" - }, - "topics": { - "items": { - "additionalProperties": true, - "properties": { - "topic": { - "type": "string" - }, - "when": { - "additionalProperties": true, - "properties": { - "condition": { - "type": "string" - }, - "type": { - "enum": [ - "equals", - "contains", - "regexp" - ], - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ - "topic" - ], - "type": "object" - }, - "minItems": 1, - "type": "array" - }, - "type": { - "enum": [ - "kafka" - ], - "type": "string" - }, - "username": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts", - "compression_level", - "auth_type", - "connection_type", - "username", - "password" - ], - "type": "object" - } - ] - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet outputs" - ] - }, - "post": { - "description": "Create output", - "operationId": "post-fleet-outputs", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": false, - "properties": { - "service_token": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - }, - "service_token": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "remote_elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": false, - "properties": { - "ssl": { - "additionalProperties": false, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "logstash" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "auth_type": { - "enum": [ - "none", - "user_pass", - "ssl", - "kerberos" - ], - "type": "string" - }, - "broker_timeout": { - "type": "number" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "client_id": { - "type": "string" - }, - "compression": { - "enum": [ - "gzip", - "snappy", - "lz4", - "none" - ], - "type": "string" - }, - "compression_level": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "number" - }, - { - "not": {} - } - ] - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "connection_type": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "enum": [ - "plaintext", - "encryption" - ], - "type": "string" - }, - { - "not": {} - } - ] - }, - "hash": { - "additionalProperties": false, - "properties": { - "hash": { - "type": "string" - }, - "random": { - "type": "boolean" - } - }, - "type": "object" - }, - "headers": { - "items": { - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - }, - "value": { - "type": "string" - } - }, - "required": [ - "key", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "key": { - "type": "string" - }, - "name": { - "type": "string" - }, - "partition": { - "enum": [ - "random", - "round_robin", - "hash" - ], - "type": "string" - }, - "password": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "not": {} - }, - { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - } - ] - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "random": { - "additionalProperties": false, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "required_acks": { - "enum": [ - 1, - 0, - -1 - ], - "type": "integer" - }, - "round_robin": { - "additionalProperties": false, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "sasl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "mechanism": { - "enum": [ - "PLAIN", - "SCRAM-SHA-256", - "SCRAM-SHA-512" - ], - "type": "string" - } - }, - "type": "object" - }, - "secrets": { - "additionalProperties": false, - "properties": { - "password": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - }, - "ssl": { - "additionalProperties": false, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "key" - ], - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "timeout": { - "type": "number" - }, - "topic": { - "type": "string" - }, - "topics": { - "items": { - "additionalProperties": false, - "properties": { - "topic": { - "type": "string" - }, - "when": { - "additionalProperties": false, - "properties": { - "condition": { - "type": "string" - }, - "type": { - "enum": [ - "equals", - "contains", - "regexp" - ], - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ - "topic" - ], - "type": "object" - }, - "minItems": 1, - "type": "array" - }, - "type": { - "enum": [ - "kafka" - ], - "type": "string" - }, - "username": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts", - "compression_level", - "auth_type", - "connection_type", - "username", - "password" - ], - "type": "object" - } - ] - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "service_token": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - }, - "service_token": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "remote_elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "logstash" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "auth_type": { - "enum": [ - "none", - "user_pass", - "ssl", - "kerberos" - ], - "type": "string" - }, - "broker_timeout": { - "type": "number" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "client_id": { - "type": "string" - }, - "compression": { - "enum": [ - "gzip", - "snappy", - "lz4", - "none" - ], - "type": "string" - }, - "compression_level": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "number" - }, - { - "not": {} - } - ] - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "connection_type": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "enum": [ - "plaintext", - "encryption" - ], - "type": "string" - }, - { - "not": {} - } - ] - }, - "hash": { - "additionalProperties": true, - "properties": { - "hash": { - "type": "string" - }, - "random": { - "type": "boolean" - } - }, - "type": "object" - }, - "headers": { - "items": { - "additionalProperties": true, - "properties": { - "key": { - "type": "string" - }, - "value": { - "type": "string" - } - }, - "required": [ - "key", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "key": { - "type": "string" - }, - "name": { - "type": "string" - }, - "partition": { - "enum": [ - "random", - "round_robin", - "hash" - ], - "type": "string" - }, - "password": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "not": {} - }, - { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - } - ] - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "random": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "required_acks": { - "enum": [ - 1, - 0, - -1 - ], - "type": "integer" - }, - "round_robin": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "sasl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "mechanism": { - "enum": [ - "PLAIN", - "SCRAM-SHA-256", - "SCRAM-SHA-512" - ], - "type": "string" - } - }, - "type": "object" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "password": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - }, - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "key" - ], - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "timeout": { - "type": "number" - }, - "topic": { - "type": "string" - }, - "topics": { - "items": { - "additionalProperties": true, - "properties": { - "topic": { - "type": "string" - }, - "when": { - "additionalProperties": true, - "properties": { - "condition": { - "type": "string" - }, - "type": { - "enum": [ - "equals", - "contains", - "regexp" - ], - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ - "topic" - ], - "type": "object" - }, - "minItems": 1, - "type": "array" - }, - "type": { - "enum": [ - "kafka" - ], - "type": "string" - }, - "username": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts", - "compression_level", - "auth_type", - "connection_type", - "username", - "password" - ], - "type": "object" - } - ] - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet outputs" - ] - } - }, - "/api/fleet/outputs/{outputId}": { - "delete": { - "description": "Delete output by ID", - "operationId": "delete-fleet-outputs-outputid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "outputId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet outputs" - ] - }, - "get": { - "description": "Get output by ID", - "operationId": "get-fleet-outputs-outputid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "outputId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "service_token": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - }, - "service_token": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "remote_elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "logstash" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "auth_type": { - "enum": [ - "none", - "user_pass", - "ssl", - "kerberos" - ], - "type": "string" - }, - "broker_timeout": { - "type": "number" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "client_id": { - "type": "string" - }, - "compression": { - "enum": [ - "gzip", - "snappy", - "lz4", - "none" - ], - "type": "string" - }, - "compression_level": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "number" - }, - { - "not": {} - } - ] - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "connection_type": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "enum": [ - "plaintext", - "encryption" - ], - "type": "string" - }, - { - "not": {} - } - ] - }, - "hash": { - "additionalProperties": true, - "properties": { - "hash": { - "type": "string" - }, - "random": { - "type": "boolean" - } - }, - "type": "object" - }, - "headers": { - "items": { - "additionalProperties": true, - "properties": { - "key": { - "type": "string" - }, - "value": { - "type": "string" - } - }, - "required": [ - "key", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "key": { - "type": "string" - }, - "name": { - "type": "string" - }, - "partition": { - "enum": [ - "random", - "round_robin", - "hash" - ], - "type": "string" - }, - "password": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "not": {} - }, - { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - } - ] - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "random": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "required_acks": { - "enum": [ - 1, - 0, - -1 - ], - "type": "integer" - }, - "round_robin": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "sasl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "mechanism": { - "enum": [ - "PLAIN", - "SCRAM-SHA-256", - "SCRAM-SHA-512" - ], - "type": "string" - } - }, - "type": "object" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "password": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - }, - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "key" - ], - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "timeout": { - "type": "number" - }, - "topic": { - "type": "string" - }, - "topics": { - "items": { - "additionalProperties": true, - "properties": { - "topic": { - "type": "string" - }, - "when": { - "additionalProperties": true, - "properties": { - "condition": { - "type": "string" - }, - "type": { - "enum": [ - "equals", - "contains", - "regexp" - ], - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ - "topic" - ], - "type": "object" - }, - "minItems": 1, - "type": "array" - }, - "type": { - "enum": [ - "kafka" - ], - "type": "string" - }, - "username": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts", - "compression_level", - "auth_type", - "connection_type", - "username", - "password" - ], - "type": "object" - } - ] - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet outputs" - ] - }, - "put": { - "description": "Update output by ID", - "operationId": "put-fleet-outputs-outputid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "outputId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "type": "boolean" - }, - "is_default_monitoring": { - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "elasticsearch" - ], - "type": "string" - } - }, - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "type": "boolean" - }, - "is_default_monitoring": { - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": false, - "properties": { - "service_token": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - }, - "service_token": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "remote_elasticsearch" - ], - "type": "string" - } - }, - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "type": "boolean" - }, - "is_default_monitoring": { - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": false, - "properties": { - "ssl": { - "additionalProperties": false, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "logstash" - ], - "type": "string" - } - }, - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "auth_type": { - "enum": [ - "none", - "user_pass", - "ssl", - "kerberos" - ], - "type": "string" - }, - "broker_timeout": { - "type": "number" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "client_id": { - "type": "string" - }, - "compression": { - "enum": [ - "gzip", - "snappy", - "lz4", - "none" - ], - "type": "string" - }, - "compression_level": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "number" - }, - { - "not": {} - } - ] - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "connection_type": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "enum": [ - "plaintext", - "encryption" - ], - "type": "string" - }, - { - "not": {} - } - ] - }, - "hash": { - "additionalProperties": false, - "properties": { - "hash": { - "type": "string" - }, - "random": { - "type": "boolean" - } - }, - "type": "object" - }, - "headers": { - "items": { - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - }, - "value": { - "type": "string" - } - }, - "required": [ - "key", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "key": { - "type": "string" - }, - "name": { - "type": "string" - }, - "partition": { - "enum": [ - "random", - "round_robin", - "hash" - ], - "type": "string" - }, - "password": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "not": {} - }, - { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - } - ] - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "random": { - "additionalProperties": false, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "required_acks": { - "enum": [ - 1, - 0, - -1 - ], - "type": "integer" - }, - "round_robin": { - "additionalProperties": false, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "sasl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "mechanism": { - "enum": [ - "PLAIN", - "SCRAM-SHA-256", - "SCRAM-SHA-512" - ], - "type": "string" - } - }, - "type": "object" - }, - "secrets": { - "additionalProperties": false, - "properties": { - "password": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - }, - "ssl": { - "additionalProperties": false, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "key" - ], - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": false, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": false, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "timeout": { - "type": "number" - }, - "topic": { - "type": "string" - }, - "topics": { - "items": { - "additionalProperties": false, - "properties": { - "topic": { - "type": "string" - }, - "when": { - "additionalProperties": false, - "properties": { - "condition": { - "type": "string" - }, - "type": { - "enum": [ - "equals", - "contains", - "regexp" - ], - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ - "topic" - ], - "type": "object" - }, - "minItems": 1, - "type": "array" - }, - "type": { - "enum": [ - "kafka" - ], - "type": "string" - }, - "username": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "compression_level", - "connection_type", - "username", - "password" - ], - "type": "object" - } - ] - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "format": "uri", - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "preset": { - "enum": [ - "balanced", - "custom", - "throughput", - "scale", - "latency" - ], - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "service_token": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - }, - "service_token": { - "nullable": true, - "type": "string" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "remote_elasticsearch" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "type": { - "enum": [ - "logstash" - ], - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts" - ], - "type": "object" - }, - { - "additionalProperties": true, - "properties": { - "allow_edit": { - "items": { - "type": "string" - }, - "type": "array" - }, - "auth_type": { - "enum": [ - "none", - "user_pass", - "ssl", - "kerberos" - ], - "type": "string" - }, - "broker_timeout": { - "type": "number" - }, - "ca_sha256": { - "nullable": true, - "type": "string" - }, - "ca_trusted_fingerprint": { - "nullable": true, - "type": "string" - }, - "client_id": { - "type": "string" - }, - "compression": { - "enum": [ - "gzip", - "snappy", - "lz4", - "none" - ], - "type": "string" - }, - "compression_level": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "number" - }, - { - "not": {} - } - ] - }, - "config_yaml": { - "nullable": true, - "type": "string" - }, - "connection_type": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "enum": [ - "plaintext", - "encryption" - ], - "type": "string" - }, - { - "not": {} - } - ] - }, - "hash": { - "additionalProperties": true, - "properties": { - "hash": { - "type": "string" - }, - "random": { - "type": "boolean" - } - }, - "type": "object" - }, - "headers": { - "items": { - "additionalProperties": true, - "properties": { - "key": { - "type": "string" - }, - "value": { - "type": "string" - } - }, - "required": [ - "key", - "value" - ], - "type": "object" - }, - "type": "array" - }, - "hosts": { - "items": { - "type": "string" - }, - "minItems": 1, - "type": "array" - }, - "id": { - "type": "string" - }, - "is_default": { - "default": false, - "type": "boolean" - }, - "is_default_monitoring": { - "default": false, - "type": "boolean" - }, - "is_internal": { - "type": "boolean" - }, - "is_preconfigured": { - "type": "boolean" - }, - "key": { - "type": "string" - }, - "name": { - "type": "string" - }, - "partition": { - "enum": [ - "random", - "round_robin", - "hash" - ], - "type": "string" - }, - "password": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "not": {} - }, - { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - } - ] - }, - "proxy_id": { - "nullable": true, - "type": "string" - }, - "random": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "required_acks": { - "enum": [ - 1, - 0, - -1 - ], - "type": "integer" - }, - "round_robin": { - "additionalProperties": true, - "properties": { - "group_events": { - "type": "number" - } - }, - "type": "object" - }, - "sasl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "mechanism": { - "enum": [ - "PLAIN", - "SCRAM-SHA-256", - "SCRAM-SHA-512" - ], - "type": "string" - } - }, - "type": "object" - }, - "secrets": { - "additionalProperties": true, - "properties": { - "password": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - }, - "ssl": { - "additionalProperties": true, - "properties": { - "key": { - "anyOf": [ - { - "additionalProperties": true, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - { - "type": "string" - } - ] - } - }, - "required": [ - "key" - ], - "type": "object" - } - }, - "type": "object" - }, - "shipper": { - "additionalProperties": true, - "nullable": true, - "properties": { - "compression_level": { - "nullable": true, - "type": "number" - }, - "disk_queue_compression_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_enabled": { - "default": false, - "nullable": true, - "type": "boolean" - }, - "disk_queue_encryption_enabled": { - "nullable": true, - "type": "boolean" - }, - "disk_queue_max_size": { - "nullable": true, - "type": "number" - }, - "disk_queue_path": { - "nullable": true, - "type": "string" - }, - "loadbalance": { - "nullable": true, - "type": "boolean" - }, - "max_batch_bytes": { - "nullable": true, - "type": "number" - }, - "mem_queue_events": { - "nullable": true, - "type": "number" - }, - "queue_flush_timeout": { - "nullable": true, - "type": "number" - } - }, - "required": [ - "disk_queue_path", - "disk_queue_max_size", - "disk_queue_encryption_enabled", - "disk_queue_compression_enabled", - "compression_level", - "loadbalance", - "mem_queue_events", - "queue_flush_timeout", - "max_batch_bytes" - ], - "type": "object" - }, - "ssl": { - "additionalProperties": true, - "nullable": true, - "properties": { - "certificate": { - "type": "string" - }, - "certificate_authorities": { - "items": { - "type": "string" - }, - "type": "array" - }, - "key": { - "type": "string" - }, - "verification_mode": { - "enum": [ - "full", - "none", - "certificate", - "strict" - ], - "type": "string" - } - }, - "type": "object" - }, - "timeout": { - "type": "number" - }, - "topic": { - "type": "string" - }, - "topics": { - "items": { - "additionalProperties": true, - "properties": { - "topic": { - "type": "string" - }, - "when": { - "additionalProperties": true, - "properties": { - "condition": { - "type": "string" - }, - "type": { - "enum": [ - "equals", - "contains", - "regexp" - ], - "type": "string" - } - }, - "type": "object" - } - }, - "required": [ - "topic" - ], - "type": "object" - }, - "minItems": 1, - "type": "array" - }, - "type": { - "enum": [ - "kafka" - ], - "type": "string" - }, - "username": { - "anyOf": [ - { - "items": {}, - "type": "array" - }, - { - "type": "boolean" - }, - { - "type": "number" - }, - { - "type": "object" - }, - { - "type": "string" - } - ], - "nullable": true, - "oneOf": [ - { - "type": "string" - }, - { - "not": {} - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "type", - "hosts", - "compression_level", - "auth_type", - "connection_type", - "username", - "password" - ], - "type": "object" - } - ] - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet outputs" - ] - } - }, - "/api/fleet/outputs/{outputId}/health": { - "get": { - "description": "Get latest output health", - "operationId": "get-fleet-outputs-outputid-health", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "outputId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "message": { - "description": "long message if unhealthy", - "type": "string" - }, - "state": { - "description": "state of output, HEALTHY or DEGRADED", - "type": "string" - }, - "timestamp": { - "description": "timestamp of reported state", - "type": "string" - } - }, - "required": [ - "state", - "message", - "timestamp" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet outputs" - ] - } - }, - "/api/fleet/package_policies": { - "get": { - "description": "List package policies", - "operationId": "get-fleet-package-policies", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "page", - "required": false, - "schema": { - "type": "number" - } - }, - { - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "type": "number" - } - }, - { - "in": "query", - "name": "sortField", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "sortOrder", - "required": false, - "schema": { - "enum": [ - "desc", - "asc" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "showUpgradeable", - "required": false, - "schema": { - "type": "boolean" - } - }, - { - "in": "query", - "name": "kuery", - "required": false, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - }, - { - "in": "query", - "name": "withAgentCount", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "agents": { - "type": "number" - }, - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "anyOf": [ - { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" - }, - "streams": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "spaceIds": { - "items": { - "type": "string" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "anyOf": [ - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet package policies" - ] - }, - "post": { - "description": "Create package policy", - "operationId": "post-fleet-package-policies", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "description": { - "description": "Package policy description", - "type": "string" - }, - "enabled": { - "type": "boolean" - }, - "force": { - "description": "Force package policy creation even if package is not verified, or if the agent policy is managed.", - "type": "boolean" - }, - "id": { - "description": "Package policy unique identifier", - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "name", - "inputs" - ], - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "description": { - "type": "string" - }, - "force": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" - }, - "streams": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object" - }, - "name": { - "type": "string" - }, - "namespace": { - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "name", - "package" - ], - "type": "object" - } - ], - "description": "You should use inputs as an object and not use the deprecated inputs array." - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "agents": { - "type": "number" - }, - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "anyOf": [ - { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" - }, - "streams": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "spaceIds": { - "items": { - "type": "string" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "anyOf": [ - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], + } + }, + "required": [ + "id", + "name", + "connector_type_id", + "is_preconfigured", + "is_deprecated", + "is_system_action" + ], + "type": "object" + } + } + }, + "description": "Indicates a successful call." + } + }, + "summary": "Get connector information", + "tags": [ + "connectors" + ] + }, + "post": { + "operationId": "post-actions-connector-id", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "An identifier for the connector.", + "in": "path", + "name": "id", + "required": false, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "config": { + "additionalProperties": {}, + "default": {}, + "type": "object" + }, + "connector_type_id": { + "description": "The type of connector.", + "type": "string" + }, + "name": { + "description": "The display name for the connector.", + "type": "string" + }, + "secrets": { + "additionalProperties": {}, + "default": {}, + "type": "object" + } + }, + "required": [ + "name", + "connector_type_id" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "config": { + "additionalProperties": {}, "type": "object" + }, + "connector_type_id": { + "description": "The connector type identifier.", + "type": "string" + }, + "id": { + "description": "The identifier for the connector.", + "type": "string" + }, + "is_deprecated": { + "description": "Indicates whether the connector is deprecated.", + "type": "boolean" + }, + "is_missing_secrets": { + "description": "Indicates whether the connector is missing secrets.", + "type": "boolean" + }, + "is_preconfigured": { + "description": "Indicates whether the connector is preconfigured. If true, the `config` and `is_missing_secrets` properties are omitted from the response. ", + "type": "boolean" + }, + "is_system_action": { + "description": "Indicates whether the connector is used for system actions.", + "type": "boolean" + }, + "name": { + "description": " The name of the rule.", + "type": "string" } }, "required": [ - "item" + "id", + "name", + "connector_type_id", + "is_preconfigured", + "is_deprecated", + "is_system_action" ], "type": "object" } } + }, + "description": "Indicates a successful call." + } + }, + "summary": "Create a connector", + "tags": [ + "connectors" + ] + }, + "put": { + "operationId": "put-actions-connector-id", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" } }, - "400": { + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "An identifier for the connector.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "config": { + "additionalProperties": {}, + "default": {}, + "type": "object" + }, + "name": { + "description": "The display name for the connector.", + "type": "string" + }, + "secrets": { + "additionalProperties": {}, + "default": {}, + "type": "object" + } + }, + "required": [ + "name" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { "content": { "application/json; Elastic-Api-Version=2023-10-31": { "schema": { "additionalProperties": false, - "description": "Generic Error", "properties": { - "error": { + "config": { + "additionalProperties": {}, + "type": "object" + }, + "connector_type_id": { + "description": "The connector type identifier.", "type": "string" }, - "message": { + "id": { + "description": "The identifier for the connector.", "type": "string" }, - "statusCode": { - "type": "number" + "is_deprecated": { + "description": "Indicates whether the connector is deprecated.", + "type": "boolean" + }, + "is_missing_secrets": { + "description": "Indicates whether the connector is missing secrets.", + "type": "boolean" + }, + "is_preconfigured": { + "description": "Indicates whether the connector is preconfigured. If true, the `config` and `is_missing_secrets` properties are omitted from the response. ", + "type": "boolean" + }, + "is_system_action": { + "description": "Indicates whether the connector is used for system actions.", + "type": "boolean" + }, + "name": { + "description": " The name of the rule.", + "type": "string" } }, "required": [ - "message" + "id", + "name", + "connector_type_id", + "is_preconfigured", + "is_deprecated", + "is_system_action" ], "type": "object" } } + }, + "description": "Indicates a successful call." + } + }, + "summary": "Update a connector", + "tags": [ + "connectors" + ] + } + }, + "/api/actions/connector/{id}/_execute": { + "post": { + "description": "You can use this API to test an action that involves interaction with Kibana services or integrations with third-party systems.", + "operationId": "post-actions-connector-id-execute", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "An identifier for the connector.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "params": { + "additionalProperties": {}, + "type": "object" + } + }, + "required": [ + "params" + ], + "type": "object" + } } - }, - "409": { + } + }, + "responses": { + "200": { "content": { "application/json; Elastic-Api-Version=2023-10-31": { "schema": { "additionalProperties": false, - "description": "Generic Error", "properties": { - "error": { + "config": { + "additionalProperties": {}, + "type": "object" + }, + "connector_type_id": { + "description": "The connector type identifier.", "type": "string" }, - "message": { + "id": { + "description": "The identifier for the connector.", "type": "string" }, - "statusCode": { - "type": "number" + "is_deprecated": { + "description": "Indicates whether the connector is deprecated.", + "type": "boolean" + }, + "is_missing_secrets": { + "description": "Indicates whether the connector is missing secrets.", + "type": "boolean" + }, + "is_preconfigured": { + "description": "Indicates whether the connector is preconfigured. If true, the `config` and `is_missing_secrets` properties are omitted from the response. ", + "type": "boolean" + }, + "is_system_action": { + "description": "Indicates whether the connector is used for system actions.", + "type": "boolean" + }, + "name": { + "description": " The name of the rule.", + "type": "string" } }, "required": [ - "message" + "id", + "name", + "connector_type_id", + "is_preconfigured", + "is_deprecated", + "is_system_action" ], "type": "object" } } - } + }, + "description": "Indicates a successful call." } }, - "summary": "", + "summary": "Run a connector", "tags": [ - "Fleet package policies" + "connectors" ] } }, - "/api/fleet/package_policies/_bulk_get": { - "post": { - "description": "Bulk get package policies", - "operationId": "post-fleet-package-policies-bulk-get", + "/api/actions/connector_types": { + "get": { + "description": "You do not need any Kibana feature privileges to run this API.", + "operationId": "get-actions-connector-types", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "A filter to limit the retrieved connector types to those that support a specific feature (such as alerting or cases).", + "in": "query", + "name": "feature_id", + "required": false, + "schema": { + "type": "string" + } + } + ], + "responses": {}, + "summary": "Get connector types", + "tags": [ + "connectors" + ] + } + }, + "/api/actions/connectors": { + "get": { + "operationId": "get-actions-connectors", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + } + ], + "responses": {}, + "summary": "Get all connectors", + "tags": [ + "connectors" + ] + } + }, + "/api/actions/list_action_types": { + "get": { + "deprecated": true, + "operationId": "get-actions-list-action-types", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + } + ], + "responses": {}, + "summary": "Get connector types", + "tags": [ + "connectors" + ] + } + }, + "/api/alerting/rule/{id}": { + "delete": { + "operationId": "delete-alerting-rule-id", "parameters": [ { "description": "The version of the API to use", @@ -34742,2954 +1481,2210 @@ } }, { - "in": "query", - "name": "format", - "required": false, + "description": "The identifier for the rule.", + "in": "path", + "name": "id", + "required": true, "schema": { - "enum": [ - "simplified", - "legacy" - ], "type": "string" } } ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "ids": { - "description": "list of package policy ids", - "items": { - "type": "string" - }, - "type": "array" - }, - "ignoreMissing": { - "type": "boolean" - } - }, - "required": [ - "ids" - ], - "type": "object" - } - } + "responses": { + "204": { + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." } }, + "summary": "Delete a rule", + "tags": [ + "alerting" + ] + }, + "get": { + "operationId": "get-alerting-rule-id", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "The identifier for the rule.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + } + } + ], "responses": { "200": { "content": { "application/json; Elastic-Api-Version=2023-10-31": { "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "agents": { - "type": "number" - }, - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "anyOf": [ - { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" + "additionalProperties": false, + "properties": { + "actions": { + "items": { + "additionalProperties": false, + "properties": { + "alerts_filter": { + "additionalProperties": false, + "description": "Defines a period that limits whether the action runs.", + "properties": { + "query": { + "additionalProperties": false, + "properties": { + "dsl": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", + "type": "string" + }, + "filters": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", + "items": { + "additionalProperties": false, + "properties": { + "$state": { + "additionalProperties": false, + "properties": { + "store": { + "description": "A filter can be either specific to an application context or applied globally.", + "enum": [ + "appState", + "globalState" ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" + "type": "string" + } }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } + "required": [ + "store" + ], + "type": "object" }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} + "meta": { + "additionalProperties": {}, + "type": "object" }, - "required": [ - "value" - ], - "type": "object" + "query": { + "additionalProperties": {}, + "type": "object" + } }, - "description": "Package variable (see integration documentation for more information)", + "required": [ + "meta" + ], "type": "object" - } + }, + "type": "array" }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" + "kql": { + "description": "A filter written in Kibana Query Language (KQL).", + "type": "string" + } }, - "type": "array" + "required": [ + "kql", + "filters" + ], + "type": "object" }, - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" + "timeframe": { + "additionalProperties": false, + "properties": { + "days": { + "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", + "items": { + "enum": [ + 1, + 2, + 3, + 4, + 5, + 6, + 7 + ], + "type": "integer" }, - "streams": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" + "type": "array" + }, + "hours": { + "additionalProperties": false, + "properties": { + "end": { + "description": "The end of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" + "start": { + "description": "The start of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + } }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } + "required": [ + "start", + "end" + ], + "type": "object" }, - "type": "object" + "timezone": { + "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", + "type": "string" + } }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object", - "x-oas-optional": true + "required": [ + "days", + "hours", + "timezone" + ], + "type": "object" } - ] - }, - "is_managed": { - "type": "boolean" + }, + "type": "object" }, - "name": { - "description": "Package policy name (should be unique)", + "connector_type_id": { + "description": "The type of connector. This property appears in responses but cannot be set in requests.", "type": "string" }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", + "frequency": { + "additionalProperties": false, + "properties": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "type": "string" + }, + "summary": { + "description": "Indicates whether the action is a summary.", + "type": "boolean" + }, + "throttle": { + "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + } + }, + "required": [ + "summary", + "notify_when", + "throttle" + ], + "type": "object" + }, + "group": { + "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", "type": "string" }, - "output_id": { - "nullable": true, + "id": { + "description": "The identifier for the connector saved object.", "type": "string" }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } + "params": { + "additionalProperties": {}, + "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", + "type": "object" + }, + "use_alert_data_for_template": { + "description": "Indicates whether to use alert data as a template.", + "type": "boolean" + }, + "uuid": { + "description": "A universally unique identifier (UUID) for the action.", + "type": "string" + } + }, + "required": [ + "id", + "connector_type_id", + "params" + ], + "type": "object" + }, + "type": "array" + }, + "active_snoozes": { + "items": { + "description": "List of active snoozes for the rule.", + "type": "string" + }, + "type": "array" + }, + "alert_delay": { + "additionalProperties": false, + "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", + "properties": { + "active": { + "description": "The number of consecutive runs that must meet the rule conditions.", + "type": "number" + } + }, + "required": [ + "active" + ], + "type": "object" + }, + "api_key_created_by_user": { + "description": "Indicates whether the API key that is associated with the rule was created by the user.", + "nullable": true, + "type": "boolean" + }, + "api_key_owner": { + "description": "The owner of the API key that is associated with the rule and used to run background tasks.", + "nullable": true, + "type": "string" + }, + "consumer": { + "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", + "type": "string" + }, + "created_at": { + "description": "The date and time that the rule was created.", + "type": "string" + }, + "created_by": { + "description": "The identifier for the user that created the rule.", + "nullable": true, + "type": "string" + }, + "enabled": { + "description": "Indicates whether you want to run the rule on an interval basis after it is created.", + "type": "boolean" + }, + "execution_status": { + "additionalProperties": false, + "properties": { + "error": { + "additionalProperties": false, + "properties": { + "message": { + "description": "Error message.", + "type": "string" }, - "type": "object" + "reason": { + "description": "Reason for error.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate" + ], + "type": "string" + } }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } + "required": [ + "reason", + "message" + ], + "type": "object" + }, + "last_duration": { + "description": "Duration of last execution of the rule.", + "type": "number" + }, + "last_execution_date": { + "description": "The date and time when rule was executed last.", + "type": "string" + }, + "status": { + "description": "Status of rule execution.", + "enum": [ + "ok", + "active", + "error", + "warning", + "pending", + "unknown" + ], + "type": "string" + }, + "warning": { + "additionalProperties": false, + "properties": { + "message": { + "description": "Warning message.", + "type": "string" }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", + "reason": { + "description": "Reason for warning.", + "enum": [ + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], "type": "string" + } + }, + "required": [ + "reason", + "message" + ], + "type": "object" + } + }, + "required": [ + "status", + "last_execution_date" + ], + "type": "object" + }, + "flapping": { + "additionalProperties": false, + "nullable": true, + "properties": { + "look_back_window": { + "maximum": 20, + "minimum": 2, + "type": "number" + }, + "status_change_threshold": { + "maximum": 20, + "minimum": 2, + "type": "number" + } + }, + "required": [ + "look_back_window", + "status_change_threshold" + ], + "type": "object" + }, + "id": { + "description": "The identifier for the rule.", + "type": "string" + }, + "is_snoozed_until": { + "description": "The date when the rule will no longer be snoozed.", + "nullable": true, + "type": "string" + }, + "last_run": { + "additionalProperties": false, + "nullable": true, + "properties": { + "alerts_count": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" }, - "type": "array" + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, + "type": "number" + }, + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" + }, + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } }, - "revision": { - "type": "number" + "type": "object" + }, + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], + "type": "string" + }, + "outcome_msg": { + "items": { + "description": "Outcome message generated during last rule run.", + "type": "string" }, - "secret_references": { - "items": { + "nullable": true, + "type": "array" + }, + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" + }, + "warning": { + "description": "Warning of last rule execution.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "nullable": true, + "type": "string" + } + }, + "required": [ + "outcome", + "alerts_count" + ], + "type": "object" + }, + "mapped_params": { + "additionalProperties": {}, + "type": "object" + }, + "monitoring": { + "additionalProperties": false, + "description": "Monitoring details of the rule.", + "properties": { + "run": { + "additionalProperties": false, + "description": "Rule run details.", + "properties": { + "calculated_metrics": { "additionalProperties": false, + "description": "Calculation of different percentiles and success ratio.", "properties": { - "id": { - "type": "string" + "p50": { + "type": "number" + }, + "p95": { + "type": "number" + }, + "p99": { + "type": "number" + }, + "success_ratio": { + "type": "number" } }, "required": [ - "id" + "success_ratio" ], "type": "object" }, - "type": "array" - }, - "spaceIds": { - "items": { - "type": "string" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "anyOf": [ - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} + "history": { + "description": "History of the rule run.", + "items": { + "additionalProperties": false, + "properties": { + "duration": { + "description": "Duration of the rule run.", + "type": "number" }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" + "outcome": { + "additionalProperties": false, + "properties": { + "alerts_count": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" + }, + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, + "type": "number" + }, + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" + }, + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } + }, + "type": "object" }, - "type": "array" - }, - { - "items": { - "type": "number" + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], + "type": "string" }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { + "outcome_msg": { + "items": { + "description": "Outcome message generated during last rule run.", "type": "string" }, - "isSecretRef": { - "type": "boolean" - } + "nullable": true, + "type": "array" }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" + }, + "warning": { + "description": "Warning of last rule execution.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "nullable": true, + "type": "string" + } + }, + "required": [ + "outcome", + "alerts_count" + ], + "type": "object" + }, + "success": { + "description": "Indicates whether the rule run was successful.", + "type": "boolean" + }, + "timestamp": { + "description": "Time of rule run.", + "type": "number" + } }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - }, - "type": "array" - } - }, - "required": [ - "items" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet package policies" - ] - } - }, - "/api/fleet/package_policies/delete": { - "post": { - "description": "Bulk delete package policies", - "operationId": "post-fleet-package-policies-delete", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "force": { - "type": "boolean" - }, - "packagePolicyIds": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "packagePolicyIds" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "items": { - "additionalProperties": false, - "properties": { - "body": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - }, - "id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { + "required": [ + "success", + "timestamp" + ], + "type": "object" + }, + "type": "array" + }, + "last_run": { "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { + "properties": { + "metrics": { "additionalProperties": false, "properties": { - "doc_value_only_numeric": { - "type": "boolean" + "duration": { + "description": "Duration of most recent rule run.", + "type": "number" + }, + "gap_duration_s": { + "description": "Duration in seconds of rule run gap.", + "nullable": true, + "type": "number" + }, + "total_alerts_created": { + "description": "Total number of alerts created during last rule run.", + "nullable": true, + "type": "number" }, - "doc_value_only_other": { - "type": "boolean" + "total_alerts_detected": { + "description": "Total number of alerts detected during last rule run.", + "nullable": true, + "type": "number" }, - "synthetic_source": { - "type": "boolean" + "total_indexing_duration_ms": { + "description": "Total time spent indexing documents during last rule run in milliseconds.", + "nullable": true, + "type": "number" }, - "tsdb": { - "type": "boolean" + "total_search_duration_ms": { + "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", + "nullable": true, + "type": "number" } }, "type": "object" + }, + "timestamp": { + "description": "Time of the most recent rule run.", + "type": "string" } }, "required": [ - "data_stream", - "features" + "timestamp", + "metrics" ], "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" + } }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" + "required": [ + "history", + "calculated_metrics", + "last_run" + ], + "type": "object" + } }, - "policy_id": { - "deprecated": true, - "description": "Use `policy_ids` instead", - "nullable": true, + "required": [ + "run" + ], + "type": "object" + }, + "mute_all": { + "description": "Indicates whether all alerts are muted.", + "type": "boolean" + }, + "muted_alert_ids": { + "items": { + "description": "List of identifiers of muted alerts. ", "type": "string" }, - "policy_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "statusCode": { - "type": "number" - }, - "success": { - "type": "boolean" - } - }, - "required": [ - "id", - "success", - "policy_ids", - "package" - ], - "type": "object" - }, - "type": "array" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" + "type": "array" }, - "message": { + "name": { + "description": " The name of the rule.", "type": "string" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet package policies" - ] - } - }, - "/api/fleet/package_policies/upgrade": { - "post": { - "description": "Upgrade package policy to a newer package version", - "operationId": "post-fleet-package-policies-upgrade", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "packagePolicyIds": { - "items": { + "next_run": { + "description": "Date and time of the next run of the rule.", + "nullable": true, "type": "string" }, - "type": "array" - } - }, - "required": [ - "packagePolicyIds" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "items": { - "additionalProperties": false, - "properties": { - "body": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - }, - "id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "statusCode": { - "type": "number" - }, - "success": { - "type": "boolean" - } - }, - "required": [ - "id", - "success" - ], - "type": "object" - }, - "type": "array" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "nullable": true, "type": "string" }, - "message": { - "type": "string" + "params": { + "additionalProperties": {}, + "description": "The parameters for the rule.", + "type": "object" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet package policies" - ] - } - }, - "/api/fleet/package_policies/upgrade/dryrun": { - "post": { - "description": "Dry run package policy upgrade", - "operationId": "post-fleet-package-policies-upgrade-dryrun", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "packagePolicyIds": { - "items": { + "revision": { + "description": "The rule revision number.", + "type": "number" + }, + "rule_type_id": { + "description": "The rule type identifier.", "type": "string" }, - "type": "array" - }, - "packageVersion": { - "type": "string" - } - }, - "required": [ - "packagePolicyIds" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "items": { - "additionalProperties": false, - "properties": { - "agent_diff": { - "items": { - "items": { - "additionalProperties": true, + "running": { + "description": "Indicates whether the rule is running.", + "nullable": true, + "type": "boolean" + }, + "schedule": { + "additionalProperties": false, + "properties": { + "interval": { + "description": "The interval is specified in seconds, minutes, hours, or days.", + "type": "string" + } + }, + "required": [ + "interval" + ], + "type": "object" + }, + "scheduled_task_id": { + "description": "Identifier of the scheduled task.", + "type": "string" + }, + "snooze_schedule": { + "items": { + "additionalProperties": false, + "properties": { + "duration": { + "description": "Duration of the rule snooze schedule.", + "type": "number" + }, + "id": { + "description": "Identifier of the rule snooze schedule.", + "type": "string" + }, + "rRule": { + "additionalProperties": false, "properties": { - "data_stream": { - "additionalProperties": true, - "properties": { - "namespace": { - "type": "string" - } + "byhour": { + "items": { + "description": "Indicates hours of the day to recur.", + "type": "number" }, - "required": [ - "namespace" - ], - "type": "object" - }, - "id": { - "type": "string" + "type": "array" }, - "meta": { - "additionalProperties": true, - "properties": { - "package": { - "additionalProperties": true, - "properties": { - "name": { - "type": "string" - }, - "version": { - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - } + "byminute": { + "items": { + "description": "Indicates minutes of the hour to recur.", + "type": "number" }, - "required": [ - "package" - ], - "type": "object" + "type": "array" }, - "name": { - "type": "string" + "bymonth": { + "items": { + "description": "Indicates months of the year that this rule should recur.", + "type": "number" + }, + "type": "array" }, - "package_policy_id": { - "type": "string" + "bymonthday": { + "items": { + "description": "Indicates the days of the month to recur.", + "type": "number" + }, + "type": "array" }, - "processors": { + "bysecond": { "items": { - "additionalProperties": true, - "properties": { - "add_fields": { - "additionalProperties": true, - "properties": { - "fields": { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "number" - } - ] - }, - "type": "object" - }, - "target": { - "type": "string" - } - }, - "required": [ - "target", - "fields" - ], - "type": "object" - } - }, - "required": [ - "add_fields" - ], - "type": "object" + "description": "Indicates seconds of the day to recur.", + "type": "number" }, "type": "array" }, - "revision": { - "type": "number" + "bysetpos": { + "items": { + "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", + "type": "number" + }, + "type": "array" }, - "streams": { + "byweekday": { "items": { - "additionalProperties": true, - "properties": { - "data_stream": { - "additionalProperties": true, - "properties": { - "dataset": { - "type": "string" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset" - ], - "type": "object" - }, - "id": { + "anyOf": [ + { "type": "string" + }, + { + "type": "number" } - }, - "required": [ - "id", - "data_stream" ], - "type": "object" + "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." + }, + "type": "array" + }, + "byweekno": { + "items": { + "description": "Indicates number of the week hours to recur.", + "type": "number" + }, + "type": "array" + }, + "byyearday": { + "items": { + "description": "Indicates the days of the year that this rule should recur.", + "type": "number" }, "type": "array" }, - "type": { + "count": { + "description": "Number of times the rule should recur until it stops.", + "type": "number" + }, + "dtstart": { + "description": "Rule start date in Coordinated Universal Time (UTC).", + "type": "string" + }, + "freq": { + "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", + "enum": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ], + "type": "integer" + }, + "interval": { + "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", + "type": "number" + }, + "tzid": { + "description": "Indicates timezone abbreviation.", + "type": "string" + }, + "until": { + "description": "Recur the rule until this date.", "type": "string" }, - "use_output": { + "wkst": { + "description": "Indicates the start of week, defaults to Monday.", + "enum": [ + "MO", + "TU", + "WE", + "TH", + "FR", + "SA", + "SU" + ], "type": "string" } }, "required": [ - "id", - "name", - "revision", - "type", - "data_stream", - "use_output", - "package_policy_id" + "dtstart", + "tzid" ], "type": "object" }, - "type": "array" - }, - "type": "array" - }, - "body": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" + "skipRecurrences": { + "items": { + "description": "Skips recurrence of rule on this date.", + "type": "string" + }, + "type": "array" } }, "required": [ - "message" + "duration", + "rRule" ], "type": "object" }, - "diff": { - "items": { - "anyOf": [ - { + "type": "array" + }, + "tags": { + "items": { + "description": "The tags for the rule.", + "type": "string" + }, + "type": "array" + }, + "throttle": { + "deprecated": true, + "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + }, + "updated_at": { + "description": "The date and time that the rule was updated most recently.", + "type": "string" + }, + "updated_by": { + "description": "The identifier for the user that updated this rule most recently.", + "nullable": true, + "type": "string" + }, + "view_in_app_relative_url": { + "description": "Relative URL to view rule in the app.", + "nullable": true, + "type": "string" + } + }, + "required": [ + "id", + "enabled", + "name", + "tags", + "rule_type_id", + "consumer", + "schedule", + "actions", + "params", + "created_by", + "updated_by", + "created_at", + "updated_at", + "api_key_owner", + "mute_all", + "muted_alert_ids", + "execution_status", + "revision" + ], + "type": "object" + } + } + }, + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." + } + }, + "summary": "Get rule details", + "tags": [ + "alerting" + ] + }, + "post": { + "operationId": "post-alerting-rule-id", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "The identifier for the rule. If it is omitted, an ID is randomly generated.", + "in": "path", + "name": "id", + "required": false, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "actions": { + "default": [], + "items": { + "additionalProperties": false, + "description": "An action that runs under defined conditions.", + "properties": { + "alerts_filter": { + "additionalProperties": false, + "description": "Conditions that affect whether the action runs. If you specify multiple conditions, all conditions must be met for the action to run. For example, if an alert occurs within the specified time frame and matches the query, the action runs.", + "properties": { + "query": { "additionalProperties": false, "properties": { - "agents": { - "type": "number" - }, - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "anyOf": [ - { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" - }, - "type": "array" - }, - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" - }, - "streams": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, + "dsl": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", "type": "string" }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { + "filters": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", "items": { "additionalProperties": false, "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - }, - "type": "array" - }, - "spaceIds": { - "items": { - "type": "string" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "anyOf": [ - { - "additionalProperties": { + "$state": { "additionalProperties": false, "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" + "store": { + "description": "A filter can be either specific to an application context or applied globally.", + "enum": [ + "appState", + "globalState" ], - "type": "object" + "type": "string" } + }, + "required": [ + "store" ], - "nullable": true + "type": "object" }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object", - "x-oas-optional": true - } - ] + "meta": { + "additionalProperties": {}, + "type": "object" + }, + "query": { + "additionalProperties": {}, + "type": "object" + } + }, + "required": [ + "meta" + ], + "type": "object" + }, + "type": "array" }, - "version": { + "kql": { + "description": "A filter written in Kibana Query Language (KQL).", "type": "string" } }, "required": [ - "name", - "enabled", - "inputs", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" + "kql", + "filters" ], "type": "object" }, - { + "timeframe": { "additionalProperties": false, + "description": "Defines a period that limits whether the action runs.", "properties": { - "description": { - "description": "Package policy description", - "type": "string" - }, - "enabled": { - "type": "boolean" - }, - "errors": { + "days": { + "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", "items": { - "additionalProperties": false, - "properties": { - "key": { - "type": "string" - }, - "message": { - "type": "string" - } - }, - "required": [ - "message" + "enum": [ + 1, + 2, + 3, + 4, + 5, + 6, + 7 ], - "type": "object" + "type": "integer" + }, + "type": "array" + }, + "hours": { + "additionalProperties": false, + "description": "Defines the range of time in a day that the action can run. If the `start` value is `00:00` and the `end` value is `24:00`, actions be generated all day.", + "properties": { + "end": { + "description": "The end of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + }, + "start": { + "description": "The start of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + } + }, + "required": [ + "start", + "end" + ], + "type": "object" + }, + "timezone": { + "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", + "type": "string" + } + }, + "required": [ + "days", + "hours", + "timezone" + ], + "type": "object" + } + }, + "type": "object" + }, + "frequency": { + "additionalProperties": false, + "properties": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "type": "string" + }, + "summary": { + "description": "Indicates whether the action is a summary.", + "type": "boolean" + }, + "throttle": { + "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if `notify_when` is set to `onThrottleInterval`. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + } + }, + "required": [ + "summary", + "notify_when", + "throttle" + ], + "type": "object" + }, + "group": { + "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", + "type": "string" + }, + "id": { + "description": "The identifier for the connector saved object.", + "type": "string" + }, + "params": { + "additionalProperties": {}, + "default": {}, + "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", + "type": "object" + }, + "use_alert_data_for_template": { + "description": "Indicates whether to use alert data as a template.", + "type": "boolean" + }, + "uuid": { + "description": "A universally unique identifier (UUID) for the action.", + "type": "string" + } + }, + "required": [ + "id" + ], + "type": "object" + }, + "type": "array" + }, + "alert_delay": { + "additionalProperties": false, + "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", + "properties": { + "active": { + "description": "The number of consecutive runs that must meet the rule conditions.", + "type": "number" + } + }, + "required": [ + "active" + ], + "type": "object" + }, + "consumer": { + "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", + "type": "string" + }, + "enabled": { + "default": true, + "description": "Indicates whether you want to run the rule on an interval basis after it is created.", + "type": "boolean" + }, + "flapping": { + "additionalProperties": false, + "nullable": true, + "properties": { + "look_back_window": { + "maximum": 20, + "minimum": 2, + "type": "number" + }, + "status_change_threshold": { + "maximum": 20, + "minimum": 2, + "type": "number" + } + }, + "required": [ + "look_back_window", + "status_change_threshold" + ], + "type": "object" + }, + "name": { + "description": "The name of the rule. While this name does not have to be unique, a distinctive name can help you identify a rule.", + "type": "string" + }, + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "nullable": true, + "type": "string" + }, + "params": { + "additionalProperties": {}, + "default": {}, + "description": "The parameters for the rule.", + "type": "object" + }, + "rule_type_id": { + "description": "The rule type identifier.", + "type": "string" + }, + "schedule": { + "additionalProperties": false, + "description": "The check interval, which specifies how frequently the rule conditions are checked.", + "properties": { + "interval": { + "description": "The interval is specified in seconds, minutes, hours, or days.", + "type": "string" + } + }, + "required": [ + "interval" + ], + "type": "object" + }, + "tags": { + "default": [], + "description": "The tags for the rule.", + "items": { + "type": "string" + }, + "type": "array" + }, + "throttle": { + "description": "Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + } + }, + "required": [ + "name", + "rule_type_id", + "consumer", + "schedule" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "actions": { + "items": { + "additionalProperties": false, + "properties": { + "alerts_filter": { + "additionalProperties": false, + "description": "Defines a period that limits whether the action runs.", + "properties": { + "query": { + "additionalProperties": false, + "properties": { + "dsl": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", + "type": "string" }, - "type": "array" - }, - "force": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { + "filters": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", + "items": { + "additionalProperties": false, + "properties": { + "$state": { "additionalProperties": false, "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { + "store": { + "description": "A filter can be either specific to an application context or applied globally.", "enum": [ - "ga", - "beta", - "experimental" + "appState", + "globalState" ], "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" } }, "required": [ - "enabled", - "data_stream", - "compiled_stream" + "store" ], "type": "object" }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], + "meta": { + "additionalProperties": {}, "type": "object" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } + "query": { + "additionalProperties": {}, + "type": "object" + } + }, + "required": [ + "meta" + ], + "type": "object" }, - "required": [ - "type", - "enabled", - "streams" - ], - "type": "object" + "type": "array" }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "missingVars": { - "items": { + "kql": { + "description": "A filter written in Kibana Query Language (KQL).", "type": "string" - }, - "type": "array" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" + } }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" + "required": [ + "kql", + "filters" + ], + "type": "object" + }, + "timeframe": { + "additionalProperties": false, + "properties": { + "days": { + "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", + "items": { + "enum": [ + 1, + 2, + 3, + 4, + 5, + 6, + 7 + ], + "type": "integer" }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" + "type": "array" }, - "type": "array" - }, - "vars": { - "additionalProperties": { + "hours": { "additionalProperties": false, "properties": { - "frozen": { - "type": "boolean" - }, - "type": { + "end": { + "description": "The end of the time frame in 24-hour notation (`hh:mm`).", "type": "string" }, - "value": {} + "start": { + "description": "The start of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + } }, "required": [ - "value" + "start", + "end" ], "type": "object" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } + "timezone": { + "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", + "type": "string" + } + }, + "required": [ + "days", + "hours", + "timezone" + ], + "type": "object" + } + }, + "type": "object" + }, + "connector_type_id": { + "description": "The type of connector. This property appears in responses but cannot be set in requests.", + "type": "string" + }, + "frequency": { + "additionalProperties": false, + "properties": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "type": "string" }, - "required": [ - "name", - "enabled", - "inputs" - ], - "type": "object" - } - ] + "summary": { + "description": "Indicates whether the action is a summary.", + "type": "boolean" + }, + "throttle": { + "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + } + }, + "required": [ + "summary", + "notify_when", + "throttle" + ], + "type": "object" + }, + "group": { + "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", + "type": "string" + }, + "id": { + "description": "The identifier for the connector saved object.", + "type": "string" + }, + "params": { + "additionalProperties": {}, + "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", + "type": "object" + }, + "use_alert_data_for_template": { + "description": "Indicates whether to use alert data as a template.", + "type": "boolean" + }, + "uuid": { + "description": "A universally unique identifier (UUID) for the action.", + "type": "string" + } }, - "type": "array" - }, - "hasErrors": { - "type": "boolean" + "required": [ + "id", + "connector_type_id", + "params" + ], + "type": "object" }, - "name": { + "type": "array" + }, + "active_snoozes": { + "items": { + "description": "List of active snoozes for the rule.", "type": "string" }, - "statusCode": { - "type": "number" - } + "type": "array" }, - "required": [ - "hasErrors" - ], - "type": "object" - }, - "type": "array" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" + "alert_delay": { + "additionalProperties": false, + "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", + "properties": { + "active": { + "description": "The number of consecutive runs that must meet the rule conditions.", + "type": "number" + } + }, + "required": [ + "active" + ], + "type": "object" + }, + "api_key_created_by_user": { + "description": "Indicates whether the API key that is associated with the rule was created by the user.", + "nullable": true, + "type": "boolean" }, - "message": { + "api_key_owner": { + "description": "The owner of the API key that is associated with the rule and used to run background tasks.", + "nullable": true, "type": "string" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet package policies" - ] - } - }, - "/api/fleet/package_policies/{packagePolicyId}": { - "delete": { - "description": "Delete package policy by ID", - "operationId": "delete-fleet-package-policies-packagepolicyid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - }, - { - "in": "path", - "name": "packagePolicyId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "force", - "required": false, - "schema": { - "type": "boolean" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "id": { + "consumer": { + "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + }, + "created_at": { + "description": "The date and time that the rule was created.", "type": "string" }, - "message": { + "created_by": { + "description": "The identifier for the user that created the rule.", + "nullable": true, "type": "string" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet package policies" - ] - }, - "get": { - "description": "Get package policy by ID", - "operationId": "get-fleet-package-policies-packagepolicyid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "packagePolicyId", - "required": true, - "schema": { - "type": "string" - } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { + "enabled": { + "description": "Indicates whether you want to run the rule on an interval basis after it is created.", + "type": "boolean" + }, + "execution_status": { + "additionalProperties": false, + "properties": { + "error": { + "additionalProperties": false, + "properties": { + "message": { + "description": "Error message.", + "type": "string" + }, + "reason": { + "description": "Reason for error.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate" + ], + "type": "string" + } + }, + "required": [ + "reason", + "message" + ], + "type": "object" + }, + "last_duration": { + "description": "Duration of last execution of the rule.", + "type": "number" + }, + "last_execution_date": { + "description": "The date and time when rule was executed last.", + "type": "string" + }, + "status": { + "description": "Status of rule execution.", + "enum": [ + "ok", + "active", + "error", + "warning", + "pending", + "unknown" + ], + "type": "string" + }, + "warning": { + "additionalProperties": false, + "properties": { + "message": { + "description": "Warning message.", + "type": "string" + }, + "reason": { + "description": "Reason for warning.", + "enum": [ + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "type": "string" + } + }, + "required": [ + "reason", + "message" + ], + "type": "object" + } + }, + "required": [ + "status", + "last_execution_date" + ], + "type": "object" + }, + "flapping": { "additionalProperties": false, + "nullable": true, "properties": { - "agents": { + "look_back_window": { + "maximum": 20, + "minimum": 2, "type": "number" }, - "created_at": { - "type": "string" + "status_change_threshold": { + "maximum": 20, + "minimum": 2, + "type": "number" + } + }, + "required": [ + "look_back_window", + "status_change_threshold" + ], + "type": "object" + }, + "id": { + "description": "The identifier for the rule.", + "type": "string" + }, + "is_snoozed_until": { + "description": "The date when the rule will no longer be snoozed.", + "nullable": true, + "type": "string" + }, + "last_run": { + "additionalProperties": false, + "nullable": true, + "properties": { + "alerts_count": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" + }, + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, + "type": "number" + }, + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" + }, + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } + }, + "type": "object" }, - "created_by": { + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], "type": "string" }, - "description": { - "description": "Package policy description", - "type": "string" + "outcome_msg": { + "items": { + "description": "Outcome message generated during last rule run.", + "type": "string" + }, + "nullable": true, + "type": "array" }, - "elasticsearch": { - "additionalProperties": true, + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" + }, + "warning": { + "description": "Warning of last rule execution.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "nullable": true, + "type": "string" + } + }, + "required": [ + "outcome", + "alerts_count" + ], + "type": "object" + }, + "mapped_params": { + "additionalProperties": {}, + "type": "object" + }, + "monitoring": { + "additionalProperties": false, + "description": "Monitoring details of the rule.", + "properties": { + "run": { + "additionalProperties": false, + "description": "Rule run details.", "properties": { - "privileges": { - "additionalProperties": true, + "calculated_metrics": { + "additionalProperties": false, + "description": "Calculation of different percentiles and success ratio.", "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" + "p50": { + "type": "number" + }, + "p95": { + "type": "number" + }, + "p99": { + "type": "number" + }, + "success_ratio": { + "type": "number" } }, + "required": [ + "success_ratio" + ], "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "anyOf": [ - { + }, + "history": { + "description": "History of the rule run.", "items": { "additionalProperties": false, "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" + "duration": { + "description": "Duration of the rule run.", + "type": "number" }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" + "outcome": { + "additionalProperties": false, + "properties": { + "alerts_count": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, + "type": "number" }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } }, - "type": { + "type": "object" + }, + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], + "type": "string" + }, + "outcome_msg": { + "items": { + "description": "Outcome message generated during last rule run.", "type": "string" }, - "value": {} + "nullable": true, + "type": "array" }, - "required": [ - "value" - ], - "type": "object" + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" + }, + "warning": { + "description": "Warning of last rule execution.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "nullable": true, + "type": "string" + } }, - "description": "Package variable (see integration documentation for more information)", + "required": [ + "outcome", + "alerts_count" + ], "type": "object" + }, + "success": { + "description": "Indicates whether the rule run was successful.", + "type": "boolean" + }, + "timestamp": { + "description": "Time of rule run.", + "type": "number" } }, "required": [ - "type", - "enabled", - "streams", - "compiled_input" + "success", + "timestamp" ], "type": "object" }, "type": "array" }, - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" - }, - "streams": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" + "last_run": { + "additionalProperties": false, + "properties": { + "metrics": { + "additionalProperties": false, + "properties": { + "duration": { + "description": "Duration of most recent rule run.", + "type": "number" }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true + "gap_duration_s": { + "description": "Duration in seconds of rule run gap.", + "nullable": true, + "type": "number" }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } + "total_alerts_created": { + "description": "Total number of alerts created during last rule run.", + "nullable": true, + "type": "number" + }, + "total_alerts_detected": { + "description": "Total number of alerts detected during last rule run.", + "nullable": true, + "type": "number" + }, + "total_indexing_duration_ms": { + "description": "Total time spent indexing documents during last rule run in milliseconds.", + "nullable": true, + "type": "number" + }, + "total_search_duration_ms": { + "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", + "nullable": true, + "type": "number" + } + }, + "type": "object" }, - "type": "object" + "timestamp": { + "description": "Time of the most recent rule run.", + "type": "string" + } }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, + "required": [ + "timestamp", + "metrics" + ], "type": "object" } }, + "required": [ + "history", + "calculated_metrics", + "last_run" + ], "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } + } + }, + "required": [ + "run" + ], + "type": "object" + }, + "mute_all": { + "description": "Indicates whether all alerts are muted.", + "type": "boolean" + }, + "muted_alert_ids": { + "items": { + "description": "List of identifiers of muted alerts. ", + "type": "string" + }, + "type": "array" + }, + "name": { + "description": " The name of the rule.", + "type": "string" + }, + "next_run": { + "description": "Date and time of the next run of the rule.", + "nullable": true, + "type": "string" + }, + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "nullable": true, + "type": "string" + }, + "params": { + "additionalProperties": {}, + "description": "The parameters for the rule.", + "type": "object" + }, + "revision": { + "description": "The rule revision number.", + "type": "number" + }, + "rule_type_id": { + "description": "The rule type identifier.", + "type": "string" + }, + "running": { + "description": "Indicates whether the rule is running.", + "nullable": true, + "type": "boolean" + }, + "schedule": { + "additionalProperties": false, + "properties": { + "interval": { + "description": "The interval is specified in seconds, minutes, hours, or days.", + "type": "string" + } + }, + "required": [ + "interval" + ], + "type": "object" + }, + "scheduled_task_id": { + "description": "Identifier of the scheduled task.", + "type": "string" + }, + "snooze_schedule": { + "items": { + "additionalProperties": false, + "properties": { + "duration": { + "description": "Duration of the rule snooze schedule.", + "type": "number" + }, + "id": { + "description": "Identifier of the rule snooze schedule.", + "type": "string" + }, + "rRule": { + "additionalProperties": false, + "properties": { + "byhour": { + "items": { + "description": "Indicates hours of the day to recur.", + "type": "number" + }, + "type": "array" + }, + "byminute": { + "items": { + "description": "Indicates minutes of the hour to recur.", + "type": "number" + }, + "type": "array" + }, + "bymonth": { + "items": { + "description": "Indicates months of the year that this rule should recur.", + "type": "number" + }, + "type": "array" + }, + "bymonthday": { + "items": { + "description": "Indicates the days of the month to recur.", + "type": "number" + }, + "type": "array" + }, + "bysecond": { + "items": { + "description": "Indicates seconds of the day to recur.", + "type": "number" + }, + "type": "array" + }, + "bysetpos": { + "items": { + "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", + "type": "number" + }, + "type": "array" + }, + "byweekday": { + "items": { + "anyOf": [ + { + "type": "string" }, - "type": "object" - } + { + "type": "number" + } + ], + "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." }, - "required": [ - "data_stream", - "features" + "type": "array" + }, + "byweekno": { + "items": { + "description": "Indicates number of the week hours to recur.", + "type": "number" + }, + "type": "array" + }, + "byyearday": { + "items": { + "description": "Indicates the days of the year that this rule should recur.", + "type": "number" + }, + "type": "array" + }, + "count": { + "description": "Number of times the rule should recur until it stops.", + "type": "number" + }, + "dtstart": { + "description": "Rule start date in Coordinated Universal Time (UTC).", + "type": "string" + }, + "freq": { + "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", + "enum": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 ], - "type": "object" + "type": "integer" }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { + "interval": { + "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", + "type": "number" + }, + "tzid": { + "description": "Indicates timezone abbreviation.", + "type": "string" + }, + "until": { + "description": "Recur the rule until this date.", + "type": "string" + }, + "wkst": { + "description": "Indicates the start of week, defaults to Monday.", + "enum": [ + "MO", + "TU", + "WE", + "TH", + "FR", + "SA", + "SU" + ], "type": "string" } }, "required": [ - "id" + "dtstart", + "tzid" ], "type": "object" }, - "type": "array" - }, - "spaceIds": { - "items": { - "type": "string" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "anyOf": [ - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" + "skipRecurrences": { + "items": { + "description": "Skips recurrence of rule on this date.", + "type": "string" }, - { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object", - "x-oas-optional": true - } - ] + "type": "array" + } }, - "version": { - "type": "string" - } + "required": [ + "duration", + "rRule" + ], + "type": "object" }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + "type": "array" + }, + "tags": { + "items": { + "description": "The tags for the rule.", + "type": "string" + }, + "type": "array" + }, + "throttle": { + "deprecated": true, + "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, "type": "string" }, - "message": { + "updated_at": { + "description": "The date and time that the rule was updated most recently.", "type": "string" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "message": { + "updated_by": { + "description": "The identifier for the user that updated this rule most recently.", + "nullable": true, + "type": "string" + }, + "view_in_app_relative_url": { + "description": "Relative URL to view rule in the app.", + "nullable": true, "type": "string" } }, "required": [ - "message" + "id", + "enabled", + "name", + "tags", + "rule_type_id", + "consumer", + "schedule", + "actions", + "params", + "created_by", + "updated_by", + "created_at", + "updated_at", + "api_key_owner", + "mute_all", + "muted_alert_ids", + "execution_status", + "revision" ], "type": "object" } } - } + }, + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "409": { + "description": "Indicates that the rule id is already in use." } }, - "summary": "", + "summary": "Create a rule", "tags": [ - "Fleet package policies" + "alerting" ] }, "put": { - "description": "Update package policy by ID", - "operationId": "put-fleet-package-policies-packagepolicyid", + "operationId": "put-alerting-rule-id", "parameters": [ { "description": "The version of the API to use", @@ -37714,1256 +3709,1394 @@ } }, { + "description": "The identifier for the rule.", "in": "path", - "name": "packagePolicyId", + "name": "id", "required": true, "schema": { "type": "string" } - }, - { - "in": "query", - "name": "format", - "required": false, - "schema": { - "enum": [ - "simplified", - "legacy" - ], - "type": "string" - } } ], "requestBody": { "content": { "application/json; Elastic-Api-Version=2023-10-31": { "schema": { - "anyOf": [ - { + "additionalProperties": false, + "properties": { + "actions": { + "default": [], + "items": { + "additionalProperties": false, + "description": "An action that runs under defined conditions.", + "properties": { + "alerts_filter": { + "additionalProperties": false, + "properties": { + "query": { + "additionalProperties": false, + "properties": { + "dsl": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", + "type": "string" + }, + "filters": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", + "items": { + "additionalProperties": false, + "properties": { + "$state": { + "additionalProperties": false, + "properties": { + "store": { + "description": "A filter can be either specific to an application context or applied globally.", + "enum": [ + "appState", + "globalState" + ], + "type": "string" + } + }, + "required": [ + "store" + ], + "type": "object" + }, + "meta": { + "additionalProperties": {}, + "type": "object" + }, + "query": { + "additionalProperties": {}, + "type": "object" + } + }, + "required": [ + "meta" + ], + "type": "object" + }, + "type": "array" + }, + "kql": { + "description": "A filter written in Kibana Query Language (KQL).", + "type": "string" + } + }, + "required": [ + "kql", + "filters" + ], + "type": "object" + }, + "timeframe": { + "additionalProperties": false, + "description": "Defines a period that limits whether the action runs.", + "properties": { + "days": { + "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", + "items": { + "enum": [ + 1, + 2, + 3, + 4, + 5, + 6, + 7 + ], + "type": "integer" + }, + "type": "array" + }, + "hours": { + "additionalProperties": false, + "description": "Defines the range of time in a day that the action can run. If the `start` value is `00:00` and the `end` value is `24:00`, actions be generated all day.", + "properties": { + "end": { + "description": "The end of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + }, + "start": { + "description": "The start of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + } + }, + "required": [ + "start", + "end" + ], + "type": "object" + }, + "timezone": { + "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", + "type": "string" + } + }, + "required": [ + "days", + "hours", + "timezone" + ], + "type": "object" + } + }, + "type": "object" + }, + "frequency": { + "additionalProperties": false, + "properties": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "type": "string" + }, + "summary": { + "description": "Indicates whether the action is a summary.", + "type": "boolean" + }, + "throttle": { + "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if `notify_when` is set to `onThrottleInterval`. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + } + }, + "required": [ + "summary", + "notify_when", + "throttle" + ], + "type": "object" + }, + "group": { + "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", + "type": "string" + }, + "id": { + "description": "The identifier for the connector saved object.", + "type": "string" + }, + "params": { + "additionalProperties": {}, + "default": {}, + "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", + "type": "object" + }, + "use_alert_data_for_template": { + "description": "Indicates whether to use alert data as a template.", + "type": "boolean" + }, + "uuid": { + "description": "A universally unique identifier (UUID) for the action.", + "type": "string" + } + }, + "required": [ + "id" + ], + "type": "object" + }, + "type": "array" + }, + "alert_delay": { + "additionalProperties": false, + "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", + "properties": { + "active": { + "description": "The number of consecutive runs that must meet the rule conditions.", + "type": "number" + } + }, + "required": [ + "active" + ], + "type": "object" + }, + "flapping": { + "additionalProperties": false, + "nullable": true, + "properties": { + "look_back_window": { + "maximum": 20, + "minimum": 2, + "type": "number" + }, + "status_change_threshold": { + "maximum": 20, + "minimum": 2, + "type": "number" + } + }, + "required": [ + "look_back_window", + "status_change_threshold" + ], + "type": "object" + }, + "name": { + "description": "The name of the rule. While this name does not have to be unique, a distinctive name can help you identify a rule.", + "type": "string" + }, + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "nullable": true, + "type": "string" + }, + "params": { + "additionalProperties": {}, + "default": {}, + "description": "The parameters for the rule.", + "type": "object" + }, + "schedule": { "additionalProperties": false, "properties": { - "description": { - "description": "Package policy description", + "interval": { + "description": "The interval is specified in seconds, minutes, hours, or days.", "type": "string" - }, - "enabled": { - "type": "boolean" - }, - "force": { - "type": "boolean" - }, - "inputs": { - "items": { - "additionalProperties": false, - "properties": { - "config": { - "additionalProperties": { + } + }, + "required": [ + "interval" + ], + "type": "object" + }, + "tags": { + "default": [], + "items": { + "description": "The tags for the rule.", + "type": "string" + }, + "type": "array" + }, + "throttle": { + "description": "Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + } + }, + "required": [ + "name", + "schedule" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "properties": { + "actions": { + "items": { + "additionalProperties": false, + "properties": { + "alerts_filter": { + "additionalProperties": false, + "description": "Defines a period that limits whether the action runs.", + "properties": { + "query": { "additionalProperties": false, "properties": { - "frozen": { - "type": "boolean" - }, - "type": { + "dsl": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", "type": "string" }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { + "filters": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", + "items": { "additionalProperties": false, "properties": { - "frozen": { - "type": "boolean" + "$state": { + "additionalProperties": false, + "properties": { + "store": { + "description": "A filter can be either specific to an application context or applied globally.", + "enum": [ + "appState", + "globalState" + ], + "type": "string" + } + }, + "required": [ + "store" + ], + "type": "object" }, - "type": { - "type": "string" + "meta": { + "additionalProperties": {}, + "type": "object" }, - "value": {} + "query": { + "additionalProperties": {}, + "type": "object" + } }, "required": [ - "value" + "meta" ], "type": "object" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" + "type": "array" + }, + "kql": { + "description": "A filter written in Kibana Query Language (KQL).", + "type": "string" + } + }, + "required": [ + "kql", + "filters" + ], + "type": "object" + }, + "timeframe": { + "additionalProperties": false, + "properties": { + "days": { + "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", + "items": { + "enum": [ + 1, + 2, + 3, + 4, + 5, + 6, + 7 + ], + "type": "integer" + }, + "type": "array" }, - "data_stream": { + "hours": { "additionalProperties": false, "properties": { - "dataset": { + "end": { + "description": "The end of the time frame in 24-hour notation (`hh:mm`).", "type": "string" }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { + "start": { + "description": "The start of the time frame in 24-hour notation (`hh:mm`).", "type": "string" } }, "required": [ - "dataset", - "type" + "start", + "end" ], "type": "object" }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], + "timezone": { + "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" } }, "required": [ - "enabled", - "data_stream", - "compiled_stream" + "days", + "hours", + "timezone" ], "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" + } }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" + "type": "object" + }, + "connector_type_id": { + "description": "The type of connector. This property appears in responses but cannot be set in requests.", + "type": "string" + }, + "frequency": { + "additionalProperties": false, + "properties": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" ], - "type": "object" + "type": "string" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "type", - "enabled" - ], - "type": "object" - }, - "type": "array" - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } + "summary": { + "description": "Indicates whether the action is a summary.", + "type": "boolean" }, - "required": [ - "data_stream", - "features" - ], - "type": "object" + "throttle": { + "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" + } }, - "type": "array" + "required": [ + "summary", + "notify_when", + "throttle" + ], + "type": "object" }, - "name": { - "description": "Package name", + "group": { + "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", "type": "string" }, - "requires_root": { - "type": "boolean" - }, - "title": { + "id": { + "description": "The identifier for the connector saved object.", "type": "string" }, - "version": { - "description": "Package version", + "params": { + "additionalProperties": {}, + "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", + "type": "object" + }, + "use_alert_data_for_template": { + "description": "Indicates whether to use alert data as a template.", + "type": "boolean" + }, + "uuid": { + "description": "A universally unique identifier (UUID) for the action.", "type": "string" } }, "required": [ - "name", - "version" + "id", + "connector_type_id", + "params" ], "type": "object" }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, + "type": "array" + }, + "active_snoozes": { + "items": { + "description": "List of active snoozes for the rule.", "type": "string" }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" + "type": "array" + }, + "alert_delay": { + "additionalProperties": false, + "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", + "properties": { + "active": { + "description": "The number of consecutive runs that must meet the rule conditions.", + "type": "number" + } }, - "vars": { - "additionalProperties": { + "required": [ + "active" + ], + "type": "object" + }, + "api_key_created_by_user": { + "description": "Indicates whether the API key that is associated with the rule was created by the user.", + "nullable": true, + "type": "boolean" + }, + "api_key_owner": { + "description": "The owner of the API key that is associated with the rule and used to run background tasks.", + "nullable": true, + "type": "string" + }, + "consumer": { + "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", + "type": "string" + }, + "created_at": { + "description": "The date and time that the rule was created.", + "type": "string" + }, + "created_by": { + "description": "The identifier for the user that created the rule.", + "nullable": true, + "type": "string" + }, + "enabled": { + "description": "Indicates whether you want to run the rule on an interval basis after it is created.", + "type": "boolean" + }, + "execution_status": { + "additionalProperties": false, + "properties": { + "error": { "additionalProperties": false, "properties": { - "frozen": { - "type": "boolean" + "message": { + "description": "Error message.", + "type": "string" }, - "type": { + "reason": { + "description": "Reason for error.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate" + ], + "type": "string" + } + }, + "required": [ + "reason", + "message" + ], + "type": "object" + }, + "last_duration": { + "description": "Duration of last execution of the rule.", + "type": "number" + }, + "last_execution_date": { + "description": "The date and time when rule was executed last.", + "type": "string" + }, + "status": { + "description": "Status of rule execution.", + "enum": [ + "ok", + "active", + "error", + "warning", + "pending", + "unknown" + ], + "type": "string" + }, + "warning": { + "additionalProperties": false, + "properties": { + "message": { + "description": "Warning message.", "type": "string" }, - "value": {} + "reason": { + "description": "Reason for warning.", + "enum": [ + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "type": "string" + } }, "required": [ - "value" + "reason", + "message" ], "type": "object" + } + }, + "required": [ + "status", + "last_execution_date" + ], + "type": "object" + }, + "flapping": { + "additionalProperties": false, + "nullable": true, + "properties": { + "look_back_window": { + "maximum": 20, + "minimum": 2, + "type": "number" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" + "status_change_threshold": { + "maximum": 20, + "minimum": 2, + "type": "number" + } + }, + "required": [ + "look_back_window", + "status_change_threshold" + ], + "type": "object" + }, + "id": { + "description": "The identifier for the rule.", + "type": "string" + }, + "is_snoozed_until": { + "description": "The date when the rule will no longer be snoozed.", + "nullable": true, + "type": "string" + }, + "last_run": { + "additionalProperties": false, + "nullable": true, + "properties": { + "alerts_count": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" + }, + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, + "type": "number" + }, + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" + }, + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } + }, + "type": "object" + }, + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], + "type": "string" + }, + "outcome_msg": { + "items": { + "description": "Outcome message generated during last rule run.", + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" + }, + "warning": { + "description": "Warning of last rule execution.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "nullable": true, + "type": "string" + } }, - "version": { - "type": "string" - } + "required": [ + "outcome", + "alerts_count" + ], + "type": "object" }, - "type": "object" - }, - { - "additionalProperties": false, - "properties": { - "description": { - "type": "string" - }, - "force": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "additionalProperties": { + "mapped_params": { + "additionalProperties": {}, + "type": "object" + }, + "monitoring": { + "additionalProperties": false, + "description": "Monitoring details of the rule.", + "properties": { + "run": { "additionalProperties": false, + "description": "Rule run details.", "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" + "calculated_metrics": { + "additionalProperties": false, + "description": "Calculation of different percentiles and success ratio.", + "properties": { + "p50": { + "type": "number" + }, + "p95": { + "type": "number" + }, + "p99": { + "type": "number" + }, + "success_ratio": { + "type": "number" + } + }, + "required": [ + "success_ratio" + ], + "type": "object" }, - "streams": { - "additionalProperties": { + "history": { + "description": "History of the rule run.", + "items": { "additionalProperties": false, "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" + "duration": { + "description": "Duration of the rule run.", + "type": "number" }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" + "outcome": { + "additionalProperties": false, + "properties": { + "alerts_count": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" }, - "type": "array" - }, - { - "items": { + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, "type": "number" }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } + }, + "type": "object" + }, + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], + "type": "string" + }, + "outcome_msg": { + "items": { + "description": "Outcome message generated during last rule run.", + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" + }, + "warning": { + "description": "Warning of last rule execution.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "nullable": true, + "type": "string" + } }, - "description": "Input/stream level variable (see integration documentation for more information)", + "required": [ + "outcome", + "alerts_count" + ], "type": "object" + }, + "success": { + "description": "Indicates whether the rule run was successful.", + "type": "boolean" + }, + "timestamp": { + "description": "Time of rule run.", + "type": "number" } }, + "required": [ + "success", + "timestamp" + ], "type": "object" }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" + "type": "array" }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" + "last_run": { + "additionalProperties": false, + "properties": { + "metrics": { + "additionalProperties": false, + "properties": { + "duration": { + "description": "Duration of most recent rule run.", + "type": "number" }, - "type": "array" - }, - { - "items": { + "gap_duration_s": { + "description": "Duration in seconds of rule run gap.", + "nullable": true, "type": "number" }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } + "total_alerts_created": { + "description": "Total number of alerts created during last rule run.", + "nullable": true, + "type": "number" }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true + "total_alerts_detected": { + "description": "Total number of alerts detected during last rule run.", + "nullable": true, + "type": "number" + }, + "total_indexing_duration_ms": { + "description": "Total time spent indexing documents during last rule run in milliseconds.", + "nullable": true, + "type": "number" + }, + "total_search_duration_ms": { + "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", + "nullable": true, + "type": "number" + } + }, + "type": "object" + }, + "timestamp": { + "description": "Time of the most recent rule run.", + "type": "string" + } }, - "description": "Input/stream level variable (see integration documentation for more information)", + "required": [ + "timestamp", + "metrics" + ], "type": "object" } }, + "required": [ + "history", + "calculated_metrics", + "last_run" + ], "type": "object" - }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object" - }, - "name": { - "type": "string" + } }, - "namespace": { + "required": [ + "run" + ], + "type": "object" + }, + "mute_all": { + "description": "Indicates whether all alerts are muted.", + "type": "boolean" + }, + "muted_alert_ids": { + "items": { + "description": "List of identifiers of muted alerts. ", "type": "string" }, - "output_id": { - "nullable": true, - "type": "string" + "type": "array" + }, + "name": { + "description": " The name of the rule.", + "type": "string" + }, + "next_run": { + "description": "Date and time of the next run of the rule.", + "nullable": true, + "type": "string" + }, + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "nullable": true, + "type": "string" + }, + "params": { + "additionalProperties": {}, + "description": "The parameters for the rule.", + "type": "object" + }, + "revision": { + "description": "The rule revision number.", + "type": "number" + }, + "rule_type_id": { + "description": "The rule type identifier.", + "type": "string" + }, + "running": { + "description": "Indicates whether the rule is running.", + "nullable": true, + "type": "boolean" + }, + "schedule": { + "additionalProperties": false, + "properties": { + "interval": { + "description": "The interval is specified in seconds, minutes, hours, or days.", + "type": "string" + } }, - "package": { + "required": [ + "interval" + ], + "type": "object" + }, + "scheduled_task_id": { + "description": "Identifier of the scheduled task.", + "type": "string" + }, + "snooze_schedule": { + "items": { "additionalProperties": false, "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } - }, - "required": [ - "data_stream", - "features" - ], - "type": "object" - }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" + "duration": { + "description": "Duration of the rule snooze schedule.", + "type": "number" }, - "title": { + "id": { + "description": "Identifier of the rule snooze schedule.", "type": "string" }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "type": "string" - }, - "type": "array" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" + "rRule": { + "additionalProperties": false, + "properties": { + "byhour": { + "items": { + "description": "Indicates hours of the day to recur.", + "type": "number" + }, + "type": "array" }, - "type": "array" - }, - { - "items": { - "type": "number" + "byminute": { + "items": { + "description": "Indicates minutes of the hour to recur.", + "type": "number" + }, + "type": "array" }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" + "bymonth": { + "items": { + "description": "Indicates months of the year that this rule should recur.", + "type": "number" }, - "isSecretRef": { - "type": "boolean" - } + "type": "array" }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "name", - "package" - ], - "type": "object" - } - ] - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "agents": { - "type": "number" - }, - "created_at": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "description": { - "description": "Package policy description", - "type": "string" - }, - "elasticsearch": { - "additionalProperties": true, - "properties": { - "privileges": { - "additionalProperties": true, - "properties": { - "cluster": { - "items": { - "type": "string" - }, - "type": "array" - } + "bymonthday": { + "items": { + "description": "Indicates the days of the month to recur.", + "type": "number" + }, + "type": "array" }, - "type": "object" - } - }, - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "inputs": { - "anyOf": [ - { - "items": { - "additionalProperties": false, - "properties": { - "compiled_input": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "policy_template": { - "type": "string" - }, - "streams": { - "items": { - "additionalProperties": false, - "properties": { - "compiled_stream": {}, - "config": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - }, - "data_stream": { - "additionalProperties": false, - "properties": { - "dataset": { - "type": "string" - }, - "elasticsearch": { - "additionalProperties": false, - "properties": { - "dynamic_dataset": { - "type": "boolean" - }, - "dynamic_namespace": { - "type": "boolean" - }, - "privileges": { - "additionalProperties": false, - "properties": { - "indices": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - } - }, - "type": "object" - }, - "type": { - "type": "string" - } - }, - "required": [ - "dataset", - "type" - ], - "type": "object" - }, - "enabled": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "keep_enabled": { - "type": "boolean" - }, - "release": { - "enum": [ - "ga", - "beta", - "experimental" - ], - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } - }, - "required": [ - "enabled", - "data_stream", - "compiled_stream" - ], - "type": "object" - }, - "type": "array" - }, - "type": { - "type": "string" - }, - "vars": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" + "bysecond": { + "items": { + "description": "Indicates seconds of the day to recur.", + "type": "number" + }, + "type": "array" + }, + "bysetpos": { + "items": { + "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", + "type": "number" + }, + "type": "array" + }, + "byweekday": { + "items": { + "anyOf": [ + { + "type": "string" }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" - } + { + "type": "number" + } + ], + "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." }, - "required": [ - "type", - "enabled", - "streams", - "compiled_input" - ], - "type": "object" + "type": "array" }, - "type": "array" - }, - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that input, (default to true)", - "type": "boolean" - }, - "streams": { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "enabled": { - "description": "enable or disable that stream, (default to true)", - "type": "boolean" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } - }, - "type": "object" - }, - "description": "Input streams (see integration documentation to know what streams are available)", - "type": "object" - }, - "vars": { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object" - } + "byweekno": { + "items": { + "description": "Indicates number of the week hours to recur.", + "type": "number" }, - "type": "object" + "type": "array" }, - "description": "Package policy inputs (see integration documentation to know what inputs are available)", - "type": "object", - "x-oas-optional": true - } - ] - }, - "is_managed": { - "type": "boolean" - }, - "name": { - "description": "Package policy name (should be unique)", - "type": "string" - }, - "namespace": { - "description": "The package policy namespace. Leave blank to inherit the agent policy's namespace.", - "type": "string" - }, - "output_id": { - "nullable": true, - "type": "string" - }, - "overrides": { - "additionalProperties": false, - "description": "Override settings that are defined in the package policy. The override option should be used only in unusual circumstances and not as a routine procedure.", - "nullable": true, - "properties": { - "inputs": { - "additionalProperties": {}, - "type": "object" - } - }, - "type": "object" - }, - "package": { - "additionalProperties": false, - "properties": { - "experimental_data_stream_features": { - "items": { - "additionalProperties": false, - "properties": { - "data_stream": { - "type": "string" - }, - "features": { - "additionalProperties": false, - "properties": { - "doc_value_only_numeric": { - "type": "boolean" - }, - "doc_value_only_other": { - "type": "boolean" - }, - "synthetic_source": { - "type": "boolean" - }, - "tsdb": { - "type": "boolean" - } - }, - "type": "object" - } + "byyearday": { + "items": { + "description": "Indicates the days of the year that this rule should recur.", + "type": "number" }, - "required": [ - "data_stream", - "features" + "type": "array" + }, + "count": { + "description": "Number of times the rule should recur until it stops.", + "type": "number" + }, + "dtstart": { + "description": "Rule start date in Coordinated Universal Time (UTC).", + "type": "string" + }, + "freq": { + "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", + "enum": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 ], - "type": "object" + "type": "integer" }, - "type": "array" - }, - "name": { - "description": "Package name", - "type": "string" - }, - "requires_root": { - "type": "boolean" - }, - "title": { - "type": "string" - }, - "version": { - "description": "Package version", - "type": "string" - } - }, - "required": [ - "name", - "version" - ], - "type": "object" - }, - "policy_id": { - "deprecated": true, - "description": "Agent policy ID where that package policy will be added", - "nullable": true, - "type": "string" - }, - "policy_ids": { - "items": { - "description": "Agent policy IDs where that package policy will be added", - "type": "string" - }, - "type": "array" - }, - "revision": { - "type": "number" - }, - "secret_references": { - "items": { - "additionalProperties": false, - "properties": { - "id": { + "interval": { + "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", + "type": "number" + }, + "tzid": { + "description": "Indicates timezone abbreviation.", + "type": "string" + }, + "until": { + "description": "Recur the rule until this date.", + "type": "string" + }, + "wkst": { + "description": "Indicates the start of week, defaults to Monday.", + "enum": [ + "MO", + "TU", + "WE", + "TH", + "FR", + "SA", + "SU" + ], "type": "string" } }, "required": [ - "id" + "dtstart", + "tzid" ], "type": "object" }, - "type": "array" - }, - "spaceIds": { - "items": { - "type": "string" - }, - "type": "array" - }, - "updated_at": { - "type": "string" - }, - "updated_by": { - "type": "string" - }, - "vars": { - "anyOf": [ - { - "additionalProperties": { - "additionalProperties": false, - "properties": { - "frozen": { - "type": "boolean" - }, - "type": { - "type": "string" - }, - "value": {} - }, - "required": [ - "value" - ], - "type": "object" - }, - "description": "Package variable (see integration documentation for more information)", - "type": "object" + "skipRecurrences": { + "items": { + "description": "Skips recurrence of rule on this date.", + "type": "string" }, - { - "additionalProperties": { - "anyOf": [ - { - "type": "boolean" - }, - { - "type": "string" - }, - { - "type": "number" - }, - { - "items": { - "type": "string" - }, - "type": "array" - }, - { - "items": { - "type": "number" - }, - "type": "array" - }, - { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - }, - "isSecretRef": { - "type": "boolean" - } - }, - "required": [ - "id", - "isSecretRef" - ], - "type": "object" - } - ], - "nullable": true - }, - "description": "Input/stream level variable (see integration documentation for more information)", - "type": "object", - "x-oas-optional": true - } - ] + "type": "array" + } }, - "version": { - "type": "string" - } + "required": [ + "duration", + "rRule" + ], + "type": "object" + }, + "type": "array" + }, + "tags": { + "items": { + "description": "The tags for the rule.", + "type": "string" }, - "required": [ - "name", - "enabled", - "inputs", - "id", - "revision", - "updated_at", - "updated_by", - "created_at", - "created_by" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" + "type": "array" }, - "message": { + "throttle": { + "deprecated": true, + "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, "type": "string" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "403": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + "updated_at": { + "description": "The date and time that the rule was updated most recently.", "type": "string" }, - "message": { + "updated_by": { + "description": "The identifier for the user that updated this rule most recently.", + "nullable": true, "type": "string" }, - "statusCode": { - "type": "number" + "view_in_app_relative_url": { + "description": "Relative URL to view rule in the app.", + "nullable": true, + "type": "string" } }, "required": [ - "message" + "id", + "enabled", + "name", + "tags", + "rule_type_id", + "consumer", + "schedule", + "actions", + "params", + "created_by", + "updated_by", + "created_at", + "updated_at", + "api_key_owner", + "mute_all", + "muted_alert_ids", + "execution_status", + "revision" ], "type": "object" } } + }, + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." + }, + "409": { + "description": "Indicates that the rule has already been updated by another user." + } + }, + "summary": "Update a rule", + "tags": [ + "alerting" + ] + } + }, + "/api/alerting/rule/{id}/_disable": { + "post": { + "operationId": "post-alerting-rule-id-disable", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "The identifier for the rule.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/json; Elastic-Api-Version=2023-10-31": { + "schema": { + "additionalProperties": false, + "nullable": true, + "properties": { + "untrack": { + "description": "Defines whether this rule's alerts should be untracked.", + "type": "boolean" + } + }, + "type": "object", + "x-oas-optional": true + } + } + } + }, + "responses": { + "204": { + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." + } + }, + "summary": "Disable a rule", + "tags": [ + "alerting" + ] + } + }, + "/api/alerting/rule/{id}/_enable": { + "post": { + "operationId": "post-alerting-rule-id-enable", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "The identifier for the rule.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." + } + }, + "summary": "Enable a rule", + "tags": [ + "alerting" + ] + } + }, + "/api/alerting/rule/{id}/_mute_all": { + "post": { + "operationId": "post-alerting-rule-id-mute-all", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "The identifier for the rule.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" } } + ], + "responses": { + "204": { + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." + } }, - "summary": "", + "summary": "Mute all alerts", "tags": [ - "Fleet package policies" + "alerting" ] } }, - "/api/fleet/proxies": { - "get": { - "description": "List proxies", - "operationId": "get-fleet-proxies", + "/api/alerting/rule/{id}/_unmute_all": { + "post": { + "operationId": "post-alerting-rule-id-unmute-all", "parameters": [ { "description": "The version of the API to use", @@ -38976,126 +5109,50 @@ ], "type": "string" } + }, + { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "The identifier for the rule.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" + } } ], "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { - "items": { - "additionalProperties": false, - "properties": { - "certificate": { - "nullable": true, - "type": "string" - }, - "certificate_authorities": { - "nullable": true, - "type": "string" - }, - "certificate_key": { - "nullable": true, - "type": "string" - }, - "id": { - "type": "string" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_headers": { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "boolean" - }, - { - "type": "number" - } - ] - }, - "nullable": true, - "type": "object" - }, - "url": { - "type": "string" - } - }, - "required": [ - "id", - "url", - "name" - ], - "type": "object" - }, - "type": "array" - }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" - }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } + "204": { + "description": "Indicates a successful call." }, "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." } }, - "summary": "", + "summary": "Unmute all alerts", "tags": [ - "Fleet proxies" + "alerting" ] - }, + } + }, + "/api/alerting/rule/{id}/_update_api_key": { "post": { - "description": "Create proxy", - "operationId": "post-fleet-proxies", + "operationId": "post-alerting-rule-id-update-api-key", "parameters": [ { "description": "The version of the API to use", @@ -39118,171 +5175,43 @@ "example": "true", "type": "string" } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "certificate": { - "nullable": true, - "type": "string" - }, - "certificate_authorities": { - "nullable": true, - "type": "string" - }, - "certificate_key": { - "nullable": true, - "type": "string" - }, - "id": { - "type": "string" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_headers": { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "boolean" - }, - { - "type": "number" - } - ] - }, - "nullable": true, - "type": "object" - }, - "url": { - "type": "string" - } - }, - "required": [ - "url", - "name" - ], - "type": "object" - } + }, + { + "description": "The identifier for the rule.", + "in": "path", + "name": "id", + "required": true, + "schema": { + "type": "string" } } - }, + ], "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "certificate": { - "nullable": true, - "type": "string" - }, - "certificate_authorities": { - "nullable": true, - "type": "string" - }, - "certificate_key": { - "nullable": true, - "type": "string" - }, - "id": { - "type": "string" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_headers": { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "boolean" - }, - { - "type": "number" - } - ] - }, - "nullable": true, - "type": "object" - }, - "url": { - "type": "string" - } - }, - "required": [ - "id", - "url", - "name" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } + "204": { + "description": "Indicates a successful call." }, "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule with the given ID does not exist." + }, + "409": { + "description": "Indicates that the rule has already been updated by another user." } }, - "summary": "", + "summary": "Update the API key for a rule", "tags": [ - "Fleet proxies" + "alerting" ] } }, - "/api/fleet/proxies/{itemId}": { - "delete": { - "description": "Delete proxy by ID", - "operationId": "delete-fleet-proxies-itemid", + "/api/alerting/rule/{rule_id}/alert/{alert_id}/_mute": { + "post": { + "operationId": "post-alerting-rule-rule-id-alert-alert-id-mute", "parameters": [ { "description": "The version of the API to use", @@ -39307,8 +5236,18 @@ } }, { + "description": "The identifier for the rule.", + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The identifier for the alert.", "in": "path", - "name": "itemId", + "name": "alert_id", "required": true, "schema": { "type": "string" @@ -39316,58 +5255,28 @@ } ], "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "id": { - "type": "string" - } - }, - "required": [ - "id" - ], - "type": "object" - } - } - } + "204": { + "description": "Indicates a successful call." }, "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule or alert with the given ID does not exist." } }, - "summary": "", + "summary": "Mute an alert", "tags": [ - "Fleet proxies" + "alerting" ] - }, - "get": { - "description": "Get proxy by ID", - "operationId": "get-fleet-proxies-itemid", + } + }, + "/api/alerting/rule/{rule_id}/alert/{alert_id}/_unmute": { + "post": { + "operationId": "post-alerting-rule-rule-id-alert-alert-id-unmute", "parameters": [ { "description": "The version of the API to use", @@ -39382,8 +5291,28 @@ } }, { + "description": "A required header to protect against CSRF attacks", + "in": "header", + "name": "kbn-xsrf", + "required": true, + "schema": { + "example": "true", + "type": "string" + } + }, + { + "description": "The identifier for the rule.", + "in": "path", + "name": "rule_id", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The identifier for the alert.", "in": "path", - "name": "itemId", + "name": "alert_id", "required": true, "schema": { "type": "string" @@ -39391,193 +5320,184 @@ } ], "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "certificate": { - "nullable": true, - "type": "string" - }, - "certificate_authorities": { - "nullable": true, - "type": "string" - }, - "certificate_key": { - "nullable": true, - "type": "string" - }, - "id": { - "type": "string" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_headers": { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "boolean" - }, - { - "type": "number" - } - ] - }, - "nullable": true, - "type": "object" - }, - "url": { - "type": "string" - } - }, - "required": [ - "id", - "url", - "name" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } + "204": { + "description": "Indicates a successful call." }, "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" - }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." + }, + "404": { + "description": "Indicates a rule or alert with the given ID does not exist." + } + }, + "summary": "Unmute an alert", + "tags": [ + "alerting" + ] + } + }, + "/api/alerting/rules/_find": { + "get": { + "operationId": "get-alerting-rules-find", + "parameters": [ + { + "description": "The version of the API to use", + "in": "header", + "name": "elastic-api-version", + "schema": { + "default": "2023-10-31", + "enum": [ + "2023-10-31" + ], + "type": "string" + } + }, + { + "description": "The number of rules to return per page.", + "in": "query", + "name": "per_page", + "required": false, + "schema": { + "default": 10, + "minimum": 0, + "type": "number" + } + }, + { + "description": "The page number to return.", + "in": "query", + "name": "page", + "required": false, + "schema": { + "default": 1, + "minimum": 1, + "type": "number" + } + }, + { + "description": "An Elasticsearch simple_query_string query that filters the objects in the response.", + "in": "query", + "name": "search", + "required": false, + "schema": { + "type": "string" + } + }, + { + "description": "The default operator to use for the simple_query_string.", + "in": "query", + "name": "default_search_operator", + "required": false, + "schema": { + "default": "OR", + "enum": [ + "OR", + "AND" + ], + "type": "string" + } + }, + { + "description": "The fields to perform the simple_query_string parsed query against.", + "in": "query", + "name": "search_fields", + "required": false, + "schema": { + "anyOf": [ + { + "items": { + "type": "string" }, - "required": [ - "message" - ], - "type": "object" + "type": "array" + }, + { + "type": "string" } - } + ] + } + }, + { + "description": "Determines which field is used to sort the results. The field must exist in the `attributes` key of the response.", + "in": "query", + "name": "sort_field", + "required": false, + "schema": { + "type": "string" } - } - }, - "summary": "", - "tags": [ - "Fleet proxies" - ] - }, - "put": { - "description": "Update proxy by ID", - "operationId": "put-fleet-proxies-itemid", - "parameters": [ + }, { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", + "description": "Determines the sort order.", + "in": "query", + "name": "sort_order", + "required": false, "schema": { - "default": "2023-10-31", "enum": [ - "2023-10-31" + "asc", + "desc" ], "type": "string" } }, { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, + "description": "Filters the rules that have a relation with the reference objects with a specific type and identifier.", + "in": "query", + "name": "has_reference", + "required": false, "schema": { - "example": "true", - "type": "string" + "additionalProperties": false, + "nullable": true, + "properties": { + "id": { + "type": "string" + }, + "type": { + "type": "string" + } + }, + "required": [ + "type", + "id" + ], + "type": "object" } }, { - "in": "path", - "name": "itemId", - "required": true, + "in": "query", + "name": "fields", + "required": false, + "schema": { + "items": { + "description": "The fields to return in the `attributes` key of the response.", + "type": "string" + }, + "type": "array" + } + }, + { + "description": "A KQL string that you filter with an attribute from your saved object. It should look like `savedObjectType.attributes.title: \"myTitle\"`. However, if you used a direct attribute of a saved object, such as `updatedAt`, you must define your filter, for example, `savedObjectType.updatedAt > 2018-12-22`.", + "in": "query", + "name": "filter", + "required": false, "schema": { "type": "string" } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "certificate": { - "nullable": true, - "type": "string" - }, - "certificate_authorities": { - "nullable": true, - "type": "string" - }, - "certificate_key": { - "nullable": true, - "type": "string" - }, - "name": { - "type": "string" - }, - "proxy_headers": { - "additionalProperties": { - "anyOf": [ - { - "type": "string" - }, - { - "type": "boolean" - }, - { - "type": "number" - } - ] - }, - "nullable": true, - "type": "object" - }, - "url": { - "type": "string" - } - }, - "required": [ - "proxy_headers", - "certificate_authorities", - "certificate", - "certificate_key" - ], - "type": "object" - } + }, + { + "in": "query", + "name": "filter_consumers", + "required": false, + "schema": { + "items": { + "description": "List of consumers to filter.", + "type": "string" + }, + "type": "array" } } - }, + ], "responses": { "200": { "content": { @@ -39585,974 +5505,905 @@ "schema": { "additionalProperties": false, "properties": { - "item": { - "additionalProperties": false, - "properties": { - "certificate": { - "nullable": true, - "type": "string" - }, - "certificate_authorities": { - "nullable": true, - "type": "string" - }, - "certificate_key": { - "nullable": true, - "type": "string" - }, - "id": { - "type": "string" - }, - "is_preconfigured": { - "default": false, - "type": "boolean" - }, - "name": { - "type": "string" - }, - "proxy_headers": { - "additionalProperties": { - "anyOf": [ - { + "actions": { + "items": { + "additionalProperties": false, + "properties": { + "alerts_filter": { + "additionalProperties": false, + "description": "Defines a period that limits whether the action runs.", + "properties": { + "query": { + "additionalProperties": false, + "properties": { + "dsl": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL).", + "type": "string" + }, + "filters": { + "description": "A filter written in Elasticsearch Query Domain Specific Language (DSL) as defined in the `kbn-es-query` package.", + "items": { + "additionalProperties": false, + "properties": { + "$state": { + "additionalProperties": false, + "properties": { + "store": { + "description": "A filter can be either specific to an application context or applied globally.", + "enum": [ + "appState", + "globalState" + ], + "type": "string" + } + }, + "required": [ + "store" + ], + "type": "object" + }, + "meta": { + "additionalProperties": {}, + "type": "object" + }, + "query": { + "additionalProperties": {}, + "type": "object" + } + }, + "required": [ + "meta" + ], + "type": "object" + }, + "type": "array" + }, + "kql": { + "description": "A filter written in Kibana Query Language (KQL).", + "type": "string" + } + }, + "required": [ + "kql", + "filters" + ], + "type": "object" + }, + "timeframe": { + "additionalProperties": false, + "properties": { + "days": { + "description": "Defines the days of the week that the action can run, represented as an array of numbers. For example, `1` represents Monday. An empty array is equivalent to specifying all the days of the week.", + "items": { + "enum": [ + 1, + 2, + 3, + 4, + 5, + 6, + 7 + ], + "type": "integer" + }, + "type": "array" + }, + "hours": { + "additionalProperties": false, + "properties": { + "end": { + "description": "The end of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + }, + "start": { + "description": "The start of the time frame in 24-hour notation (`hh:mm`).", + "type": "string" + } + }, + "required": [ + "start", + "end" + ], + "type": "object" + }, + "timezone": { + "description": "The ISO time zone for the `hours` values. Values such as `UTC` and `UTC+1` also work but lack built-in daylight savings time support and are not recommended.", + "type": "string" + } + }, + "required": [ + "days", + "hours", + "timezone" + ], + "type": "object" + } + }, + "type": "object" + }, + "connector_type_id": { + "description": "The type of connector. This property appears in responses but cannot be set in requests.", + "type": "string" + }, + "frequency": { + "additionalProperties": false, + "properties": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], "type": "string" }, - { + "summary": { + "description": "Indicates whether the action is a summary.", "type": "boolean" }, - { - "type": "number" + "throttle": { + "description": "The throttle interval, which defines how often an alert generates repeated actions. It is specified in seconds, minutes, hours, or days and is applicable only if 'notify_when' is set to 'onThrottleInterval'. NOTE: You cannot specify the throttle interval at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, + "type": "string" } - ] + }, + "required": [ + "summary", + "notify_when", + "throttle" + ], + "type": "object" }, - "nullable": true, - "type": "object" + "group": { + "description": "The group name, which affects when the action runs (for example, when the threshold is met or when the alert is recovered). Each rule type has a list of valid action group names. If you don't need to group actions, set to `default`.", + "type": "string" + }, + "id": { + "description": "The identifier for the connector saved object.", + "type": "string" + }, + "params": { + "additionalProperties": {}, + "description": "The parameters for the action, which are sent to the connector. The `params` are handled as Mustache templates and passed a default set of context.", + "type": "object" + }, + "use_alert_data_for_template": { + "description": "Indicates whether to use alert data as a template.", + "type": "boolean" + }, + "uuid": { + "description": "A universally unique identifier (UUID) for the action.", + "type": "string" + } }, - "url": { - "type": "string" + "required": [ + "id", + "connector_type_id", + "params" + ], + "type": "object" + }, + "type": "array" + }, + "active_snoozes": { + "items": { + "description": "List of active snoozes for the rule.", + "type": "string" + }, + "type": "array" + }, + "alert_delay": { + "additionalProperties": false, + "description": "Indicates that an alert occurs only when the specified number of consecutive runs met the rule conditions.", + "properties": { + "active": { + "description": "The number of consecutive runs that must meet the rule conditions.", + "type": "number" } }, "required": [ - "id", - "url", - "name" + "active" ], "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" }, - "message": { - "type": "string" + "api_key_created_by_user": { + "description": "Indicates whether the API key that is associated with the rule was created by the user.", + "nullable": true, + "type": "boolean" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet proxies" - ] - } - }, - "/api/fleet/service-tokens": { - "post": { - "description": "Create a service token", - "operationId": "post-fleet-service-tokens-2", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "responses": {}, - "summary": "", - "tags": [] - } - }, - "/api/fleet/service_tokens": { - "post": { - "description": "Create a service token", - "operationId": "post-fleet-service-tokens", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "nullable": true, - "properties": { - "remote": { - "default": false, - "type": "boolean" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "name": { + "api_key_owner": { + "description": "The owner of the API key that is associated with the rule and used to run background tasks.", + "nullable": true, "type": "string" }, - "value": { + "consumer": { + "description": "The name of the application or feature that owns the rule. For example: `alerts`, `apm`, `discover`, `infrastructure`, `logs`, `metrics`, `ml`, `monitoring`, `securitySolution`, `siem`, `stackAlerts`, or `uptime`.", "type": "string" - } - }, - "required": [ - "name", - "value" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + }, + "created_at": { + "description": "The date and time that the rule was created.", "type": "string" }, - "message": { + "created_by": { + "description": "The identifier for the user that created the rule.", + "nullable": true, "type": "string" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet service tokens" - ] - } - }, - "/api/fleet/settings": { - "get": { - "description": "Get settings", - "operationId": "get-fleet-settings", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { + "enabled": { + "description": "Indicates whether you want to run the rule on an interval basis after it is created.", + "type": "boolean" + }, + "execution_status": { "additionalProperties": false, "properties": { - "delete_unenrolled_agents": { + "error": { "additionalProperties": false, "properties": { - "enabled": { - "type": "boolean" + "message": { + "description": "Error message.", + "type": "string" }, - "is_preconfigured": { - "type": "boolean" + "reason": { + "description": "Reason for error.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate" + ], + "type": "string" } }, "required": [ - "enabled", - "is_preconfigured" + "reason", + "message" ], "type": "object" }, - "fleet_server_hosts": { - "items": { - "type": "string" - }, - "type": "array" - }, - "has_seen_add_data_notice": { - "type": "boolean" - }, - "id": { - "type": "string" - }, - "output_secret_storage_requirements_met": { - "type": "boolean" - }, - "preconfigured_fields": { - "items": { - "enum": [ - "fleet_server_hosts" - ], - "type": "string" - }, - "type": "array" - }, - "prerelease_integrations_enabled": { - "type": "boolean" - }, - "secret_storage_requirements_met": { - "type": "boolean" + "last_duration": { + "description": "Duration of last execution of the rule.", + "type": "number" }, - "use_space_awareness_migration_started_at": { + "last_execution_date": { + "description": "The date and time when rule was executed last.", "type": "string" }, - "use_space_awareness_migration_status": { + "status": { + "description": "Status of rule execution.", "enum": [ + "ok", + "active", + "error", + "warning", "pending", - "success", - "error" + "unknown" ], "type": "string" }, - "version": { - "type": "string" + "warning": { + "additionalProperties": false, + "properties": { + "message": { + "description": "Warning message.", + "type": "string" + }, + "reason": { + "description": "Reason for warning.", + "enum": [ + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "type": "string" + } + }, + "required": [ + "reason", + "message" + ], + "type": "object" } }, "required": [ - "id" + "status", + "last_execution_date" ], "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" }, - "message": { - "type": "string" - }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet internals" - ] - }, - "put": { - "description": "Update settings", - "operationId": "put-fleet-settings", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "additional_yaml_config": { - "type": "string" - }, - "delete_unenrolled_agents": { - "additionalProperties": false, - "properties": { - "enabled": { - "type": "boolean" + "flapping": { + "additionalProperties": false, + "nullable": true, + "properties": { + "look_back_window": { + "maximum": 20, + "minimum": 2, + "type": "number" + }, + "status_change_threshold": { + "maximum": 20, + "minimum": 2, + "type": "number" + } }, - "is_preconfigured": { - "type": "boolean" - } + "required": [ + "look_back_window", + "status_change_threshold" + ], + "type": "object" }, - "required": [ - "enabled", - "is_preconfigured" - ], - "type": "object" - }, - "fleet_server_hosts": { - "items": { - "format": "uri", + "id": { + "description": "The identifier for the rule.", "type": "string" }, - "type": "array" - }, - "has_seen_add_data_notice": { - "type": "boolean" - }, - "kibana_ca_sha256": { - "type": "string" - }, - "kibana_urls": { - "items": { - "format": "uri", + "is_snoozed_until": { + "description": "The date when the rule will no longer be snoozed.", + "nullable": true, "type": "string" }, - "type": "array" - }, - "prerelease_integrations_enabled": { - "type": "boolean" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { + "last_run": { "additionalProperties": false, + "nullable": true, "properties": { - "delete_unenrolled_agents": { + "alerts_count": { "additionalProperties": false, "properties": { - "enabled": { - "type": "boolean" + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" }, - "is_preconfigured": { - "type": "boolean" - } - }, - "required": [ - "enabled", - "is_preconfigured" - ], - "type": "object" - }, - "fleet_server_hosts": { - "items": { - "type": "string" - }, - "type": "array" - }, - "has_seen_add_data_notice": { - "type": "boolean" + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, + "type": "number" + }, + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" + }, + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } + }, + "type": "object" }, - "id": { + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], "type": "string" }, - "output_secret_storage_requirements_met": { - "type": "boolean" - }, - "preconfigured_fields": { + "outcome_msg": { "items": { - "enum": [ - "fleet_server_hosts" - ], + "description": "Outcome message generated during last rule run.", "type": "string" }, + "nullable": true, "type": "array" }, - "prerelease_integrations_enabled": { - "type": "boolean" - }, - "secret_storage_requirements_met": { - "type": "boolean" - }, - "use_space_awareness_migration_started_at": { - "type": "string" + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" }, - "use_space_awareness_migration_status": { + "warning": { + "description": "Warning of last rule execution.", "enum": [ - "pending", - "success", - "error" + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" ], - "type": "string" - }, - "version": { + "nullable": true, "type": "string" } }, "required": [ - "id" + "outcome", + "alerts_count" ], "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { - "type": "string" }, - "message": { - "type": "string" + "mapped_params": { + "additionalProperties": {}, + "type": "object" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "404": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet internals" - ] - } - }, - "/api/fleet/setup": { - "post": { - "description": "Initiate Fleet setup", - "operationId": "post-fleet-setup", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "A required header to protect against CSRF attacks", - "in": "header", - "name": "kbn-xsrf", - "required": true, - "schema": { - "example": "true", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "A summary of the result of Fleet's `setup` lifecycle. If `isInitialized` is true, Fleet is ready to accept agent enrollment. `nonFatalErrors` may include useful insight into non-blocking issues with Fleet setup.", - "properties": { - "isInitialized": { + "monitoring": { + "additionalProperties": false, + "description": "Monitoring details of the rule.", + "properties": { + "run": { + "additionalProperties": false, + "description": "Rule run details.", + "properties": { + "calculated_metrics": { + "additionalProperties": false, + "description": "Calculation of different percentiles and success ratio.", + "properties": { + "p50": { + "type": "number" + }, + "p95": { + "type": "number" + }, + "p99": { + "type": "number" + }, + "success_ratio": { + "type": "number" + } + }, + "required": [ + "success_ratio" + ], + "type": "object" + }, + "history": { + "description": "History of the rule run.", + "items": { + "additionalProperties": false, + "properties": { + "duration": { + "description": "Duration of the rule run.", + "type": "number" + }, + "outcome": { + "additionalProperties": false, + "properties": { + "alerts_count": { + "additionalProperties": false, + "properties": { + "active": { + "description": "Number of active alerts during last run.", + "nullable": true, + "type": "number" + }, + "ignored": { + "description": "Number of ignored alerts during last run.", + "nullable": true, + "type": "number" + }, + "new": { + "description": "Number of new alerts during last run.", + "nullable": true, + "type": "number" + }, + "recovered": { + "description": "Number of recovered alerts during last run.", + "nullable": true, + "type": "number" + } + }, + "type": "object" + }, + "outcome": { + "description": "Outcome of last run of the rule. Value could be succeeded, warning or failed.", + "enum": [ + "succeeded", + "warning", + "failed" + ], + "type": "string" + }, + "outcome_msg": { + "items": { + "description": "Outcome message generated during last rule run.", + "type": "string" + }, + "nullable": true, + "type": "array" + }, + "outcome_order": { + "description": "Order of the outcome.", + "type": "number" + }, + "warning": { + "description": "Warning of last rule execution.", + "enum": [ + "read", + "decrypt", + "execute", + "unknown", + "license", + "timeout", + "disabled", + "validate", + "maxExecutableActions", + "maxAlerts", + "maxQueuedActions", + "ruleExecution" + ], + "nullable": true, + "type": "string" + } + }, + "required": [ + "outcome", + "alerts_count" + ], + "type": "object" + }, + "success": { + "description": "Indicates whether the rule run was successful.", + "type": "boolean" + }, + "timestamp": { + "description": "Time of rule run.", + "type": "number" + } + }, + "required": [ + "success", + "timestamp" + ], + "type": "object" + }, + "type": "array" + }, + "last_run": { + "additionalProperties": false, + "properties": { + "metrics": { + "additionalProperties": false, + "properties": { + "duration": { + "description": "Duration of most recent rule run.", + "type": "number" + }, + "gap_duration_s": { + "description": "Duration in seconds of rule run gap.", + "nullable": true, + "type": "number" + }, + "total_alerts_created": { + "description": "Total number of alerts created during last rule run.", + "nullable": true, + "type": "number" + }, + "total_alerts_detected": { + "description": "Total number of alerts detected during last rule run.", + "nullable": true, + "type": "number" + }, + "total_indexing_duration_ms": { + "description": "Total time spent indexing documents during last rule run in milliseconds.", + "nullable": true, + "type": "number" + }, + "total_search_duration_ms": { + "description": "Total time spent performing Elasticsearch searches as measured by Kibana; includes network latency and time spent serializing or deserializing the request and response.", + "nullable": true, + "type": "number" + } + }, + "type": "object" + }, + "timestamp": { + "description": "Time of the most recent rule run.", + "type": "string" + } + }, + "required": [ + "timestamp", + "metrics" + ], + "type": "object" + } + }, + "required": [ + "history", + "calculated_metrics", + "last_run" + ], + "type": "object" + } + }, + "required": [ + "run" + ], + "type": "object" + }, + "mute_all": { + "description": "Indicates whether all alerts are muted.", "type": "boolean" }, - "nonFatalErrors": { + "muted_alert_ids": { "items": { - "additionalProperties": false, - "properties": { - "message": { - "type": "string" - }, - "name": { - "type": "string" - } - }, - "required": [ - "name", - "message" - ], - "type": "object" + "description": "List of identifiers of muted alerts. ", + "type": "string" }, "type": "array" - } - }, - "required": [ - "isInitialized", - "nonFatalErrors" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + }, + "name": { + "description": " The name of the rule.", + "type": "string" + }, + "next_run": { + "description": "Date and time of the next run of the rule.", + "nullable": true, "type": "string" }, - "message": { + "notify_when": { + "description": "Indicates how often alerts generate actions. Valid values include: `onActionGroupChange`: Actions run when the alert status changes; `onActiveAlert`: Actions run when the alert becomes active and at each check interval while the rule conditions are met; `onThrottleInterval`: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met. NOTE: You cannot specify `notify_when` at both the rule and action level. The recommended method is to set it for each action. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "enum": [ + "onActionGroupChange", + "onActiveAlert", + "onThrottleInterval" + ], + "nullable": true, "type": "string" }, - "statusCode": { + "params": { + "additionalProperties": {}, + "description": "The parameters for the rule.", + "type": "object" + }, + "revision": { + "description": "The rule revision number.", "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - }, - "500": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Internal Server Error", - "properties": { - "message": { + }, + "rule_type_id": { + "description": "The rule type identifier.", "type": "string" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet internals" - ] - } - }, - "/api/fleet/uninstall_tokens": { - "get": { - "description": "List metadata for latest uninstall tokens per agent policy", - "operationId": "get-fleet-uninstall-tokens", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "description": "Partial match filtering for policy IDs", - "in": "query", - "name": "policyId", - "required": false, - "schema": { - "maxLength": 50, - "type": "string" - } - }, - { - "in": "query", - "name": "search", - "required": false, - "schema": { - "maxLength": 50, - "type": "string" - } - }, - { - "description": "The number of items to return", - "in": "query", - "name": "perPage", - "required": false, - "schema": { - "minimum": 5, - "type": "number" - } - }, - { - "in": "query", - "name": "page", - "required": false, - "schema": { - "minimum": 1, - "type": "number" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "items": { + }, + "running": { + "description": "Indicates whether the rule is running.", + "nullable": true, + "type": "boolean" + }, + "schedule": { + "additionalProperties": false, + "properties": { + "interval": { + "description": "The interval is specified in seconds, minutes, hours, or days.", + "type": "string" + } + }, + "required": [ + "interval" + ], + "type": "object" + }, + "scheduled_task_id": { + "description": "Identifier of the scheduled task.", + "type": "string" + }, + "snooze_schedule": { "items": { "additionalProperties": false, "properties": { - "created_at": { - "type": "string" + "duration": { + "description": "Duration of the rule snooze schedule.", + "type": "number" }, "id": { + "description": "Identifier of the rule snooze schedule.", "type": "string" }, - "namespaces": { + "rRule": { + "additionalProperties": false, + "properties": { + "byhour": { + "items": { + "description": "Indicates hours of the day to recur.", + "type": "number" + }, + "type": "array" + }, + "byminute": { + "items": { + "description": "Indicates minutes of the hour to recur.", + "type": "number" + }, + "type": "array" + }, + "bymonth": { + "items": { + "description": "Indicates months of the year that this rule should recur.", + "type": "number" + }, + "type": "array" + }, + "bymonthday": { + "items": { + "description": "Indicates the days of the month to recur.", + "type": "number" + }, + "type": "array" + }, + "bysecond": { + "items": { + "description": "Indicates seconds of the day to recur.", + "type": "number" + }, + "type": "array" + }, + "bysetpos": { + "items": { + "description": "A positive or negative integer affecting the nth day of the month. For example, -2 combined with `byweekday` of FR is 2nd to last Friday of the month. It is recommended to not set this manually and just use `byweekday`.", + "type": "number" + }, + "type": "array" + }, + "byweekday": { + "items": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "number" + } + ], + "description": "Indicates the days of the week to recur or else nth-day-of-month strings. For example, \"+2TU\" second Tuesday of month, \"-1FR\" last Friday of the month, which are internally converted to a `byweekday/bysetpos` combination." + }, + "type": "array" + }, + "byweekno": { + "items": { + "description": "Indicates number of the week hours to recur.", + "type": "number" + }, + "type": "array" + }, + "byyearday": { + "items": { + "description": "Indicates the days of the year that this rule should recur.", + "type": "number" + }, + "type": "array" + }, + "count": { + "description": "Number of times the rule should recur until it stops.", + "type": "number" + }, + "dtstart": { + "description": "Rule start date in Coordinated Universal Time (UTC).", + "type": "string" + }, + "freq": { + "description": "Indicates frequency of the rule. Options are YEARLY, MONTHLY, WEEKLY, DAILY.", + "enum": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ], + "type": "integer" + }, + "interval": { + "description": "Indicates the interval of frequency. For example, 1 and YEARLY is every 1 year, 2 and WEEKLY is every 2 weeks.", + "type": "number" + }, + "tzid": { + "description": "Indicates timezone abbreviation.", + "type": "string" + }, + "until": { + "description": "Recur the rule until this date.", + "type": "string" + }, + "wkst": { + "description": "Indicates the start of week, defaults to Monday.", + "enum": [ + "MO", + "TU", + "WE", + "TH", + "FR", + "SA", + "SU" + ], + "type": "string" + } + }, + "required": [ + "dtstart", + "tzid" + ], + "type": "object" + }, + "skipRecurrences": { "items": { + "description": "Skips recurrence of rule on this date.", "type": "string" }, "type": "array" - }, - "policy_id": { - "type": "string" - }, - "policy_name": { - "nullable": true, - "type": "string" } }, "required": [ - "id", - "policy_id", - "created_at" + "duration", + "rRule" ], "type": "object" }, "type": "array" }, - "page": { - "type": "number" - }, - "perPage": { - "type": "number" + "tags": { + "items": { + "description": "The tags for the rule.", + "type": "string" + }, + "type": "array" }, - "total": { - "type": "number" - } - }, - "required": [ - "items", - "total", - "page", - "perPage" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + "throttle": { + "deprecated": true, + "description": "Deprecated in 8.13.0. Use the `throttle` property in the action `frequency` object instead. The throttle interval, which defines how often an alert generates repeated actions. NOTE: You cannot specify the throttle interval at both the rule and action level. If you set it at the rule level then update the rule in Kibana, it is automatically changed to use action-specific values.", + "nullable": true, "type": "string" }, - "message": { + "updated_at": { + "description": "The date and time that the rule was updated most recently.", "type": "string" }, - "statusCode": { - "type": "number" - } - }, - "required": [ - "message" - ], - "type": "object" - } - } - } - } - }, - "summary": "", - "tags": [ - "Fleet uninstall tokens" - ] - } - }, - "/api/fleet/uninstall_tokens/{uninstallTokenId}": { - "get": { - "description": "Get one decrypted uninstall token by its ID", - "operationId": "get-fleet-uninstall-tokens-uninstalltokenid", - "parameters": [ - { - "description": "The version of the API to use", - "in": "header", - "name": "elastic-api-version", - "schema": { - "default": "2023-10-31", - "enum": [ - "2023-10-31" - ], - "type": "string" - } - }, - { - "in": "path", - "name": "uninstallTokenId", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "properties": { - "item": { - "additionalProperties": false, - "properties": { - "created_at": { - "type": "string" - }, - "id": { - "type": "string" - }, - "namespaces": { - "items": { - "type": "string" - }, - "type": "array" - }, - "policy_id": { - "type": "string" - }, - "policy_name": { - "nullable": true, - "type": "string" - }, - "token": { - "type": "string" - } - }, - "required": [ - "id", - "policy_id", - "created_at", - "token" - ], - "type": "object" - } - }, - "required": [ - "item" - ], - "type": "object" - } - } - } - }, - "400": { - "content": { - "application/json; Elastic-Api-Version=2023-10-31": { - "schema": { - "additionalProperties": false, - "description": "Generic Error", - "properties": { - "error": { + "updated_by": { + "description": "The identifier for the user that updated this rule most recently.", + "nullable": true, "type": "string" }, - "message": { + "view_in_app_relative_url": { + "description": "Relative URL to view rule in the app.", + "nullable": true, "type": "string" - }, - "statusCode": { - "type": "number" } }, "required": [ - "message" + "id", + "enabled", + "name", + "tags", + "rule_type_id", + "consumer", + "schedule", + "actions", + "params", + "created_by", + "updated_by", + "created_at", + "updated_at", + "api_key_owner", + "mute_all", + "muted_alert_ids", + "execution_status", + "revision" ], "type": "object" } } - } + }, + "description": "Indicates a successful call." + }, + "400": { + "description": "Indicates an invalid schema or parameters." + }, + "403": { + "description": "Indicates that this call is forbidden." } }, - "summary": "", + "summary": "Get information about rules", "tags": [ - "Fleet uninstall tokens" + "alerting" ] } }, @@ -42234,54 +8085,6 @@ { "name": "connectors" }, - { - "name": "Data streams" - }, - { - "name": "Elastic Agent actions" - }, - { - "name": "Elastic Agent binary download sources" - }, - { - "name": "Elastic Agent policies" - }, - { - "name": "Elastic Agent status" - }, - { - "name": "Elastic Agents" - }, - { - "name": "Elastic Package Manager (EPM)" - }, - { - "name": "Fleet enrollment API keys" - }, - { - "name": "Fleet internals" - }, - { - "name": "Fleet outputs" - }, - { - "name": "Fleet package policies" - }, - { - "name": "Fleet proxies" - }, - { - "name": "Fleet Server hosts" - }, - { - "name": "Fleet service tokens" - }, - { - "name": "Fleet uninstall tokens" - }, - { - "name": "Message Signing Service" - }, { "name": "roles" },