From 5a8fc985ba95b5bcb33d43dbe79c50c8896676da Mon Sep 17 00:00:00 2001 From: lcawl Date: Wed, 11 Oct 2023 19:32:25 -0700 Subject: [PATCH 1/4] [DOCS] Add preconfigured AWS Bedrock connector --- .../pre-configured-connectors.asciidoc | 31 ++++++++++++++++++- docs/settings/alert-action-settings.asciidoc | 14 ++++++++- 2 files changed, 43 insertions(+), 2 deletions(-) diff --git a/docs/management/connectors/pre-configured-connectors.asciidoc b/docs/management/connectors/pre-configured-connectors.asciidoc index 6e6694e8a839d..ecf65e887a988 100644 --- a/docs/management/connectors/pre-configured-connectors.asciidoc +++ b/docs/management/connectors/pre-configured-connectors.asciidoc @@ -1,5 +1,9 @@ [[pre-configured-connectors]] == Preconfigured connectors +:frontmatter-description: Define connectors in the {kib} configuration file. +:frontmatter-tags-products: [kibana] +:frontmatter-tags-content-type: [how-to] +:frontmatter-tags-user-goals: [configure] If you are running {kib} on-prem, you can preconfigure a connector to have all the information it needs prior to startup by adding it to the `kibana.yml` file. @@ -107,6 +111,7 @@ Index names must start with `kibana-alert-history-` to take advantage of the pre [[preconfigured-connector-examples]] === Examples +* <> * <> * <> * <> @@ -128,6 +133,30 @@ Index names must start with `kibana-alert-history-` to take advantage of the pre * <> * <> +[float] +[[preconfigured-bedrock-configuration]] +==== AWS Bedrock connectors + +The following example creates a <>: + +[source,text] +-- +xpack.actions.preconfigured: + my-bedrock: + name: preconfigured-bedrock-connector-type + actionTypeId: .bedrock + config: + apiUrl: https://bedrock.us-east-1.amazonaws.com <1> + defaultModel: anthropic.claude-v2 <2> + secrets: + accessKey: key-value <3> + secret: secret-value <4> +-- +<1> The AWS Bedrock request URL. +<2> The default model to use for requests. Current support is for the Anthropic Claude models, defaulting to Claude 2. +<3> The AWS access key for authentication. +<4> The AWS secret for authentication. + [float] [[preconfigured-d3security-configuration]] ==== D3 Security connectors @@ -302,7 +331,7 @@ xpack.actions.preconfigured: secrets: apiKey: superlongapikey <4> -- -<1> The OpenAI request URL +<1> The OpenAI request URL. <2> The OpenAI API provider, either `OpenAI` or `Azure OpenAI`. <3> The default model to use for requests. This setting is optional and applicable only when `apiProvider` is `OpenAI`. <4> The OpenAI or Azure OpenAI API key for authentication. diff --git a/docs/settings/alert-action-settings.asciidoc b/docs/settings/alert-action-settings.asciidoc index 4312d2825a9d4..c5fe25919d709 100644 --- a/docs/settings/alert-action-settings.asciidoc +++ b/docs/settings/alert-action-settings.asciidoc @@ -267,6 +267,7 @@ For a <>, specifies the OpenAI API provider A configuration URL that varies by connector: + -- +* For an <>, specifies the AWS Bedrock request URL. * For a <>, specifies the OpenAI request URL. * For a <>, specifies the {ibm-r} instance URL. * For a <>, specifies the Jira instance URL. @@ -327,7 +328,12 @@ NOTE: If you are using the `xpack.actions.allowedHosts` setting, make sure the h For a <>, specifies a string from the response body of the create case method that corresponds to the external service identifier. `xpack.actions.preconfigured..config.defaultModel`:: -For a <>, specifies the default model to use for requests. It is optional and applicable only when `xpack.actions.preconfigured..config.apiProvider` is `OpenAI`. +The default model to use for requests, which varies by connector: ++ +-- +* For an <>, current support is for the Anthropic Claude models. Defaults to `anthropic.claude-v2`. +* For a <>, it is optional and applicable only when `xpack.actions.preconfigured..config.apiProvider` is `OpenAI`. +-- `xpack.actions.preconfigured..config.executionTimeField`:: For an <>, a field that indicates when the document was indexed. @@ -463,6 +469,9 @@ Sensitive configuration details, such as username, password, and keys, which are + TIP: Sensitive properties, such as passwords, should be stored in the <>. +`xpack.actions.preconfigured..secrets.accessKey`:: +For an <>, specifies the AWS access key for authentication. + `xpack.actions.preconfigured..secrets.apikey`:: An API key secret that varies by connector: + @@ -517,6 +526,9 @@ For a <>, <.secrets.routingKey`:: For a <>, specifies the 32 character PagerDuty Integration Key for an integration on a service, also referred to as the routing key. +`xpack.actions.preconfigured..secrets.secret`:: +For an <>, specifies the AWS secret for authentication. + `xpack.actions.preconfigured..secrets.secretsUrl`:: For an <> with URL authentication, specifies the request URL for the Elastic Alerts trigger in xMatters with the API key included in the URL. It is used only when `xpack.actions.preconfigured..config.usesBasic` is `false`. From 0832c7d257978b16d30c117a63741a384dd89de0 Mon Sep 17 00:00:00 2001 From: lcawl Date: Wed, 11 Oct 2023 20:00:30 -0700 Subject: [PATCH 2/4] [DOCS] Minor fixes --- docs/management/connectors/pre-configured-connectors.asciidoc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/management/connectors/pre-configured-connectors.asciidoc b/docs/management/connectors/pre-configured-connectors.asciidoc index ecf65e887a988..9d71cb02634fd 100644 --- a/docs/management/connectors/pre-configured-connectors.asciidoc +++ b/docs/management/connectors/pre-configured-connectors.asciidoc @@ -24,6 +24,7 @@ predefined, including the connector name and ID. Add `xpack.actions.preconfigured` settings to your `kibana.yml` file. The settings vary depending on which type of connector you're adding. +Refer to <>. This example shows a valid configuration for a Slack connector and a Webhook connector: @@ -137,7 +138,7 @@ Index names must start with `kibana-alert-history-` to take advantage of the pre [[preconfigured-bedrock-configuration]] ==== AWS Bedrock connectors -The following example creates a <>: +The following example creates an <>: [source,text] -- From fd0d2c10cdb9206fa6518d98a13ccf9664f648fd Mon Sep 17 00:00:00 2001 From: lcawl Date: Wed, 11 Oct 2023 20:02:56 -0700 Subject: [PATCH 3/4] Update connector template --- docs/action-type-template.asciidoc | 35 +----------------------------- 1 file changed, 1 insertion(+), 34 deletions(-) diff --git a/docs/action-type-template.asciidoc b/docs/action-type-template.asciidoc index 8ff643c883a40..9bd61039712b3 100644 --- a/docs/action-type-template.asciidoc +++ b/docs/action-type-template.asciidoc @@ -28,42 +28,9 @@ List of user-facing connector configurations. This should align with the fields Property1:: A short description of this property. Property2:: A short description of this property with format hints. This can be specified in `this specific format`. -[float] -[[preconfigured--configuration]] -=== Create preconfigured connectors - -If you are running {kib} on-prem, you can define connectors by -adding `xpack.actions.preconfigured` settings to your `kibana.yml` file. -For example: - -//// -Example preconfigured format for this connector type -//// - -[source,text] --- -xpack.actions.preconfigured: - my-: - name: preconfigured--connector-type - actionTypeId: . - config: - property1: value1 - property2: value2 - secrets: - property3: value3 --- - //// -List of properties from the ConfigSchema and SecretsSchema for this action type. +Add preconfigured settings for this connector type in alert-action-settings.asciidoc and an example in pre-configured-connectors.asciidoc. //// -Config defines information for the connector type. - -`property1`:: A short description of this property. -`property2`:: A short descriptionn of this property. - -Secrets defines sensitive information for the connector type. - -`property3`:: A short descriptionn of this property. [float] [[-action-configuration]] From 58207fb9450aa5ed2c204dedb5a6280fc4c07c2b Mon Sep 17 00:00:00 2001 From: lcawl Date: Fri, 13 Oct 2023 14:29:07 -0700 Subject: [PATCH 4/4] [DOCS] Use shared attribute for connector name --- docs/management/action-types.asciidoc | 4 ++-- .../connectors/action-types/bedrock.asciidoc | 24 +++++++++---------- .../pre-configured-connectors.asciidoc | 6 ++--- docs/settings/alert-action-settings.asciidoc | 8 +++---- 4 files changed, 21 insertions(+), 21 deletions(-) diff --git a/docs/management/action-types.asciidoc b/docs/management/action-types.asciidoc index 357d0e5de50ea..a8a6409ec49ba 100644 --- a/docs/management/action-types.asciidoc +++ b/docs/management/action-types.asciidoc @@ -7,9 +7,9 @@ Connectors provide a central place to store connection information for services [cols="2"] |=== -a| <> +a| <> -| Send a request to AWS Bedrock. +| Send a request to {bedrock}. a| <> diff --git a/docs/management/connectors/action-types/bedrock.asciidoc b/docs/management/connectors/action-types/bedrock.asciidoc index afefc5914435f..a01a750ae77aa 100644 --- a/docs/management/connectors/action-types/bedrock.asciidoc +++ b/docs/management/connectors/action-types/bedrock.asciidoc @@ -1,15 +1,15 @@ [[bedrock-action-type]] -== AWS Bedrock connector and action +== {bedrock} connector and action ++++ -AWS Bedrock +{bedrock} ++++ -:frontmatter-description: Add a connector that can send requests to AWS Bedrock. +:frontmatter-description: Add a connector that can send requests to {bedrock}. :frontmatter-tags-products: [kibana] :frontmatter-tags-content-type: [how-to] :frontmatter-tags-user-goals: [configure] -The AWS Bedrock connector uses https://github.com/axios/axios[axios] to send a POST request to AWS Bedrock. The connector uses the <> to send the request. +The {bedrock} connector uses https://github.com/axios/axios[axios] to send a POST request to {bedrock}. The connector uses the <> to send the request. [float] [[define-bedrock-ui]] @@ -19,18 +19,18 @@ You can create connectors in *{stack-manage-app} > {connectors-ui}*. For exampl [role="screenshot"] // TODO: need logo before screenshot -image::management/connectors/images/bedrock-connector.png[AWS Bedrock connector] +image::management/connectors/images/bedrock-connector.png[{bedrock} connector] [float] [[bedrock-connector-configuration]] ==== Connector configuration -AWS Bedrock connectors have the following configuration properties: +{bedrock} connectors have the following configuration properties: Name:: The name of the connector. -API URL:: The AWS Bedrock request URL. -Default model:: The GAI model for AWS Bedrock to use. Current support is for the Anthropic Claude models, defaulting to Claude 2. The model can be set on a per request basis by including a "model" parameter alongside the request body. -Region:: The AWS Bedrock request URL. +API URL:: The {bedrock} request URL. +Default model:: The GAI model for {bedrock} to use. Current support is for the Anthropic Claude models, defaulting to Claude 2. The model can be set on a per request basis by including a "model" parameter alongside the request body. +Region:: The {bedrock} request URL. Access Key:: The AWS access key for authentication. Secret:: The secret for authentication. @@ -43,11 +43,11 @@ as you're creating or editing the connector in {kib}. For example: [role="screenshot"] // TODO: need logo before screenshot -image::management/connectors/images/bedrock-params.png[AWS Bedrock params test] +image::management/connectors/images/bedrock-params.png[{bedrock} params test] -The AWS Bedrock actions have the following configuration properties. +The {bedrock} actions have the following configuration properties. -Body:: A stringified JSON payload sent to the AWS Bedrock Invoke Model API URL. For example: +Body:: A stringified JSON payload sent to the {bedrock} Invoke Model API URL. For example: + [source,text] -- diff --git a/docs/management/connectors/pre-configured-connectors.asciidoc b/docs/management/connectors/pre-configured-connectors.asciidoc index 9d71cb02634fd..3b0a5e3004f83 100644 --- a/docs/management/connectors/pre-configured-connectors.asciidoc +++ b/docs/management/connectors/pre-configured-connectors.asciidoc @@ -136,9 +136,9 @@ Index names must start with `kibana-alert-history-` to take advantage of the pre [float] [[preconfigured-bedrock-configuration]] -==== AWS Bedrock connectors +==== {bedrock} connectors -The following example creates an <>: +The following example creates an <>: [source,text] -- @@ -153,7 +153,7 @@ xpack.actions.preconfigured: accessKey: key-value <3> secret: secret-value <4> -- -<1> The AWS Bedrock request URL. +<1> The {bedrock} request URL. <2> The default model to use for requests. Current support is for the Anthropic Claude models, defaulting to Claude 2. <3> The AWS access key for authentication. <4> The AWS secret for authentication. diff --git a/docs/settings/alert-action-settings.asciidoc b/docs/settings/alert-action-settings.asciidoc index c5fe25919d709..5130fad9abad4 100644 --- a/docs/settings/alert-action-settings.asciidoc +++ b/docs/settings/alert-action-settings.asciidoc @@ -267,7 +267,7 @@ For a <>, specifies the OpenAI API provider A configuration URL that varies by connector: + -- -* For an <>, specifies the AWS Bedrock request URL. +* For an <>, specifies the {bedrock} request URL. * For a <>, specifies the OpenAI request URL. * For a <>, specifies the {ibm-r} instance URL. * For a <>, specifies the Jira instance URL. @@ -331,7 +331,7 @@ For a <>, specifies a string f The default model to use for requests, which varies by connector: + -- -* For an <>, current support is for the Anthropic Claude models. Defaults to `anthropic.claude-v2`. +* For an <>, current support is for the Anthropic Claude models. Defaults to `anthropic.claude-v2`. * For a <>, it is optional and applicable only when `xpack.actions.preconfigured..config.apiProvider` is `OpenAI`. -- @@ -470,7 +470,7 @@ Sensitive configuration details, such as username, password, and keys, which are TIP: Sensitive properties, such as passwords, should be stored in the <>. `xpack.actions.preconfigured..secrets.accessKey`:: -For an <>, specifies the AWS access key for authentication. +For an <>, specifies the AWS access key for authentication. `xpack.actions.preconfigured..secrets.apikey`:: An API key secret that varies by connector: @@ -527,7 +527,7 @@ For a <>, <>, specifies the 32 character PagerDuty Integration Key for an integration on a service, also referred to as the routing key. `xpack.actions.preconfigured..secrets.secret`:: -For an <>, specifies the AWS secret for authentication. +For an <>, specifies the AWS secret for authentication. `xpack.actions.preconfigured..secrets.secretsUrl`:: For an <> with URL authentication, specifies the request URL for the Elastic Alerts trigger in xMatters with the API key included in the URL.