diff --git a/oas_docs/bundle.serverless.json b/oas_docs/bundle.serverless.json
new file mode 100644
index 0000000000000..4f38eb68de2ed
--- /dev/null
+++ b/oas_docs/bundle.serverless.json
@@ -0,0 +1,47301 @@
+{
+ "components": {
+ "schemas": {
+ "core_status_redactedResponse": {
+ "additionalProperties": false,
+ "description": "A minimal representation of Kibana's operational status.",
+ "properties": {
+ "status": {
+ "additionalProperties": false,
+ "properties": {
+ "overall": {
+ "additionalProperties": false,
+ "properties": {
+ "level": {
+ "description": "Service status levels as human and machine readable values.",
+ "enum": [
+ "available",
+ "degraded",
+ "unavailable",
+ "critical"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "level"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "overall"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "status"
+ ],
+ "type": "object"
+ },
+ "core_status_response": {
+ "additionalProperties": false,
+ "description": "Kibana's operational status as well as a detailed breakdown of plugin statuses indication of various loads (like event loop utilization and network traffic) at time of request.",
+ "properties": {
+ "metrics": {
+ "additionalProperties": false,
+ "description": "Metric groups collected by Kibana.",
+ "properties": {
+ "collection_interval_in_millis": {
+ "description": "The interval at which metrics should be collected.",
+ "type": "number"
+ },
+ "elasticsearch_client": {
+ "additionalProperties": false,
+ "description": "Current network metrics of Kibana's Elasticsearch client.",
+ "properties": {
+ "totalActiveSockets": {
+ "description": "Count of network sockets currently in use.",
+ "type": "number"
+ },
+ "totalIdleSockets": {
+ "description": "Count of network sockets currently idle.",
+ "type": "number"
+ },
+ "totalQueuedRequests": {
+ "description": "Count of requests not yet assigned to sockets.",
+ "type": "number"
+ }
+ },
+ "required": [
+ "totalActiveSockets",
+ "totalIdleSockets",
+ "totalQueuedRequests"
+ ],
+ "type": "object"
+ },
+ "last_updated": {
+ "description": "The time metrics were collected.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "elasticsearch_client",
+ "last_updated",
+ "collection_interval_in_millis"
+ ],
+ "type": "object"
+ },
+ "name": {
+ "description": "Kibana instance name.",
+ "type": "string"
+ },
+ "status": {
+ "additionalProperties": false,
+ "properties": {
+ "core": {
+ "additionalProperties": false,
+ "description": "Statuses of core Kibana services.",
+ "properties": {
+ "elasticsearch": {
+ "additionalProperties": false,
+ "properties": {
+ "detail": {
+ "description": "Human readable detail of the service status.",
+ "type": "string"
+ },
+ "documentationUrl": {
+ "description": "A URL to further documentation regarding this service.",
+ "type": "string"
+ },
+ "level": {
+ "description": "Service status levels as human and machine readable values.",
+ "enum": [
+ "available",
+ "degraded",
+ "unavailable",
+ "critical"
+ ],
+ "type": "string"
+ },
+ "meta": {
+ "additionalProperties": {},
+ "description": "An unstructured set of extra metadata about this service.",
+ "type": "object"
+ },
+ "summary": {
+ "description": "A human readable summary of the service status.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "level",
+ "summary",
+ "meta"
+ ],
+ "type": "object"
+ },
+ "savedObjects": {
+ "additionalProperties": false,
+ "properties": {
+ "detail": {
+ "description": "Human readable detail of the service status.",
+ "type": "string"
+ },
+ "documentationUrl": {
+ "description": "A URL to further documentation regarding this service.",
+ "type": "string"
+ },
+ "level": {
+ "description": "Service status levels as human and machine readable values.",
+ "enum": [
+ "available",
+ "degraded",
+ "unavailable",
+ "critical"
+ ],
+ "type": "string"
+ },
+ "meta": {
+ "additionalProperties": {},
+ "description": "An unstructured set of extra metadata about this service.",
+ "type": "object"
+ },
+ "summary": {
+ "description": "A human readable summary of the service status.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "level",
+ "summary",
+ "meta"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "elasticsearch",
+ "savedObjects"
+ ],
+ "type": "object"
+ },
+ "overall": {
+ "additionalProperties": false,
+ "properties": {
+ "detail": {
+ "description": "Human readable detail of the service status.",
+ "type": "string"
+ },
+ "documentationUrl": {
+ "description": "A URL to further documentation regarding this service.",
+ "type": "string"
+ },
+ "level": {
+ "description": "Service status levels as human and machine readable values.",
+ "enum": [
+ "available",
+ "degraded",
+ "unavailable",
+ "critical"
+ ],
+ "type": "string"
+ },
+ "meta": {
+ "additionalProperties": {},
+ "description": "An unstructured set of extra metadata about this service.",
+ "type": "object"
+ },
+ "summary": {
+ "description": "A human readable summary of the service status.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "level",
+ "summary",
+ "meta"
+ ],
+ "type": "object"
+ },
+ "plugins": {
+ "additionalProperties": {
+ "additionalProperties": false,
+ "properties": {
+ "detail": {
+ "description": "Human readable detail of the service status.",
+ "type": "string"
+ },
+ "documentationUrl": {
+ "description": "A URL to further documentation regarding this service.",
+ "type": "string"
+ },
+ "level": {
+ "description": "Service status levels as human and machine readable values.",
+ "enum": [
+ "available",
+ "degraded",
+ "unavailable",
+ "critical"
+ ],
+ "type": "string"
+ },
+ "meta": {
+ "additionalProperties": {},
+ "description": "An unstructured set of extra metadata about this service.",
+ "type": "object"
+ },
+ "summary": {
+ "description": "A human readable summary of the service status.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "level",
+ "summary",
+ "meta"
+ ],
+ "type": "object"
+ },
+ "description": "A dynamic mapping of plugin ID to plugin status.",
+ "type": "object"
+ }
+ },
+ "required": [
+ "overall",
+ "core",
+ "plugins"
+ ],
+ "type": "object"
+ },
+ "uuid": {
+ "description": "Unique, generated Kibana instance UUID. This UUID should persist even if the Kibana process restarts.",
+ "type": "string"
+ },
+ "version": {
+ "additionalProperties": false,
+ "properties": {
+ "build_date": {
+ "description": "The date and time of this build.",
+ "type": "string"
+ },
+ "build_flavor": {
+ "description": "The build flavour determines configuration and behavior of Kibana. On premise users will almost always run the \"traditional\" flavour, while other flavours are reserved for Elastic-specific use cases.",
+ "enum": [
+ "serverless",
+ "traditional"
+ ],
+ "type": "string"
+ },
+ "build_hash": {
+ "description": "A unique hash value representing the git commit of this Kibana build.",
+ "type": "string"
+ },
+ "build_number": {
+ "description": "A monotonically increasing number, each subsequent build will have a higher number.",
+ "type": "number"
+ },
+ "build_snapshot": {
+ "description": "Whether this build is a snapshot build.",
+ "type": "boolean"
+ },
+ "number": {
+ "description": "A semantic version number.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "number",
+ "build_hash",
+ "build_number",
+ "build_snapshot",
+ "build_flavor",
+ "build_date"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "uuid",
+ "version",
+ "status",
+ "metrics"
+ ],
+ "type": "object"
+ }
+ },
+ "securitySchemes": {
+ "apiKeyAuth": {
+ "in": "header",
+ "name": "Authorization",
+ "type": "apiKey"
+ },
+ "basicAuth": {
+ "scheme": "basic",
+ "type": "http"
+ }
+ }
+ },
+ "info": {
+ "title": "Kibana HTTP APIs",
+ "version": "0.0.0"
+ },
+ "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",
+ "parameters": [
+ {
+ "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",
+ "tags": [
+ "connectors"
+ ]
+ },
+ "get": {
+ "operationId": "get-actions-connector-id",
+ "parameters": [
+ {
+ "description": "An identifier for the connector.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": [
+ "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": "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": {
+ "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": {
+ "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": [
+ "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": "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": {
+ "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": {
+ "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": [
+ "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": "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "params": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "params"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": [
+ "id",
+ "name",
+ "connector_type_id",
+ "is_preconfigured",
+ "is_deprecated",
+ "is_system_action"
+ ],
+ "type": "object"
+ }
+ }
+ },
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Run a connector",
+ "tags": [
+ "connectors"
+ ]
+ }
+ },
+ "/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": "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": [],
+ "responses": {},
+ "summary": "Get all connectors",
+ "tags": [
+ "connectors"
+ ]
+ }
+ },
+ "/api/alerting/rule/{id}": {
+ "delete": {
+ "operationId": "delete-alerting-rule-id",
+ "parameters": [
+ {
+ "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": "Delete a rule",
+ "tags": [
+ "alerting"
+ ]
+ },
+ "get": {
+ "operationId": "get-alerting-rule-id",
+ "parameters": [
+ {
+ "description": "The identifier for the rule.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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,
+ "description": "When flapping detection is turned on, alerts that switch quickly between active and recovered states are identified as “flapping” and notifications are reduced.",
+ "nullable": true,
+ "properties": {
+ "look_back_window": {
+ "description": "The minimum number of runs in which the threshold must be met.",
+ "maximum": 20,
+ "minimum": 2,
+ "type": "number"
+ },
+ "status_change_threshold": {
+ "description": "The minimum number of times an alert must switch states in the look back window.",
+ "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"
+ },
+ "gap_range": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "gte": {
+ "description": "End of the gap range.",
+ "type": "string"
+ },
+ "lte": {
+ "description": "Start of the gap range.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "lte",
+ "gte"
+ ],
+ "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"
+ },
+ "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": "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": {
+ "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,
+ "description": "When flapping detection is turned on, alerts that switch quickly between active and recovered states are identified as “flapping” and notifications are reduced.",
+ "nullable": true,
+ "properties": {
+ "look_back_window": {
+ "description": "The minimum number of runs in which the threshold must be met.",
+ "maximum": 20,
+ "minimum": 2,
+ "type": "number"
+ },
+ "status_change_threshold": {
+ "description": "The minimum number of times an alert must switch states in the look back window.",
+ "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": {
+ "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,
+ "description": "When flapping detection is turned on, alerts that switch quickly between active and recovered states are identified as “flapping” and notifications are reduced.",
+ "nullable": true,
+ "properties": {
+ "look_back_window": {
+ "description": "The minimum number of runs in which the threshold must be met.",
+ "maximum": 20,
+ "minimum": 2,
+ "type": "number"
+ },
+ "status_change_threshold": {
+ "description": "The minimum number of times an alert must switch states in the look back window.",
+ "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"
+ },
+ "gap_range": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "gte": {
+ "description": "End of the gap range.",
+ "type": "string"
+ },
+ "lte": {
+ "description": "Start of the gap range.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "lte",
+ "gte"
+ ],
+ "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"
+ },
+ "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": "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": {
+ "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,
+ "description": "When flapping detection is turned on, alerts that switch quickly between active and recovered states are identified as “flapping” and notifications are reduced.",
+ "nullable": true,
+ "properties": {
+ "look_back_window": {
+ "description": "The minimum number of runs in which the threshold must be met.",
+ "maximum": 20,
+ "minimum": 2,
+ "type": "number"
+ },
+ "status_change_threshold": {
+ "description": "The minimum number of times an alert must switch states in the look back window.",
+ "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": {
+ "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,
+ "description": "When flapping detection is turned on, alerts that switch quickly between active and recovered states are identified as “flapping” and notifications are reduced.",
+ "nullable": true,
+ "properties": {
+ "look_back_window": {
+ "description": "The minimum number of runs in which the threshold must be met.",
+ "maximum": 20,
+ "minimum": 2,
+ "type": "number"
+ },
+ "status_change_threshold": {
+ "description": "The minimum number of times an alert must switch states in the look back window.",
+ "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"
+ },
+ "gap_range": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "gte": {
+ "description": "End of the gap range.",
+ "type": "string"
+ },
+ "lte": {
+ "description": "Start of the gap range.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "lte",
+ "gte"
+ ],
+ "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"
+ },
+ "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": "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": {
+ "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": "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": "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": "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": "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": "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": "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 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": {
+ "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,
+ "description": "When flapping detection is turned on, alerts that switch quickly between active and recovered states are identified as “flapping” and notifications are reduced.",
+ "nullable": true,
+ "properties": {
+ "look_back_window": {
+ "description": "The minimum number of runs in which the threshold must be met.",
+ "maximum": 20,
+ "minimum": 2,
+ "type": "number"
+ },
+ "status_change_threshold": {
+ "description": "The minimum number of times an alert must switch states in the look back window.",
+ "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"
+ },
+ "gap_range": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "gte": {
+ "description": "End of the gap range.",
+ "type": "string"
+ },
+ "lte": {
+ "description": "Start of the gap range.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "lte",
+ "gte"
+ ],
+ "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"
+ },
+ "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/dashboards/dashboard": {
+ "get": {
+ "description": "This functionality is in technical preview and may be changed or removed in a future release. Elastic will work to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.",
+ "operationId": "get-dashboards-dashboard",
+ "parameters": [
+ {
+ "description": "The page number to return. Default is \"1\".",
+ "in": "query",
+ "name": "page",
+ "required": false,
+ "schema": {
+ "default": 1,
+ "minimum": 1,
+ "type": "number"
+ }
+ },
+ {
+ "description": "The number of dashboards to display on each page (max 1000). Default is \"20\".",
+ "in": "query",
+ "name": "perPage",
+ "required": false,
+ "schema": {
+ "maximum": 1000,
+ "minimum": 1,
+ "type": "number"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "additionalProperties": true,
+ "properties": {
+ "attributes": {
+ "additionalProperties": false,
+ "properties": {
+ "description": {
+ "default": "",
+ "description": "A short description.",
+ "type": "string"
+ },
+ "timeRestore": {
+ "default": false,
+ "description": "Whether to restore time upon viewing this dashboard",
+ "type": "boolean"
+ },
+ "title": {
+ "description": "A human-readable title for the dashboard",
+ "type": "string"
+ }
+ },
+ "required": [
+ "title"
+ ],
+ "type": "object"
+ },
+ "createdAt": {
+ "type": "string"
+ },
+ "createdBy": {
+ "type": "string"
+ },
+ "error": {
+ "additionalProperties": false,
+ "properties": {
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "metadata": {
+ "additionalProperties": true,
+ "properties": {},
+ "type": "object"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "error",
+ "message",
+ "statusCode"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "type": "string"
+ },
+ "managed": {
+ "type": "boolean"
+ },
+ "namespaces": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "originId": {
+ "type": "string"
+ },
+ "references": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "type",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ },
+ "updatedAt": {
+ "type": "string"
+ },
+ "updatedBy": {
+ "type": "string"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "type",
+ "attributes",
+ "references"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "total": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "items",
+ "total"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a list of dashboards",
+ "tags": [
+ "Dashboards"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/dashboards/dashboard/{id}": {
+ "delete": {
+ "description": "This functionality is in technical preview and may be changed or removed in a future release. Elastic will work to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.",
+ "operationId": "delete-dashboards-dashboard-id",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "description": "A unique identifier for the dashboard.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {},
+ "summary": "Delete a dashboard",
+ "tags": [
+ "Dashboards"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "get": {
+ "description": "This functionality is in technical preview and may be changed or removed in a future release. Elastic will work to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.",
+ "operationId": "get-dashboards-dashboard-id",
+ "parameters": [
+ {
+ "description": "A unique identifier for the dashboard.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": true,
+ "properties": {
+ "attributes": {
+ "additionalProperties": false,
+ "properties": {
+ "controlGroupInput": {
+ "additionalProperties": false,
+ "properties": {
+ "autoApplySelections": {
+ "default": true,
+ "description": "Show apply selections button in controls.",
+ "type": "boolean"
+ },
+ "chainingSystem": {
+ "default": "HIERARCHICAL",
+ "description": "The chaining strategy for multiple controls. For example, \"HIERARCHICAL\" or \"NONE\".",
+ "enum": [
+ "NONE",
+ "HIERARCHICAL"
+ ],
+ "type": "string"
+ },
+ "controls": {
+ "default": [],
+ "description": "An array of control panels and their state in the control group.",
+ "items": {
+ "additionalProperties": true,
+ "properties": {
+ "controlConfig": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "grow": {
+ "default": false,
+ "description": "Expand width of the control panel to fit available space.",
+ "type": "boolean"
+ },
+ "id": {
+ "description": "The unique ID of the control.",
+ "type": "string"
+ },
+ "order": {
+ "description": "The order of the control panel in the control group.",
+ "type": "number"
+ },
+ "type": {
+ "description": "The type of the control panel.",
+ "type": "string"
+ },
+ "width": {
+ "default": "medium",
+ "description": "Minimum width of the control panel in the control group.",
+ "enum": [
+ "small",
+ "medium",
+ "large"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type",
+ "order"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "ignoreParentSettings": {
+ "additionalProperties": false,
+ "properties": {
+ "ignoreFilters": {
+ "default": false,
+ "description": "Ignore global filters in controls.",
+ "type": "boolean"
+ },
+ "ignoreQuery": {
+ "default": false,
+ "description": "Ignore the global query bar in controls.",
+ "type": "boolean"
+ },
+ "ignoreTimerange": {
+ "default": false,
+ "description": "Ignore the global time range in controls.",
+ "type": "boolean"
+ },
+ "ignoreValidations": {
+ "default": false,
+ "description": "Ignore validations in controls.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "labelPosition": {
+ "default": "oneLine",
+ "description": "Position of the labels for controls. For example, \"oneLine\", \"twoLine\".",
+ "enum": [
+ "oneLine",
+ "twoLine"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "ignoreParentSettings"
+ ],
+ "type": "object"
+ },
+ "description": {
+ "default": "",
+ "description": "A short description.",
+ "type": "string"
+ },
+ "kibanaSavedObjectMeta": {
+ "additionalProperties": false,
+ "default": {},
+ "description": "A container for various metadata",
+ "properties": {
+ "searchSource": {
+ "additionalProperties": true,
+ "properties": {
+ "filter": {
+ "items": {
+ "additionalProperties": false,
+ "description": "A filter for the search source.",
+ "properties": {
+ "$state": {
+ "additionalProperties": false,
+ "properties": {
+ "store": {
+ "description": "Denote whether a filter is specific to an application's context (e.g. 'appState') or whether it should be applied globally (e.g. 'globalState').",
+ "enum": [
+ "appState",
+ "globalState"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "store"
+ ],
+ "type": "object"
+ },
+ "meta": {
+ "additionalProperties": true,
+ "properties": {
+ "alias": {
+ "nullable": true,
+ "type": "string"
+ },
+ "controlledBy": {
+ "type": "string"
+ },
+ "disabled": {
+ "type": "boolean"
+ },
+ "field": {
+ "type": "string"
+ },
+ "group": {
+ "type": "string"
+ },
+ "index": {
+ "type": "string"
+ },
+ "isMultiIndex": {
+ "type": "boolean"
+ },
+ "key": {
+ "type": "string"
+ },
+ "negate": {
+ "type": "boolean"
+ },
+ "params": {},
+ "type": {
+ "type": "string"
+ },
+ "value": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "params"
+ ],
+ "type": "object"
+ },
+ "query": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "meta"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "query": {
+ "additionalProperties": false,
+ "properties": {
+ "language": {
+ "description": "The query language such as KQL or Lucene.",
+ "type": "string"
+ },
+ "query": {
+ "anyOf": [
+ {
+ "description": "A text-based query such as Kibana Query Language (KQL) or Lucene query language.",
+ "type": "string"
+ },
+ {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "query",
+ "language"
+ ],
+ "type": "object"
+ },
+ "sort": {
+ "items": {
+ "additionalProperties": {
+ "anyOf": [
+ {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "format": {
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "numeric_type": {
+ "enum": [
+ "double",
+ "long",
+ "date",
+ "date_nanos"
+ ],
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "options": {
+ "additionalProperties": false,
+ "properties": {
+ "hidePanelTitles": {
+ "default": false,
+ "description": "Hide the panel titles in the dashboard.",
+ "type": "boolean"
+ },
+ "syncColors": {
+ "default": true,
+ "description": "Synchronize colors between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncCursor": {
+ "default": true,
+ "description": "Synchronize cursor position between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncTooltips": {
+ "default": true,
+ "description": "Synchronize tooltips between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "useMargins": {
+ "default": true,
+ "description": "Show margins between panels in the dashboard layout.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "panels": {
+ "default": [],
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "gridData": {
+ "additionalProperties": false,
+ "properties": {
+ "h": {
+ "default": 15,
+ "description": "The height of the panel in grid units",
+ "minimum": 1,
+ "type": "number"
+ },
+ "i": {
+ "type": "string"
+ },
+ "w": {
+ "default": 24,
+ "description": "The width of the panel in grid units",
+ "maximum": 48,
+ "minimum": 1,
+ "type": "number"
+ },
+ "x": {
+ "description": "The x coordinate of the panel in grid units",
+ "type": "number"
+ },
+ "y": {
+ "description": "The y coordinate of the panel in grid units",
+ "type": "number"
+ }
+ },
+ "required": [
+ "x",
+ "y",
+ "i"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "description": "The saved object id for by reference panels",
+ "type": "string"
+ },
+ "panelConfig": {
+ "additionalProperties": true,
+ "properties": {
+ "description": {
+ "description": "The description of the panel",
+ "type": "string"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "hidePanelTitles": {
+ "description": "Set to true to hide the panel title in its container.",
+ "type": "boolean"
+ },
+ "savedObjectId": {
+ "description": "The unique id of the library item to construct the embeddable.",
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "version": {
+ "description": "The version of the embeddable in the panel.",
+ "type": "string"
+ }
+ },
+ "type": "object"
+ },
+ "panelIndex": {
+ "type": "string"
+ },
+ "panelRefName": {
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "type": {
+ "description": "The embeddable type",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "description": "The version was used to store Kibana version information from versions 7.3.0 -> 8.11.0. As of version 8.11.0, the versioning information is now per-embeddable-type and is stored on the embeddable's input. (panelConfig in this type).",
+ "type": "string"
+ }
+ },
+ "required": [
+ "panelConfig",
+ "type",
+ "gridData",
+ "panelIndex"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "refreshInterval": {
+ "additionalProperties": false,
+ "description": "A container for various refresh interval settings",
+ "properties": {
+ "display": {
+ "deprecated": true,
+ "description": "A human-readable string indicating the refresh frequency. No longer used.",
+ "type": "string"
+ },
+ "pause": {
+ "description": "Whether the refresh interval is set to be paused while viewing the dashboard.",
+ "type": "boolean"
+ },
+ "section": {
+ "deprecated": true,
+ "description": "No longer used.",
+ "type": "number"
+ },
+ "value": {
+ "description": "A numeric value indicating refresh frequency in milliseconds.",
+ "type": "number"
+ }
+ },
+ "required": [
+ "pause",
+ "value"
+ ],
+ "type": "object"
+ },
+ "timeFrom": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "timeRestore": {
+ "default": false,
+ "description": "Whether to restore time upon viewing this dashboard",
+ "type": "boolean"
+ },
+ "timeTo": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "title": {
+ "description": "A human-readable title for the dashboard",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "type": "number"
+ }
+ },
+ "required": [
+ "title",
+ "options"
+ ],
+ "type": "object"
+ },
+ "createdAt": {
+ "type": "string"
+ },
+ "createdBy": {
+ "type": "string"
+ },
+ "error": {
+ "additionalProperties": false,
+ "properties": {
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "metadata": {
+ "additionalProperties": true,
+ "properties": {},
+ "type": "object"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "error",
+ "message",
+ "statusCode"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "type": "string"
+ },
+ "managed": {
+ "type": "boolean"
+ },
+ "namespaces": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "originId": {
+ "type": "string"
+ },
+ "references": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "type",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ },
+ "updatedAt": {
+ "type": "string"
+ },
+ "updatedBy": {
+ "type": "string"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "type",
+ "attributes",
+ "references"
+ ],
+ "type": "object"
+ },
+ "meta": {
+ "additionalProperties": false,
+ "properties": {
+ "aliasPurpose": {
+ "enum": [
+ "savedObjectConversion",
+ "savedObjectImport"
+ ],
+ "type": "string"
+ },
+ "aliasTargetId": {
+ "type": "string"
+ },
+ "outcome": {
+ "enum": [
+ "exactMatch",
+ "aliasMatch",
+ "conflict"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "outcome"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item",
+ "meta"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a dashboard",
+ "tags": [
+ "Dashboards"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "post": {
+ "description": "This functionality is in technical preview and may be changed or removed in a future release. Elastic will work to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.",
+ "operationId": "post-dashboards-dashboard-id",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "description": "A unique identifier for the dashboard.",
+ "in": "path",
+ "name": "id",
+ "required": false,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "attributes": {
+ "additionalProperties": false,
+ "properties": {
+ "controlGroupInput": {
+ "additionalProperties": false,
+ "properties": {
+ "autoApplySelections": {
+ "default": true,
+ "description": "Show apply selections button in controls.",
+ "type": "boolean"
+ },
+ "chainingSystem": {
+ "default": "HIERARCHICAL",
+ "description": "The chaining strategy for multiple controls. For example, \"HIERARCHICAL\" or \"NONE\".",
+ "enum": [
+ "NONE",
+ "HIERARCHICAL"
+ ],
+ "type": "string"
+ },
+ "controls": {
+ "default": [],
+ "description": "An array of control panels and their state in the control group.",
+ "items": {
+ "additionalProperties": true,
+ "properties": {
+ "controlConfig": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "grow": {
+ "default": false,
+ "description": "Expand width of the control panel to fit available space.",
+ "type": "boolean"
+ },
+ "id": {
+ "description": "The unique ID of the control.",
+ "type": "string"
+ },
+ "order": {
+ "description": "The order of the control panel in the control group.",
+ "type": "number"
+ },
+ "type": {
+ "description": "The type of the control panel.",
+ "type": "string"
+ },
+ "width": {
+ "default": "medium",
+ "description": "Minimum width of the control panel in the control group.",
+ "enum": [
+ "small",
+ "medium",
+ "large"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type",
+ "order"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "ignoreParentSettings": {
+ "additionalProperties": false,
+ "properties": {
+ "ignoreFilters": {
+ "default": false,
+ "description": "Ignore global filters in controls.",
+ "type": "boolean"
+ },
+ "ignoreQuery": {
+ "default": false,
+ "description": "Ignore the global query bar in controls.",
+ "type": "boolean"
+ },
+ "ignoreTimerange": {
+ "default": false,
+ "description": "Ignore the global time range in controls.",
+ "type": "boolean"
+ },
+ "ignoreValidations": {
+ "default": false,
+ "description": "Ignore validations in controls.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "labelPosition": {
+ "default": "oneLine",
+ "description": "Position of the labels for controls. For example, \"oneLine\", \"twoLine\".",
+ "enum": [
+ "oneLine",
+ "twoLine"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "ignoreParentSettings"
+ ],
+ "type": "object"
+ },
+ "description": {
+ "default": "",
+ "description": "A short description.",
+ "type": "string"
+ },
+ "kibanaSavedObjectMeta": {
+ "additionalProperties": false,
+ "default": {},
+ "description": "A container for various metadata",
+ "properties": {
+ "searchSource": {
+ "additionalProperties": true,
+ "properties": {
+ "filter": {
+ "items": {
+ "additionalProperties": false,
+ "description": "A filter for the search source.",
+ "properties": {
+ "$state": {
+ "additionalProperties": false,
+ "properties": {
+ "store": {
+ "description": "Denote whether a filter is specific to an application's context (e.g. 'appState') or whether it should be applied globally (e.g. 'globalState').",
+ "enum": [
+ "appState",
+ "globalState"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "store"
+ ],
+ "type": "object"
+ },
+ "meta": {
+ "additionalProperties": true,
+ "properties": {
+ "alias": {
+ "nullable": true,
+ "type": "string"
+ },
+ "controlledBy": {
+ "type": "string"
+ },
+ "disabled": {
+ "type": "boolean"
+ },
+ "field": {
+ "type": "string"
+ },
+ "group": {
+ "type": "string"
+ },
+ "index": {
+ "type": "string"
+ },
+ "isMultiIndex": {
+ "type": "boolean"
+ },
+ "key": {
+ "type": "string"
+ },
+ "negate": {
+ "type": "boolean"
+ },
+ "params": {},
+ "type": {
+ "type": "string"
+ },
+ "value": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "params"
+ ],
+ "type": "object"
+ },
+ "query": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "meta"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "query": {
+ "additionalProperties": false,
+ "properties": {
+ "language": {
+ "description": "The query language such as KQL or Lucene.",
+ "type": "string"
+ },
+ "query": {
+ "anyOf": [
+ {
+ "description": "A text-based query such as Kibana Query Language (KQL) or Lucene query language.",
+ "type": "string"
+ },
+ {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "query",
+ "language"
+ ],
+ "type": "object"
+ },
+ "sort": {
+ "items": {
+ "additionalProperties": {
+ "anyOf": [
+ {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "format": {
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "numeric_type": {
+ "enum": [
+ "double",
+ "long",
+ "date",
+ "date_nanos"
+ ],
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "options": {
+ "additionalProperties": false,
+ "properties": {
+ "hidePanelTitles": {
+ "default": false,
+ "description": "Hide the panel titles in the dashboard.",
+ "type": "boolean"
+ },
+ "syncColors": {
+ "default": true,
+ "description": "Synchronize colors between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncCursor": {
+ "default": true,
+ "description": "Synchronize cursor position between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncTooltips": {
+ "default": true,
+ "description": "Synchronize tooltips between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "useMargins": {
+ "default": true,
+ "description": "Show margins between panels in the dashboard layout.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "panels": {
+ "default": [],
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "gridData": {
+ "additionalProperties": false,
+ "properties": {
+ "h": {
+ "default": 15,
+ "description": "The height of the panel in grid units",
+ "minimum": 1,
+ "type": "number"
+ },
+ "i": {
+ "description": "The unique identifier of the panel",
+ "type": "string"
+ },
+ "w": {
+ "default": 24,
+ "description": "The width of the panel in grid units",
+ "maximum": 48,
+ "minimum": 1,
+ "type": "number"
+ },
+ "x": {
+ "description": "The x coordinate of the panel in grid units",
+ "type": "number"
+ },
+ "y": {
+ "description": "The y coordinate of the panel in grid units",
+ "type": "number"
+ }
+ },
+ "required": [
+ "x",
+ "y"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "description": "The saved object id for by reference panels",
+ "type": "string"
+ },
+ "panelConfig": {
+ "additionalProperties": true,
+ "properties": {
+ "description": {
+ "description": "The description of the panel",
+ "type": "string"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "hidePanelTitles": {
+ "description": "Set to true to hide the panel title in its container.",
+ "type": "boolean"
+ },
+ "savedObjectId": {
+ "description": "The unique id of the library item to construct the embeddable.",
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "version": {
+ "description": "The version of the embeddable in the panel.",
+ "type": "string"
+ }
+ },
+ "type": "object"
+ },
+ "panelIndex": {
+ "description": "The unique ID of the panel.",
+ "type": "string"
+ },
+ "panelRefName": {
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "type": {
+ "description": "The embeddable type",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "description": "The version was used to store Kibana version information from versions 7.3.0 -> 8.11.0. As of version 8.11.0, the versioning information is now per-embeddable-type and is stored on the embeddable's input. (panelConfig in this type).",
+ "type": "string"
+ }
+ },
+ "required": [
+ "panelConfig",
+ "type",
+ "gridData"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "refreshInterval": {
+ "additionalProperties": false,
+ "description": "A container for various refresh interval settings",
+ "properties": {
+ "display": {
+ "deprecated": true,
+ "description": "A human-readable string indicating the refresh frequency. No longer used.",
+ "type": "string"
+ },
+ "pause": {
+ "description": "Whether the refresh interval is set to be paused while viewing the dashboard.",
+ "type": "boolean"
+ },
+ "section": {
+ "deprecated": true,
+ "description": "No longer used.",
+ "type": "number"
+ },
+ "value": {
+ "description": "A numeric value indicating refresh frequency in milliseconds.",
+ "type": "number"
+ }
+ },
+ "required": [
+ "pause",
+ "value"
+ ],
+ "type": "object"
+ },
+ "timeFrom": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "timeRestore": {
+ "default": false,
+ "description": "Whether to restore time upon viewing this dashboard",
+ "type": "boolean"
+ },
+ "timeTo": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "title": {
+ "description": "A human-readable title for the dashboard",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "type": "number"
+ }
+ },
+ "required": [
+ "title",
+ "options"
+ ],
+ "type": "object"
+ },
+ "references": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "type",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "spaces": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": true,
+ "properties": {
+ "attributes": {
+ "additionalProperties": false,
+ "properties": {
+ "controlGroupInput": {
+ "additionalProperties": false,
+ "properties": {
+ "autoApplySelections": {
+ "default": true,
+ "description": "Show apply selections button in controls.",
+ "type": "boolean"
+ },
+ "chainingSystem": {
+ "default": "HIERARCHICAL",
+ "description": "The chaining strategy for multiple controls. For example, \"HIERARCHICAL\" or \"NONE\".",
+ "enum": [
+ "NONE",
+ "HIERARCHICAL"
+ ],
+ "type": "string"
+ },
+ "controls": {
+ "default": [],
+ "description": "An array of control panels and their state in the control group.",
+ "items": {
+ "additionalProperties": true,
+ "properties": {
+ "controlConfig": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "grow": {
+ "default": false,
+ "description": "Expand width of the control panel to fit available space.",
+ "type": "boolean"
+ },
+ "id": {
+ "description": "The unique ID of the control.",
+ "type": "string"
+ },
+ "order": {
+ "description": "The order of the control panel in the control group.",
+ "type": "number"
+ },
+ "type": {
+ "description": "The type of the control panel.",
+ "type": "string"
+ },
+ "width": {
+ "default": "medium",
+ "description": "Minimum width of the control panel in the control group.",
+ "enum": [
+ "small",
+ "medium",
+ "large"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type",
+ "order"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "ignoreParentSettings": {
+ "additionalProperties": false,
+ "properties": {
+ "ignoreFilters": {
+ "default": false,
+ "description": "Ignore global filters in controls.",
+ "type": "boolean"
+ },
+ "ignoreQuery": {
+ "default": false,
+ "description": "Ignore the global query bar in controls.",
+ "type": "boolean"
+ },
+ "ignoreTimerange": {
+ "default": false,
+ "description": "Ignore the global time range in controls.",
+ "type": "boolean"
+ },
+ "ignoreValidations": {
+ "default": false,
+ "description": "Ignore validations in controls.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "labelPosition": {
+ "default": "oneLine",
+ "description": "Position of the labels for controls. For example, \"oneLine\", \"twoLine\".",
+ "enum": [
+ "oneLine",
+ "twoLine"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "ignoreParentSettings"
+ ],
+ "type": "object"
+ },
+ "description": {
+ "default": "",
+ "description": "A short description.",
+ "type": "string"
+ },
+ "kibanaSavedObjectMeta": {
+ "additionalProperties": false,
+ "default": {},
+ "description": "A container for various metadata",
+ "properties": {
+ "searchSource": {
+ "additionalProperties": true,
+ "properties": {
+ "filter": {
+ "items": {
+ "additionalProperties": false,
+ "description": "A filter for the search source.",
+ "properties": {
+ "$state": {
+ "additionalProperties": false,
+ "properties": {
+ "store": {
+ "description": "Denote whether a filter is specific to an application's context (e.g. 'appState') or whether it should be applied globally (e.g. 'globalState').",
+ "enum": [
+ "appState",
+ "globalState"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "store"
+ ],
+ "type": "object"
+ },
+ "meta": {
+ "additionalProperties": true,
+ "properties": {
+ "alias": {
+ "nullable": true,
+ "type": "string"
+ },
+ "controlledBy": {
+ "type": "string"
+ },
+ "disabled": {
+ "type": "boolean"
+ },
+ "field": {
+ "type": "string"
+ },
+ "group": {
+ "type": "string"
+ },
+ "index": {
+ "type": "string"
+ },
+ "isMultiIndex": {
+ "type": "boolean"
+ },
+ "key": {
+ "type": "string"
+ },
+ "negate": {
+ "type": "boolean"
+ },
+ "params": {},
+ "type": {
+ "type": "string"
+ },
+ "value": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "params"
+ ],
+ "type": "object"
+ },
+ "query": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "meta"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "query": {
+ "additionalProperties": false,
+ "properties": {
+ "language": {
+ "description": "The query language such as KQL or Lucene.",
+ "type": "string"
+ },
+ "query": {
+ "anyOf": [
+ {
+ "description": "A text-based query such as Kibana Query Language (KQL) or Lucene query language.",
+ "type": "string"
+ },
+ {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "query",
+ "language"
+ ],
+ "type": "object"
+ },
+ "sort": {
+ "items": {
+ "additionalProperties": {
+ "anyOf": [
+ {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "format": {
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "numeric_type": {
+ "enum": [
+ "double",
+ "long",
+ "date",
+ "date_nanos"
+ ],
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "options": {
+ "additionalProperties": false,
+ "properties": {
+ "hidePanelTitles": {
+ "default": false,
+ "description": "Hide the panel titles in the dashboard.",
+ "type": "boolean"
+ },
+ "syncColors": {
+ "default": true,
+ "description": "Synchronize colors between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncCursor": {
+ "default": true,
+ "description": "Synchronize cursor position between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncTooltips": {
+ "default": true,
+ "description": "Synchronize tooltips between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "useMargins": {
+ "default": true,
+ "description": "Show margins between panels in the dashboard layout.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "panels": {
+ "default": [],
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "gridData": {
+ "additionalProperties": false,
+ "properties": {
+ "h": {
+ "default": 15,
+ "description": "The height of the panel in grid units",
+ "minimum": 1,
+ "type": "number"
+ },
+ "i": {
+ "type": "string"
+ },
+ "w": {
+ "default": 24,
+ "description": "The width of the panel in grid units",
+ "maximum": 48,
+ "minimum": 1,
+ "type": "number"
+ },
+ "x": {
+ "description": "The x coordinate of the panel in grid units",
+ "type": "number"
+ },
+ "y": {
+ "description": "The y coordinate of the panel in grid units",
+ "type": "number"
+ }
+ },
+ "required": [
+ "x",
+ "y",
+ "i"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "description": "The saved object id for by reference panels",
+ "type": "string"
+ },
+ "panelConfig": {
+ "additionalProperties": true,
+ "properties": {
+ "description": {
+ "description": "The description of the panel",
+ "type": "string"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "hidePanelTitles": {
+ "description": "Set to true to hide the panel title in its container.",
+ "type": "boolean"
+ },
+ "savedObjectId": {
+ "description": "The unique id of the library item to construct the embeddable.",
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "version": {
+ "description": "The version of the embeddable in the panel.",
+ "type": "string"
+ }
+ },
+ "type": "object"
+ },
+ "panelIndex": {
+ "type": "string"
+ },
+ "panelRefName": {
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "type": {
+ "description": "The embeddable type",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "description": "The version was used to store Kibana version information from versions 7.3.0 -> 8.11.0. As of version 8.11.0, the versioning information is now per-embeddable-type and is stored on the embeddable's input. (panelConfig in this type).",
+ "type": "string"
+ }
+ },
+ "required": [
+ "panelConfig",
+ "type",
+ "gridData",
+ "panelIndex"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "refreshInterval": {
+ "additionalProperties": false,
+ "description": "A container for various refresh interval settings",
+ "properties": {
+ "display": {
+ "deprecated": true,
+ "description": "A human-readable string indicating the refresh frequency. No longer used.",
+ "type": "string"
+ },
+ "pause": {
+ "description": "Whether the refresh interval is set to be paused while viewing the dashboard.",
+ "type": "boolean"
+ },
+ "section": {
+ "deprecated": true,
+ "description": "No longer used.",
+ "type": "number"
+ },
+ "value": {
+ "description": "A numeric value indicating refresh frequency in milliseconds.",
+ "type": "number"
+ }
+ },
+ "required": [
+ "pause",
+ "value"
+ ],
+ "type": "object"
+ },
+ "timeFrom": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "timeRestore": {
+ "default": false,
+ "description": "Whether to restore time upon viewing this dashboard",
+ "type": "boolean"
+ },
+ "timeTo": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "title": {
+ "description": "A human-readable title for the dashboard",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "type": "number"
+ }
+ },
+ "required": [
+ "title",
+ "options"
+ ],
+ "type": "object"
+ },
+ "createdAt": {
+ "type": "string"
+ },
+ "createdBy": {
+ "type": "string"
+ },
+ "error": {
+ "additionalProperties": false,
+ "properties": {
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "metadata": {
+ "additionalProperties": true,
+ "properties": {},
+ "type": "object"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "error",
+ "message",
+ "statusCode"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "type": "string"
+ },
+ "managed": {
+ "type": "boolean"
+ },
+ "namespaces": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "originId": {
+ "type": "string"
+ },
+ "references": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "type",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ },
+ "updatedAt": {
+ "type": "string"
+ },
+ "updatedBy": {
+ "type": "string"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "type",
+ "attributes",
+ "references"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create a dashboard",
+ "tags": [
+ "Dashboards"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "put": {
+ "description": "This functionality is in technical preview and may be changed or removed in a future release. Elastic will work to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.",
+ "operationId": "put-dashboards-dashboard-id",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "description": "A unique identifier for the dashboard.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "attributes": {
+ "additionalProperties": false,
+ "properties": {
+ "controlGroupInput": {
+ "additionalProperties": false,
+ "properties": {
+ "autoApplySelections": {
+ "default": true,
+ "description": "Show apply selections button in controls.",
+ "type": "boolean"
+ },
+ "chainingSystem": {
+ "default": "HIERARCHICAL",
+ "description": "The chaining strategy for multiple controls. For example, \"HIERARCHICAL\" or \"NONE\".",
+ "enum": [
+ "NONE",
+ "HIERARCHICAL"
+ ],
+ "type": "string"
+ },
+ "controls": {
+ "default": [],
+ "description": "An array of control panels and their state in the control group.",
+ "items": {
+ "additionalProperties": true,
+ "properties": {
+ "controlConfig": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "grow": {
+ "default": false,
+ "description": "Expand width of the control panel to fit available space.",
+ "type": "boolean"
+ },
+ "id": {
+ "description": "The unique ID of the control.",
+ "type": "string"
+ },
+ "order": {
+ "description": "The order of the control panel in the control group.",
+ "type": "number"
+ },
+ "type": {
+ "description": "The type of the control panel.",
+ "type": "string"
+ },
+ "width": {
+ "default": "medium",
+ "description": "Minimum width of the control panel in the control group.",
+ "enum": [
+ "small",
+ "medium",
+ "large"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type",
+ "order"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "ignoreParentSettings": {
+ "additionalProperties": false,
+ "properties": {
+ "ignoreFilters": {
+ "default": false,
+ "description": "Ignore global filters in controls.",
+ "type": "boolean"
+ },
+ "ignoreQuery": {
+ "default": false,
+ "description": "Ignore the global query bar in controls.",
+ "type": "boolean"
+ },
+ "ignoreTimerange": {
+ "default": false,
+ "description": "Ignore the global time range in controls.",
+ "type": "boolean"
+ },
+ "ignoreValidations": {
+ "default": false,
+ "description": "Ignore validations in controls.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "labelPosition": {
+ "default": "oneLine",
+ "description": "Position of the labels for controls. For example, \"oneLine\", \"twoLine\".",
+ "enum": [
+ "oneLine",
+ "twoLine"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "ignoreParentSettings"
+ ],
+ "type": "object"
+ },
+ "description": {
+ "default": "",
+ "description": "A short description.",
+ "type": "string"
+ },
+ "kibanaSavedObjectMeta": {
+ "additionalProperties": false,
+ "default": {},
+ "description": "A container for various metadata",
+ "properties": {
+ "searchSource": {
+ "additionalProperties": true,
+ "properties": {
+ "filter": {
+ "items": {
+ "additionalProperties": false,
+ "description": "A filter for the search source.",
+ "properties": {
+ "$state": {
+ "additionalProperties": false,
+ "properties": {
+ "store": {
+ "description": "Denote whether a filter is specific to an application's context (e.g. 'appState') or whether it should be applied globally (e.g. 'globalState').",
+ "enum": [
+ "appState",
+ "globalState"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "store"
+ ],
+ "type": "object"
+ },
+ "meta": {
+ "additionalProperties": true,
+ "properties": {
+ "alias": {
+ "nullable": true,
+ "type": "string"
+ },
+ "controlledBy": {
+ "type": "string"
+ },
+ "disabled": {
+ "type": "boolean"
+ },
+ "field": {
+ "type": "string"
+ },
+ "group": {
+ "type": "string"
+ },
+ "index": {
+ "type": "string"
+ },
+ "isMultiIndex": {
+ "type": "boolean"
+ },
+ "key": {
+ "type": "string"
+ },
+ "negate": {
+ "type": "boolean"
+ },
+ "params": {},
+ "type": {
+ "type": "string"
+ },
+ "value": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "params"
+ ],
+ "type": "object"
+ },
+ "query": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "meta"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "query": {
+ "additionalProperties": false,
+ "properties": {
+ "language": {
+ "description": "The query language such as KQL or Lucene.",
+ "type": "string"
+ },
+ "query": {
+ "anyOf": [
+ {
+ "description": "A text-based query such as Kibana Query Language (KQL) or Lucene query language.",
+ "type": "string"
+ },
+ {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "query",
+ "language"
+ ],
+ "type": "object"
+ },
+ "sort": {
+ "items": {
+ "additionalProperties": {
+ "anyOf": [
+ {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "format": {
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "numeric_type": {
+ "enum": [
+ "double",
+ "long",
+ "date",
+ "date_nanos"
+ ],
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "options": {
+ "additionalProperties": false,
+ "properties": {
+ "hidePanelTitles": {
+ "default": false,
+ "description": "Hide the panel titles in the dashboard.",
+ "type": "boolean"
+ },
+ "syncColors": {
+ "default": true,
+ "description": "Synchronize colors between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncCursor": {
+ "default": true,
+ "description": "Synchronize cursor position between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncTooltips": {
+ "default": true,
+ "description": "Synchronize tooltips between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "useMargins": {
+ "default": true,
+ "description": "Show margins between panels in the dashboard layout.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "panels": {
+ "default": [],
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "gridData": {
+ "additionalProperties": false,
+ "properties": {
+ "h": {
+ "default": 15,
+ "description": "The height of the panel in grid units",
+ "minimum": 1,
+ "type": "number"
+ },
+ "i": {
+ "description": "The unique identifier of the panel",
+ "type": "string"
+ },
+ "w": {
+ "default": 24,
+ "description": "The width of the panel in grid units",
+ "maximum": 48,
+ "minimum": 1,
+ "type": "number"
+ },
+ "x": {
+ "description": "The x coordinate of the panel in grid units",
+ "type": "number"
+ },
+ "y": {
+ "description": "The y coordinate of the panel in grid units",
+ "type": "number"
+ }
+ },
+ "required": [
+ "x",
+ "y"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "description": "The saved object id for by reference panels",
+ "type": "string"
+ },
+ "panelConfig": {
+ "additionalProperties": true,
+ "properties": {
+ "description": {
+ "description": "The description of the panel",
+ "type": "string"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "hidePanelTitles": {
+ "description": "Set to true to hide the panel title in its container.",
+ "type": "boolean"
+ },
+ "savedObjectId": {
+ "description": "The unique id of the library item to construct the embeddable.",
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "version": {
+ "description": "The version of the embeddable in the panel.",
+ "type": "string"
+ }
+ },
+ "type": "object"
+ },
+ "panelIndex": {
+ "description": "The unique ID of the panel.",
+ "type": "string"
+ },
+ "panelRefName": {
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "type": {
+ "description": "The embeddable type",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "description": "The version was used to store Kibana version information from versions 7.3.0 -> 8.11.0. As of version 8.11.0, the versioning information is now per-embeddable-type and is stored on the embeddable's input. (panelConfig in this type).",
+ "type": "string"
+ }
+ },
+ "required": [
+ "panelConfig",
+ "type",
+ "gridData"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "refreshInterval": {
+ "additionalProperties": false,
+ "description": "A container for various refresh interval settings",
+ "properties": {
+ "display": {
+ "deprecated": true,
+ "description": "A human-readable string indicating the refresh frequency. No longer used.",
+ "type": "string"
+ },
+ "pause": {
+ "description": "Whether the refresh interval is set to be paused while viewing the dashboard.",
+ "type": "boolean"
+ },
+ "section": {
+ "deprecated": true,
+ "description": "No longer used.",
+ "type": "number"
+ },
+ "value": {
+ "description": "A numeric value indicating refresh frequency in milliseconds.",
+ "type": "number"
+ }
+ },
+ "required": [
+ "pause",
+ "value"
+ ],
+ "type": "object"
+ },
+ "timeFrom": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "timeRestore": {
+ "default": false,
+ "description": "Whether to restore time upon viewing this dashboard",
+ "type": "boolean"
+ },
+ "timeTo": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "title": {
+ "description": "A human-readable title for the dashboard",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "type": "number"
+ }
+ },
+ "required": [
+ "title",
+ "options"
+ ],
+ "type": "object"
+ },
+ "references": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "type",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": true,
+ "properties": {
+ "attributes": {
+ "additionalProperties": false,
+ "properties": {
+ "controlGroupInput": {
+ "additionalProperties": false,
+ "properties": {
+ "autoApplySelections": {
+ "default": true,
+ "description": "Show apply selections button in controls.",
+ "type": "boolean"
+ },
+ "chainingSystem": {
+ "default": "HIERARCHICAL",
+ "description": "The chaining strategy for multiple controls. For example, \"HIERARCHICAL\" or \"NONE\".",
+ "enum": [
+ "NONE",
+ "HIERARCHICAL"
+ ],
+ "type": "string"
+ },
+ "controls": {
+ "default": [],
+ "description": "An array of control panels and their state in the control group.",
+ "items": {
+ "additionalProperties": true,
+ "properties": {
+ "controlConfig": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "grow": {
+ "default": false,
+ "description": "Expand width of the control panel to fit available space.",
+ "type": "boolean"
+ },
+ "id": {
+ "description": "The unique ID of the control.",
+ "type": "string"
+ },
+ "order": {
+ "description": "The order of the control panel in the control group.",
+ "type": "number"
+ },
+ "type": {
+ "description": "The type of the control panel.",
+ "type": "string"
+ },
+ "width": {
+ "default": "medium",
+ "description": "Minimum width of the control panel in the control group.",
+ "enum": [
+ "small",
+ "medium",
+ "large"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type",
+ "order"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "ignoreParentSettings": {
+ "additionalProperties": false,
+ "properties": {
+ "ignoreFilters": {
+ "default": false,
+ "description": "Ignore global filters in controls.",
+ "type": "boolean"
+ },
+ "ignoreQuery": {
+ "default": false,
+ "description": "Ignore the global query bar in controls.",
+ "type": "boolean"
+ },
+ "ignoreTimerange": {
+ "default": false,
+ "description": "Ignore the global time range in controls.",
+ "type": "boolean"
+ },
+ "ignoreValidations": {
+ "default": false,
+ "description": "Ignore validations in controls.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "labelPosition": {
+ "default": "oneLine",
+ "description": "Position of the labels for controls. For example, \"oneLine\", \"twoLine\".",
+ "enum": [
+ "oneLine",
+ "twoLine"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "ignoreParentSettings"
+ ],
+ "type": "object"
+ },
+ "description": {
+ "default": "",
+ "description": "A short description.",
+ "type": "string"
+ },
+ "kibanaSavedObjectMeta": {
+ "additionalProperties": false,
+ "default": {},
+ "description": "A container for various metadata",
+ "properties": {
+ "searchSource": {
+ "additionalProperties": true,
+ "properties": {
+ "filter": {
+ "items": {
+ "additionalProperties": false,
+ "description": "A filter for the search source.",
+ "properties": {
+ "$state": {
+ "additionalProperties": false,
+ "properties": {
+ "store": {
+ "description": "Denote whether a filter is specific to an application's context (e.g. 'appState') or whether it should be applied globally (e.g. 'globalState').",
+ "enum": [
+ "appState",
+ "globalState"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "store"
+ ],
+ "type": "object"
+ },
+ "meta": {
+ "additionalProperties": true,
+ "properties": {
+ "alias": {
+ "nullable": true,
+ "type": "string"
+ },
+ "controlledBy": {
+ "type": "string"
+ },
+ "disabled": {
+ "type": "boolean"
+ },
+ "field": {
+ "type": "string"
+ },
+ "group": {
+ "type": "string"
+ },
+ "index": {
+ "type": "string"
+ },
+ "isMultiIndex": {
+ "type": "boolean"
+ },
+ "key": {
+ "type": "string"
+ },
+ "negate": {
+ "type": "boolean"
+ },
+ "params": {},
+ "type": {
+ "type": "string"
+ },
+ "value": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "params"
+ ],
+ "type": "object"
+ },
+ "query": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "meta"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "query": {
+ "additionalProperties": false,
+ "properties": {
+ "language": {
+ "description": "The query language such as KQL or Lucene.",
+ "type": "string"
+ },
+ "query": {
+ "anyOf": [
+ {
+ "description": "A text-based query such as Kibana Query Language (KQL) or Lucene query language.",
+ "type": "string"
+ },
+ {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "query",
+ "language"
+ ],
+ "type": "object"
+ },
+ "sort": {
+ "items": {
+ "additionalProperties": {
+ "anyOf": [
+ {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "format": {
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "numeric_type": {
+ "enum": [
+ "double",
+ "long",
+ "date",
+ "date_nanos"
+ ],
+ "type": "string"
+ },
+ "order": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "order"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "options": {
+ "additionalProperties": false,
+ "properties": {
+ "hidePanelTitles": {
+ "default": false,
+ "description": "Hide the panel titles in the dashboard.",
+ "type": "boolean"
+ },
+ "syncColors": {
+ "default": true,
+ "description": "Synchronize colors between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncCursor": {
+ "default": true,
+ "description": "Synchronize cursor position between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "syncTooltips": {
+ "default": true,
+ "description": "Synchronize tooltips between related panels in the dashboard.",
+ "type": "boolean"
+ },
+ "useMargins": {
+ "default": true,
+ "description": "Show margins between panels in the dashboard layout.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "panels": {
+ "default": [],
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "gridData": {
+ "additionalProperties": false,
+ "properties": {
+ "h": {
+ "default": 15,
+ "description": "The height of the panel in grid units",
+ "minimum": 1,
+ "type": "number"
+ },
+ "i": {
+ "type": "string"
+ },
+ "w": {
+ "default": 24,
+ "description": "The width of the panel in grid units",
+ "maximum": 48,
+ "minimum": 1,
+ "type": "number"
+ },
+ "x": {
+ "description": "The x coordinate of the panel in grid units",
+ "type": "number"
+ },
+ "y": {
+ "description": "The y coordinate of the panel in grid units",
+ "type": "number"
+ }
+ },
+ "required": [
+ "x",
+ "y",
+ "i"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "description": "The saved object id for by reference panels",
+ "type": "string"
+ },
+ "panelConfig": {
+ "additionalProperties": true,
+ "properties": {
+ "description": {
+ "description": "The description of the panel",
+ "type": "string"
+ },
+ "enhancements": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "hidePanelTitles": {
+ "description": "Set to true to hide the panel title in its container.",
+ "type": "boolean"
+ },
+ "savedObjectId": {
+ "description": "The unique id of the library item to construct the embeddable.",
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "version": {
+ "description": "The version of the embeddable in the panel.",
+ "type": "string"
+ }
+ },
+ "type": "object"
+ },
+ "panelIndex": {
+ "type": "string"
+ },
+ "panelRefName": {
+ "type": "string"
+ },
+ "title": {
+ "description": "The title of the panel",
+ "type": "string"
+ },
+ "type": {
+ "description": "The embeddable type",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "description": "The version was used to store Kibana version information from versions 7.3.0 -> 8.11.0. As of version 8.11.0, the versioning information is now per-embeddable-type and is stored on the embeddable's input. (panelConfig in this type).",
+ "type": "string"
+ }
+ },
+ "required": [
+ "panelConfig",
+ "type",
+ "gridData",
+ "panelIndex"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "refreshInterval": {
+ "additionalProperties": false,
+ "description": "A container for various refresh interval settings",
+ "properties": {
+ "display": {
+ "deprecated": true,
+ "description": "A human-readable string indicating the refresh frequency. No longer used.",
+ "type": "string"
+ },
+ "pause": {
+ "description": "Whether the refresh interval is set to be paused while viewing the dashboard.",
+ "type": "boolean"
+ },
+ "section": {
+ "deprecated": true,
+ "description": "No longer used.",
+ "type": "number"
+ },
+ "value": {
+ "description": "A numeric value indicating refresh frequency in milliseconds.",
+ "type": "number"
+ }
+ },
+ "required": [
+ "pause",
+ "value"
+ ],
+ "type": "object"
+ },
+ "timeFrom": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "timeRestore": {
+ "default": false,
+ "description": "Whether to restore time upon viewing this dashboard",
+ "type": "boolean"
+ },
+ "timeTo": {
+ "description": "An ISO string indicating when to restore time from",
+ "type": "string"
+ },
+ "title": {
+ "description": "A human-readable title for the dashboard",
+ "type": "string"
+ },
+ "version": {
+ "deprecated": true,
+ "type": "number"
+ }
+ },
+ "required": [
+ "title",
+ "options"
+ ],
+ "type": "object"
+ },
+ "createdAt": {
+ "type": "string"
+ },
+ "createdBy": {
+ "type": "string"
+ },
+ "error": {
+ "additionalProperties": false,
+ "properties": {
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "metadata": {
+ "additionalProperties": true,
+ "properties": {},
+ "type": "object"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "error",
+ "message",
+ "statusCode"
+ ],
+ "type": "object"
+ },
+ "id": {
+ "type": "string"
+ },
+ "managed": {
+ "type": "boolean"
+ },
+ "namespaces": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "originId": {
+ "type": "string"
+ },
+ "references": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "type": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "type",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "type": {
+ "type": "string"
+ },
+ "updatedAt": {
+ "type": "string"
+ },
+ "updatedBy": {
+ "type": "string"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "type",
+ "attributes",
+ "references"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update an existing dashboard",
+ "tags": [
+ "Dashboards"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/fleet/agent_download_sources": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agent-policies-read OR fleet-settings-read].",
+ "operationId": "get-fleet-agent-download-sources",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "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"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get agent binary download sources",
+ "tags": [
+ "Elastic Agent binary download sources"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "post-fleet-agent-download-sources",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ },
+ "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"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "host"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "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"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "id",
+ "name",
+ "host"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create an agent binary download source",
+ "tags": [
+ "Elastic Agent binary download sources"
+ ]
+ }
+ },
+ "/api/fleet/agent_download_sources/{sourceId}": {
+ "delete": {
+ "description": "Delete an agent binary download source by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "delete-fleet-agent-download-sources-sourceid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete an agent binary download source",
+ "tags": [
+ "Elastic Agent binary download sources"
+ ]
+ },
+ "get": {
+ "description": "Get an agent binary download source by ID.
[Required authorization] Route required privileges: ANY of [fleet-agent-policies-read OR fleet-settings-read].",
+ "operationId": "get-fleet-agent-download-sources-sourceid",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "sourceId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "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"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "id",
+ "name",
+ "host"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an agent binary download source",
+ "tags": [
+ "Elastic Agent binary download sources"
+ ]
+ },
+ "put": {
+ "description": "Update an agent binary download source by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "put-fleet-agent-download-sources-sourceid",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ },
+ "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"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "host"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "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"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "id",
+ "name",
+ "host"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update an agent binary download source",
+ "tags": [
+ "Elastic Agent binary download sources"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agent-policies-read OR fleet-agents-read OR fleet-setup].",
+ "operationId": "get-fleet-agent-policies",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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"
+ }
+ },
+ "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": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ ]
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get agent policies",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agent-policies-all].",
+ "operationId": "post-fleet-agent-policies",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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"
+ }
+ },
+ "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"
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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"
+ }
+ },
+ "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": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ ]
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create an agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/_bulk_get": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agent-policies-read OR fleet-agents-read OR fleet-setup].",
+ "operationId": "post-fleet-agent-policies-bulk-get",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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"
+ }
+ },
+ "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": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ ]
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk get agent policies",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/delete": {
+ "post": {
+ "description": "Delete an agent policy by ID.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-all].",
+ "operationId": "post-fleet-agent-policies-delete",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "name"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete an agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/outputs": {
+ "post": {
+ "description": "Get a list of outputs associated with agent policies.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-read, fleet-settings-read].",
+ "operationId": "post-fleet-agent-policies-outputs",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get outputs for agent policies",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/{agentPolicyId}": {
+ "get": {
+ "description": "Get an agent policy by ID.
[Required authorization] Route required privileges: ANY of [fleet-agent-policies-read OR fleet-agents-read OR fleet-setup].",
+ "operationId": "get-fleet-agent-policies-agentpolicyid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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"
+ }
+ },
+ "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": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ ]
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ },
+ "put": {
+ "description": "Update an agent policy by ID.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-all].",
+ "operationId": "put-fleet-agent-policies-agentpolicyid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "bumpRevision": {
+ "type": "boolean"
+ },
+ "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"
+ }
+ },
+ "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"
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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"
+ }
+ },
+ "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": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ ]
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update an agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/{agentPolicyId}/copy": {
+ "post": {
+ "description": "Copy an agent policy by ID.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-all].",
+ "operationId": "post-fleet-agent-policies-agentpolicyid-copy",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "name": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "name"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "advanced_settings": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_download_target_directory": {
+ "nullable": true
+ },
+ "agent_download_timeout": {
+ "nullable": true
+ },
+ "agent_limits_go_max_procs": {
+ "nullable": true
+ },
+ "agent_logging_files_interval": {
+ "nullable": true
+ },
+ "agent_logging_files_keepfiles": {
+ "nullable": true
+ },
+ "agent_logging_files_rotateeverybytes": {
+ "nullable": true
+ },
+ "agent_logging_level": {
+ "nullable": true
+ },
+ "agent_logging_metrics_period": {
+ "nullable": true
+ },
+ "agent_logging_to_files": {
+ "nullable": true
+ }
+ },
+ "type": "object"
+ },
+ "agent_features": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "agentless": {
+ "additionalProperties": false,
+ "properties": {
+ "resources": {
+ "additionalProperties": false,
+ "properties": {
+ "requests": {
+ "additionalProperties": false,
+ "properties": {
+ "cpu": {
+ "type": "string"
+ },
+ "memory": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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"
+ }
+ },
+ "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": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ ]
+ },
+ "required_versions": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "percentage": {
+ "description": "Target percentage of agents to auto upgrade",
+ "maximum": 100,
+ "minimum": 0,
+ "type": "number"
+ },
+ "version": {
+ "description": "Target version for automatic agent upgrade",
+ "type": "string"
+ }
+ },
+ "required": [
+ "version",
+ "percentage"
+ ],
+ "type": "object"
+ },
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Copy an agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/{agentPolicyId}/download": {
+ "get": {
+ "description": "Download an agent policy by ID.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-read, fleet-setup].",
+ "operationId": "get-fleet-agent-policies-agentpolicyid-download",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "type": "string"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Download an agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/{agentPolicyId}/full": {
+ "get": {
+ "description": "Get a full agent policy by ID.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-read].",
+ "operationId": "get-fleet-agent-policies-agentpolicyid-full",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "agent": {
+ "additionalProperties": false,
+ "properties": {
+ "download": {
+ "additionalProperties": false,
+ "properties": {
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "key": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "key"
+ ],
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "sourceURI": {
+ "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": [
+ "sourceURI"
+ ],
+ "type": "object"
+ },
+ "features": {
+ "additionalProperties": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "enabled"
+ ],
+ "type": "object"
+ },
+ "type": "object"
+ },
+ "limits": {
+ "additionalProperties": false,
+ "properties": {
+ "go_max_procs": {
+ "type": "number"
+ }
+ },
+ "type": "object"
+ },
+ "logging": {
+ "additionalProperties": false,
+ "properties": {
+ "files": {
+ "additionalProperties": false,
+ "properties": {
+ "interval": {
+ "type": "string"
+ },
+ "keepfiles": {
+ "type": "number"
+ },
+ "rotateeverybytes": {
+ "type": "number"
+ }
+ },
+ "type": "object"
+ },
+ "level": {
+ "type": "string"
+ },
+ "to_files": {
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "monitoring": {
+ "additionalProperties": false,
+ "properties": {
+ "apm": {},
+ "enabled": {
+ "type": "boolean"
+ },
+ "logs": {
+ "type": "boolean"
+ },
+ "metrics": {
+ "type": "boolean"
+ },
+ "namespace": {
+ "type": "string"
+ },
+ "traces": {
+ "type": "boolean"
+ },
+ "use_output": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "enabled",
+ "metrics",
+ "logs",
+ "traces",
+ "apm"
+ ],
+ "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"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "key": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "key"
+ ],
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a full agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_policies/{agentPolicyId}/outputs": {
+ "get": {
+ "description": "Get a list of outputs associated with agent policy by policy id.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-read, fleet-settings-read].",
+ "operationId": "get-fleet-agent-policies-agentpolicyid-outputs",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "agentPolicyId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get outputs for an agent policy",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/agent_status": {
+ "get": {
+ "operationId": "get-fleet-agent-status",
+ "parameters": [
+ {
+ "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": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "orphaned": {
+ "type": "number"
+ },
+ "other": {
+ "type": "number"
+ },
+ "unenrolled": {
+ "type": "number"
+ },
+ "uninstalled": {
+ "type": "number"
+ },
+ "updating": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "events",
+ "online",
+ "error",
+ "offline",
+ "other",
+ "updating",
+ "inactive",
+ "unenrolled",
+ "all",
+ "active"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "results"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an agent status summary",
+ "tags": [
+ "Elastic Agent status"
+ ]
+ }
+ },
+ "/api/fleet/agent_status/data": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agent-status-data",
+ "parameters": [
+ {
+ "in": "query",
+ "name": "agentsIds",
+ "required": true,
+ "schema": {
+ "anyOf": [
+ {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ }
+ },
+ {
+ "in": "query",
+ "name": "pkgName",
+ "required": false,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "query",
+ "name": "pkgVersion",
+ "required": false,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "query",
+ "name": "previewData",
+ "required": false,
+ "schema": {
+ "default": false,
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get incoming agent data",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agents",
+ "parameters": [
+ {
+ "in": "query",
+ "name": "page",
+ "required": false,
+ "schema": {
+ "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"
+ }
+ },
+ {
+ "in": "query",
+ "name": "searchAfter",
+ "required": false,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "query",
+ "name": "openPit",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ },
+ {
+ "in": "query",
+ "name": "pitId",
+ "required": false,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "query",
+ "name": "pitKeepAlive",
+ "required": false,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "audit_unenrolled_reason": {
+ "type": "string"
+ },
+ "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": {},
+ "type": "array"
+ },
+ "status": {
+ "enum": [
+ "offline",
+ "error",
+ "online",
+ "inactive",
+ "enrolling",
+ "unenrolling",
+ "unenrolled",
+ "updating",
+ "degraded",
+ "uninstalled",
+ "orphaned"
+ ],
+ "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_attempts": {
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "upgrade_details": {
+ "additionalProperties": false,
+ "nullable": true,
+ "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"
+ },
+ "nextSearchAfter": {
+ "type": "string"
+ },
+ "page": {
+ "type": "number"
+ },
+ "perPage": {
+ "type": "number"
+ },
+ "pit": {
+ "type": "string"
+ },
+ "statusSummary": {
+ "additionalProperties": {
+ "type": "number"
+ },
+ "type": "object"
+ },
+ "total": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "items",
+ "total",
+ "page",
+ "perPage"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get agents",
+ "tags": [
+ "Elastic Agents"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "post-fleet-agents",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "actionIds": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "actionIds"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "items"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get agents by action ids",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents/action_status": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agents-action-status",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an agent action status",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/actions/{actionId}/cancel": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-actions-actionid-cancel",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Cancel an agent action",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/available_versions": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agents-available-versions",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "items"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get available agent versions",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents/bulk_reassign": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-bulk-reassign",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "actionId": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "actionId"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk reassign agents",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/bulk_request_diagnostics": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "post-fleet-agents-bulk-request-diagnostics",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "actionId": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "actionId"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk request diagnostics from agents",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/bulk_unenroll": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-bulk-unenroll",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "actionId": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "actionId"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk unenroll agents",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/bulk_update_agent_tags": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-bulk-update-agent-tags",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "actionId": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "actionId"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk update agent tags",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/bulk_upgrade": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-bulk-upgrade",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "actionId": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "actionId"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk upgrade agents",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/files/{fileId}": {
+ "delete": {
+ "description": "Delete a file uploaded by an agent.
[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "delete-fleet-agents-files-fileid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "deleted": {
+ "type": "boolean"
+ },
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "deleted"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete an uploaded file",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents/files/{fileId}/{fileName}": {
+ "get": {
+ "description": "Get a file uploaded by an agent.
[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agents-files-fileid-filename",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "fileId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "fileName",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an uploaded file",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents/setup": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agents-read OR fleet-agent-policies-read OR fleet-settings-read OR fleet-setup].",
+ "operationId": "get-fleet-agents-setup",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get agent setup info",
+ "tags": [
+ "Elastic Agents"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agents-read OR fleet-agent-policies-read OR fleet-settings-read OR fleet-setup].",
+ "operationId": "post-fleet-agents-setup",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Initiate agent setup",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents/tags": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agents-tags",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "items"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get agent tags",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents/{agentId}": {
+ "delete": {
+ "description": "Delete an agent by ID.
[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "delete-fleet-agents-agentid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "action": {
+ "enum": [
+ "deleted"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "action"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete an agent",
+ "tags": [
+ "Elastic Agents"
+ ]
+ },
+ "get": {
+ "description": "Get an agent by ID.
[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agents-agentid",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ },
+ "audit_unenrolled_reason": {
+ "type": "string"
+ },
+ "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": {},
+ "type": "array"
+ },
+ "status": {
+ "enum": [
+ "offline",
+ "error",
+ "online",
+ "inactive",
+ "enrolling",
+ "unenrolling",
+ "unenrolled",
+ "updating",
+ "degraded",
+ "uninstalled",
+ "orphaned"
+ ],
+ "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_attempts": {
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "upgrade_details": {
+ "additionalProperties": false,
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an agent",
+ "tags": [
+ "Elastic Agents"
+ ]
+ },
+ "put": {
+ "description": "Update an agent by ID.
[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "put-fleet-agents-agentid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "tags": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "user_provided_metadata": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "audit_unenrolled_reason": {
+ "type": "string"
+ },
+ "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": {},
+ "type": "array"
+ },
+ "status": {
+ "enum": [
+ "offline",
+ "error",
+ "online",
+ "inactive",
+ "enrolling",
+ "unenrolling",
+ "unenrolled",
+ "updating",
+ "degraded",
+ "uninstalled",
+ "orphaned"
+ ],
+ "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_attempts": {
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "upgrade_details": {
+ "additionalProperties": false,
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update an agent",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/agents/{agentId}/actions": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-agentid-actions",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "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"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create an agent action",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/{agentId}/reassign": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-agentid-reassign",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "policy_id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "policy_id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Reassign an agent",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/{agentId}/request_diagnostics": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "post-fleet-agents-agentid-request-diagnostics",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "additional_metrics": {
+ "items": {
+ "enum": [
+ "CPU"
+ ],
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "actionId": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "actionId"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Request agent diagnostics",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/{agentId}/unenroll": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-agentid-unenroll",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "force": {
+ "type": "boolean"
+ },
+ "revoke": {
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Unenroll an agent",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/{agentId}/upgrade": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-agents-agentid-upgrade",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Upgrade an agent",
+ "tags": [
+ "Elastic Agent actions"
+ ]
+ }
+ },
+ "/api/fleet/agents/{agentId}/uploads": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-read].",
+ "operationId": "get-fleet-agents-agentid-uploads",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "agentId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get agent uploads",
+ "tags": [
+ "Elastic Agents"
+ ]
+ }
+ },
+ "/api/fleet/check-permissions": {
+ "get": {
+ "operationId": "get-fleet-check-permissions",
+ "parameters": [
+ {
+ "in": "query",
+ "name": "fleetServerSetup",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Check permissions",
+ "tags": [
+ "Fleet internals"
+ ]
+ }
+ },
+ "/api/fleet/data_streams": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all, fleet-agent-policies-all, fleet-settings-all].",
+ "operationId": "get-fleet-data-streams",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get data streams",
+ "tags": [
+ "Data streams"
+ ]
+ }
+ },
+ "/api/fleet/enrollment_api_keys": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agents-all OR fleet-setup].",
+ "operationId": "get-fleet-enrollment-api-keys",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get enrollment API keys",
+ "tags": [
+ "Fleet enrollment API keys"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-enrollment-api-keys",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "expiration": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "policy_id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "policy_id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create an enrollment API key",
+ "tags": [
+ "Fleet enrollment API keys"
+ ]
+ }
+ },
+ "/api/fleet/enrollment_api_keys/{keyId}": {
+ "delete": {
+ "description": "Revoke an enrollment API key by ID by marking it as inactive.
[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "delete-fleet-enrollment-api-keys-keyid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "action": {
+ "enum": [
+ "deleted"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "action"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Revoke an enrollment API key",
+ "tags": [
+ "Fleet enrollment API keys"
+ ]
+ },
+ "get": {
+ "description": "Get an enrollment API key by ID.
[Required authorization] Route required privileges: ANY of [fleet-agents-all OR fleet-setup].",
+ "operationId": "get-fleet-enrollment-api-keys-keyid",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "keyId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an enrollment API key",
+ "tags": [
+ "Fleet enrollment API keys"
+ ]
+ }
+ },
+ "/api/fleet/epm/bulk_assets": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "post-fleet-epm-bulk-assets",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk get assets",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/categories": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-categories",
+ "parameters": [
+ {
+ "in": "query",
+ "name": "prerelease",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ },
+ {
+ "in": "query",
+ "name": "include_policy_templates",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ }
+ },
+ "required": [
+ "items"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get package categories",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/custom_integrations": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [integrations-all, fleet-agent-policies-all].",
+ "operationId": "post-fleet-epm-custom-integrations",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create a custom integration",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/data_streams": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-data-streams",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get data streams",
+ "tags": [
+ "Data streams"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-packages",
+ "parameters": [
+ {
+ "in": "query",
+ "name": "category",
+ "required": false,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "query",
+ "name": "prerelease",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ },
+ {
+ "in": "query",
+ "name": "excludeInstallStatus",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ },
+ {
+ "in": "query",
+ "name": "withPackagePoliciesCount",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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"
+ }
+ },
+ "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"
+ },
+ "signature_path": {
+ "type": "string"
+ },
+ "source": {
+ "additionalProperties": true,
+ "properties": {
+ "license": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "license"
+ ],
+ "type": "object"
+ },
+ "status": {
+ "type": "string"
+ },
+ "title": {
+ "type": "string"
+ },
+ "type": {
+ "anyOf": [
+ {
+ "enum": [
+ "integration"
+ ],
+ "type": "string"
+ },
+ {
+ "enum": [
+ "input"
+ ],
+ "type": "string"
+ },
+ {
+ "enum": [
+ "content"
+ ],
+ "type": "string"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "vars": {
+ "items": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "version",
+ "title",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "items"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get packages",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [integrations-all, fleet-agent-policies-all].",
+ "operationId": "post-fleet-epm-packages",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "format": "binary",
+ "type": "string"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/gzip; application/zip": {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Install a package by upload",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages/_bulk": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [integrations-all, fleet-agent-policies-all].",
+ "operationId": "post-fleet-epm-packages-bulk",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk install packages",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages/installed": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-packages-installed",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get installed packages",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages/limited": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-packages-limited",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "items"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a limited package list",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages/{pkgName}/stats": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-packages-pkgname-stats",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "pkgName",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get package stats",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages/{pkgName}/{pkgVersion}": {
+ "delete": {
+ "description": "[Required authorization] Route required privileges: ALL of [integrations-all, fleet-agent-policies-all].",
+ "operationId": "delete-fleet-epm-packages-pkgname-pkgversion",
+ "parameters": [
+ {
+ "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": false,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "query",
+ "name": "force",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ },
+ "originId": {
+ "type": "string"
+ },
+ "type": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete a package",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ },
+ "get": {
+ "operationId": "get-fleet-epm-packages-pkgname-pkgversion",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "pkgName",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "pkgVersion",
+ "required": false,
+ "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": {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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"
+ }
+ },
+ "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"
+ },
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "integration"
+ ],
+ "type": "string"
+ },
+ {
+ "enum": [
+ "input"
+ ],
+ "type": "string"
+ },
+ {
+ "enum": [
+ "content"
+ ],
+ "type": "string"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "vars": {
+ "items": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "version",
+ "title",
+ "assets"
+ ],
+ "type": "object"
+ },
+ "metadata": {
+ "additionalProperties": false,
+ "properties": {
+ "has_policies": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "has_policies"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a package",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [integrations-all, fleet-agent-policies-all].",
+ "operationId": "post-fleet-epm-packages-pkgname-pkgversion",
+ "parameters": [
+ {
+ "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": false,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "force": {
+ "default": false,
+ "type": "boolean"
+ },
+ "ignore_constraints": {
+ "default": false,
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Install a package from the registry",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ },
+ "put": {
+ "description": "[Required authorization] Route required privileges: ALL of [integrations-all, fleet-agent-policies-all].",
+ "operationId": "put-fleet-epm-packages-pkgname-pkgversion",
+ "parameters": [
+ {
+ "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": false,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "keepPoliciesUpToDate": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "keepPoliciesUpToDate"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "dashboard",
+ "lens",
+ "visualization",
+ "search",
+ "index-pattern",
+ "map",
+ "ml-module",
+ "security-rule",
+ "csp-rule-template",
+ "osquery-pack-asset",
+ "osquery-saved-query",
+ "tag"
+ ],
+ "type": "string"
+ },
+ {
+ "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"
+ }
+ },
+ "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"
+ },
+ "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": {
+ "anyOf": [
+ {
+ "enum": [
+ "integration"
+ ],
+ "type": "string"
+ },
+ {
+ "enum": [
+ "input"
+ ],
+ "type": "string"
+ },
+ {
+ "enum": [
+ "content"
+ ],
+ "type": "string"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "vars": {
+ "items": {
+ "additionalProperties": {},
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "version",
+ "title",
+ "assets"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update package settings",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages/{pkgName}/{pkgVersion}/transforms/authorize": {
+ "post": {
+ "operationId": "post-fleet-epm-packages-pkgname-pkgversion-transforms-authorize",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Authorize transforms",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath}": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-packages-pkgname-pkgversion-filepath",
+ "parameters": [
+ {
+ "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": {
+ "schema": {}
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a package file",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/templates/{pkgName}/{pkgVersion}/inputs": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-templates-pkgname-pkgversion-inputs",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get an inputs template",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/epm/verification_key_id": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [integrations-read OR fleet-setup OR fleet-all].",
+ "operationId": "get-fleet-epm-verification-key-id",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "nullable": true,
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a package signature verification key ID",
+ "tags": [
+ "Elastic Package Manager (EPM)"
+ ]
+ }
+ },
+ "/api/fleet/fleet_server_hosts": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agents-all OR fleet-settings-read].",
+ "operationId": "get-fleet-fleet-server-hosts",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "es_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "client_auth": {
+ "enum": [
+ "optional",
+ "required",
+ "none"
+ ],
+ "type": "string"
+ },
+ "es_certificate": {
+ "type": "string"
+ },
+ "es_certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "es_key": {
+ "type": "string"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "host_urls",
+ "id"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "page": {
+ "type": "number"
+ },
+ "perPage": {
+ "type": "number"
+ },
+ "total": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "items",
+ "total",
+ "page",
+ "perPage"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get Fleet Server hosts",
+ "tags": [
+ "Fleet Server hosts"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "post-fleet-fleet-server-hosts",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "es_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "client_auth": {
+ "enum": [
+ "optional",
+ "required",
+ "none"
+ ],
+ "type": "string"
+ },
+ "es_certificate": {
+ "type": "string"
+ },
+ "es_certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "es_key": {
+ "type": "string"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "host_urls"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "es_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "client_auth": {
+ "enum": [
+ "optional",
+ "required",
+ "none"
+ ],
+ "type": "string"
+ },
+ "es_certificate": {
+ "type": "string"
+ },
+ "es_certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "es_key": {
+ "type": "string"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "host_urls",
+ "id"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create a Fleet Server host",
+ "tags": [
+ "Fleet Server hosts"
+ ]
+ }
+ },
+ "/api/fleet/fleet_server_hosts/{itemId}": {
+ "delete": {
+ "description": "Delete a Fleet Server host by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "delete-fleet-fleet-server-hosts-itemid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete a Fleet Server host",
+ "tags": [
+ "Fleet Server hosts"
+ ]
+ },
+ "get": {
+ "description": "Get a Fleet Server host by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-read].",
+ "operationId": "get-fleet-fleet-server-hosts-itemid",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "itemId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "es_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "client_auth": {
+ "enum": [
+ "optional",
+ "required",
+ "none"
+ ],
+ "type": "string"
+ },
+ "es_certificate": {
+ "type": "string"
+ },
+ "es_certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "es_key": {
+ "type": "string"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "host_urls",
+ "id"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a Fleet Server host",
+ "tags": [
+ "Fleet Server hosts"
+ ]
+ },
+ "put": {
+ "description": "Update a Fleet Server host by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "put-fleet-fleet-server-hosts-itemid",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "es_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "client_auth": {
+ "enum": [
+ "optional",
+ "required",
+ "none"
+ ],
+ "type": "string"
+ },
+ "es_certificate": {
+ "type": "string"
+ },
+ "es_certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "es_key": {
+ "type": "string"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "proxy_id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "ssl": {
+ "additionalProperties": false,
+ "properties": {
+ "es_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "type": "object"
+ },
+ "ssl": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "certificate": {
+ "type": "string"
+ },
+ "certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "client_auth": {
+ "enum": [
+ "optional",
+ "required",
+ "none"
+ ],
+ "type": "string"
+ },
+ "es_certificate": {
+ "type": "string"
+ },
+ "es_certificate_authorities": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "es_key": {
+ "type": "string"
+ },
+ "key": {
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "name",
+ "host_urls",
+ "id"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update a Fleet Server host",
+ "tags": [
+ "Fleet Server hosts"
+ ]
+ }
+ },
+ "/api/fleet/health_check": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "post-fleet-health-check",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "host_id": {
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "status": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "status"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Check Fleet Server health",
+ "tags": [
+ "Fleet internals"
+ ]
+ }
+ },
+ "/api/fleet/kubernetes": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agent-policies-read, fleet-setup].",
+ "operationId": "get-fleet-kubernetes",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a full K8s agent manifest",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/kubernetes/download": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agent-policies-read, fleet-setup].",
+ "operationId": "get-fleet-kubernetes-download",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "type": "string"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Download an agent manifest",
+ "tags": [
+ "Elastic Agent policies"
+ ]
+ }
+ },
+ "/api/fleet/logstash_api_keys": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "post-fleet-logstash-api-keys",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "api_key": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "api_key"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Generate a Logstash API key",
+ "tags": [
+ "Fleet outputs"
+ ]
+ }
+ },
+ "/api/fleet/message_signing_service/rotate_key_pair": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all, fleet-agent-policies-all, fleet-settings-all].",
+ "operationId": "post-fleet-message-signing-service-rotate-key-pair",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "500": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Rotate a Fleet message signing key pair",
+ "tags": [
+ "Message Signing Service"
+ ]
+ }
+ },
+ "/api/fleet/outputs": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-settings-read OR fleet-agent-policies-read].",
+ "operationId": "get-fleet-outputs",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "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": [
+ "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"
+ },
+ "kibana_api_key": {
+ "nullable": true,
+ "type": "string"
+ },
+ "kibana_url": {
+ "nullable": true,
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "preset": {
+ "enum": [
+ "balanced",
+ "custom",
+ "throughput",
+ "scale",
+ "latency"
+ ],
+ "type": "string"
+ },
+ "proxy_id": {
+ "nullable": true,
+ "type": "string"
+ },
+ "secrets": {
+ "additionalProperties": true,
+ "properties": {
+ "kibana_api_key": {
+ "anyOf": [
+ {
+ "additionalProperties": true,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "service_token": {
+ "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"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "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"
+ },
+ "sync_integrations": {
+ "type": "boolean"
+ },
+ "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"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get outputs",
+ "tags": [
+ "Fleet outputs"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "post-fleet-outputs",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ },
+ "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": [
+ "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"
+ },
+ "kibana_api_key": {
+ "nullable": true,
+ "type": "string"
+ },
+ "kibana_url": {
+ "nullable": true,
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "preset": {
+ "enum": [
+ "balanced",
+ "custom",
+ "throughput",
+ "scale",
+ "latency"
+ ],
+ "type": "string"
+ },
+ "proxy_id": {
+ "nullable": true,
+ "type": "string"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "kibana_api_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "service_token": {
+ "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"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "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"
+ },
+ "sync_integrations": {
+ "type": "boolean"
+ },
+ "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"
+ },
+ "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": {
+ "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"
+ },
+ "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": [
+ "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"
+ },
+ "kibana_api_key": {
+ "nullable": true,
+ "type": "string"
+ },
+ "kibana_url": {
+ "nullable": true,
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "preset": {
+ "enum": [
+ "balanced",
+ "custom",
+ "throughput",
+ "scale",
+ "latency"
+ ],
+ "type": "string"
+ },
+ "proxy_id": {
+ "nullable": true,
+ "type": "string"
+ },
+ "secrets": {
+ "additionalProperties": true,
+ "properties": {
+ "kibana_api_key": {
+ "anyOf": [
+ {
+ "additionalProperties": true,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "service_token": {
+ "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"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "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"
+ },
+ "sync_integrations": {
+ "type": "boolean"
+ },
+ "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"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create output",
+ "tags": [
+ "Fleet outputs"
+ ]
+ }
+ },
+ "/api/fleet/outputs/{outputId}": {
+ "delete": {
+ "description": "Delete output by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "delete-fleet-outputs-outputid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete output",
+ "tags": [
+ "Fleet outputs"
+ ]
+ },
+ "get": {
+ "description": "Get output by ID.
[Required authorization] Route required privileges: ANY of [fleet-settings-read OR fleet-agent-policies-read].",
+ "operationId": "get-fleet-outputs-outputid",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "outputId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ },
+ "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": [
+ "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"
+ },
+ "kibana_api_key": {
+ "nullable": true,
+ "type": "string"
+ },
+ "kibana_url": {
+ "nullable": true,
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "preset": {
+ "enum": [
+ "balanced",
+ "custom",
+ "throughput",
+ "scale",
+ "latency"
+ ],
+ "type": "string"
+ },
+ "proxy_id": {
+ "nullable": true,
+ "type": "string"
+ },
+ "secrets": {
+ "additionalProperties": true,
+ "properties": {
+ "kibana_api_key": {
+ "anyOf": [
+ {
+ "additionalProperties": true,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "service_token": {
+ "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"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "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"
+ },
+ "sync_integrations": {
+ "type": "boolean"
+ },
+ "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"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get output",
+ "tags": [
+ "Fleet outputs"
+ ]
+ },
+ "put": {
+ "description": "Update output by ID.
[Required authorization] Route required privileges: ANY of [fleet-settings-all OR fleet-agent-policies-all].",
+ "operationId": "put-fleet-outputs-outputid",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ },
+ "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": [
+ "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"
+ },
+ "kibana_api_key": {
+ "nullable": true,
+ "type": "string"
+ },
+ "kibana_url": {
+ "nullable": true,
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "preset": {
+ "enum": [
+ "balanced",
+ "custom",
+ "throughput",
+ "scale",
+ "latency"
+ ],
+ "type": "string"
+ },
+ "proxy_id": {
+ "nullable": true,
+ "type": "string"
+ },
+ "secrets": {
+ "additionalProperties": false,
+ "properties": {
+ "kibana_api_key": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "service_token": {
+ "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"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "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"
+ },
+ "sync_integrations": {
+ "type": "boolean"
+ },
+ "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"
+ },
+ "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": {
+ "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"
+ },
+ "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": [
+ "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"
+ },
+ "kibana_api_key": {
+ "nullable": true,
+ "type": "string"
+ },
+ "kibana_url": {
+ "nullable": true,
+ "type": "string"
+ },
+ "name": {
+ "type": "string"
+ },
+ "preset": {
+ "enum": [
+ "balanced",
+ "custom",
+ "throughput",
+ "scale",
+ "latency"
+ ],
+ "type": "string"
+ },
+ "proxy_id": {
+ "nullable": true,
+ "type": "string"
+ },
+ "secrets": {
+ "additionalProperties": true,
+ "properties": {
+ "kibana_api_key": {
+ "anyOf": [
+ {
+ "additionalProperties": true,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ]
+ },
+ "service_token": {
+ "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"
+ }
+ ]
+ }
+ },
+ "type": "object"
+ }
+ },
+ "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"
+ },
+ "sync_integrations": {
+ "type": "boolean"
+ },
+ "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"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update output",
+ "tags": [
+ "Fleet outputs"
+ ]
+ }
+ },
+ "/api/fleet/outputs/{outputId}/health": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-read].",
+ "operationId": "get-fleet-outputs-outputid-health",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "outputId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get the latest output health",
+ "tags": [
+ "Fleet outputs"
+ ]
+ }
+ },
+ "/api/fleet/package_policies": {
+ "get": {
+ "operationId": "get-fleet-package-policies",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get package policies",
+ "tags": [
+ "Fleet package policies"
+ ]
+ },
+ "post": {
+ "operationId": "post-fleet-package-policies",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": 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"
+ }
+ },
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "409": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create a package policy",
+ "tags": [
+ "Fleet package policies"
+ ]
+ }
+ },
+ "/api/fleet/package_policies/_bulk_get": {
+ "post": {
+ "operationId": "post-fleet-package-policies-bulk-get",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "ids": {
+ "description": "list of package policy ids",
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "ignoreMissing": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "ids"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ },
+ "required": [
+ "items"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk get package policies",
+ "tags": [
+ "Fleet package policies"
+ ]
+ }
+ },
+ "/api/fleet/package_policies/delete": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agent-policies-all, integrations-all].",
+ "operationId": "post-fleet-package-policies-delete",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "force": {
+ "type": "boolean"
+ },
+ "packagePolicyIds": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "packagePolicyIds"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "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": "Use `policy_ids` instead",
+ "nullable": true,
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Bulk delete package policies",
+ "tags": [
+ "Fleet package policies"
+ ]
+ }
+ },
+ "/api/fleet/package_policies/upgrade": {
+ "post": {
+ "description": "Upgrade a package policy to a newer package version.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-all, integrations-all].",
+ "operationId": "post-fleet-package-policies-upgrade",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "packagePolicyIds": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "packagePolicyIds"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Upgrade a package policy",
+ "tags": [
+ "Fleet package policies"
+ ]
+ }
+ },
+ "/api/fleet/package_policies/upgrade/dryrun": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agent-policies-read, integrations-read].",
+ "operationId": "post-fleet-package-policies-upgrade-dryrun",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "packagePolicyIds": {
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "packageVersion": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "packagePolicyIds"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "agent_diff": {
+ "items": {
+ "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"
+ }
+ },
+ "required": [
+ "package"
+ ],
+ "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"
+ },
+ "type": "array"
+ },
+ "body": {
+ "additionalProperties": false,
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ },
+ "diff": {
+ "items": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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",
+ "revision",
+ "updated_at",
+ "updated_by",
+ "created_at",
+ "created_by"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "description": {
+ "description": "Package policy description",
+ "type": "string"
+ },
+ "enabled": {
+ "type": "boolean"
+ },
+ "errors": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "key": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ },
+ "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": {
+ "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"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "is_managed": {
+ "type": "boolean"
+ },
+ "missingVars": {
+ "items": {
+ "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"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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",
+ "enabled",
+ "inputs"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "array"
+ },
+ "hasErrors": {
+ "type": "boolean"
+ },
+ "name": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "hasErrors"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Dry run a package policy upgrade",
+ "tags": [
+ "Fleet package policies"
+ ]
+ }
+ },
+ "/api/fleet/package_policies/{packagePolicyId}": {
+ "delete": {
+ "description": "Delete a package policy by ID.
[Required authorization] Route required privileges: ALL of [fleet-agent-policies-all, integrations-all].",
+ "operationId": "delete-fleet-package-policies-packagepolicyid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete a package policy",
+ "tags": [
+ "Fleet package policies"
+ ]
+ },
+ "get": {
+ "description": "Get a package policy by ID.",
+ "operationId": "get-fleet-package-policies-packagepolicyid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a package policy",
+ "tags": [
+ "Fleet package policies"
+ ]
+ },
+ "put": {
+ "description": "Update a package policy by ID.",
+ "operationId": "put-fleet-package-policies-packagepolicyid",
+ "parameters": [
+ {
+ "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": "format",
+ "required": false,
+ "schema": {
+ "enum": [
+ "simplified",
+ "legacy"
+ ],
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "description": {
+ "description": "Package policy description",
+ "type": "string"
+ },
+ "enabled": {
+ "type": "boolean"
+ },
+ "force": {
+ "type": "boolean"
+ },
+ "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": {
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ },
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": 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"
+ }
+ },
+ "required": [
+ "name",
+ "package"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "additional_datastreams_permissions": {
+ "description": "Additional datastream permissions, that will be added to the agent policy.",
+ "items": {
+ "type": "string"
+ },
+ "nullable": true,
+ "type": "array"
+ },
+ "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"
+ },
+ "supports_agentless": {
+ "default": false,
+ "description": "Indicates whether the package policy belongs to an agentless agent policy.",
+ "nullable": true,
+ "type": "boolean"
+ },
+ "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"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "403": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update a package policy",
+ "tags": [
+ "Fleet package policies"
+ ]
+ }
+ },
+ "/api/fleet/proxies": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-read].",
+ "operationId": "get-fleet-proxies",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get proxies",
+ "tags": [
+ "Fleet proxies"
+ ]
+ },
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "post-fleet-proxies",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create a proxy",
+ "tags": [
+ "Fleet proxies"
+ ]
+ }
+ },
+ "/api/fleet/proxies/{itemId}": {
+ "delete": {
+ "description": "Delete a proxy by ID
[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "delete-fleet-proxies-itemid",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Delete a proxy",
+ "tags": [
+ "Fleet proxies"
+ ]
+ },
+ "get": {
+ "description": "Get a proxy by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-read].",
+ "operationId": "get-fleet-proxies-itemid",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "itemId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a proxy",
+ "tags": [
+ "Fleet proxies"
+ ]
+ },
+ "put": {
+ "description": "Update a proxy by ID.
[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "put-fleet-proxies-itemid",
+ "parameters": [
+ {
+ "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": {
+ "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"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update a proxy",
+ "tags": [
+ "Fleet proxies"
+ ]
+ }
+ },
+ "/api/fleet/service_tokens": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "post-fleet-service-tokens",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "nullable": true,
+ "properties": {
+ "remote": {
+ "default": false,
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "name": {
+ "type": "string"
+ },
+ "value": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name",
+ "value"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Create a service token",
+ "tags": [
+ "Fleet service tokens"
+ ]
+ }
+ },
+ "/api/fleet/settings": {
+ "get": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-read].",
+ "operationId": "get-fleet-settings",
+ "parameters": [],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "delete_unenrolled_agents": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "is_preconfigured": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "enabled",
+ "is_preconfigured"
+ ],
+ "type": "object"
+ },
+ "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"
+ },
+ "use_space_awareness_migration_started_at": {
+ "nullable": true,
+ "type": "string"
+ },
+ "use_space_awareness_migration_status": {
+ "enum": [
+ "pending",
+ "success",
+ "error"
+ ],
+ "type": "string"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get settings",
+ "tags": [
+ "Fleet internals"
+ ]
+ },
+ "put": {
+ "description": "[Required authorization] Route required privileges: ALL of [fleet-settings-all].",
+ "operationId": "put-fleet-settings",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "additional_yaml_config": {
+ "type": "string"
+ },
+ "delete_unenrolled_agents": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "is_preconfigured": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "enabled",
+ "is_preconfigured"
+ ],
+ "type": "object"
+ },
+ "has_seen_add_data_notice": {
+ "type": "boolean"
+ },
+ "kibana_ca_sha256": {
+ "type": "string"
+ },
+ "kibana_urls": {
+ "items": {
+ "format": "uri",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "prerelease_integrations_enabled": {
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "item": {
+ "additionalProperties": false,
+ "properties": {
+ "delete_unenrolled_agents": {
+ "additionalProperties": false,
+ "properties": {
+ "enabled": {
+ "type": "boolean"
+ },
+ "is_preconfigured": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "enabled",
+ "is_preconfigured"
+ ],
+ "type": "object"
+ },
+ "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"
+ },
+ "use_space_awareness_migration_started_at": {
+ "nullable": true,
+ "type": "string"
+ },
+ "use_space_awareness_migration_status": {
+ "enum": [
+ "pending",
+ "success",
+ "error"
+ ],
+ "type": "string"
+ },
+ "version": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "item"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "404": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Update settings",
+ "tags": [
+ "Fleet internals"
+ ]
+ }
+ },
+ "/api/fleet/setup": {
+ "post": {
+ "description": "[Required authorization] Route required privileges: ANY of [fleet-agents-read OR fleet-agent-policies-read OR fleet-settings-read OR fleet-setup].",
+ "operationId": "post-fleet-setup",
+ "parameters": [
+ {
+ "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": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "500": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Internal Server Error",
+ "properties": {
+ "message": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "message"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Initiate Fleet setup",
+ "tags": [
+ "Fleet internals"
+ ]
+ }
+ },
+ "/api/fleet/uninstall_tokens": {
+ "get": {
+ "description": "List the metadata for the latest uninstall tokens per agent policy.
[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "get-fleet-uninstall-tokens",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "items": {
+ "items": {
+ "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"
+ }
+ },
+ "required": [
+ "id",
+ "policy_id",
+ "created_at"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "page": {
+ "type": "number"
+ },
+ "perPage": {
+ "type": "number"
+ },
+ "total": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "items",
+ "total",
+ "page",
+ "perPage"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "400": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get metadata for latest uninstall tokens",
+ "tags": [
+ "Fleet uninstall tokens"
+ ]
+ }
+ },
+ "/api/fleet/uninstall_tokens/{uninstallTokenId}": {
+ "get": {
+ "description": "Get one decrypted uninstall token by its ID.
[Required authorization] Route required privileges: ALL of [fleet-agents-all].",
+ "operationId": "get-fleet-uninstall-tokens-uninstalltokenid",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "uninstallTokenId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "description": "Generic Error",
+ "properties": {
+ "attributes": {},
+ "error": {
+ "type": "string"
+ },
+ "message": {
+ "type": "string"
+ },
+ "statusCode": {
+ "type": "number"
+ }
+ },
+ "required": [
+ "message",
+ "attributes"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ }
+ },
+ "summary": "Get a decrypted uninstall token",
+ "tags": [
+ "Fleet uninstall tokens"
+ ]
+ }
+ },
+ "/api/security/role": {
+ "get": {
+ "operationId": "get-security-role",
+ "parameters": [
+ {
+ "description": "If `true` and the response contains any privileges that are associated with deprecated features, they are omitted in favor of details about the appropriate replacement feature privileges.",
+ "in": "query",
+ "name": "replaceDeprecatedPrivileges",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Get all roles",
+ "tags": [
+ "roles"
+ ]
+ }
+ },
+ "/api/security/role/_query": {
+ "post": {
+ "operationId": "post-security-role-query",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "filters": {
+ "additionalProperties": false,
+ "properties": {
+ "showReservedRoles": {
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+ },
+ "from": {
+ "type": "number"
+ },
+ "query": {
+ "type": "string"
+ },
+ "size": {
+ "type": "number"
+ },
+ "sort": {
+ "additionalProperties": false,
+ "properties": {
+ "direction": {
+ "enum": [
+ "asc",
+ "desc"
+ ],
+ "type": "string"
+ },
+ "field": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "direction"
+ ],
+ "type": "object"
+ }
+ },
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Query roles",
+ "tags": []
+ }
+ },
+ "/api/security/role/{name}": {
+ "delete": {
+ "operationId": "delete-security-role-name",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "minLength": 1,
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "204": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Delete a role",
+ "tags": [
+ "roles"
+ ]
+ },
+ "get": {
+ "operationId": "get-security-role-name",
+ "parameters": [
+ {
+ "description": "The role name.",
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ {
+ "description": "If `true` and the response contains any privileges that are associated with deprecated features, they are omitted in favor of details about the appropriate replacement feature privileges.",
+ "in": "query",
+ "name": "replaceDeprecatedPrivileges",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Get a role",
+ "tags": [
+ "roles"
+ ]
+ },
+ "put": {
+ "description": "Create a new Kibana role or update the attributes of an existing role. Kibana roles are stored in the Elasticsearch native realm.",
+ "operationId": "put-security-role-name",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "description": "The role name.",
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "maxLength": 1024,
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ {
+ "description": "When true, a role is not overwritten if it already exists.",
+ "in": "query",
+ "name": "createOnly",
+ "required": false,
+ "schema": {
+ "default": false,
+ "type": "boolean"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "description": {
+ "description": "A description for the role.",
+ "maxLength": 2048,
+ "type": "string"
+ },
+ "elasticsearch": {
+ "additionalProperties": false,
+ "properties": {
+ "cluster": {
+ "items": {
+ "description": "Cluster privileges that define the cluster level actions that users can perform.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "indices": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "allow_restricted_indices": {
+ "description": "Restricted indices are a special category of indices that are used internally to store configuration data and should not be directly accessed. Only internal system roles should normally grant privileges over the restricted indices. Toggling this flag is very strongly discouraged because it could effectively grant unrestricted operations on critical data, making the entire system unstable or leaking sensitive information. If for administrative purposes you need to create a role with privileges covering restricted indices, however, you can set this property to true. In that case, the names field covers the restricted indices too.",
+ "type": "boolean"
+ },
+ "field_security": {
+ "additionalProperties": {
+ "items": {
+ "description": "The document fields that the role members have read access to.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "type": "object"
+ },
+ "names": {
+ "items": {
+ "description": "The data streams, indices, and aliases to which the permissions in this entry apply. It supports wildcards (*).",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "privileges": {
+ "items": {
+ "description": "The index level privileges that the role members have for the data streams and indices.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "query": {
+ "description": "A search query that defines the documents the role members have read access to. A document within the specified data streams and indices must match this query in order for it to be accessible by the role members.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "names",
+ "privileges"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "remote_cluster": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "clusters": {
+ "items": {
+ "description": "A list of remote cluster aliases. It supports literal strings as well as wildcards and regular expressions.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "privileges": {
+ "items": {
+ "description": "The cluster level privileges for the remote cluster. The allowed values are a subset of the cluster privileges.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ }
+ },
+ "required": [
+ "privileges",
+ "clusters"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "remote_indices": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "allow_restricted_indices": {
+ "description": "Restricted indices are a special category of indices that are used internally to store configuration data and should not be directly accessed. Only internal system roles should normally grant privileges over the restricted indices. Toggling this flag is very strongly discouraged because it could effectively grant unrestricted operations on critical data, making the entire system unstable or leaking sensitive information. If for administrative purposes you need to create a role with privileges covering restricted indices, however, you can set this property to true. In that case, the names field will cover the restricted indices too.",
+ "type": "boolean"
+ },
+ "clusters": {
+ "items": {
+ "description": "A list of remote cluster aliases. It supports literal strings as well as wildcards and regular expressions.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "field_security": {
+ "additionalProperties": {
+ "items": {
+ "description": "The document fields that the role members have read access to.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "type": "object"
+ },
+ "names": {
+ "items": {
+ "description": "A list of remote aliases, data streams, or indices to which the permissions apply. It supports wildcards (*).",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "privileges": {
+ "items": {
+ "description": "The index level privileges that role members have for the specified indices.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "query": {
+ "description": "A search query that defines the documents the role members have read access to. A document within the specified data streams and indices must match this query in order for it to be accessible by the role members. ",
+ "type": "string"
+ }
+ },
+ "required": [
+ "clusters",
+ "names",
+ "privileges"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "run_as": {
+ "items": {
+ "description": "A user name that the role member can impersonate.",
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "type": "object"
+ },
+ "kibana": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "base": {
+ "anyOf": [
+ {
+ "items": {},
+ "type": "array"
+ },
+ {
+ "type": "boolean"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ],
+ "nullable": true,
+ "oneOf": [
+ {
+ "items": {
+ "description": "A base privilege that grants applies to all spaces.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ {
+ "items": {
+ "description": "A base privilege that applies to specific spaces.",
+ "type": "string"
+ },
+ "type": "array"
+ }
+ ]
+ },
+ "feature": {
+ "additionalProperties": {
+ "items": {
+ "description": "The privileges that the role member has for the feature.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "type": "object"
+ },
+ "spaces": {
+ "anyOf": [
+ {
+ "items": {
+ "enum": [
+ "*"
+ ],
+ "type": "string"
+ },
+ "maxItems": 1,
+ "minItems": 1,
+ "type": "array"
+ },
+ {
+ "items": {
+ "description": "A space that the privilege applies to.",
+ "type": "string"
+ },
+ "type": "array"
+ }
+ ],
+ "default": [
+ "*"
+ ]
+ }
+ },
+ "required": [
+ "base"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "metadata": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "elasticsearch"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "204": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Create or update a role",
+ "tags": [
+ "roles"
+ ]
+ }
+ },
+ "/api/security/roles": {
+ "post": {
+ "operationId": "post-security-roles",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "roles": {
+ "additionalProperties": {
+ "additionalProperties": false,
+ "properties": {
+ "description": {
+ "description": "A description for the role.",
+ "maxLength": 2048,
+ "type": "string"
+ },
+ "elasticsearch": {
+ "additionalProperties": false,
+ "properties": {
+ "cluster": {
+ "items": {
+ "description": "Cluster privileges that define the cluster level actions that users can perform.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "indices": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "allow_restricted_indices": {
+ "description": "Restricted indices are a special category of indices that are used internally to store configuration data and should not be directly accessed. Only internal system roles should normally grant privileges over the restricted indices. Toggling this flag is very strongly discouraged because it could effectively grant unrestricted operations on critical data, making the entire system unstable or leaking sensitive information. If for administrative purposes you need to create a role with privileges covering restricted indices, however, you can set this property to true. In that case, the names field covers the restricted indices too.",
+ "type": "boolean"
+ },
+ "field_security": {
+ "additionalProperties": {
+ "items": {
+ "description": "The document fields that the role members have read access to.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "type": "object"
+ },
+ "names": {
+ "items": {
+ "description": "The data streams, indices, and aliases to which the permissions in this entry apply. It supports wildcards (*).",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "privileges": {
+ "items": {
+ "description": "The index level privileges that the role members have for the data streams and indices.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "query": {
+ "description": "A search query that defines the documents the role members have read access to. A document within the specified data streams and indices must match this query in order for it to be accessible by the role members.",
+ "type": "string"
+ }
+ },
+ "required": [
+ "names",
+ "privileges"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "remote_cluster": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "clusters": {
+ "items": {
+ "description": "A list of remote cluster aliases. It supports literal strings as well as wildcards and regular expressions.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "privileges": {
+ "items": {
+ "description": "The cluster level privileges for the remote cluster. The allowed values are a subset of the cluster privileges.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ }
+ },
+ "required": [
+ "privileges",
+ "clusters"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "remote_indices": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "allow_restricted_indices": {
+ "description": "Restricted indices are a special category of indices that are used internally to store configuration data and should not be directly accessed. Only internal system roles should normally grant privileges over the restricted indices. Toggling this flag is very strongly discouraged because it could effectively grant unrestricted operations on critical data, making the entire system unstable or leaking sensitive information. If for administrative purposes you need to create a role with privileges covering restricted indices, however, you can set this property to true. In that case, the names field will cover the restricted indices too.",
+ "type": "boolean"
+ },
+ "clusters": {
+ "items": {
+ "description": "A list of remote cluster aliases. It supports literal strings as well as wildcards and regular expressions.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "field_security": {
+ "additionalProperties": {
+ "items": {
+ "description": "The document fields that the role members have read access to.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "type": "object"
+ },
+ "names": {
+ "items": {
+ "description": "A list of remote aliases, data streams, or indices to which the permissions apply. It supports wildcards (*).",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "privileges": {
+ "items": {
+ "description": "The index level privileges that role members have for the specified indices.",
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ },
+ "query": {
+ "description": "A search query that defines the documents the role members have read access to. A document within the specified data streams and indices must match this query in order for it to be accessible by the role members. ",
+ "type": "string"
+ }
+ },
+ "required": [
+ "clusters",
+ "names",
+ "privileges"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "run_as": {
+ "items": {
+ "description": "A user name that the role member can impersonate.",
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "type": "object"
+ },
+ "kibana": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "base": {
+ "anyOf": [
+ {
+ "items": {},
+ "type": "array"
+ },
+ {
+ "type": "boolean"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ],
+ "nullable": true,
+ "oneOf": [
+ {
+ "items": {
+ "description": "A base privilege that grants applies to all spaces.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ {
+ "items": {
+ "description": "A base privilege that applies to specific spaces.",
+ "type": "string"
+ },
+ "type": "array"
+ }
+ ]
+ },
+ "feature": {
+ "additionalProperties": {
+ "items": {
+ "description": "The privileges that the role member has for the feature.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "type": "object"
+ },
+ "spaces": {
+ "anyOf": [
+ {
+ "items": {
+ "enum": [
+ "*"
+ ],
+ "type": "string"
+ },
+ "maxItems": 1,
+ "minItems": 1,
+ "type": "array"
+ },
+ {
+ "items": {
+ "description": "A space that the privilege applies to.",
+ "type": "string"
+ },
+ "type": "array"
+ }
+ ],
+ "default": [
+ "*"
+ ]
+ }
+ },
+ "required": [
+ "base"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "metadata": {
+ "additionalProperties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "elasticsearch"
+ ],
+ "type": "object"
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "roles"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Create or update roles",
+ "tags": [
+ "roles"
+ ]
+ }
+ },
+ "/api/spaces/space": {
+ "get": {
+ "operationId": "get-spaces-space",
+ "parameters": [
+ {
+ "description": "Specifies which authorization checks are applied to the API call. The default value is `any`.",
+ "in": "query",
+ "name": "purpose",
+ "required": false,
+ "schema": {
+ "enum": [
+ "any",
+ "copySavedObjectsIntoSpace",
+ "shareSavedObjectsIntoSpace"
+ ],
+ "type": "string"
+ }
+ },
+ {
+ "description": "When enabled, the API returns any spaces that the user is authorized to access in any capacity and each space will contain the purposes for which the user is authorized. This can be useful to determine which spaces a user can read but not take a specific action in. If the security plugin is not enabled, this parameter has no effect, since no authorization checks take place. This parameter cannot be used in with the `purpose` parameter.",
+ "in": "query",
+ "name": "include_authorized_purposes",
+ "required": true,
+ "schema": {
+ "anyOf": [
+ {
+ "items": {},
+ "type": "array"
+ },
+ {
+ "type": "boolean"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "object"
+ },
+ {
+ "type": "string"
+ }
+ ],
+ "nullable": true,
+ "oneOf": [
+ {
+ "enum": [
+ false
+ ],
+ "type": "boolean",
+ "x-oas-optional": true
+ },
+ {
+ "type": "boolean",
+ "x-oas-optional": true
+ }
+ ]
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Get all spaces",
+ "tags": [
+ "spaces"
+ ]
+ },
+ "post": {
+ "operationId": "post-spaces-space",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "_reserved": {
+ "type": "boolean"
+ },
+ "color": {
+ "description": "The hexadecimal color code used in the space avatar. By default, the color is automatically generated from the space name.",
+ "type": "string"
+ },
+ "description": {
+ "description": "A description for the space.",
+ "type": "string"
+ },
+ "disabledFeatures": {
+ "default": [],
+ "items": {
+ "description": "The list of features that are turned off in the space.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "id": {
+ "description": "The space ID that is part of the Kibana URL when inside the space. Space IDs are limited to lowercase alphanumeric, underscore, and hyphen characters (a-z, 0-9, _, and -). You are cannot change the ID with the update operation.",
+ "type": "string"
+ },
+ "imageUrl": {
+ "description": "The data-URL encoded image to display in the space avatar. If specified, initials will not be displayed and the color will be visible as the background color for transparent images. For best results, your image should be 64x64. Images will not be optimized by this API call, so care should be taken when using custom images.",
+ "type": "string"
+ },
+ "initials": {
+ "description": "One or two characters that are shown in the space avatar. By default, the initials are automatically generated from the space name.",
+ "maxLength": 2,
+ "type": "string"
+ },
+ "name": {
+ "description": "The display name for the space. ",
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "name"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Create a space",
+ "tags": [
+ "spaces"
+ ]
+ }
+ },
+ "/api/spaces/space/{id}": {
+ "delete": {
+ "description": "When you delete a space, all saved objects that belong to the space are automatically deleted, which is permanent and cannot be undone.",
+ "operationId": "delete-spaces-space-id",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "description": "The space identifier.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "204": {
+ "description": "Indicates a successful call."
+ },
+ "404": {
+ "description": "Indicates that the request failed."
+ }
+ },
+ "summary": "Delete a space",
+ "tags": [
+ "spaces"
+ ]
+ },
+ "get": {
+ "operationId": "get-spaces-space-id",
+ "parameters": [
+ {
+ "description": "The space identifier.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Get a space",
+ "tags": [
+ "spaces"
+ ]
+ },
+ "put": {
+ "operationId": "put-spaces-space-id",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "description": "The space identifier. You are unable to change the ID with the update operation.",
+ "in": "path",
+ "name": "id",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "_reserved": {
+ "type": "boolean"
+ },
+ "color": {
+ "description": "The hexadecimal color code used in the space avatar. By default, the color is automatically generated from the space name.",
+ "type": "string"
+ },
+ "description": {
+ "description": "A description for the space.",
+ "type": "string"
+ },
+ "disabledFeatures": {
+ "default": [],
+ "items": {
+ "description": "The list of features that are turned off in the space.",
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "id": {
+ "description": "The space ID that is part of the Kibana URL when inside the space. Space IDs are limited to lowercase alphanumeric, underscore, and hyphen characters (a-z, 0-9, _, and -). You are cannot change the ID with the update operation.",
+ "type": "string"
+ },
+ "imageUrl": {
+ "description": "The data-URL encoded image to display in the space avatar. If specified, initials will not be displayed and the color will be visible as the background color for transparent images. For best results, your image should be 64x64. Images will not be optimized by this API call, so care should be taken when using custom images.",
+ "type": "string"
+ },
+ "initials": {
+ "description": "One or two characters that are shown in the space avatar. By default, the initials are automatically generated from the space name.",
+ "maxLength": 2,
+ "type": "string"
+ },
+ "name": {
+ "description": "The display name for the space. ",
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "id",
+ "name"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {
+ "200": {
+ "description": "Indicates a successful call."
+ }
+ },
+ "summary": "Update a space",
+ "tags": [
+ "spaces"
+ ]
+ }
+ },
+ "/api/status": {
+ "get": {
+ "operationId": "get-status",
+ "parameters": [
+ {
+ "description": "Set to \"true\" to get the response in v7 format.",
+ "in": "query",
+ "name": "v7format",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ },
+ {
+ "description": "Set to \"true\" to get the response in v8 format.",
+ "in": "query",
+ "name": "v8format",
+ "required": false,
+ "schema": {
+ "type": "boolean"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "$ref": "#/components/schemas/core_status_response"
+ },
+ {
+ "$ref": "#/components/schemas/core_status_redactedResponse"
+ }
+ ],
+ "description": "Kibana's operational status. A minimal response is sent for unauthorized users."
+ }
+ }
+ },
+ "description": "Overall status is OK and Kibana should be functioning normally."
+ },
+ "503": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "$ref": "#/components/schemas/core_status_response"
+ },
+ {
+ "$ref": "#/components/schemas/core_status_redactedResponse"
+ }
+ ],
+ "description": "Kibana's operational status. A minimal response is sent for unauthorized users."
+ }
+ }
+ },
+ "description": "Kibana or some of it's essential services are unavailable. Kibana may be degraded or unavailable."
+ }
+ },
+ "summary": "Get Kibana's current status",
+ "tags": [
+ "system"
+ ]
+ }
+ },
+ "/api/streams": {
+ "get": {
+ "description": "Fetches list of all streams",
+ "operationId": "get-streams",
+ "parameters": [],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Get stream list",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/_disable": {
+ "post": {
+ "description": "Disables wired streams and deletes all existing stream definitions. The data of wired streams is deleted, but the data of classic streams is preserved.",
+ "operationId": "post-streams-disable",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Disable streams",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/_enable": {
+ "post": {
+ "description": "Enables wired streams",
+ "operationId": "post-streams-enable",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Enable streams",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/_resync": {
+ "post": {
+ "description": "Resyncs all streams, making sure that Elasticsearch assets are up to date",
+ "operationId": "post-streams-resync",
+ "parameters": [
+ {
+ "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": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Resync streams",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/{name}": {
+ "delete": {
+ "description": "Deletes a stream definition and the underlying data stream",
+ "operationId": "delete-streams-name",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Delete a stream",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "get": {
+ "description": "Fetches a stream definition and associated dashboards",
+ "operationId": "get-streams-name",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Get a stream",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "put": {
+ "description": "Creates or updates a stream definition. Classic streams can not be created through this API, only updated",
+ "operationId": "put-streams-name",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "allOf": [
+ {
+ "properties": {
+ "dashboards": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "dashboards"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "stream": {
+ "additionalProperties": false,
+ "properties": {
+ "ingest": {
+ "allOf": [
+ {
+ "properties": {
+ "lifecycle": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dsl": {
+ "additionalProperties": false,
+ "properties": {
+ "data_retention": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "dsl"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "ilm": {
+ "additionalProperties": false,
+ "properties": {
+ "policy": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "policy"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "ilm"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "inherit": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "inherit"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "processing": {
+ "items": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "grok": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern_definitions": {
+ "additionalProperties": {
+ "type": "string"
+ },
+ "type": "object"
+ },
+ "patterns": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ }
+ },
+ "required": [
+ "field",
+ "patterns"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "grok"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dissect": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "append_separator": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "pattern"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "dissect"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "lifecycle",
+ "processing"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "wired": {
+ "additionalProperties": false,
+ "properties": {
+ "fields": {
+ "additionalProperties": {
+ "allOf": [
+ {
+ "additionalProperties": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ },
+ {
+ "items": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ },
+ "type": "array"
+ },
+ {}
+ ]
+ },
+ "type": "object"
+ },
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "format": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "type": {
+ "enum": [
+ "keyword",
+ "match_only_text",
+ "long",
+ "double",
+ "date",
+ "boolean",
+ "ip"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "type": {
+ "enum": [
+ "system"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ ]
+ },
+ "type": "object"
+ },
+ "routing": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "destination": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "destination",
+ "if"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "fields",
+ "routing"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "wired"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "ingest"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "stream"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "allOf": [
+ {
+ "properties": {
+ "dashboards": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "dashboards"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "stream": {
+ "additionalProperties": false,
+ "properties": {
+ "ingest": {
+ "allOf": [
+ {
+ "properties": {
+ "lifecycle": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dsl": {
+ "additionalProperties": false,
+ "properties": {
+ "data_retention": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "dsl"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "ilm": {
+ "additionalProperties": false,
+ "properties": {
+ "policy": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "policy"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "ilm"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "inherit": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "inherit"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "processing": {
+ "items": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "grok": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern_definitions": {
+ "additionalProperties": {
+ "type": "string"
+ },
+ "type": "object"
+ },
+ "patterns": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ }
+ },
+ "required": [
+ "field",
+ "patterns"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "grok"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dissect": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "append_separator": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "pattern"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "dissect"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "lifecycle",
+ "processing"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "unwired": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "unwired"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "ingest"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "stream"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "allOf": [
+ {
+ "properties": {
+ "dashboards": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "dashboards"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "stream": {
+ "additionalProperties": false,
+ "properties": {
+ "group": {
+ "additionalProperties": false,
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "members": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "members"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "group"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "stream"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Create or update a stream",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/{name}/_fork": {
+ "post": {
+ "description": "Forks a wired stream and creates a child stream",
+ "operationId": "post-streams-name-fork",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "stream": {
+ "additionalProperties": false,
+ "properties": {
+ "name": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "name"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "stream",
+ "if"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Fork a stream",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/{name}/_group": {
+ "get": {
+ "description": "Fetches the group settings of a group stream definition",
+ "operationId": "get-streams-name-group",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Get group stream settings",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "put": {
+ "description": "Upserts the group settings of a group stream definition",
+ "operationId": "put-streams-name-group",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "group": {
+ "additionalProperties": false,
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "members": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "members"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "group"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Upsert group stream settings",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/{name}/_ingest": {
+ "get": {
+ "description": "Fetches the ingest settings of an ingest stream definition",
+ "operationId": "get-streams-name-ingest",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Get ingest stream settings",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "put": {
+ "description": "Upserts the ingest settings of an ingest stream definition",
+ "operationId": "put-streams-name-ingest",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "ingest": {
+ "allOf": [
+ {
+ "properties": {
+ "lifecycle": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dsl": {
+ "additionalProperties": false,
+ "properties": {
+ "data_retention": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "dsl"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "ilm": {
+ "additionalProperties": false,
+ "properties": {
+ "policy": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "policy"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "ilm"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "inherit": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "inherit"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "processing": {
+ "items": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "grok": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern_definitions": {
+ "additionalProperties": {
+ "type": "string"
+ },
+ "type": "object"
+ },
+ "patterns": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ }
+ },
+ "required": [
+ "field",
+ "patterns"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "grok"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dissect": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "append_separator": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "pattern"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "dissect"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "lifecycle",
+ "processing"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "wired": {
+ "additionalProperties": false,
+ "properties": {
+ "fields": {
+ "additionalProperties": {
+ "allOf": [
+ {
+ "additionalProperties": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ },
+ {
+ "items": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ },
+ "type": "array"
+ },
+ {}
+ ]
+ },
+ "type": "object"
+ },
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "format": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "type": {
+ "enum": [
+ "keyword",
+ "match_only_text",
+ "long",
+ "double",
+ "date",
+ "boolean",
+ "ip"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "type": {
+ "enum": [
+ "system"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "type"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ ]
+ },
+ "type": "object"
+ },
+ "routing": {
+ "items": {
+ "additionalProperties": false,
+ "properties": {
+ "destination": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "destination",
+ "if"
+ ],
+ "type": "object"
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "fields",
+ "routing"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "wired"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "ingest"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "ingest": {
+ "allOf": [
+ {
+ "properties": {
+ "lifecycle": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dsl": {
+ "additionalProperties": false,
+ "properties": {
+ "data_retention": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "type": "object"
+ }
+ },
+ "required": [
+ "dsl"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "ilm": {
+ "additionalProperties": false,
+ "properties": {
+ "policy": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "policy"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "ilm"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "inherit": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "inherit"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "processing": {
+ "items": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "grok": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern_definitions": {
+ "additionalProperties": {
+ "type": "string"
+ },
+ "type": "object"
+ },
+ "patterns": {
+ "items": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "minItems": 1,
+ "type": "array"
+ }
+ },
+ "required": [
+ "field",
+ "patterns"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "grok"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "dissect": {
+ "allOf": [
+ {
+ "properties": {
+ "description": {
+ "type": "string"
+ },
+ "if": {
+ "anyOf": [
+ {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "exists",
+ "notExists"
+ ],
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "operator"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "operator": {
+ "enum": [
+ "eq",
+ "neq",
+ "lt",
+ "lte",
+ "gt",
+ "gte",
+ "contains",
+ "startsWith",
+ "endsWith"
+ ],
+ "type": "string"
+ },
+ "value": {
+ "anyOf": [
+ {
+ "type": "string"
+ },
+ {
+ "type": "number"
+ },
+ {
+ "type": "boolean"
+ }
+ ]
+ }
+ },
+ "required": [
+ "field",
+ "operator",
+ "value"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "and": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "and"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "or": {
+ "items": {},
+ "type": "array"
+ }
+ },
+ "required": [
+ "or"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "never": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "never"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "always": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "always"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "ignore_failure": {
+ "type": "boolean"
+ }
+ },
+ "required": [
+ "if"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "append_separator": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "field": {
+ "minLength": 1,
+ "type": "string"
+ },
+ "ignore_missing": {
+ "type": "boolean"
+ },
+ "pattern": {
+ "minLength": 1,
+ "type": "string"
+ }
+ },
+ "required": [
+ "field",
+ "pattern"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "dissect"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "lifecycle",
+ "processing"
+ ],
+ "type": "object"
+ },
+ {
+ "properties": {
+ "unwired": {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ }
+ },
+ "required": [
+ "unwired"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ },
+ "required": [
+ "ingest"
+ ],
+ "type": "object"
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Update ingest stream settings",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/{name}/dashboards": {
+ "get": {
+ "description": "Fetches all dashboards linked to a stream that are visible to the current user in the current space.",
+ "operationId": "get-streams-name-dashboards",
+ "parameters": [
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Get stream dashboards",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/{name}/dashboards/_bulk": {
+ "post": {
+ "description": "Bulk update dashboards linked to a stream. Can link new dashboards and delete existing ones.",
+ "operationId": "post-streams-name-dashboards-bulk",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "additionalProperties": false,
+ "properties": {
+ "operations": {
+ "items": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {
+ "index": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "index"
+ ],
+ "type": "object"
+ },
+ {
+ "additionalProperties": false,
+ "properties": {
+ "delete": {
+ "additionalProperties": false,
+ "properties": {
+ "id": {
+ "type": "string"
+ }
+ },
+ "required": [
+ "id"
+ ],
+ "type": "object"
+ }
+ },
+ "required": [
+ "delete"
+ ],
+ "type": "object"
+ }
+ ]
+ },
+ "type": "array"
+ }
+ },
+ "required": [
+ "operations"
+ ],
+ "type": "object"
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Bulk update dashboards",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ },
+ "/api/streams/{name}/dashboards/{dashboardId}": {
+ "delete": {
+ "description": "Unlinks a dashboard from a stream. Noop if the dashboard is not linked to the stream.",
+ "operationId": "delete-streams-name-dashboards-dashboardid",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "dashboardId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Unlink a dashboard from a stream",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ },
+ "put": {
+ "description": "Links a dashboard to a stream. Noop if the dashboard is already linked to the stream.",
+ "operationId": "put-streams-name-dashboards-dashboardid",
+ "parameters": [
+ {
+ "description": "A required header to protect against CSRF attacks",
+ "in": "header",
+ "name": "kbn-xsrf",
+ "required": true,
+ "schema": {
+ "example": "true",
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "name",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ },
+ {
+ "in": "path",
+ "name": "dashboardId",
+ "required": true,
+ "schema": {
+ "type": "string"
+ }
+ }
+ ],
+ "requestBody": {
+ "content": {
+ "application/json": {
+ "schema": {
+ "anyOf": [
+ {
+ "additionalProperties": false,
+ "properties": {},
+ "type": "object"
+ },
+ {
+ "enum": [
+ "null"
+ ],
+ "nullable": true
+ },
+ {
+ "not": {}
+ }
+ ]
+ }
+ }
+ }
+ },
+ "responses": {},
+ "summary": "Link a dashboard to a stream",
+ "tags": [
+ "streams"
+ ],
+ "x-state": "Technical Preview"
+ }
+ }
+ },
+ "security": [
+ {
+ "basicAuth": []
+ }
+ ],
+ "servers": [
+ {
+ "url": "http://localhost:5622"
+ }
+ ],
+ "tags": [
+ {
+ "name": "alerting"
+ },
+ {
+ "name": "connectors"
+ },
+ {
+ "name": "Dashboards"
+ },
+ {
+ "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"
+ },
+ {
+ "name": "spaces"
+ },
+ {
+ "name": "streams"
+ },
+ {
+ "name": "system"
+ }
+ ]
+}
\ No newline at end of file
diff --git a/oas_docs/output/kibana.serverless.yaml b/oas_docs/output/kibana.serverless.yaml
index b13b8c1775655..7a49dc76189b7 100644
--- a/oas_docs/output/kibana.serverless.yaml
+++ b/oas_docs/output/kibana.serverless.yaml
@@ -143,6 +143,10 @@ tags:
- name: spaces
x-displayName: Spaces
description: Manage your Kibana spaces.
+ - name: streams
+ description: |
+ Streams is a new and experimental way to manage your data in Kibana. The API is currently not considered stable and can change at any point.
+ x-displayName: Streams
- name: system
x-displayName: System
description: |
@@ -35329,6 +35333,2113 @@ paths:
tags:
- system
x-beta: true
+ /api/streams:
+ get:
+ description: Fetches list of all streams
+ operationId: get-streams
+ parameters: []
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Get stream list
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/_disable:
+ post:
+ description: Disables wired streams and deletes all existing stream definitions. The data of wired streams is deleted, but the data of classic streams is preserved.
+ operationId: post-streams-disable
+ parameters:
+ - 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:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Disable streams
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/_enable:
+ post:
+ description: Enables wired streams
+ operationId: post-streams-enable
+ parameters:
+ - 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:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Enable streams
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/_resync:
+ post:
+ description: Resyncs all streams, making sure that Elasticsearch assets are up to date
+ operationId: post-streams-resync
+ parameters:
+ - 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:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Resync streams
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/{name}:
+ delete:
+ description: Deletes a stream definition and the underlying data stream
+ operationId: delete-streams-name
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Delete a stream
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ get:
+ description: Fetches a stream definition and associated dashboards
+ operationId: get-streams-name
+ parameters:
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Get a stream
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ put:
+ description: Creates or updates a stream definition. Classic streams can not be created through this API, only updated
+ operationId: put-streams-name
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - anyOf:
+ - allOf:
+ - type: object
+ properties:
+ dashboards:
+ items:
+ minLength: 1
+ type: string
+ type: array
+ required:
+ - dashboards
+ - type: object
+ properties:
+ stream:
+ additionalProperties: false
+ type: object
+ properties:
+ ingest:
+ allOf:
+ - type: object
+ properties:
+ lifecycle:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ dsl:
+ additionalProperties: false
+ type: object
+ properties:
+ data_retention:
+ minLength: 1
+ type: string
+ required:
+ - dsl
+ - additionalProperties: false
+ type: object
+ properties:
+ ilm:
+ additionalProperties: false
+ type: object
+ properties:
+ policy:
+ minLength: 1
+ type: string
+ required:
+ - policy
+ required:
+ - ilm
+ - additionalProperties: false
+ type: object
+ properties:
+ inherit:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - inherit
+ processing:
+ items:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ grok:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern_definitions:
+ additionalProperties:
+ type: string
+ type: object
+ patterns:
+ items:
+ minLength: 1
+ type: string
+ minItems: 1
+ type: array
+ required:
+ - field
+ - patterns
+ required:
+ - grok
+ - additionalProperties: false
+ type: object
+ properties:
+ dissect:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ append_separator:
+ minLength: 1
+ type: string
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern:
+ minLength: 1
+ type: string
+ required:
+ - field
+ - pattern
+ required:
+ - dissect
+ type: array
+ required:
+ - lifecycle
+ - processing
+ - type: object
+ properties:
+ wired:
+ additionalProperties: false
+ type: object
+ properties:
+ fields:
+ additionalProperties:
+ allOf:
+ - additionalProperties:
+ anyOf:
+ - anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ - items:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ type: array
+ - {}
+ type: object
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ format:
+ minLength: 1
+ type: string
+ type:
+ enum:
+ - keyword
+ - match_only_text
+ - long
+ - double
+ - date
+ - boolean
+ - ip
+ type: string
+ required:
+ - type
+ - additionalProperties: false
+ type: object
+ properties:
+ type:
+ enum:
+ - system
+ type: string
+ required:
+ - type
+ type: object
+ routing:
+ items:
+ additionalProperties: false
+ type: object
+ properties:
+ destination:
+ minLength: 1
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ required:
+ - destination
+ - if
+ type: array
+ required:
+ - fields
+ - routing
+ required:
+ - wired
+ required:
+ - ingest
+ required:
+ - stream
+ - allOf:
+ - type: object
+ properties:
+ dashboards:
+ items:
+ minLength: 1
+ type: string
+ type: array
+ required:
+ - dashboards
+ - type: object
+ properties:
+ stream:
+ additionalProperties: false
+ type: object
+ properties:
+ ingest:
+ allOf:
+ - type: object
+ properties:
+ lifecycle:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ dsl:
+ additionalProperties: false
+ type: object
+ properties:
+ data_retention:
+ minLength: 1
+ type: string
+ required:
+ - dsl
+ - additionalProperties: false
+ type: object
+ properties:
+ ilm:
+ additionalProperties: false
+ type: object
+ properties:
+ policy:
+ minLength: 1
+ type: string
+ required:
+ - policy
+ required:
+ - ilm
+ - additionalProperties: false
+ type: object
+ properties:
+ inherit:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - inherit
+ processing:
+ items:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ grok:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern_definitions:
+ additionalProperties:
+ type: string
+ type: object
+ patterns:
+ items:
+ minLength: 1
+ type: string
+ minItems: 1
+ type: array
+ required:
+ - field
+ - patterns
+ required:
+ - grok
+ - additionalProperties: false
+ type: object
+ properties:
+ dissect:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ append_separator:
+ minLength: 1
+ type: string
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern:
+ minLength: 1
+ type: string
+ required:
+ - field
+ - pattern
+ required:
+ - dissect
+ type: array
+ required:
+ - lifecycle
+ - processing
+ - type: object
+ properties:
+ unwired:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - unwired
+ required:
+ - ingest
+ required:
+ - stream
+ - allOf:
+ - type: object
+ properties:
+ dashboards:
+ items:
+ minLength: 1
+ type: string
+ type: array
+ required:
+ - dashboards
+ - type: object
+ properties:
+ stream:
+ additionalProperties: false
+ type: object
+ properties:
+ group:
+ additionalProperties: false
+ type: object
+ properties:
+ description:
+ type: string
+ members:
+ items:
+ minLength: 1
+ type: string
+ type: array
+ required:
+ - members
+ required:
+ - group
+ required:
+ - stream
+ responses: {}
+ summary: Create or update a stream
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/{name}/_fork:
+ post:
+ description: Forks a wired stream and creates a child stream
+ operationId: post-streams-name-fork
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ additionalProperties: false
+ type: object
+ properties:
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ stream:
+ additionalProperties: false
+ type: object
+ properties:
+ name:
+ type: string
+ required:
+ - name
+ required:
+ - stream
+ - if
+ responses: {}
+ summary: Fork a stream
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/{name}/_group:
+ get:
+ description: Fetches the group settings of a group stream definition
+ operationId: get-streams-name-group
+ parameters:
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Get group stream settings
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ put:
+ description: Upserts the group settings of a group stream definition
+ operationId: put-streams-name-group
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ additionalProperties: false
+ type: object
+ properties:
+ group:
+ additionalProperties: false
+ type: object
+ properties:
+ description:
+ type: string
+ members:
+ items:
+ minLength: 1
+ type: string
+ type: array
+ required:
+ - members
+ required:
+ - group
+ responses: {}
+ summary: Upsert group stream settings
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/{name}/_ingest:
+ get:
+ description: Fetches the ingest settings of an ingest stream definition
+ operationId: get-streams-name-ingest
+ parameters:
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Get ingest stream settings
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ put:
+ description: Upserts the ingest settings of an ingest stream definition
+ operationId: put-streams-name-ingest
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ ingest:
+ allOf:
+ - type: object
+ properties:
+ lifecycle:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ dsl:
+ additionalProperties: false
+ type: object
+ properties:
+ data_retention:
+ minLength: 1
+ type: string
+ required:
+ - dsl
+ - additionalProperties: false
+ type: object
+ properties:
+ ilm:
+ additionalProperties: false
+ type: object
+ properties:
+ policy:
+ minLength: 1
+ type: string
+ required:
+ - policy
+ required:
+ - ilm
+ - additionalProperties: false
+ type: object
+ properties:
+ inherit:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - inherit
+ processing:
+ items:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ grok:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern_definitions:
+ additionalProperties:
+ type: string
+ type: object
+ patterns:
+ items:
+ minLength: 1
+ type: string
+ minItems: 1
+ type: array
+ required:
+ - field
+ - patterns
+ required:
+ - grok
+ - additionalProperties: false
+ type: object
+ properties:
+ dissect:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ append_separator:
+ minLength: 1
+ type: string
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern:
+ minLength: 1
+ type: string
+ required:
+ - field
+ - pattern
+ required:
+ - dissect
+ type: array
+ required:
+ - lifecycle
+ - processing
+ - type: object
+ properties:
+ wired:
+ additionalProperties: false
+ type: object
+ properties:
+ fields:
+ additionalProperties:
+ allOf:
+ - additionalProperties:
+ anyOf:
+ - anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ - items:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ type: array
+ - {}
+ type: object
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ format:
+ minLength: 1
+ type: string
+ type:
+ enum:
+ - keyword
+ - match_only_text
+ - long
+ - double
+ - date
+ - boolean
+ - ip
+ type: string
+ required:
+ - type
+ - additionalProperties: false
+ type: object
+ properties:
+ type:
+ enum:
+ - system
+ type: string
+ required:
+ - type
+ type: object
+ routing:
+ items:
+ additionalProperties: false
+ type: object
+ properties:
+ destination:
+ minLength: 1
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ required:
+ - destination
+ - if
+ type: array
+ required:
+ - fields
+ - routing
+ required:
+ - wired
+ required:
+ - ingest
+ - additionalProperties: false
+ type: object
+ properties:
+ ingest:
+ allOf:
+ - type: object
+ properties:
+ lifecycle:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ dsl:
+ additionalProperties: false
+ type: object
+ properties:
+ data_retention:
+ minLength: 1
+ type: string
+ required:
+ - dsl
+ - additionalProperties: false
+ type: object
+ properties:
+ ilm:
+ additionalProperties: false
+ type: object
+ properties:
+ policy:
+ minLength: 1
+ type: string
+ required:
+ - policy
+ required:
+ - ilm
+ - additionalProperties: false
+ type: object
+ properties:
+ inherit:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - inherit
+ processing:
+ items:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ grok:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern_definitions:
+ additionalProperties:
+ type: string
+ type: object
+ patterns:
+ items:
+ minLength: 1
+ type: string
+ minItems: 1
+ type: array
+ required:
+ - field
+ - patterns
+ required:
+ - grok
+ - additionalProperties: false
+ type: object
+ properties:
+ dissect:
+ allOf:
+ - type: object
+ properties:
+ description:
+ type: string
+ if:
+ anyOf:
+ - anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - exists
+ - notExists
+ type: string
+ required:
+ - field
+ - operator
+ - additionalProperties: false
+ type: object
+ properties:
+ field:
+ minLength: 1
+ type: string
+ operator:
+ enum:
+ - eq
+ - neq
+ - lt
+ - lte
+ - gt
+ - gte
+ - contains
+ - startsWith
+ - endsWith
+ type: string
+ value:
+ anyOf:
+ - type: string
+ - type: number
+ - type: boolean
+ required:
+ - field
+ - operator
+ - value
+ - additionalProperties: false
+ type: object
+ properties:
+ and:
+ items: {}
+ type: array
+ required:
+ - and
+ - additionalProperties: false
+ type: object
+ properties:
+ or:
+ items: {}
+ type: array
+ required:
+ - or
+ - additionalProperties: false
+ type: object
+ properties:
+ never:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - never
+ - additionalProperties: false
+ type: object
+ properties:
+ always:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - always
+ ignore_failure:
+ type: boolean
+ required:
+ - if
+ - type: object
+ properties:
+ append_separator:
+ minLength: 1
+ type: string
+ field:
+ minLength: 1
+ type: string
+ ignore_missing:
+ type: boolean
+ pattern:
+ minLength: 1
+ type: string
+ required:
+ - field
+ - pattern
+ required:
+ - dissect
+ type: array
+ required:
+ - lifecycle
+ - processing
+ - type: object
+ properties:
+ unwired:
+ additionalProperties: false
+ type: object
+ properties: {}
+ required:
+ - unwired
+ required:
+ - ingest
+ responses: {}
+ summary: Update ingest stream settings
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/{name}/dashboards:
+ get:
+ description: Fetches all dashboards linked to a stream that are visible to the current user in the current space.
+ operationId: get-streams-name-dashboards
+ parameters:
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Get stream dashboards
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/{name}/dashboards/_bulk:
+ post:
+ description: Bulk update dashboards linked to a stream. Can link new dashboards and delete existing ones.
+ operationId: post-streams-name-dashboards-bulk
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ additionalProperties: false
+ type: object
+ properties:
+ operations:
+ items:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties:
+ index:
+ additionalProperties: false
+ type: object
+ properties:
+ id:
+ type: string
+ required:
+ - id
+ required:
+ - index
+ - additionalProperties: false
+ type: object
+ properties:
+ delete:
+ additionalProperties: false
+ type: object
+ properties:
+ id:
+ type: string
+ required:
+ - id
+ required:
+ - delete
+ type: array
+ required:
+ - operations
+ responses: {}
+ summary: Bulk update dashboards
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ /api/streams/{name}/dashboards/{dashboardId}:
+ delete:
+ description: Unlinks a dashboard from a stream. Noop if the dashboard is not linked to the stream.
+ operationId: delete-streams-name-dashboards-dashboardid
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ - in: path
+ name: dashboardId
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Unlink a dashboard from a stream
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
+ put:
+ description: Links a dashboard to a stream. Noop if the dashboard is already linked to the stream.
+ operationId: put-streams-name-dashboards-dashboardid
+ parameters:
+ - description: A required header to protect against CSRF attacks
+ in: header
+ name: kbn-xsrf
+ required: true
+ schema:
+ example: 'true'
+ type: string
+ - in: path
+ name: name
+ required: true
+ schema:
+ type: string
+ - in: path
+ name: dashboardId
+ required: true
+ schema:
+ type: string
+ requestBody:
+ content:
+ application/json:
+ schema:
+ anyOf:
+ - additionalProperties: false
+ type: object
+ properties: {}
+ - enum:
+ - 'null'
+ nullable: true
+ - not: {}
+ responses: {}
+ summary: Link a dashboard to a stream
+ tags:
+ - streams
+ x-state: Technical Preview
+ x-beta: true
/api/timeline:
delete:
description: Delete one or more Timelines or Timeline templates.
diff --git a/oas_docs/overlays/kibana.overlays.serverless.yaml b/oas_docs/overlays/kibana.overlays.serverless.yaml
new file mode 100644
index 0000000000000..63163045ed821
--- /dev/null
+++ b/oas_docs/overlays/kibana.overlays.serverless.yaml
@@ -0,0 +1,85 @@
+# overlays.yaml
+overlay: 1.0.0
+info:
+ title: Overlays for the Kibana API document
+ version: 0.0.1
+actions:
+# Clean up server definitions
+ - target: '$.servers.*'
+ description: Remove all servers so we can add our own.
+ remove: true
+ - target: '$.servers'
+ description: Add server into the now empty server array.
+ update:
+ - url: https://{kibana_url}
+ variables:
+ kibana_url:
+ default:
+# Mark all operations as beta
+ - target: "$.paths[*]['get','put','post','delete','options','head','patch','trace']"
+ description: Add x-beta
+ update:
+ x-beta: true
+# Add some tag descriptions and displayNames
+ - target: '$.tags[?(@.name=="alerting")]'
+ description: Change tag description and displayName
+ update:
+ description: >
+ Alerting enables you to define rules, which detect complex conditions within your data.
+ When a condition is met, the rule tracks it as an alert and runs the actions that are defined in the rule.
+ Actions typically involve the use of connectors to interact with Kibana services or third party integrations.
+ externalDocs:
+ description: Alerting documentation
+ url: https://www.elastic.co/docs/current/serverless/rules
+ x-displayName: "Alerting"
+ - target: '$.tags[?(@.name=="streams")]'
+ description: Change tag description and displayName
+ update:
+ description: >
+ Streams is a new and experimental way to manage your data in Kibana. The API is currently not considered stable and can change at any point.
+ x-displayName: "Streams"
+ - target: '$.tags[?(@.name=="connectors")]'
+ description: Change tag description and displayName
+ update:
+ description: >
+ Connectors provide a central place to store connection information for services and integrations with Elastic or third party systems.
+ Alerting rules can use connectors to run actions when rule conditions are met.
+ externalDocs:
+ description: Connector documentation
+ url: https://www.elastic.co/docs/current/serverless/action-connectors
+ x-displayName: "Connectors"
+ - target: '$.tags[?(@.name=="data views")]'
+ description: Change displayName
+ update:
+ x-displayName: "Data views"
+ - target: '$.tags[?(@.name=="ml")]'
+ description: Change displayName
+ update:
+ x-displayName: "Machine learning"
+ - target: '$.tags[?(@.name=="roles")]'
+ description: Change displayName and description
+ update:
+ x-displayName: "Roles"
+ description: Manage the roles that grant Elasticsearch and Kibana privileges.
+ externalDocs:
+ description: Kibana role management
+ url: https://www.elastic.co/guide/en/kibana/master/kibana-role-management.html
+ - target: '$.tags[?(@.name=="slo")]'
+ description: Change displayName
+ update:
+ x-displayName: "Service level objectives"
+ - target: '$.tags[?(@.name=="spaces")]'
+ description: Change displayName
+ update:
+ x-displayName: "Spaces"
+ description: Manage your Kibana spaces.
+ - target: '$.tags[?(@.name=="system")]'
+ description: Change displayName and description
+ update:
+ x-displayName: "System"
+ description: >
+ Get information about the system status, resource usage, and installed plugins.
+# Remove extra tags from operations
+ - target: "$.paths[*][*].tags[1:]"
+ description: Remove all but first tag from operations
+ remove: true
\ No newline at end of file
diff --git a/oas_docs/overlays/kibana.overlays.yaml b/oas_docs/overlays/kibana.overlays.yaml
index 30333dc50e21e..0aacb8aae3202 100644
--- a/oas_docs/overlays/kibana.overlays.yaml
+++ b/oas_docs/overlays/kibana.overlays.yaml
@@ -47,6 +47,12 @@ actions:
description: Alerting documentation
url: https://www.elastic.co/guide/en/kibana/8.x/alerting-getting-started.html
x-displayName: "Alerting"
+ - target: '$.tags[?(@.name=="streams")]'
+ description: Change tag description and displayName
+ update:
+ description: >
+ Streams is a new and experimental way to manage your data in Kibana (currently experimental - expect changes).
+ x-displayName: "Streams"
- target: '$.tags[?(@.name=="cases")]'
description: Change tag description and displayName
update:
diff --git a/src/platform/packages/shared/kbn-server-route-repository/src/register_routes.ts b/src/platform/packages/shared/kbn-server-route-repository/src/register_routes.ts
index 90c4f42b9ce44..3b5cedc8c7fb2 100644
--- a/src/platform/packages/shared/kbn-server-route-repository/src/register_routes.ts
+++ b/src/platform/packages/shared/kbn-server-route-repository/src/register_routes.ts
@@ -169,6 +169,8 @@ export function registerRoutes>({
router.versioned[method]({
path: pathname,
access,
+ summary: options.summary,
+ description: options.description,
// @ts-expect-error we are essentially calling multiple methods at the same type so TS gets confused
options: omit(options, 'access', 'description', 'summary', 'deprecated', 'discontinued'),
security,
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/create_server_route.ts b/x-pack/platform/plugins/shared/streams/server/routes/create_server_route.ts
index de74e7e39083a..32508717518f1 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/create_server_route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/create_server_route.ts
@@ -20,6 +20,10 @@ export const createServerRoute: CreateServerRouteFactory<
> = ({ handler, ...config }) => {
return createPlainStreamsServerRoute({
...config,
+ options: {
+ ...config.options,
+ tags: [...(config.options?.tags ?? []), 'oas-tag:streams'],
+ },
handler: (options) => {
return handler(options).catch((error) => {
if (error instanceof StatusError || error instanceof errors.ResponseError) {
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/dashboards/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/dashboards/route.ts
index d8399aedb2836..12baca546fa49 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/dashboards/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/dashboards/route.ts
@@ -48,9 +48,15 @@ function sanitizeDashboardAsset(asset: DashboardAsset): SanitizedDashboardAsset
}
const listDashboardsRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}/dashboards',
+ endpoint: 'GET /api/streams/{name}/dashboards 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Get stream dashboards',
+ description:
+ 'Fetches all dashboards linked to a stream that are visible to the current user in the current space.',
+ availability: {
+ stability: 'experimental',
+ },
},
params: z.object({
path: z.object({
@@ -90,9 +96,15 @@ const listDashboardsRoute = createServerRoute({
});
const linkDashboardRoute = createServerRoute({
- endpoint: 'PUT /api/streams/{name}/dashboards/{dashboardId}',
+ endpoint: 'PUT /api/streams/{name}/dashboards/{dashboardId} 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Link a dashboard to a stream',
+ description:
+ 'Links a dashboard to a stream. Noop if the dashboard is already linked to the stream.',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -131,9 +143,15 @@ const linkDashboardRoute = createServerRoute({
});
const unlinkDashboardRoute = createServerRoute({
- endpoint: 'DELETE /api/streams/{name}/dashboards/{dashboardId}',
+ endpoint: 'DELETE /api/streams/{name}/dashboards/{dashboardId} 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Unlink a dashboard from a stream',
+ description:
+ 'Unlinks a dashboard from a stream. Noop if the dashboard is not linked to the stream.',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -171,7 +189,7 @@ const unlinkDashboardRoute = createServerRoute({
});
const suggestDashboardsRoute = createServerRoute({
- endpoint: 'POST /api/streams/{name}/dashboards/_suggestions',
+ endpoint: 'POST /internal/streams/{name}/dashboards/_suggestions',
options: {
access: 'internal',
},
@@ -224,9 +242,15 @@ const dashboardSchema = z.object({
});
const bulkDashboardsRoute = createServerRoute({
- endpoint: `POST /api/streams/{name}/dashboards/_bulk`,
+ endpoint: `POST /api/streams/{name}/dashboards/_bulk 2023-10-31`,
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Bulk update dashboards',
+ description:
+ 'Bulk update dashboards linked to a stream. Can link new dashboards and delete existing ones.',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/index.ts b/x-pack/platform/plugins/shared/streams/server/routes/index.ts
index 3e47693cf7176..e090c88f8628c 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/index.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/index.ts
@@ -5,27 +5,35 @@
* 2.0.
*/
-import { esqlRoutes } from './esql/route';
+import { internalEsqlRoutes } from './internal/esql/route';
import { dashboardRoutes } from './dashboards/route';
import { crudRoutes } from './streams/crud/route';
import { enablementRoutes } from './streams/enablement/route';
import { managementRoutes } from './streams/management/route';
-import { schemaRoutes } from './streams/schema/route';
-import { processingRoutes } from './streams/processing/route';
+import { internalSchemaRoutes } from './internal/streams/schema/route';
+import { internalProcessingRoutes } from './internal/streams/processing/route';
import { ingestRoutes } from './streams/ingest/route';
-import { lifecycleRoutes } from './streams/lifecycle/route';
+import { internalLifecycleRoutes } from './internal/streams/lifecycle/route';
import { groupRoutes } from './streams/group/route';
+import { internalDashboardRoutes } from './internal/dashboards/route';
+import { internalCrudRoutes } from './internal/streams/crud/route';
+import { internalManagementRoutes } from './internal/streams/management/route';
export const streamsRouteRepository = {
- ...esqlRoutes,
+ // internal APIs
+ ...internalEsqlRoutes,
+ ...internalDashboardRoutes,
+ ...internalCrudRoutes,
+ ...internalManagementRoutes,
+ ...internalSchemaRoutes,
+ ...internalLifecycleRoutes,
+ ...internalProcessingRoutes,
+ // public APIs
...dashboardRoutes,
...crudRoutes,
...enablementRoutes,
...managementRoutes,
- ...schemaRoutes,
- ...processingRoutes,
...ingestRoutes,
- ...lifecycleRoutes,
...groupRoutes,
};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/internal/dashboards/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/dashboards/route.ts
new file mode 100644
index 0000000000000..fc754f2b65100
--- /dev/null
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/dashboards/route.ts
@@ -0,0 +1,76 @@
+/*
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
+ * or more contributor license agreements. Licensed under the Elastic License
+ * 2.0; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import { z } from '@kbn/zod';
+import { DashboardAsset } from '../../../../common/assets';
+import { createServerRoute } from '../../create_server_route';
+import { SanitizedDashboardAsset } from '../../dashboards/route';
+
+export interface SuggestDashboardResponse {
+ suggestions: SanitizedDashboardAsset[];
+}
+
+function sanitizeDashboardAsset(asset: DashboardAsset): SanitizedDashboardAsset {
+ return {
+ id: asset.assetId,
+ label: asset.label,
+ tags: asset.tags,
+ };
+}
+
+const suggestDashboardsRoute = createServerRoute({
+ endpoint: 'POST /internal/streams/{name}/dashboards/_suggestions',
+ options: {
+ access: 'internal',
+ },
+ security: {
+ authz: {
+ enabled: false,
+ reason:
+ 'This API delegates security to the currently logged in user and their Elasticsearch permissions.',
+ },
+ },
+ params: z.object({
+ path: z.object({
+ name: z.string(),
+ }),
+ query: z.object({
+ query: z.string(),
+ }),
+ body: z.object({
+ tags: z.optional(z.array(z.string())),
+ }),
+ }),
+ handler: async ({ params, request, getScopedClients }): Promise => {
+ const { assetClient, streamsClient } = await getScopedClients({ request });
+
+ await streamsClient.ensureStream(params.path.name);
+
+ const {
+ query: { query },
+ body: { tags },
+ } = params;
+
+ const suggestions = (
+ await assetClient.getSuggestions({
+ assetTypes: ['dashboard'],
+ query,
+ tags,
+ })
+ ).assets.map((asset) => {
+ return sanitizeDashboardAsset(asset as DashboardAsset);
+ });
+
+ return {
+ suggestions,
+ };
+ },
+});
+
+export const internalDashboardRoutes = {
+ ...suggestDashboardsRoute,
+};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/esql/query_helpers.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/esql/query_helpers.ts
similarity index 100%
rename from x-pack/platform/plugins/shared/streams/server/routes/esql/query_helpers.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/esql/query_helpers.ts
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/esql/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/esql/route.ts
similarity index 95%
rename from x-pack/platform/plugins/shared/streams/server/routes/esql/route.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/esql/route.ts
index e70ab43890352..e5d0990a3a7f5 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/esql/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/esql/route.ts
@@ -8,7 +8,7 @@
import { UnparsedEsqlResponse, createTracedEsClient } from '@kbn/traced-es-client';
import { z } from '@kbn/zod';
import { isNumber } from 'lodash';
-import { createServerRoute } from '../create_server_route';
+import { createServerRoute } from '../../create_server_route';
import { excludeFrozenQuery, kqlQuery, rangeQuery } from './query_helpers';
export const executeEsqlRoute = createServerRoute({
@@ -67,6 +67,6 @@ export const executeEsqlRoute = createServerRoute({
},
});
-export const esqlRoutes = {
+export const internalEsqlRoutes = {
...executeEsqlRoute,
};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/crud/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/crud/route.ts
new file mode 100644
index 0000000000000..17c1055fdd28e
--- /dev/null
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/crud/route.ts
@@ -0,0 +1,72 @@
+/*
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
+ * or more contributor license agreements. Licensed under the Elastic License
+ * 2.0; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import { SearchTotalHits } from '@elastic/elasticsearch/lib/api/types';
+import { isGroupStreamDefinition } from '@kbn/streams-schema';
+import { z } from '@kbn/zod';
+import { createServerRoute } from '../../../create_server_route';
+
+export interface StreamDetailsResponse {
+ details: {
+ count: number;
+ };
+}
+
+export const streamDetailRoute = createServerRoute({
+ endpoint: 'GET /internal/streams/{name}/_details',
+ options: {
+ access: 'internal',
+ },
+ security: {
+ authz: {
+ enabled: false,
+ reason:
+ 'This API delegates security to the currently logged in user and their Elasticsearch permissions.',
+ },
+ },
+ params: z.object({
+ path: z.object({ name: z.string() }),
+ query: z.object({
+ start: z.string(),
+ end: z.string(),
+ }),
+ }),
+ handler: async ({ params, request, getScopedClients }): Promise => {
+ const { scopedClusterClient, streamsClient } = await getScopedClients({ request });
+ const streamEntity = await streamsClient.getStream(params.path.name);
+
+ const indexPattern = isGroupStreamDefinition(streamEntity)
+ ? streamEntity.group.members.join(',')
+ : streamEntity.name;
+ // check doc count
+ const docCountResponse = await scopedClusterClient.asCurrentUser.search({
+ index: indexPattern,
+ track_total_hits: true,
+ query: {
+ range: {
+ '@timestamp': {
+ gte: params.query.start,
+ lte: params.query.end,
+ },
+ },
+ },
+ size: 0,
+ });
+
+ const count = (docCountResponse.hits.total as SearchTotalHits).value;
+
+ return {
+ details: {
+ count,
+ },
+ };
+ },
+});
+
+export const internalCrudRoutes = {
+ ...streamDetailRoute,
+};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/lifecycle/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/lifecycle/route.ts
similarity index 84%
rename from x-pack/platform/plugins/shared/streams/server/routes/streams/lifecycle/route.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/streams/lifecycle/route.ts
index 05766628e43c3..8bbce39633a57 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/lifecycle/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/lifecycle/route.ts
@@ -7,13 +7,13 @@
import { isIlmLifecycle, isIngestStreamDefinition } from '@kbn/streams-schema';
import { z } from '@kbn/zod';
-import { createServerRoute } from '../../create_server_route';
-import { ilmPhases } from '../../../lib/streams/lifecycle/ilm_phases';
-import { getEffectiveLifecycle } from '../../../lib/streams/lifecycle/get_effective_lifecycle';
-import { StatusError } from '../../../lib/streams/errors/status_error';
+import { createServerRoute } from '../../../create_server_route';
+import { ilmPhases } from '../../../../lib/streams/lifecycle/ilm_phases';
+import { getEffectiveLifecycle } from '../../../../lib/streams/lifecycle/get_effective_lifecycle';
+import { StatusError } from '../../../../lib/streams/errors/status_error';
const lifecycleStatsRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}/lifecycle/_stats',
+ endpoint: 'GET /internal/streams/{name}/lifecycle/_stats',
options: {
access: 'internal',
},
@@ -56,7 +56,7 @@ const lifecycleStatsRoute = createServerRoute({
});
const lifecycleIlmExplainRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}/lifecycle/_explain',
+ endpoint: 'GET /internal/streams/{name}/lifecycle/_explain',
options: {
access: 'internal',
},
@@ -83,7 +83,7 @@ const lifecycleIlmExplainRoute = createServerRoute({
},
});
-export const lifecycleRoutes = {
+export const internalLifecycleRoutes = {
...lifecycleStatsRoute,
...lifecycleIlmExplainRoute,
};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/management/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/management/route.ts
new file mode 100644
index 0000000000000..25384e3c2898d
--- /dev/null
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/management/route.ts
@@ -0,0 +1,103 @@
+/*
+ * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
+ * or more contributor license agreements. Licensed under the Elastic License
+ * 2.0; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import {
+ SampleDocument,
+ conditionSchema,
+ conditionToQueryDsl,
+ getFields,
+} from '@kbn/streams-schema';
+import { z } from '@kbn/zod';
+import { checkAccess } from '../../../../lib/streams/stream_crud';
+import { createServerRoute } from '../../../create_server_route';
+import { DefinitionNotFoundError } from '../../../../lib/streams/errors/definition_not_found_error';
+
+export const sampleStreamRoute = createServerRoute({
+ endpoint: 'POST /internal/streams/{name}/_sample',
+ options: {
+ access: 'internal',
+ },
+ security: {
+ authz: {
+ enabled: false,
+ reason:
+ 'This API delegates security to the currently logged in user and their Elasticsearch permissions.',
+ },
+ },
+ params: z.object({
+ path: z.object({ name: z.string() }),
+ body: z.object({
+ if: z.optional(conditionSchema),
+ start: z.optional(z.number()),
+ end: z.optional(z.number()),
+ size: z.optional(z.number()),
+ }),
+ }),
+ handler: async ({ params, request, getScopedClients }) => {
+ const { scopedClusterClient } = await getScopedClients({ request });
+
+ const { read } = await checkAccess({ name: params.path.name, scopedClusterClient });
+
+ if (!read) {
+ throw new DefinitionNotFoundError(`Stream definition for ${params.path.name} not found`);
+ }
+
+ const { if: condition, start, end, size } = params.body;
+ const searchBody = {
+ query: {
+ bool: {
+ must: [
+ condition ? conditionToQueryDsl(condition) : { match_all: {} },
+ {
+ range: {
+ '@timestamp': {
+ gte: start,
+ lte: end,
+ format: 'epoch_millis',
+ },
+ },
+ },
+ ],
+ },
+ },
+ // Conditions could be using fields which are not indexed or they could use it with other types than they are eventually mapped as.
+ // Because of this we can't rely on mapped fields to draw a sample, instead we need to use runtime fields to simulate what happens during
+ // ingest in the painless condition checks.
+ // This is less efficient than it could be - in some cases, these fields _are_ indexed with the right type and we could use them directly.
+ // This can be optimized in the future.
+ runtime_mappings: condition
+ ? Object.fromEntries(
+ getFields(condition).map((field) => [
+ field.name,
+ { type: field.type === 'string' ? ('keyword' as const) : ('double' as const) },
+ ])
+ )
+ : undefined,
+ sort: [
+ {
+ '@timestamp': {
+ order: 'desc' as const,
+ },
+ },
+ ],
+ terminate_after: size,
+ track_total_hits: false,
+ size,
+ };
+ const results = await scopedClusterClient.asCurrentUser.search({
+ index: params.path.name,
+ allow_no_indices: true,
+ ...searchBody,
+ });
+
+ return { documents: results.hits.hits.map((hit) => hit._source) as SampleDocument[] };
+ },
+});
+
+export const internalManagementRoutes = {
+ ...sampleStreamRoute,
+};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/route.ts
similarity index 87%
rename from x-pack/platform/plugins/shared/streams/server/routes/streams/processing/route.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/route.ts
index 259d313821994..b632e99232a92 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/route.ts
@@ -12,9 +12,9 @@ import {
processorWithIdDefinitionSchema,
} from '@kbn/streams-schema';
import { z } from '@kbn/zod';
-import { checkAccess } from '../../../lib/streams/stream_crud';
-import { createServerRoute } from '../../create_server_route';
-import { DefinitionNotFoundError } from '../../../lib/streams/errors/definition_not_found_error';
+import { checkAccess } from '../../../../lib/streams/stream_crud';
+import { createServerRoute } from '../../../create_server_route';
+import { DefinitionNotFoundError } from '../../../../lib/streams/errors/definition_not_found_error';
import { ProcessingSimulationParams, simulateProcessing } from './simulation_handler';
import { handleProcessingSuggestion } from './suggestions_handler';
@@ -28,7 +28,7 @@ const paramsSchema = z.object({
}) satisfies z.Schema;
export const simulateProcessorRoute = createServerRoute({
- endpoint: 'POST /api/streams/{name}/processing/_simulate',
+ endpoint: 'POST /internal/streams/{name}/processing/_simulate',
options: {
access: 'internal',
},
@@ -70,7 +70,7 @@ const suggestionsParamsSchema = z.object({
});
export const processingSuggestionRoute = createServerRoute({
- endpoint: 'POST /api/streams/{name}/processing/_suggestions',
+ endpoint: 'POST /internal/streams/{name}/processing/_suggestions',
options: {
access: 'internal',
},
@@ -96,7 +96,7 @@ export const processingSuggestionRoute = createServerRoute({
},
});
-export const processingRoutes = {
+export const internalProcessingRoutes = {
...simulateProcessorRoute,
...processingSuggestionRoute,
};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/simulation_handler.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/simulation_handler.ts
similarity index 98%
rename from x-pack/platform/plugins/shared/streams/server/routes/streams/processing/simulation_handler.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/simulation_handler.ts
index 40548371c6796..8e8b0c5557c5b 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/simulation_handler.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/simulation_handler.ts
@@ -33,9 +33,9 @@ import {
FieldDefinition,
} from '@kbn/streams-schema';
import { mapValues, uniq, omit, isEmpty, uniqBy, some } from 'lodash';
-import { StreamsClient } from '../../../lib/streams/client';
-import { DetectedMappingFailureError } from '../../../lib/streams/errors/detected_mapping_failure_error';
-import { formatToIngestProcessors } from '../../../lib/streams/helpers/processing';
+import { StreamsClient } from '../../../../lib/streams/client';
+import { DetectedMappingFailureError } from '../../../../lib/streams/errors/detected_mapping_failure_error';
+import { formatToIngestProcessors } from '../../../../lib/streams/helpers/processing';
export interface ProcessingSimulationParams {
path: {
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/suggestions_handler.test.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/suggestions_handler.test.ts
similarity index 99%
rename from x-pack/platform/plugins/shared/streams/server/routes/streams/processing/suggestions_handler.test.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/suggestions_handler.test.ts
index 1660036795e79..8913ca7096e72 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/suggestions_handler.test.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/suggestions_handler.test.ts
@@ -9,7 +9,7 @@ import { handleProcessingSuggestion, extractAndGroupPatterns } from './suggestio
import { simulateProcessing } from './simulation_handler';
import { InferenceClient } from '@kbn/inference-plugin/server';
import { ScopedClusterClient } from '@kbn/core-elasticsearch-client-server-internal';
-import { StreamsClient } from '../../../lib/streams/client';
+import { StreamsClient } from '../../../../lib/streams/client';
jest.mock('./simulation_handler', () => ({
simulateProcessing: jest.fn((params) =>
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/suggestions_handler.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/suggestions_handler.ts
similarity index 99%
rename from x-pack/platform/plugins/shared/streams/server/routes/streams/processing/suggestions_handler.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/suggestions_handler.ts
index 121f401cc934d..b5e5542ee67ed 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/processing/suggestions_handler.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/processing/suggestions_handler.ts
@@ -9,7 +9,7 @@ import { IScopedClusterClient } from '@kbn/core/server';
import { get, groupBy, mapValues, orderBy, shuffle, uniq, uniqBy } from 'lodash';
import { InferenceClient } from '@kbn/inference-plugin/server';
import { FlattenRecord } from '@kbn/streams-schema';
-import { StreamsClient } from '../../../lib/streams/client';
+import { StreamsClient } from '../../../../lib/streams/client';
import { simulateProcessing } from './simulation_handler';
import { ProcessingSuggestionBody } from './route';
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/schema/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/schema/route.ts
similarity index 95%
rename from x-pack/platform/plugins/shared/streams/server/routes/streams/schema/route.ts
rename to x-pack/platform/plugins/shared/streams/server/routes/internal/streams/schema/route.ts
index 110ac8c9c5231..e7981040b4811 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/schema/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/internal/streams/schema/route.ts
@@ -11,14 +11,14 @@ import {
fieldDefinitionConfigSchema,
isWiredStreamDefinition,
} from '@kbn/streams-schema';
-import { checkAccess } from '../../../lib/streams/stream_crud';
-import { createServerRoute } from '../../create_server_route';
-import { DefinitionNotFoundError } from '../../../lib/streams/errors/definition_not_found_error';
+import { checkAccess } from '../../../../lib/streams/stream_crud';
+import { createServerRoute } from '../../../create_server_route';
+import { DefinitionNotFoundError } from '../../../../lib/streams/errors/definition_not_found_error';
const UNMAPPED_SAMPLE_SIZE = 500;
export const unmappedFieldsRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}/schema/unmapped_fields',
+ endpoint: 'GET /internal/streams/{name}/schema/unmapped_fields',
options: {
access: 'internal',
},
@@ -85,7 +85,7 @@ export const unmappedFieldsRoute = createServerRoute({
const FIELD_SIMILATION_SAMPLE_SIZE = 200;
export const schemaFieldsSimulationRoute = createServerRoute({
- endpoint: 'POST /api/streams/{name}/schema/fields_simulation',
+ endpoint: 'POST /internal/streams/{name}/schema/fields_simulation',
options: {
access: 'internal',
},
@@ -285,7 +285,7 @@ export const schemaFieldsSimulationRoute = createServerRoute({
},
});
-export const schemaRoutes = {
+export const internalSchemaRoutes = {
...unmappedFieldsRoute,
...schemaFieldsSimulationRoute,
};
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/crud/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/streams/crud/route.ts
index b29995133db5a..7afbbd19dd7c1 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/crud/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/streams/crud/route.ts
@@ -5,7 +5,6 @@
* 2.0.
*/
-import { SearchTotalHits } from '@elastic/elasticsearch/lib/api/types';
import {
isGroupStreamDefinition,
StreamDefinition,
@@ -23,9 +22,14 @@ import { createServerRoute } from '../../create_server_route';
import { readStream } from './read_stream';
export const readStreamRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}',
+ endpoint: 'GET /api/streams/{name} 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Get a stream',
+ description: 'Fetches a stream definition and associated dashboards',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -53,69 +57,15 @@ export const readStreamRoute = createServerRoute({
},
});
-export interface StreamDetailsResponse {
- details: {
- count: number;
- };
-}
-
-export const streamDetailRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}/_details',
- options: {
- access: 'internal',
- },
- security: {
- authz: {
- enabled: false,
- reason:
- 'This API delegates security to the currently logged in user and their Elasticsearch permissions.',
- },
- },
- params: z.object({
- path: z.object({ name: z.string() }),
- query: z.object({
- start: z.string(),
- end: z.string(),
- }),
- }),
- handler: async ({ params, request, getScopedClients }): Promise => {
- const { scopedClusterClient, streamsClient } = await getScopedClients({ request });
- const streamEntity = await streamsClient.getStream(params.path.name);
-
- const indexPattern = isGroupStreamDefinition(streamEntity)
- ? streamEntity.group.members.join(',')
- : streamEntity.name;
- // check doc count
- const docCountResponse = await scopedClusterClient.asCurrentUser.search({
- index: indexPattern,
- body: {
- track_total_hits: true,
- query: {
- range: {
- '@timestamp': {
- gte: params.query.start,
- lte: params.query.end,
- },
- },
- },
- size: 0,
- },
- });
-
- const count = (docCountResponse.hits.total as SearchTotalHits).value;
-
- return {
- details: {
- count,
- },
- };
- },
-});
-
export const listStreamsRoute = createServerRoute({
- endpoint: 'GET /api/streams',
+ endpoint: 'GET /api/streams 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ description: 'Fetches list of all streams',
+ summary: 'Get stream list',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -134,9 +84,15 @@ export const listStreamsRoute = createServerRoute({
});
export const editStreamRoute = createServerRoute({
- endpoint: 'PUT /api/streams/{name}',
+ endpoint: 'PUT /api/streams/{name} 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Create or update a stream',
+ description:
+ 'Creates or updates a stream definition. Classic streams can not be created through this API, only updated',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -187,9 +143,14 @@ export const editStreamRoute = createServerRoute({
});
export const deleteStreamRoute = createServerRoute({
- endpoint: 'DELETE /api/streams/{name}',
+ endpoint: 'DELETE /api/streams/{name} 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Delete a stream',
+ description: 'Deletes a stream definition and the underlying data stream',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -214,7 +175,6 @@ export const deleteStreamRoute = createServerRoute({
export const crudRoutes = {
...readStreamRoute,
- ...streamDetailRoute,
...listStreamsRoute,
...editStreamRoute,
...deleteStreamRoute,
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/enablement/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/streams/enablement/route.ts
index 8972b35389365..9069968f6ea1e 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/enablement/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/streams/enablement/route.ts
@@ -12,10 +12,15 @@ import { DisableStreamsResponse, EnableStreamsResponse } from '../../../lib/stre
import { createServerRoute } from '../../create_server_route';
export const enableStreamsRoute = createServerRoute({
- endpoint: 'POST /api/streams/_enable',
+ endpoint: 'POST /api/streams/_enable 2023-10-31',
params: z.object({}),
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Enable streams',
+ description: 'Enables wired streams',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -42,14 +47,22 @@ export const enableStreamsRoute = createServerRoute({
});
export const disableStreamsRoute = createServerRoute({
- endpoint: 'POST /api/streams/_disable',
+ endpoint: 'POST /api/streams/_disable 2023-10-31',
params: z.object({}),
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Disable streams',
+ description:
+ 'Disables wired streams and deletes all existing stream definitions. The data of wired streams is deleted, but the data of classic streams is preserved.',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
- requiredPrivileges: ['streams_write'],
+ enabled: false,
+ reason:
+ 'This API delegates security to the currently logged in user and their Elasticsearch permissions.',
},
},
handler: async ({ request, getScopedClients }): Promise => {
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/group/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/streams/group/route.ts
index 64d785f9017d8..115733426f94e 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/group/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/streams/group/route.ts
@@ -16,9 +16,14 @@ import {
import { createServerRoute } from '../../create_server_route';
const readGroupRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}/_group',
+ endpoint: 'GET /api/streams/{name}/_group 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Get group stream settings',
+ description: 'Fetches the group settings of a group stream definition',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -48,9 +53,14 @@ const readGroupRoute = createServerRoute({
});
const upsertGroupRoute = createServerRoute({
- endpoint: 'PUT /api/streams/{name}/_group',
+ endpoint: 'PUT /api/streams/{name}/_group 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ description: 'Upserts the group settings of a group stream definition',
+ summary: 'Upsert group stream settings',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/ingest/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/streams/ingest/route.ts
index 3bcb826efa7d3..a70d07472ab14 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/ingest/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/streams/ingest/route.ts
@@ -17,9 +17,14 @@ import { z } from '@kbn/zod';
import { createServerRoute } from '../../create_server_route';
const readIngestRoute = createServerRoute({
- endpoint: 'GET /api/streams/{name}/_ingest',
+ endpoint: 'GET /api/streams/{name}/_ingest 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Get ingest stream settings',
+ description: 'Fetches the ingest settings of an ingest stream definition',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -53,9 +58,14 @@ const readIngestRoute = createServerRoute({
});
const upsertIngestRoute = createServerRoute({
- endpoint: 'PUT /api/streams/{name}/_ingest',
+ endpoint: 'PUT /api/streams/{name}/_ingest 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ summary: 'Update ingest stream settings',
+ description: 'Upserts the ingest settings of an ingest stream definition',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
diff --git a/x-pack/platform/plugins/shared/streams/server/routes/streams/management/route.ts b/x-pack/platform/plugins/shared/streams/server/routes/streams/management/route.ts
index 7b6e9e0cdc1c5..5e8126bedf4df 100644
--- a/x-pack/platform/plugins/shared/streams/server/routes/streams/management/route.ts
+++ b/x-pack/platform/plugins/shared/streams/server/routes/streams/management/route.ts
@@ -5,22 +5,20 @@
* 2.0.
*/
-import {
- SampleDocument,
- conditionSchema,
- conditionToQueryDsl,
- getFields,
-} from '@kbn/streams-schema';
+import { conditionSchema } from '@kbn/streams-schema';
import { z } from '@kbn/zod';
import { ResyncStreamsResponse } from '../../../lib/streams/client';
-import { checkAccess } from '../../../lib/streams/stream_crud';
import { createServerRoute } from '../../create_server_route';
-import { DefinitionNotFoundError } from '../../../lib/streams/errors/definition_not_found_error';
export const forkStreamsRoute = createServerRoute({
- endpoint: 'POST /api/streams/{name}/_fork',
+ endpoint: 'POST /api/streams/{name}/_fork 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ description: 'Forks a wired stream and creates a child stream',
+ summary: 'Fork a stream',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -49,9 +47,14 @@ export const forkStreamsRoute = createServerRoute({
});
export const resyncStreamsRoute = createServerRoute({
- endpoint: 'POST /api/streams/_resync',
+ endpoint: 'POST /api/streams/_resync 2023-10-31',
options: {
- access: 'internal',
+ access: 'public',
+ description: 'Resyncs all streams, making sure that Elasticsearch assets are up to date',
+ summary: 'Resync streams',
+ availability: {
+ stability: 'experimental',
+ },
},
security: {
authz: {
@@ -75,7 +78,9 @@ export const getStreamsStatusRoute = createServerRoute({
},
security: {
authz: {
- requiredPrivileges: ['streams_read'],
+ enabled: false,
+ reason:
+ 'This API delegates security to the currently logged in user and their Elasticsearch permissions.',
},
},
handler: async ({ request, getScopedClients }): Promise<{ enabled: boolean }> => {
@@ -87,91 +92,8 @@ export const getStreamsStatusRoute = createServerRoute({
},
});
-export const sampleStreamRoute = createServerRoute({
- endpoint: 'POST /api/streams/{name}/_sample',
- options: {
- access: 'internal',
- },
- security: {
- authz: {
- enabled: false,
- reason:
- 'This API delegates security to the currently logged in user and their Elasticsearch permissions.',
- },
- },
- params: z.object({
- path: z.object({ name: z.string() }),
- body: z.object({
- if: z.optional(conditionSchema),
- start: z.optional(z.number()),
- end: z.optional(z.number()),
- size: z.optional(z.number()),
- }),
- }),
- handler: async ({ params, request, getScopedClients }) => {
- const { scopedClusterClient } = await getScopedClients({ request });
-
- const { read } = await checkAccess({ name: params.path.name, scopedClusterClient });
-
- if (!read) {
- throw new DefinitionNotFoundError(`Stream definition for ${params.path.name} not found`);
- }
-
- const { if: condition, start, end, size } = params.body;
- const searchBody = {
- query: {
- bool: {
- must: [
- condition ? conditionToQueryDsl(condition) : { match_all: {} },
- {
- range: {
- '@timestamp': {
- gte: start,
- lte: end,
- format: 'epoch_millis',
- },
- },
- },
- ],
- },
- },
- // Conditions could be using fields which are not indexed or they could use it with other types than they are eventually mapped as.
- // Because of this we can't rely on mapped fields to draw a sample, instead we need to use runtime fields to simulate what happens during
- // ingest in the painless condition checks.
- // This is less efficient than it could be - in some cases, these fields _are_ indexed with the right type and we could use them directly.
- // This can be optimized in the future.
- runtime_mappings: condition
- ? Object.fromEntries(
- getFields(condition).map((field) => [
- field.name,
- { type: field.type === 'string' ? 'keyword' : 'double' },
- ])
- )
- : undefined,
- sort: [
- {
- '@timestamp': {
- order: 'desc',
- },
- },
- ],
- terminate_after: size,
- track_total_hits: false,
- size,
- };
- const results = await scopedClusterClient.asCurrentUser.search({
- index: params.path.name,
- allow_no_indices: true,
- ...searchBody,
- });
-
- return { documents: results.hits.hits.map((hit) => hit._source) as SampleDocument[] };
- },
-});
-
export const managementRoutes = {
...forkStreamsRoute,
...resyncStreamsRoute,
...getStreamsStatusRoute,
- ...sampleStreamRoute,
};
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/flyout/sample_preview_table.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/flyout/sample_preview_table.tsx
index a9522bc6220a6..6f1e642966cd3 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/flyout/sample_preview_table.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/flyout/sample_preview_table.tsx
@@ -42,19 +42,22 @@ const SamplePreviewTableContent = ({
const { value, loading, error } = useStreamsAppFetch(
({ signal }) => {
- return streamsRepositoryClient.fetch('POST /api/streams/{name}/schema/fields_simulation', {
- signal,
- params: {
- path: {
- name: stream.name,
+ return streamsRepositoryClient.fetch(
+ 'POST /internal/streams/{name}/schema/fields_simulation',
+ {
+ signal,
+ params: {
+ path: {
+ name: stream.name,
+ },
+ body: {
+ field_definitions: [
+ { ...convertToFieldDefinitionConfig(nextField), name: nextField.name },
+ ],
+ },
},
- body: {
- field_definitions: [
- { ...convertToFieldDefinitionConfig(nextField), name: nextField.name },
- ],
- },
- },
- });
+ }
+ );
},
[stream.name, nextField, streamsRepositoryClient],
{ disableToastOnError: true }
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/hooks/use_schema_fields.ts b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/hooks/use_schema_fields.ts
index 803b578a301f8..c2f925aa32779 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/hooks/use_schema_fields.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/schema_editor/hooks/use_schema_fields.ts
@@ -46,7 +46,7 @@ export const useSchemaFields = ({
refresh: refreshUnmappedFields,
} = useStreamsAppFetch(
({ signal }) => {
- return streamsRepositoryClient.fetch('GET /api/streams/{name}/schema/unmapped_fields', {
+ return streamsRepositoryClient.fetch('GET /internal/streams/{name}/schema/unmapped_fields', {
signal,
params: {
path: {
@@ -110,7 +110,7 @@ export const useSchemaFields = ({
throw new Error('The field is not different, hence updating is not necessary.');
}
- await streamsRepositoryClient.fetch(`PUT /api/streams/{name}/_ingest`, {
+ await streamsRepositoryClient.fetch(`PUT /api/streams/{name}/_ingest 2023-10-31`, {
signal: abortController.signal,
params: {
path: {
@@ -162,7 +162,7 @@ export const useSchemaFields = ({
throw new Error('The field is not mapped, hence it cannot be unmapped.');
}
- await streamsRepositoryClient.fetch(`PUT /api/streams/{name}/_ingest`, {
+ await streamsRepositoryClient.fetch(`PUT /api/streams/{name}/_ingest 2023-10-31`, {
signal: abortController.signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/processors/grok/grok_ai_suggestions.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/processors/grok/grok_ai_suggestions.tsx
index ab5fd8579f920..6473821cb5cec 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/processors/grok/grok_ai_suggestions.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/processors/grok/grok_ai_suggestions.tsx
@@ -184,7 +184,7 @@ function InnerGrokAiSuggestions({
setSuggestionsError(undefined);
setSuggestions(undefined);
streamsRepositoryClient
- .fetch('POST /api/streams/{name}/processing/_suggestions', {
+ .fetch('POST /internal/streams/{name}/processing/_suggestions', {
signal: abortController.signal,
params: {
path: { name: definition.stream.name },
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/samples_fetcher_actor.ts b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/samples_fetcher_actor.ts
index 9b4cee2ad2ce4..67464e0d42897 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/samples_fetcher_actor.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/samples_fetcher_actor.ts
@@ -23,18 +23,21 @@ export function createSamplesFetchActor({
streamsRepositoryClient,
}: Pick) {
return fromPromise(async ({ input, signal }) => {
- const samplesBody = await streamsRepositoryClient.fetch('POST /api/streams/{name}/_sample', {
- signal,
- params: {
- path: { name: input.streamName },
- body: {
- if: input.condition,
- start: input.absoluteTimeRange.start,
- end: input.absoluteTimeRange.end,
- size: 100,
+ const samplesBody = await streamsRepositoryClient.fetch(
+ 'POST /internal/streams/{name}/_sample',
+ {
+ signal,
+ params: {
+ path: { name: input.streamName },
+ body: {
+ if: input.condition,
+ start: input.absoluteTimeRange.start,
+ end: input.absoluteTimeRange.end,
+ size: 100,
+ },
},
- },
- });
+ }
+ );
return samplesBody.documents.map(flattenObjectNestedLast) as FlattenRecord[];
});
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/simulation_runner_actor.ts b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/simulation_runner_actor.ts
index f2e6910228058..9be731f048dda 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/simulation_runner_actor.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/simulation_runner_actor.ts
@@ -23,7 +23,7 @@ export function createSimulationRunnerActor({
streamsRepositoryClient,
}: Pick) {
return fromPromise(({ input, signal }) =>
- streamsRepositoryClient.fetch('POST /api/streams/{name}/processing/_simulate', {
+ streamsRepositoryClient.fetch('POST /internal/streams/{name}/processing/_simulate', {
signal,
params: {
path: { name: input.streamName },
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/types.ts b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/types.ts
index 1aedbd31b3635..65f93d17bb827 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/types.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/simulation_state_machine/types.ts
@@ -16,7 +16,7 @@ import {
import { ProcessorDefinitionWithUIAttributes } from '../../types';
import { PreviewDocsFilterOption } from './preview_docs_filter';
-export type Simulation = APIReturnType<'POST /api/streams/{name}/processing/_simulate'>;
+export type Simulation = APIReturnType<'POST /internal/streams/{name}/processing/_simulate'>;
export interface SimulationMachineDeps {
data: DataPublicPluginStart;
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/stream_enrichment_state_machine/upsert_stream_actor.ts b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/stream_enrichment_state_machine/upsert_stream_actor.ts
index 057ff7a596d26..89d9f3146c9b7 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/stream_enrichment_state_machine/upsert_stream_actor.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_enrichment/state_management/stream_enrichment_state_machine/upsert_stream_actor.ts
@@ -19,7 +19,7 @@ import { StreamEnrichmentServiceDependencies } from './types';
import { processorConverter } from '../../utils';
import { ProcessorDefinitionWithUIAttributes } from '../../types';
-export type UpsertStreamResponse = APIReturnType<'PUT /api/streams/{name}/_ingest'>;
+export type UpsertStreamResponse = APIReturnType<'PUT /api/streams/{name}/_ingest 2023-10-31'>;
export interface UpsertStreamInput {
definition: IngestStreamGetResponse;
@@ -31,7 +31,7 @@ export function createUpsertStreamActor({
streamsRepositoryClient,
}: Pick) {
return fromPromise(({ input, signal }) => {
- return streamsRepositoryClient.fetch(`PUT /api/streams/{name}/_ingest`, {
+ return streamsRepositoryClient.fetch(`PUT /api/streams/{name}/_ingest 2023-10-31`, {
signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/hooks/use_ingestion_rate.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/hooks/use_ingestion_rate.tsx
index 139114d0de8ef..9d459d51d987e 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/hooks/use_ingestion_rate.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/hooks/use_ingestion_rate.tsx
@@ -211,7 +211,7 @@ export const useIngestionRatePerTier = ({
}
const ilmExplain = await streamsRepositoryClient.fetch(
- 'GET /api/streams/{name}/lifecycle/_explain',
+ 'GET /internal/streams/{name}/lifecycle/_explain',
{
params: { path: { name: definition.stream.name } },
signal,
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/ilm_summary.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/ilm_summary.tsx
index 5110a7db4e250..ae45e44269261 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/ilm_summary.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/ilm_summary.tsx
@@ -57,7 +57,7 @@ export function IlmSummary({
({ signal }) => {
if (!definition) return;
- return streamsRepositoryClient.fetch('GET /api/streams/{name}/lifecycle/_stats', {
+ return streamsRepositoryClient.fetch('GET /internal/streams/{name}/lifecycle/_stats', {
params: { path: { name: definition.stream.name } },
signal,
});
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/index.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/index.tsx
index dd19273fedcfd..89113c8cb562e 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/index.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_lifecycle/index.tsx
@@ -146,7 +146,7 @@ export function StreamDetailLifecycle({
},
} as IngestUpsertRequest;
- await streamsRepositoryClient.fetch('PUT /api/streams/{name}/_ingest', {
+ await streamsRepositoryClient.fetch('PUT /api/streams/{name}/_ingest 2023-10-31', {
params: {
path: { name: definition.stream.name },
body: request,
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/control_bar.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/control_bar.tsx
index 1e5d15fb54e99..cc7b3b4c77ea8 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/control_bar.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/control_bar.tsx
@@ -57,7 +57,7 @@ export function ControlBar({
return;
}
- return streamsRepositoryClient.fetch('POST /api/streams/{name}/_fork', {
+ return streamsRepositoryClient.fetch('POST /api/streams/{name}/_fork 2023-10-31', {
signal,
params: {
path: {
@@ -96,7 +96,7 @@ export function ControlBar({
},
} as IngestUpsertRequest;
- return streamsRepositoryClient.fetch('PUT /api/streams/{name}/_ingest', {
+ return streamsRepositoryClient.fetch('PUT /api/streams/{name}/_ingest 2023-10-31', {
signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/index.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/index.tsx
index 986b00795e44c..e330b9ff21d32 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/index.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/data_management/stream_detail_routing/index.tsx
@@ -44,7 +44,7 @@ export function StreamDetailRouting({
const streamsListFetch = useStreamsAppFetch(
({ signal }) => {
- return streamsRepositoryClient.fetch('GET /api/streams', {
+ return streamsRepositoryClient.fetch('GET /api/streams 2023-10-31', {
signal,
});
},
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/stream_delete_modal/index.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/stream_delete_modal/index.tsx
index d301b44a01c2d..2cb2c25872887 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/stream_delete_modal/index.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/stream_delete_modal/index.tsx
@@ -117,7 +117,7 @@ export function StreamDeleteModal({
onClick={async () => {
try {
setDeleteInProgress(true);
- await streamsRepositoryClient.fetch('DELETE /api/streams/{name}', {
+ await streamsRepositoryClient.fetch('DELETE /api/streams/{name} 2023-10-31', {
signal: abortController.signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_dashboards_view/add_dashboard_flyout.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_dashboards_view/add_dashboard_flyout.tsx
index 96d39cf2a1d2b..44815ead55635 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_dashboards_view/add_dashboard_flyout.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_dashboards_view/add_dashboard_flyout.tsx
@@ -65,7 +65,7 @@ export function AddDashboardFlyout({
const dashboardSuggestionsFetch = useStreamsAppFetch(
({ signal }) => {
return streamsRepositoryClient
- .fetch('POST /api/streams/{name}/dashboards/_suggestions', {
+ .fetch('POST /internal/streams/{name}/dashboards/_suggestions', {
signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_overview/index.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_overview/index.tsx
index c17af5ac7c3e1..c821dfb484584 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_overview/index.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/stream_detail_overview/index.tsx
@@ -137,7 +137,7 @@ export function StreamDetailOverview({ definition }: { definition?: IngestStream
) {
return undefined;
}
- return streamsRepositoryClient.fetch('GET /api/streams/{name}/_details', {
+ return streamsRepositoryClient.fetch('GET /internal/streams/{name}/_details', {
signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/components/stream_list_view/index.tsx b/x-pack/platform/plugins/shared/streams_app/public/components/stream_list_view/index.tsx
index c1e81281f639c..0e4a7af87aca6 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/components/stream_list_view/index.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/components/stream_list_view/index.tsx
@@ -27,7 +27,7 @@ export function StreamListView() {
const streamsListFetch = useStreamsAppFetch(
({ signal }) => {
- return streamsRepositoryClient.fetch('GET /api/streams', {
+ return streamsRepositoryClient.fetch('GET /api/streams 2023-10-31', {
signal,
});
},
diff --git a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_api.ts b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_api.ts
index ba299b9a20c68..52d74d0b0b208 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_api.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_api.ts
@@ -25,7 +25,7 @@ export const useDashboardsApi = (name?: string) => {
return;
}
- await streamsRepositoryClient.fetch('POST /api/streams/{name}/dashboards/_bulk', {
+ await streamsRepositoryClient.fetch('POST /api/streams/{name}/dashboards/_bulk 2023-10-31', {
signal,
params: {
path: {
@@ -47,7 +47,7 @@ export const useDashboardsApi = (name?: string) => {
if (!name) {
return;
}
- await streamsRepositoryClient.fetch('POST /api/streams/{name}/dashboards/_bulk', {
+ await streamsRepositoryClient.fetch('POST /api/streams/{name}/dashboards/_bulk 2023-10-31', {
signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_fetch.ts b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_fetch.ts
index 656da3c6e50d0..755d27115658a 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_fetch.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_dashboards_fetch.ts
@@ -21,7 +21,7 @@ export const useDashboardsFetch = (name?: string) => {
if (!name) {
return Promise.resolve(undefined);
}
- return streamsRepositoryClient.fetch('GET /api/streams/{name}/dashboards', {
+ return streamsRepositoryClient.fetch('GET /api/streams/{name}/dashboards 2023-10-31', {
signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_stream_detail.tsx b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_stream_detail.tsx
index ba251cacfbaeb..2c889da6e6de7 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_stream_detail.tsx
+++ b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_stream_detail.tsx
@@ -39,7 +39,7 @@ export function StreamDetailContextProvider({
} = useStreamsAppFetch(
async ({ signal }) => {
return streamsRepositoryClient
- .fetch('GET /api/streams/{name}', {
+ .fetch('GET /api/streams/{name} 2023-10-31', {
signal,
params: {
path: {
diff --git a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_wired_streams.ts b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_wired_streams.ts
index 4ed4e02d86321..bdbc6e5d05206 100644
--- a/x-pack/platform/plugins/shared/streams_app/public/hooks/use_wired_streams.ts
+++ b/x-pack/platform/plugins/shared/streams_app/public/hooks/use_wired_streams.ts
@@ -19,7 +19,7 @@ export const useWiredStreams = () => {
} = useKibana();
const result = useStreamsAppFetch(
- async ({ signal }) => streamsRepositoryClient.fetch('GET /api/streams', { signal }),
+ async ({ signal }) => streamsRepositoryClient.fetch('GET /api/streams 2023-10-31', { signal }),
[streamsRepositoryClient]
);
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/assets/dashboard.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/assets/dashboard.ts
index f64e913fe069a..c3506c5baae10 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/assets/dashboard.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/assets/dashboard.ts
@@ -53,23 +53,29 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
}
async function linkDashboard(id: string) {
- const response = await apiClient.fetch('PUT /api/streams/{name}/dashboards/{dashboardId}', {
- params: { path: { name: 'logs', dashboardId: id } },
- });
+ const response = await apiClient.fetch(
+ 'PUT /api/streams/{name}/dashboards/{dashboardId} 2023-10-31',
+ {
+ params: { path: { name: 'logs', dashboardId: id } },
+ }
+ );
expect(response.status).to.be(200);
}
async function unlinkDashboard(id: string) {
- const response = await apiClient.fetch('DELETE /api/streams/{name}/dashboards/{dashboardId}', {
- params: { path: { name: 'logs', dashboardId: id } },
- });
+ const response = await apiClient.fetch(
+ 'DELETE /api/streams/{name}/dashboards/{dashboardId} 2023-10-31',
+ {
+ params: { path: { name: 'logs', dashboardId: id } },
+ }
+ );
expect(response.status).to.be(200);
}
async function bulkLinkDashboard(...ids: string[]) {
- const response = await apiClient.fetch('POST /api/streams/{name}/dashboards/_bulk', {
+ const response = await apiClient.fetch('POST /api/streams/{name}/dashboards/_bulk 2023-10-31', {
params: {
path: { name: 'logs' },
body: {
@@ -88,7 +94,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
}
async function bulkUnlinkDashboard(...ids: string[]) {
- const response = await apiClient.fetch('POST /api/streams/{name}/dashboards/_bulk', {
+ const response = await apiClient.fetch('POST /api/streams/{name}/dashboards/_bulk 2023-10-31', {
params: {
path: { name: 'logs' },
body: {
@@ -134,7 +140,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('lists the dashboard in the stream response', async () => {
- const response = await apiClient.fetch('GET /api/streams/{name}', {
+ const response = await apiClient.fetch('GET /api/streams/{name} 2023-10-31', {
params: { path: { name: 'logs' } },
});
@@ -144,7 +150,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('lists the dashboard in the dashboards get response', async () => {
- const response = await apiClient.fetch('GET /api/streams/{name}/dashboards', {
+ const response = await apiClient.fetch('GET /api/streams/{name}/dashboards 2023-10-31', {
params: { path: { name: 'logs' } },
});
@@ -161,7 +167,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('dropped all dashboards', async () => {
- const response = await apiClient.fetch('GET /api/streams/{name}/dashboards', {
+ const response = await apiClient.fetch('GET /api/streams/{name}/dashboards 2023-10-31', {
params: { path: { name: 'logs' } },
});
@@ -174,7 +180,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
await unlinkDashboard(SEARCH_DASHBOARD_ID);
await linkDashboard(SEARCH_DASHBOARD_ID);
- const response = await apiClient.fetch('GET /api/streams/{name}/dashboards', {
+ const response = await apiClient.fetch('GET /api/streams/{name}/dashboards 2023-10-31', {
params: { path: { name: 'logs' } },
});
@@ -190,7 +196,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('no longer lists the dashboard as a linked asset', async () => {
- const response = await apiClient.fetch('GET /api/streams/{name}/dashboards', {
+ const response = await apiClient.fetch('GET /api/streams/{name}/dashboards 2023-10-31', {
params: { path: { name: 'logs' } },
});
@@ -214,7 +220,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('shows the linked dashboards', async () => {
- const response = await apiClient.fetch('GET /api/streams/{name}/dashboards', {
+ const response = await apiClient.fetch('GET /api/streams/{name}/dashboards 2023-10-31', {
params: { path: { name: 'logs' } },
});
@@ -227,7 +233,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('only shows the remaining linked dashboard', async () => {
- const response = await apiClient.fetch('GET /api/streams/{name}/dashboards', {
+ const response = await apiClient.fetch('GET /api/streams/{name}/dashboards 2023-10-31', {
params: { path: { name: 'logs' } },
});
@@ -253,7 +259,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
describe('after creating multiple dashboards', () => {
it('suggests dashboards to link', async () => {
const response = await apiClient.fetch(
- 'POST /api/streams/{name}/dashboards/_suggestions',
+ 'POST /internal/streams/{name}/dashboards/_suggestions',
{
params: { path: { name: 'logs' }, body: { tags: [] }, query: { query: '' } },
}
@@ -265,7 +271,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('filters suggested dashboards based on tags', async () => {
const response = await apiClient.fetch(
- 'POST /api/streams/{name}/dashboards/_suggestions',
+ 'POST /internal/streams/{name}/dashboards/_suggestions',
{
params: { path: { name: 'logs' }, body: { tags: [TAG_ID] }, query: { query: '' } },
}
@@ -277,7 +283,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('filters suggested dashboards based on the query', async () => {
const response = await apiClient.fetch(
- 'POST /api/streams/{name}/dashboards/_suggestions',
+ 'POST /internal/streams/{name}/dashboards/_suggestions',
{
params: {
path: { name: 'logs' },
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/classic.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/classic.ts
index eb5f28cac1eb4..67b6cba189305 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/classic.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/classic.ts
@@ -39,7 +39,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
const {
body: { streams },
status,
- } = await apiClient.fetch('GET /api/streams');
+ } = await apiClient.fetch('GET /api/streams 2023-10-31');
expect(status).to.eql(200);
@@ -56,7 +56,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('Allows setting processing on classic streams', async () => {
- const putResponse = await apiClient.fetch('PUT /api/streams/{name}', {
+ const putResponse = await apiClient.fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: {
name: TEST_STREAM_NAME,
@@ -88,7 +88,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
expect(putResponse.body).to.have.property('acknowledged', true);
- const getResponse = await apiClient.fetch('GET /api/streams/{name}', {
+ const getResponse = await apiClient.fetch('GET /api/streams/{name} 2023-10-31', {
params: { path: { name: TEST_STREAM_NAME } },
});
@@ -176,7 +176,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('Allows removing processing on classic streams', async () => {
- const response = await apiClient.fetch('PUT /api/streams/{name}', {
+ const response = await apiClient.fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: TEST_STREAM_NAME },
body: {
@@ -214,7 +214,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('Allows deleting classic streams', async () => {
- const deleteStreamResponse = await apiClient.fetch('DELETE /api/streams/{name}', {
+ const deleteStreamResponse = await apiClient.fetch('DELETE /api/streams/{name} 2023-10-31', {
params: {
path: {
name: TEST_STREAM_NAME,
@@ -224,7 +224,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
expect(deleteStreamResponse.status).to.eql(200);
- const getStreamsResponse = await apiClient.fetch('GET /api/streams');
+ const getStreamsResponse = await apiClient.fetch('GET /api/streams 2023-10-31');
expect(getStreamsResponse.status).to.eql(200);
@@ -272,7 +272,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('Allows adding processing to classic streams without pipeline', async () => {
- const putResponse = await apiClient.fetch('PUT /api/streams/{name}', {
+ const putResponse = await apiClient.fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: {
name: DATA_STREAM_NAME,
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/flush_config.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/flush_config.ts
index bf9614a4a2a77..29941f3a0a0dc 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/flush_config.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/flush_config.ts
@@ -44,21 +44,21 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
if (isGroupStreamDefinitionBase(stream) || isUnwiredStreamDefinition(stream)) return [];
return stream.ingest.wired.routing.map((r) => r.destination);
}
- const logs = await apiClient.fetch('GET /api/streams/{name}', {
+ const logs = await apiClient.fetch('GET /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'logs' },
},
});
expect(getChildNames(logs.body.stream)).to.contain('logs.deeply');
- const logsDeeply = await apiClient.fetch('GET /api/streams/{name}', {
+ const logsDeeply = await apiClient.fetch('GET /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'logs.deeply' },
},
});
expect(getChildNames(logsDeeply.body.stream)).to.contain('logs.deeply.nested');
- const logsDeeplyNested = await apiClient.fetch('GET /api/streams/{name}', {
+ const logsDeeplyNested = await apiClient.fetch('GET /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'logs.deeply.nested' },
},
@@ -66,11 +66,14 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
expect(getChildNames(logsDeeplyNested.body.stream)).to.contain(
'logs.deeply.nested.streamname'
);
- const logsDeeplyNestedStreamname = await apiClient.fetch('GET /api/streams/{name}', {
- params: {
- path: { name: 'logs.deeply.nested.streamname' },
- },
- });
+ const logsDeeplyNestedStreamname = await apiClient.fetch(
+ 'GET /api/streams/{name} 2023-10-31',
+ {
+ params: {
+ path: { name: 'logs.deeply.nested.streamname' },
+ },
+ }
+ );
expect(
(logsDeeplyNestedStreamname.body as WiredStreamGetResponse).stream.ingest.wired.fields
).to.eql({
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/full_flow.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/full_flow.ts
index e3dae9972f86c..de20471ddd28b 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/full_flow.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/full_flow.ts
@@ -97,7 +97,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('returns a 404 for logs', async () => {
await apiClient
- .fetch('GET /api/streams/{name}', {
+ .fetch('GET /api/streams/{name} 2023-10-31', {
params: {
path: {
name: 'logs',
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/group_streams.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/group_streams.ts
index e889dbf5f3c15..a616b85f7878b 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/group_streams.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/group_streams.ts
@@ -36,7 +36,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('successfully creates a GroupStream', async () => {
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'test-group' },
body: {
@@ -55,7 +55,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('successfully creates a second GroupStream', async () => {
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'test-group-too' },
body: {
@@ -74,7 +74,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('unsuccessfully updates a GroupStream with an uknown stream', async () => {
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'test-group' },
body: {
@@ -92,7 +92,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('unsuccessfully updates a GroupStream with an itself as a member', async () => {
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'test-group' },
body: {
@@ -110,7 +110,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('unsuccessfully updates a GroupStream with a forbidden member', async () => {
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'test-group' },
body: {
@@ -128,7 +128,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('successfully deletes a GroupStream', async () => {
await apiClient
- .fetch('DELETE /api/streams/{name}', {
+ .fetch('DELETE /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'test-group-too' },
},
@@ -138,7 +138,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('successfully reads a GroupStream', async () => {
const response = await apiClient
- .fetch('GET /api/streams/{name}', {
+ .fetch('GET /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'test-group' },
},
@@ -157,7 +157,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('successfully upserts a GroupStream from _group', async () => {
const response = await apiClient
- .fetch('PUT /api/streams/{name}/_group', {
+ .fetch('PUT /api/streams/{name}/_group 2023-10-31', {
params: {
path: { name: 'test-group-3' },
body: {
@@ -176,7 +176,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('successfully reads a GroupStream from _group', async () => {
const response = await apiClient
- .fetch('GET /api/streams/{name}/_group', {
+ .fetch('GET /api/streams/{name}/_group 2023-10-31', {
params: {
path: { name: 'test-group-3' },
},
@@ -190,7 +190,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('successfully lists a GroupStream', async () => {
- const response = await apiClient.fetch('GET /api/streams').expect(200);
+ const response = await apiClient.fetch('GET /api/streams 2023-10-31').expect(200);
expect(response.body.streams.some((stream) => stream.name === 'test-group')).to.eql(true);
expect(response.body.streams.some((stream) => stream.name === 'test-group-3')).to.eql(true);
});
@@ -198,7 +198,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('unsuccessfully creates a group stream with the same name as a unwired stream', async () => {
await esClient.index({ index: 'metrics-test-test', document: { '@timestamp': '2025' } });
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'metrics-test-test' },
body: {
@@ -216,7 +216,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
it('unsuccessfully creates a group stream prefixed with logs', async () => {
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: { name: 'logs.group' },
body: {
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/create_streams.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/create_streams.ts
index 9af3b443689ae..5af710ffdb74b 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/create_streams.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/create_streams.ts
@@ -130,7 +130,7 @@ const streams: StreamPutItem[] = [
export async function createStreams(apiClient: StreamsSupertestRepositoryClient) {
for (const { name, ...stream } of streams) {
await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
body: {
...stream,
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/requests.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/requests.ts
index f18b19ac90270..ec5186e1ccfba 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/requests.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/helpers/requests.ts
@@ -14,11 +14,11 @@ import { StreamsRouteRepository } from '@kbn/streams-plugin/server';
import { StreamsSupertestRepositoryClient } from './repository_client';
export async function enableStreams(client: StreamsSupertestRepositoryClient) {
- await client.fetch('POST /api/streams/_enable').expect(200);
+ await client.fetch('POST /api/streams/_enable 2023-10-31').expect(200);
}
export async function disableStreams(client: StreamsSupertestRepositoryClient) {
- await client.fetch('POST /api/streams/_disable').expect(200);
+ await client.fetch('POST /api/streams/_disable 2023-10-31').expect(200);
}
export async function indexDocument(esClient: Client, index: string, document: JsonObject) {
@@ -51,11 +51,11 @@ export async function forkStream(
root: string,
body: ClientRequestParamsOf<
StreamsRouteRepository,
- 'POST /api/streams/{name}/_fork'
+ 'POST /api/streams/{name}/_fork 2023-10-31'
>['params']['body']
) {
return client
- .fetch(`POST /api/streams/{name}/_fork`, {
+ .fetch(`POST /api/streams/{name}/_fork 2023-10-31`, {
params: {
path: {
name: root,
@@ -74,7 +74,7 @@ export async function putStream(
expectStatusCode: number = 200
) {
return await apiClient
- .fetch('PUT /api/streams/{name}', {
+ .fetch('PUT /api/streams/{name} 2023-10-31', {
params: {
path: {
name,
@@ -92,7 +92,7 @@ export async function getStream(
expectStatusCode: number = 200
) {
return await apiClient
- .fetch('GET /api/streams/{name}', {
+ .fetch('GET /api/streams/{name} 2023-10-31', {
params: {
path: {
name,
@@ -109,7 +109,7 @@ export async function getIlmStats(
expectStatusCode: number = 200
) {
return await apiClient
- .fetch('GET /api/streams/{name}/lifecycle/_stats', {
+ .fetch('GET /internal/streams/{name}/lifecycle/_stats', {
params: {
path: {
name,
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/processing_simulate.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/processing_simulate.ts
index 3b812c444c7fa..12aed7c3a748b 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/processing_simulate.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/processing_simulate.ts
@@ -23,12 +23,12 @@ async function simulateProcessingForStream(
name: string,
body: ClientRequestParamsOf<
StreamsRouteRepository,
- 'POST /api/streams/{name}/processing/_simulate'
+ 'POST /internal/streams/{name}/processing/_simulate'
>['params']['body'],
statusCode = 200
) {
return client
- .fetch('POST /api/streams/{name}/processing/_simulate', {
+ .fetch('POST /internal/streams/{name}/processing/_simulate', {
params: {
path: { name },
body,
diff --git a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/schema.ts b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/schema.ts
index 7b6b0f895fae1..2054ebc7ee4fd 100644
--- a/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/schema.ts
+++ b/x-pack/test/api_integration/deployment_agnostic/apis/observability/streams/schema.ts
@@ -43,7 +43,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
describe('Unmapped fields API', () => {
it('Returns unmapped fields', async () => {
const response = await apiClient
- .fetch('GET /api/streams/{name}/schema/unmapped_fields', {
+ .fetch('GET /internal/streams/{name}/schema/unmapped_fields', {
params: {
path: {
name: 'logs',
@@ -58,7 +58,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
describe('Fields simulation API', () => {
it('Returns failure status when simulation would fail', async () => {
const response = await apiClient.fetch(
- 'POST /api/streams/{name}/schema/fields_simulation',
+ 'POST /internal/streams/{name}/schema/fields_simulation',
{
params: {
path: {
@@ -77,7 +77,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
});
it('Returns success status when simulation would succeed', async () => {
const response = await apiClient.fetch(
- 'POST /api/streams/{name}/schema/fields_simulation',
+ 'POST /internal/streams/{name}/schema/fields_simulation',
{
params: {
path: {
@@ -108,7 +108,7 @@ export default function ({ getService }: DeploymentAgnosticFtrProviderContext) {
await forkStream(apiClient, 'logs', forkBody);
const response = await apiClient.fetch(
- 'POST /api/streams/{name}/schema/fields_simulation',
+ 'POST /internal/streams/{name}/schema/fields_simulation',
{
params: {
path: {