Class: Aws::QConnect::Client

Inherits:
Seahorse::Client::Base show all
Includes:
ClientStubs
Defined in:
gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb

Overview

An API client for QConnect. To construct a client, you need to configure a :region and :credentials.

client = Aws::QConnect::Client.new(
  region: region_name,
  credentials: credentials,
  # ...
)

For details on configuring region and credentials see the developer guide.

See #initialize for a full list of supported configuration options.

Instance Attribute Summary

Attributes inherited from Seahorse::Client::Base

#config, #handlers

API Operations collapse

Instance Method Summary collapse

Methods included from ClientStubs

#api_requests, #stub_data, #stub_responses

Methods inherited from Seahorse::Client::Base

add_plugin, api, clear_plugins, define, new, #operation_names, plugins, remove_plugin, set_api, set_plugins

Methods included from Seahorse::Client::HandlerBuilder

#handle, #handle_request, #handle_response

Constructor Details

#initialize(options) ⇒ Client

Returns a new instance of Client.

Parameters:

  • options (Hash)

Options Hash (options):

  • :plugins (Array<Seahorse::Client::Plugin>) — default: []]

    A list of plugins to apply to the client. Each plugin is either a class name or an instance of a plugin class.

  • :credentials (required, Aws::CredentialProvider)

    Your AWS credentials. This can be an instance of any one of the following classes:

    • Aws::Credentials - Used for configuring static, non-refreshing credentials.

    • Aws::SharedCredentials - Used for loading static credentials from a shared file, such as ~/.aws/config.

    • Aws::AssumeRoleCredentials - Used when you need to assume a role.

    • Aws::AssumeRoleWebIdentityCredentials - Used when you need to assume a role after providing credentials via the web.

    • Aws::SSOCredentials - Used for loading credentials from AWS SSO using an access token generated from aws login.

    • Aws::ProcessCredentials - Used for loading credentials from a process that outputs to stdout.

    • Aws::InstanceProfileCredentials - Used for loading credentials from an EC2 IMDS on an EC2 instance.

    • Aws::ECSCredentials - Used for loading credentials from instances running in ECS.

    • Aws::CognitoIdentityCredentials - Used for loading credentials from the Cognito Identity service.

    When :credentials are not configured directly, the following locations will be searched for credentials:

    • Aws.config[:credentials]
    • The :access_key_id, :secret_access_key, :session_token, and :account_id options.
    • ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY'], ENV['AWS_SESSION_TOKEN'], and ENV['AWS_ACCOUNT_ID']
    • ~/.aws/credentials
    • ~/.aws/config
    • EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive. Construct and pass an instance of Aws::InstanceProfileCredentials or Aws::ECSCredentials to enable retries and extended timeouts. Instance profile credential fetching can be disabled by setting ENV['AWS_EC2_METADATA_DISABLED'] to true.
  • :region (required, String)

    The AWS region to connect to. The configured :region is used to determine the service :endpoint. When not passed, a default :region is searched for in the following locations:

    • Aws.config[:region]
    • ENV['AWS_REGION']
    • ENV['AMAZON_REGION']
    • ENV['AWS_DEFAULT_REGION']
    • ~/.aws/credentials
    • ~/.aws/config
  • :access_key_id (String)
  • :account_id (String)
  • :active_endpoint_cache (Boolean) — default: false

    When set to true, a thread polling for endpoints will be running in the background every 60 secs (default). Defaults to false.

  • :adaptive_retry_wait_to_fill (Boolean) — default: true

    Used only in adaptive retry mode. When true, the request will sleep until there is sufficent client side capacity to retry the request. When false, the request will raise a RetryCapacityNotAvailableError and will not retry instead of sleeping.

  • :client_side_monitoring (Boolean) — default: false

    When true, client-side metrics will be collected for all API requests from this client.

  • :client_side_monitoring_client_id (String) — default: ""

    Allows you to provide an identifier for this client which will be attached to all generated client side metrics. Defaults to an empty string.

  • :client_side_monitoring_host (String) — default: "127.0.0.1"

    Allows you to specify the DNS hostname or IPv4 or IPv6 address that the client side monitoring agent is running on, where client metrics will be published via UDP.

  • :client_side_monitoring_port (Integer) — default: 31000

    Required for publishing client metrics. The port that the client side monitoring agent is running on, where client metrics will be published via UDP.

  • :client_side_monitoring_publisher (Aws::ClientSideMonitoring::Publisher) — default: Aws::ClientSideMonitoring::Publisher

    Allows you to provide a custom client-side monitoring publisher class. By default, will use the Client Side Monitoring Agent Publisher.

  • :convert_params (Boolean) — default: true

    When true, an attempt is made to coerce request parameters into the required types.

  • :correct_clock_skew (Boolean) — default: true

    Used only in standard and adaptive retry modes. Specifies whether to apply a clock skew correction and retry requests with skewed client clocks.

  • :defaults_mode (String) — default: "legacy"

    See DefaultsModeConfiguration for a list of the accepted modes and the configuration defaults that are included.

  • :disable_host_prefix_injection (Boolean) — default: false

    Set to true to disable SDK automatically adding host prefix to default service endpoint when available.

  • :disable_request_compression (Boolean) — default: false

    When set to 'true' the request body will not be compressed for supported operations.

  • :endpoint (String, URI::HTTPS, URI::HTTP)

    Normally you should not configure the :endpoint option directly. This is normally constructed from the :region option. Configuring :endpoint is normally reserved for connecting to test or custom endpoints. The endpoint should be a URI formatted like:

    'http://example.com'
    'https://example.com'
    'http://example.com:123'
    
  • :endpoint_cache_max_entries (Integer) — default: 1000

    Used for the maximum size limit of the LRU cache storing endpoints data for endpoint discovery enabled operations. Defaults to 1000.

  • :endpoint_cache_max_threads (Integer) — default: 10

    Used for the maximum threads in use for polling endpoints to be cached, defaults to 10.

  • :endpoint_cache_poll_interval (Integer) — default: 60

    When :endpoint_discovery and :active_endpoint_cache is enabled, Use this option to config the time interval in seconds for making requests fetching endpoints information. Defaults to 60 sec.

  • :endpoint_discovery (Boolean) — default: false

    When set to true, endpoint discovery will be enabled for operations when available.

  • :ignore_configured_endpoint_urls (Boolean)

    Setting to true disables use of endpoint URLs provided via environment variables and the shared configuration file.

  • :log_formatter (Aws::Log::Formatter) — default: Aws::Log::Formatter.default

    The log formatter.

  • :log_level (Symbol) — default: :info

    The log level to send messages to the :logger at.

  • :logger (Logger)

    The Logger instance to send log messages to. If this option is not set, logging will be disabled.

  • :max_attempts (Integer) — default: 3

    An integer representing the maximum number attempts that will be made for a single request, including the initial attempt. For example, setting this value to 5 will result in a request being retried up to 4 times. Used in standard and adaptive retry modes.

  • :profile (String) — default: "default"

    Used when loading credentials from the shared credentials file at HOME/.aws/credentials. When not specified, 'default' is used.

  • :request_min_compression_size_bytes (Integer) — default: 10240

    The minimum size in bytes that triggers compression for request bodies. The value must be non-negative integer value between 0 and 10485780 bytes inclusive.

  • :retry_backoff (Proc)

    A proc or lambda used for backoff. Defaults to 2**retries * retry_base_delay. This option is only used in the legacy retry mode.

  • :retry_base_delay (Float) — default: 0.3

    The base delay in seconds used by the default backoff function. This option is only used in the legacy retry mode.

  • :retry_jitter (Symbol) — default: :none

    A delay randomiser function used by the default backoff function. Some predefined functions can be referenced by name - :none, :equal, :full, otherwise a Proc that takes and returns a number. This option is only used in the legacy retry mode.

    @see https://www.awsarchitectureblog.com/2015/03/backoff.html

  • :retry_limit (Integer) — default: 3

    The maximum number of times to retry failed requests. Only ~ 500 level server errors and certain ~ 400 level client errors are retried. Generally, these are throttling errors, data checksum errors, networking errors, timeout errors, auth errors, endpoint discovery, and errors from expired credentials. This option is only used in the legacy retry mode.

  • :retry_max_delay (Integer) — default: 0

    The maximum number of seconds to delay between retries (0 for no limit) used by the default backoff function. This option is only used in the legacy retry mode.

  • :retry_mode (String) — default: "legacy"

    Specifies which retry algorithm to use. Values are:

    • legacy - The pre-existing retry behavior. This is default value if no retry mode is provided.

    • standard - A standardized set of retry rules across the AWS SDKs. This includes support for retry quotas, which limit the number of unsuccessful retries a client can make.

    • adaptive - An experimental retry mode that includes all the functionality of standard mode along with automatic client side throttling. This is a provisional mode that may change behavior in the future.

  • :sdk_ua_app_id (String)

    A unique and opaque application ID that is appended to the User-Agent header as app/sdk_ua_app_id. It should have a maximum length of 50. This variable is sourced from environment variable AWS_SDK_UA_APP_ID or the shared config profile attribute sdk_ua_app_id.

  • :secret_access_key (String)
  • :session_token (String)
  • :sigv4a_signing_region_set (Array)

    A list of regions that should be signed with SigV4a signing. When not passed, a default :sigv4a_signing_region_set is searched for in the following locations:

    • Aws.config[:sigv4a_signing_region_set]
    • ENV['AWS_SIGV4A_SIGNING_REGION_SET']
    • ~/.aws/config
  • :stub_responses (Boolean) — default: false

    Causes the client to return stubbed responses. By default fake responses are generated and returned. You can specify the response data to return or errors to raise by calling ClientStubs#stub_responses. See ClientStubs for more information.

    Please note When response stubbing is enabled, no HTTP requests are made, and retries are disabled.

  • :telemetry_provider (Aws::Telemetry::TelemetryProviderBase) — default: Aws::Telemetry::NoOpTelemetryProvider

    Allows you to provide a telemetry provider, which is used to emit telemetry data. By default, uses NoOpTelemetryProvider which will not record or emit any telemetry data. The SDK supports the following telemetry providers:

    • OpenTelemetry (OTel) - To use the OTel provider, install and require the opentelemetry-sdk gem and then, pass in an instance of a Aws::Telemetry::OTelProvider for telemetry provider.
  • :token_provider (Aws::TokenProvider)

    A Bearer Token Provider. This can be an instance of any one of the following classes:

    • Aws::StaticTokenProvider - Used for configuring static, non-refreshing tokens.

    • Aws::SSOTokenProvider - Used for loading tokens from AWS SSO using an access token generated from aws login.

    When :token_provider is not configured directly, the Aws::TokenProviderChain will be used to search for tokens configured for your profile in shared configuration files.

  • :use_dualstack_endpoint (Boolean)

    When set to true, dualstack enabled endpoints (with .aws TLD) will be used if available.

  • :use_fips_endpoint (Boolean)

    When set to true, fips compatible endpoints will be used if available. When a fips region is used, the region is normalized and this config is set to true.

  • :validate_params (Boolean) — default: true

    When true, request parameters are validated before sending the request.

  • :endpoint_provider (Aws::QConnect::EndpointProvider)

    The endpoint provider used to resolve endpoints. Any object that responds to #resolve_endpoint(parameters) where parameters is a Struct similar to Aws::QConnect::EndpointParameters.

  • :http_continue_timeout (Float) — default: 1

    The number of seconds to wait for a 100-continue response before sending the request body. This option has no effect unless the request has "Expect" header set to "100-continue". Defaults to nil which disables this behaviour. This value can safely be set per request on the session.

  • :http_idle_timeout (Float) — default: 5

    The number of seconds a connection is allowed to sit idle before it is considered stale. Stale connections are closed and removed from the pool before making a request.

  • :http_open_timeout (Float) — default: 15

    The default number of seconds to wait for response data. This value can safely be set per-request on the session.

  • :http_proxy (URI::HTTP, String)

    A proxy to send requests through. Formatted like 'http://proxy.com:123'.

  • :http_read_timeout (Float) — default: 60

    The default number of seconds to wait for response data. This value can safely be set per-request on the session.

  • :http_wire_trace (Boolean) — default: false

    When true, HTTP debug output will be sent to the :logger.

  • :on_chunk_received (Proc)

    When a Proc object is provided, it will be used as callback when each chunk of the response body is received. It provides three arguments: the chunk, the number of bytes received, and the total number of bytes in the response (or nil if the server did not send a content-length).

  • :on_chunk_sent (Proc)

    When a Proc object is provided, it will be used as callback when each chunk of the request body is sent. It provides three arguments: the chunk, the number of bytes read from the body, and the total number of bytes in the body.

  • :raise_response_errors (Boolean) — default: true

    When true, response errors are raised.

  • :ssl_ca_bundle (String)

    Full path to the SSL certificate authority bundle file that should be used when verifying peer certificates. If you do not pass :ssl_ca_bundle or :ssl_ca_directory the the system default will be used if available.

  • :ssl_ca_directory (String)

    Full path of the directory that contains the unbundled SSL certificate authority files for verifying peer certificates. If you do not pass :ssl_ca_bundle or :ssl_ca_directory the the system default will be used if available.

  • :ssl_ca_store (String)

    Sets the X509::Store to verify peer certificate.

  • :ssl_cert (OpenSSL::X509::Certificate)

    Sets a client certificate when creating http connections.

  • :ssl_key (OpenSSL::PKey)

    Sets a client key when creating http connections.

  • :ssl_timeout (Float)

    Sets the SSL timeout in seconds

  • :ssl_verify_peer (Boolean) — default: true

    When true, SSL peer certificates are verified when establishing a connection.



444
445
446
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 444

def initialize(*args)
  super
end

Instance Method Details

#activate_message_template(params = {}) ⇒ Types::ActivateMessageTemplateResponse

Activates a specific version of the Amazon Q in Connect message template. After the version is activated, the previous active version will be deactivated automatically. You can use the $ACTIVE_VERSION qualifier later to reference the version that is in active status.

Examples:

Request syntax with placeholder values


resp = client.activate_message_template({
  knowledge_base_id: "UuidOrArn", # required
  message_template_id: "UuidOrArnOrEitherWithQualifier", # required
  version_number: 1, # required
})

Response structure


resp.message_template_arn #=> String
resp.message_template_id #=> String
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :message_template_id (required, String)

    The identifier of the message template. Can be either the ID or the ARN. It cannot contain any qualifier.

  • :version_number (required, Integer)

    The version number of the message template version to activate.

Returns:

See Also:



490
491
492
493
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 490

def activate_message_template(params = {}, options = {})
  req = build_request(:activate_message_template, params)
  req.send_request(options)
end

#create_ai_agent(params = {}) ⇒ Types::CreateAIAgentResponse

Creates an Amazon Q in Connect AI Agent.

Examples:

Request syntax with placeholder values


resp = client.create_ai_agent({
  assistant_id: "UuidOrArn", # required
  client_token: "ClientToken",
  configuration: { # required
    answer_recommendation_ai_agent_configuration: {
      answer_generation_ai_guardrail_id: "UuidWithQualifier",
      answer_generation_ai_prompt_id: "UuidWithQualifier",
      association_configurations: [
        {
          association_configuration_data: {
            knowledge_base_association_configuration_data: {
              content_tag_filter: {
                and_conditions: [
                  {
                    key: "TagKey", # required
                    value: "TagValue",
                  },
                ],
                or_conditions: [
                  {
                    and_conditions: [
                      {
                        key: "TagKey", # required
                        value: "TagValue",
                      },
                    ],
                    tag_condition: {
                      key: "TagKey", # required
                      value: "TagValue",
                    },
                  },
                ],
                tag_condition: {
                  key: "TagKey", # required
                  value: "TagValue",
                },
              },
              max_results: 1,
              override_knowledge_base_search_type: "HYBRID", # accepts HYBRID, SEMANTIC
            },
          },
          association_id: "Uuid",
          association_type: "KNOWLEDGE_BASE", # accepts KNOWLEDGE_BASE
        },
      ],
      intent_labeling_generation_ai_prompt_id: "UuidWithQualifier",
      query_reformulation_ai_prompt_id: "UuidWithQualifier",
    },
    manual_search_ai_agent_configuration: {
      answer_generation_ai_guardrail_id: "UuidWithQualifier",
      answer_generation_ai_prompt_id: "UuidWithQualifier",
      association_configurations: [
        {
          association_configuration_data: {
            knowledge_base_association_configuration_data: {
              content_tag_filter: {
                and_conditions: [
                  {
                    key: "TagKey", # required
                    value: "TagValue",
                  },
                ],
                or_conditions: [
                  {
                    and_conditions: [
                      {
                        key: "TagKey", # required
                        value: "TagValue",
                      },
                    ],
                    tag_condition: {
                      key: "TagKey", # required
                      value: "TagValue",
                    },
                  },
                ],
                tag_condition: {
                  key: "TagKey", # required
                  value: "TagValue",
                },
              },
              max_results: 1,
              override_knowledge_base_search_type: "HYBRID", # accepts HYBRID, SEMANTIC
            },
          },
          association_id: "Uuid",
          association_type: "KNOWLEDGE_BASE", # accepts KNOWLEDGE_BASE
        },
      ],
    },
    self_service_ai_agent_configuration: {
      association_configurations: [
        {
          association_configuration_data: {
            knowledge_base_association_configuration_data: {
              content_tag_filter: {
                and_conditions: [
                  {
                    key: "TagKey", # required
                    value: "TagValue",
                  },
                ],
                or_conditions: [
                  {
                    and_conditions: [
                      {
                        key: "TagKey", # required
                        value: "TagValue",
                      },
                    ],
                    tag_condition: {
                      key: "TagKey", # required
                      value: "TagValue",
                    },
                  },
                ],
                tag_condition: {
                  key: "TagKey", # required
                  value: "TagValue",
                },
              },
              max_results: 1,
              override_knowledge_base_search_type: "HYBRID", # accepts HYBRID, SEMANTIC
            },
          },
          association_id: "Uuid",
          association_type: "KNOWLEDGE_BASE", # accepts KNOWLEDGE_BASE
        },
      ],
      self_service_ai_guardrail_id: "UuidWithQualifier",
      self_service_answer_generation_ai_prompt_id: "UuidWithQualifier",
      self_service_pre_processing_ai_prompt_id: "UuidWithQualifier",
    },
  },
  description: "Description",
  name: "Name", # required
  tags: {
    "TagKey" => "TagValue",
  },
  type: "MANUAL_SEARCH", # required, accepts MANUAL_SEARCH, ANSWER_RECOMMENDATION, SELF_SERVICE
  visibility_status: "SAVED", # required, accepts SAVED, PUBLISHED
})

Response structure


resp.ai_agent.ai_agent_arn #=> String
resp.ai_agent.ai_agent_id #=> String
resp.ai_agent.assistant_arn #=> String
resp.ai_agent.assistant_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.answer_generation_ai_guardrail_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.intent_labeling_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.query_reformulation_ai_prompt_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.answer_generation_ai_guardrail_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_ai_guardrail_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_pre_processing_ai_prompt_id #=> String
resp.ai_agent.description #=> String
resp.ai_agent.modified_time #=> Time
resp.ai_agent.name #=> String
resp.ai_agent.origin #=> String, one of "SYSTEM", "CUSTOMER"
resp.ai_agent.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_agent.tags #=> Hash
resp.ai_agent.tags["TagKey"] #=> String
resp.ai_agent.type #=> String, one of "MANUAL_SEARCH", "ANSWER_RECOMMENDATION", "SELF_SERVICE"
resp.ai_agent.visibility_status #=> String, one of "SAVED", "PUBLISHED"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs..

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :configuration (required, Types::AIAgentConfiguration)

    The configuration of the AI Agent.

  • :description (String)

    The description of the AI Agent.

  • :name (required, String)

    The name of the AI Agent.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

  • :type (required, String)

    The type of the AI Agent.

  • :visibility_status (required, String)

    The visibility status of the AI Agent.

Returns:

See Also:



758
759
760
761
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 758

def create_ai_agent(params = {}, options = {})
  req = build_request(:create_ai_agent, params)
  req.send_request(options)
end

#create_ai_agent_version(params = {}) ⇒ Types::CreateAIAgentVersionResponse

Creates and Amazon Q in Connect AI Agent version.

Examples:

Request syntax with placeholder values


resp = client.create_ai_agent_version({
  ai_agent_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
  client_token: "ClientToken",
  modified_time: Time.now,
})

Response structure


resp.ai_agent.ai_agent_arn #=> String
resp.ai_agent.ai_agent_id #=> String
resp.ai_agent.assistant_arn #=> String
resp.ai_agent.assistant_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.answer_generation_ai_guardrail_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.intent_labeling_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.query_reformulation_ai_prompt_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.answer_generation_ai_guardrail_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_ai_guardrail_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_pre_processing_ai_prompt_id #=> String
resp.ai_agent.description #=> String
resp.ai_agent.modified_time #=> Time
resp.ai_agent.name #=> String
resp.ai_agent.origin #=> String, one of "SYSTEM", "CUSTOMER"
resp.ai_agent.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_agent.tags #=> Hash
resp.ai_agent.tags["TagKey"] #=> String
resp.ai_agent.type #=> String, one of "MANUAL_SEARCH", "ANSWER_RECOMMENDATION", "SELF_SERVICE"
resp.ai_agent.visibility_status #=> String, one of "SAVED", "PUBLISHED"
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_agent_id (required, String)

    The identifier of the Amazon Q in Connect AI Agent.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs..

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :modified_time (Time, DateTime, Date, Integer, String)

    The modification time of the AI Agent should be tracked for version creation. This field should be specified to avoid version creation when simultaneous update to the underlying AI Agent are possible. The value should be the modifiedTime returned from the request to create or update an AI Agent so that version creation can fail if an update to the AI Agent post the specified modification time has been made.

Returns:

See Also:



885
886
887
888
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 885

def create_ai_agent_version(params = {}, options = {})
  req = build_request(:create_ai_agent_version, params)
  req.send_request(options)
end

#create_ai_guardrail(params = {}) ⇒ Types::CreateAIGuardrailResponse

Creates an Amazon Q in Connect AI Guardrail.

Examples:

Request syntax with placeholder values


resp = client.create_ai_guardrail({
  assistant_id: "UuidOrArn", # required
  blocked_input_messaging: "AIGuardrailBlockedMessaging", # required
  blocked_outputs_messaging: "AIGuardrailBlockedMessaging", # required
  client_token: "ClientToken",
  content_policy_config: {
    filters_config: [ # required
      {
        input_strength: "NONE", # required, accepts NONE, LOW, MEDIUM, HIGH
        output_strength: "NONE", # required, accepts NONE, LOW, MEDIUM, HIGH
        type: "SEXUAL", # required, accepts SEXUAL, VIOLENCE, HATE, INSULTS, MISCONDUCT, PROMPT_ATTACK
      },
    ],
  },
  contextual_grounding_policy_config: {
    filters_config: [ # required
      {
        threshold: 1.0, # required
        type: "GROUNDING", # required, accepts GROUNDING, RELEVANCE
      },
    ],
  },
  description: "AIGuardrailDescription",
  name: "Name", # required
  sensitive_information_policy_config: {
    pii_entities_config: [
      {
        action: "BLOCK", # required, accepts BLOCK, ANONYMIZE
        type: "ADDRESS", # required, accepts ADDRESS, AGE, AWS_ACCESS_KEY, AWS_SECRET_KEY, CA_HEALTH_NUMBER, CA_SOCIAL_INSURANCE_NUMBER, CREDIT_DEBIT_CARD_CVV, CREDIT_DEBIT_CARD_EXPIRY, CREDIT_DEBIT_CARD_NUMBER, DRIVER_ID, EMAIL, INTERNATIONAL_BANK_ACCOUNT_NUMBER, IP_ADDRESS, LICENSE_PLATE, MAC_ADDRESS, NAME, PASSWORD, PHONE, PIN, SWIFT_CODE, UK_NATIONAL_HEALTH_SERVICE_NUMBER, UK_NATIONAL_INSURANCE_NUMBER, UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER, URL, USERNAME, US_BANK_ACCOUNT_NUMBER, US_BANK_ROUTING_NUMBER, US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER, US_PASSPORT_NUMBER, US_SOCIAL_SECURITY_NUMBER, VEHICLE_IDENTIFICATION_NUMBER
      },
    ],
    regexes_config: [
      {
        action: "BLOCK", # required, accepts BLOCK, ANONYMIZE
        description: "GuardrailRegexDescription",
        name: "GuardrailRegexName", # required
        pattern: "GuardrailRegexPattern", # required
      },
    ],
  },
  tags: {
    "TagKey" => "TagValue",
  },
  topic_policy_config: {
    topics_config: [ # required
      {
        definition: "GuardrailTopicDefinition", # required
        examples: ["GuardrailTopicExample"],
        name: "GuardrailTopicName", # required
        type: "DENY", # required, accepts DENY
      },
    ],
  },
  visibility_status: "SAVED", # required, accepts SAVED, PUBLISHED
  word_policy_config: {
    managed_word_lists_config: [
      {
        type: "PROFANITY", # required, accepts PROFANITY
      },
    ],
    words_config: [
      {
        text: "GuardrailWordText", # required
      },
    ],
  },
})

Response structure


resp.ai_guardrail.ai_guardrail_arn #=> String
resp.ai_guardrail.ai_guardrail_id #=> String
resp.ai_guardrail.assistant_arn #=> String
resp.ai_guardrail.assistant_id #=> String
resp.ai_guardrail.blocked_input_messaging #=> String
resp.ai_guardrail.blocked_outputs_messaging #=> String
resp.ai_guardrail.content_policy_config.filters_config #=> Array
resp.ai_guardrail.content_policy_config.filters_config[0].input_strength #=> String, one of "NONE", "LOW", "MEDIUM", "HIGH"
resp.ai_guardrail.content_policy_config.filters_config[0].output_strength #=> String, one of "NONE", "LOW", "MEDIUM", "HIGH"
resp.ai_guardrail.content_policy_config.filters_config[0].type #=> String, one of "SEXUAL", "VIOLENCE", "HATE", "INSULTS", "MISCONDUCT", "PROMPT_ATTACK"
resp.ai_guardrail.contextual_grounding_policy_config.filters_config #=> Array
resp.ai_guardrail.contextual_grounding_policy_config.filters_config[0].threshold #=> Float
resp.ai_guardrail.contextual_grounding_policy_config.filters_config[0].type #=> String, one of "GROUNDING", "RELEVANCE"
resp.ai_guardrail.description #=> String
resp.ai_guardrail.modified_time #=> Time
resp.ai_guardrail.name #=> String
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config #=> Array
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config[0].action #=> String, one of "BLOCK", "ANONYMIZE"
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config[0].type #=> String, one of "ADDRESS", "AGE", "AWS_ACCESS_KEY", "AWS_SECRET_KEY", "CA_HEALTH_NUMBER", "CA_SOCIAL_INSURANCE_NUMBER", "CREDIT_DEBIT_CARD_CVV", "CREDIT_DEBIT_CARD_EXPIRY", "CREDIT_DEBIT_CARD_NUMBER", "DRIVER_ID", "EMAIL", "INTERNATIONAL_BANK_ACCOUNT_NUMBER", "IP_ADDRESS", "LICENSE_PLATE", "MAC_ADDRESS", "NAME", "PASSWORD", "PHONE", "PIN", "SWIFT_CODE", "UK_NATIONAL_HEALTH_SERVICE_NUMBER", "UK_NATIONAL_INSURANCE_NUMBER", "UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER", "URL", "USERNAME", "US_BANK_ACCOUNT_NUMBER", "US_BANK_ROUTING_NUMBER", "US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER", "US_PASSPORT_NUMBER", "US_SOCIAL_SECURITY_NUMBER", "VEHICLE_IDENTIFICATION_NUMBER"
resp.ai_guardrail.sensitive_information_policy_config.regexes_config #=> Array
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].action #=> String, one of "BLOCK", "ANONYMIZE"
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].description #=> String
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].name #=> String
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].pattern #=> String
resp.ai_guardrail.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_guardrail.tags #=> Hash
resp.ai_guardrail.tags["TagKey"] #=> String
resp.ai_guardrail.topic_policy_config.topics_config #=> Array
resp.ai_guardrail.topic_policy_config.topics_config[0].definition #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].examples #=> Array
resp.ai_guardrail.topic_policy_config.topics_config[0].examples[0] #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].name #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].type #=> String, one of "DENY"
resp.ai_guardrail.visibility_status #=> String, one of "SAVED", "PUBLISHED"
resp.ai_guardrail.word_policy_config.managed_word_lists_config #=> Array
resp.ai_guardrail.word_policy_config.managed_word_lists_config[0].type #=> String, one of "PROFANITY"
resp.ai_guardrail.word_policy_config.words_config #=> Array
resp.ai_guardrail.word_policy_config.words_config[0].text #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :blocked_input_messaging (required, String)

    The message to return when the AI Guardrail blocks a prompt.

  • :blocked_outputs_messaging (required, String)

    The message to return when the AI Guardrail blocks a model response.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs..

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :content_policy_config (Types::AIGuardrailContentPolicyConfig)

    The content filter policies to configure for the AI Guardrail.

  • :contextual_grounding_policy_config (Types::AIGuardrailContextualGroundingPolicyConfig)

    The contextual grounding policy configuration used to create an AI Guardrail.

  • :description (String)

    A description of the AI Guardrail.

  • :name (required, String)

    The name of the AI Guardrail.

  • :sensitive_information_policy_config (Types::AIGuardrailSensitiveInformationPolicyConfig)

    The sensitive information policy to configure for the AI Guardrail.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

  • :topic_policy_config (Types::AIGuardrailTopicPolicyConfig)

    The topic policies to configure for the AI Guardrail.

  • :visibility_status (required, String)

    The visibility status of the AI Guardrail.

  • :word_policy_config (Types::AIGuardrailWordPolicyConfig)

    The word policy you configure for the AI Guardrail.

Returns:

See Also:



1062
1063
1064
1065
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1062

def create_ai_guardrail(params = {}, options = {})
  req = build_request(:create_ai_guardrail, params)
  req.send_request(options)
end

#create_ai_guardrail_version(params = {}) ⇒ Types::CreateAIGuardrailVersionResponse

Creates an Amazon Q in Connect AI Guardrail version.

Examples:

Request syntax with placeholder values


resp = client.create_ai_guardrail_version({
  ai_guardrail_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
  client_token: "ClientToken",
  modified_time: Time.now,
})

Response structure


resp.ai_guardrail.ai_guardrail_arn #=> String
resp.ai_guardrail.ai_guardrail_id #=> String
resp.ai_guardrail.assistant_arn #=> String
resp.ai_guardrail.assistant_id #=> String
resp.ai_guardrail.blocked_input_messaging #=> String
resp.ai_guardrail.blocked_outputs_messaging #=> String
resp.ai_guardrail.content_policy_config.filters_config #=> Array
resp.ai_guardrail.content_policy_config.filters_config[0].input_strength #=> String, one of "NONE", "LOW", "MEDIUM", "HIGH"
resp.ai_guardrail.content_policy_config.filters_config[0].output_strength #=> String, one of "NONE", "LOW", "MEDIUM", "HIGH"
resp.ai_guardrail.content_policy_config.filters_config[0].type #=> String, one of "SEXUAL", "VIOLENCE", "HATE", "INSULTS", "MISCONDUCT", "PROMPT_ATTACK"
resp.ai_guardrail.contextual_grounding_policy_config.filters_config #=> Array
resp.ai_guardrail.contextual_grounding_policy_config.filters_config[0].threshold #=> Float
resp.ai_guardrail.contextual_grounding_policy_config.filters_config[0].type #=> String, one of "GROUNDING", "RELEVANCE"
resp.ai_guardrail.description #=> String
resp.ai_guardrail.modified_time #=> Time
resp.ai_guardrail.name #=> String
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config #=> Array
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config[0].action #=> String, one of "BLOCK", "ANONYMIZE"
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config[0].type #=> String, one of "ADDRESS", "AGE", "AWS_ACCESS_KEY", "AWS_SECRET_KEY", "CA_HEALTH_NUMBER", "CA_SOCIAL_INSURANCE_NUMBER", "CREDIT_DEBIT_CARD_CVV", "CREDIT_DEBIT_CARD_EXPIRY", "CREDIT_DEBIT_CARD_NUMBER", "DRIVER_ID", "EMAIL", "INTERNATIONAL_BANK_ACCOUNT_NUMBER", "IP_ADDRESS", "LICENSE_PLATE", "MAC_ADDRESS", "NAME", "PASSWORD", "PHONE", "PIN", "SWIFT_CODE", "UK_NATIONAL_HEALTH_SERVICE_NUMBER", "UK_NATIONAL_INSURANCE_NUMBER", "UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER", "URL", "USERNAME", "US_BANK_ACCOUNT_NUMBER", "US_BANK_ROUTING_NUMBER", "US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER", "US_PASSPORT_NUMBER", "US_SOCIAL_SECURITY_NUMBER", "VEHICLE_IDENTIFICATION_NUMBER"
resp.ai_guardrail.sensitive_information_policy_config.regexes_config #=> Array
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].action #=> String, one of "BLOCK", "ANONYMIZE"
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].description #=> String
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].name #=> String
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].pattern #=> String
resp.ai_guardrail.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_guardrail.tags #=> Hash
resp.ai_guardrail.tags["TagKey"] #=> String
resp.ai_guardrail.topic_policy_config.topics_config #=> Array
resp.ai_guardrail.topic_policy_config.topics_config[0].definition #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].examples #=> Array
resp.ai_guardrail.topic_policy_config.topics_config[0].examples[0] #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].name #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].type #=> String, one of "DENY"
resp.ai_guardrail.visibility_status #=> String, one of "SAVED", "PUBLISHED"
resp.ai_guardrail.word_policy_config.managed_word_lists_config #=> Array
resp.ai_guardrail.word_policy_config.managed_word_lists_config[0].type #=> String, one of "PROFANITY"
resp.ai_guardrail.word_policy_config.words_config #=> Array
resp.ai_guardrail.word_policy_config.words_config[0].text #=> String
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_guardrail_id (required, String)

    The identifier of the Amazon Q in Connect AI Guardrail.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs..

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :modified_time (Time, DateTime, Date, Integer, String)

    The time the AI Guardrail was last modified.

Returns:

See Also:



1152
1153
1154
1155
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1152

def create_ai_guardrail_version(params = {}, options = {})
  req = build_request(:create_ai_guardrail_version, params)
  req.send_request(options)
end

#create_ai_prompt(params = {}) ⇒ Types::CreateAIPromptResponse

Creates an Amazon Q in Connect AI Prompt.

Examples:

Request syntax with placeholder values


resp = client.create_ai_prompt({
  api_format: "ANTHROPIC_CLAUDE_MESSAGES", # required, accepts ANTHROPIC_CLAUDE_MESSAGES, ANTHROPIC_CLAUDE_TEXT_COMPLETIONS
  assistant_id: "UuidOrArn", # required
  client_token: "ClientToken",
  description: "Description",
  model_id: "AIPromptModelIdentifier", # required
  name: "Name", # required
  tags: {
    "TagKey" => "TagValue",
  },
  template_configuration: { # required
    text_full_ai_prompt_edit_template_configuration: {
      text: "TextAIPrompt", # required
    },
  },
  template_type: "TEXT", # required, accepts TEXT
  type: "ANSWER_GENERATION", # required, accepts ANSWER_GENERATION, INTENT_LABELING_GENERATION, QUERY_REFORMULATION, SELF_SERVICE_PRE_PROCESSING, SELF_SERVICE_ANSWER_GENERATION
  visibility_status: "SAVED", # required, accepts SAVED, PUBLISHED
})

Response structure


resp.ai_prompt.ai_prompt_arn #=> String
resp.ai_prompt.ai_prompt_id #=> String
resp.ai_prompt.api_format #=> String, one of "ANTHROPIC_CLAUDE_MESSAGES", "ANTHROPIC_CLAUDE_TEXT_COMPLETIONS"
resp.ai_prompt.assistant_arn #=> String
resp.ai_prompt.assistant_id #=> String
resp.ai_prompt.description #=> String
resp.ai_prompt.model_id #=> String
resp.ai_prompt.modified_time #=> Time
resp.ai_prompt.name #=> String
resp.ai_prompt.origin #=> String, one of "SYSTEM", "CUSTOMER"
resp.ai_prompt.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_prompt.tags #=> Hash
resp.ai_prompt.tags["TagKey"] #=> String
resp.ai_prompt.template_configuration.text_full_ai_prompt_edit_template_configuration.text #=> String
resp.ai_prompt.template_type #=> String, one of "TEXT"
resp.ai_prompt.type #=> String, one of "ANSWER_GENERATION", "INTENT_LABELING_GENERATION", "QUERY_REFORMULATION", "SELF_SERVICE_PRE_PROCESSING", "SELF_SERVICE_ANSWER_GENERATION"
resp.ai_prompt.visibility_status #=> String, one of "SAVED", "PUBLISHED"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :api_format (required, String)

    The API Format of the AI Prompt.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs..

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :description (String)

    The description of the AI Prompt.

  • :model_id (required, String)

    The identifier of the model used for this AI Prompt. Model Ids supported are: CLAUDE_3_HAIKU_20240307_V1

  • :name (required, String)

    The name of the AI Prompt.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

  • :template_configuration (required, Types::AIPromptTemplateConfiguration)

    The configuration of the prompt template for this AI Prompt.

  • :template_type (required, String)

    The type of the prompt template for this AI Prompt.

  • :type (required, String)

    The type of this AI Prompt.

  • :visibility_status (required, String)

    The visibility status of the AI Prompt.

Returns:

See Also:



1254
1255
1256
1257
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1254

def create_ai_prompt(params = {}, options = {})
  req = build_request(:create_ai_prompt, params)
  req.send_request(options)
end

#create_ai_prompt_version(params = {}) ⇒ Types::CreateAIPromptVersionResponse

Creates an Amazon Q in Connect AI Prompt version.

Examples:

Request syntax with placeholder values


resp = client.create_ai_prompt_version({
  ai_prompt_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
  client_token: "ClientToken",
  modified_time: Time.now,
})

Response structure


resp.ai_prompt.ai_prompt_arn #=> String
resp.ai_prompt.ai_prompt_id #=> String
resp.ai_prompt.api_format #=> String, one of "ANTHROPIC_CLAUDE_MESSAGES", "ANTHROPIC_CLAUDE_TEXT_COMPLETIONS"
resp.ai_prompt.assistant_arn #=> String
resp.ai_prompt.assistant_id #=> String
resp.ai_prompt.description #=> String
resp.ai_prompt.model_id #=> String
resp.ai_prompt.modified_time #=> Time
resp.ai_prompt.name #=> String
resp.ai_prompt.origin #=> String, one of "SYSTEM", "CUSTOMER"
resp.ai_prompt.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_prompt.tags #=> Hash
resp.ai_prompt.tags["TagKey"] #=> String
resp.ai_prompt.template_configuration.text_full_ai_prompt_edit_template_configuration.text #=> String
resp.ai_prompt.template_type #=> String, one of "TEXT"
resp.ai_prompt.type #=> String, one of "ANSWER_GENERATION", "INTENT_LABELING_GENERATION", "QUERY_REFORMULATION", "SELF_SERVICE_PRE_PROCESSING", "SELF_SERVICE_ANSWER_GENERATION"
resp.ai_prompt.visibility_status #=> String, one of "SAVED", "PUBLISHED"
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_prompt_id (required, String)

    The identifier of the Amazon Q in Connect AI prompt.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs..

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :modified_time (Time, DateTime, Date, Integer, String)

    The time the AI Prompt was last modified.

Returns:

See Also:



1323
1324
1325
1326
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1323

def create_ai_prompt_version(params = {}, options = {})
  req = build_request(:create_ai_prompt_version, params)
  req.send_request(options)
end

#create_assistant(params = {}) ⇒ Types::CreateAssistantResponse

Creates an Amazon Q in Connect assistant.

Examples:

Request syntax with placeholder values


resp = client.create_assistant({
  client_token: "ClientToken",
  description: "Description",
  name: "Name", # required
  server_side_encryption_configuration: {
    kms_key_id: "NonEmptyString",
  },
  tags: {
    "TagKey" => "TagValue",
  },
  type: "AGENT", # required, accepts AGENT
})

Response structure


resp.assistant.ai_agent_configuration #=> Hash
resp.assistant.ai_agent_configuration["AIAgentType"].ai_agent_id #=> String
resp.assistant.assistant_arn #=> String
resp.assistant.assistant_id #=> String
resp.assistant.capability_configuration.type #=> String, one of "V1", "V2"
resp.assistant.description #=> String
resp.assistant.integration_configuration.topic_integration_arn #=> String
resp.assistant.name #=> String
resp.assistant.server_side_encryption_configuration.kms_key_id #=> String
resp.assistant.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.assistant.tags #=> Hash
resp.assistant.tags["TagKey"] #=> String
resp.assistant.type #=> String, one of "AGENT"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :description (String)

    The description of the assistant.

  • :name (required, String)

    The name of the assistant.

  • :server_side_encryption_configuration (Types::ServerSideEncryptionConfiguration)

    The configuration information for the customer managed key used for encryption.

    The customer managed key must have a policy that allows kms:CreateGrant, kms:DescribeKey, kms:Decrypt, and kms:GenerateDataKey* permissions to the IAM identity using the key to invoke Amazon Q in Connect. To use Amazon Q in Connect with chat, the key policy must also allow kms:Decrypt, kms:GenerateDataKey*, and kms:DescribeKey permissions to the connect.amazonaws.com service principal.

    For more information about setting up a customer managed key for Amazon Q in Connect, see Enable Amazon Q in Connect for your instance.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

  • :type (required, String)

    The type of assistant.

Returns:

See Also:



1414
1415
1416
1417
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1414

def create_assistant(params = {}, options = {})
  req = build_request(:create_assistant, params)
  req.send_request(options)
end

#create_assistant_association(params = {}) ⇒ Types::CreateAssistantAssociationResponse

Creates an association between an Amazon Q in Connect assistant and another resource. Currently, the only supported association is with a knowledge base. An assistant can have only a single association.

Examples:

Request syntax with placeholder values


resp = client.create_assistant_association({
  assistant_id: "UuidOrArn", # required
  association: { # required
    knowledge_base_id: "Uuid",
  },
  association_type: "KNOWLEDGE_BASE", # required, accepts KNOWLEDGE_BASE
  client_token: "ClientToken",
  tags: {
    "TagKey" => "TagValue",
  },
})

Response structure


resp.assistant_association.assistant_arn #=> String
resp.assistant_association.assistant_association_arn #=> String
resp.assistant_association.assistant_association_id #=> String
resp.assistant_association.assistant_id #=> String
resp.assistant_association.association_data.knowledge_base_association.knowledge_base_arn #=> String
resp.assistant_association.association_data.knowledge_base_association.knowledge_base_id #=> String
resp.assistant_association.association_type #=> String, one of "KNOWLEDGE_BASE"
resp.assistant_association.tags #=> Hash
resp.assistant_association.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :association (required, Types::AssistantAssociationInputData)

    The identifier of the associated resource.

  • :association_type (required, String)

    The type of association.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

Returns:

See Also:



1483
1484
1485
1486
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1483

def create_assistant_association(params = {}, options = {})
  req = build_request(:create_assistant_association, params)
  req.send_request(options)
end

#create_content(params = {}) ⇒ Types::CreateContentResponse

Creates Amazon Q in Connect content. Before to calling this API, use StartContentUpload to upload an asset.

Examples:

Request syntax with placeholder values


resp = client.create_content({
  client_token: "NonEmptyString",
  knowledge_base_id: "UuidOrArn", # required
  metadata: {
    "NonEmptyString" => "NonEmptyString",
  },
  name: "Name", # required
  override_link_out_uri: "Uri",
  tags: {
    "TagKey" => "TagValue",
  },
  title: "ContentTitle",
  upload_id: "UploadId", # required
})

Response structure


resp.content.content_arn #=> String
resp.content.content_id #=> String
resp.content.content_type #=> String
resp.content.knowledge_base_arn #=> String
resp.content.knowledge_base_id #=> String
resp.content.link_out_uri #=> String
resp.content. #=> Hash
resp.content.["NonEmptyString"] #=> String
resp.content.name #=> String
resp.content.revision_id #=> String
resp.content.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED", "UPDATE_FAILED"
resp.content.tags #=> Hash
resp.content.tags["TagKey"] #=> String
resp.content.title #=> String
resp.content.url #=> String
resp.content.url_expiry #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. This should not be a QUICK_RESPONSES type knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :metadata (Hash<String,String>)

    A key/value map to store attributes without affecting tagging or recommendations. For example, when synchronizing data between an external system and Amazon Q in Connect, you can store an external version identifier as metadata to utilize for determining drift.

  • :name (required, String)

    The name of the content. Each piece of content in a knowledge base must have a unique name. You can retrieve a piece of content using only its knowledge base and its name with the SearchContent API.

  • :override_link_out_uri (String)

    The URI you want to use for the article. If the knowledge base has a templateUri, setting this argument overrides it for this piece of content.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

  • :title (String)

    The title of the content. If not set, the title is equal to the name.

  • :upload_id (required, String)

    A pointer to the uploaded asset. This value is returned by StartContentUpload.

Returns:

See Also:



1591
1592
1593
1594
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1591

def create_content(params = {}, options = {})
  req = build_request(:create_content, params)
  req.send_request(options)
end

#create_content_association(params = {}) ⇒ Types::CreateContentAssociationResponse

Creates an association between a content resource in a knowledge base and step-by-step guides. Step-by-step guides offer instructions to agents for resolving common customer issues. You create a content association to integrate Amazon Q in Connect and step-by-step guides.

After you integrate Amazon Q and step-by-step guides, when Amazon Q provides a recommendation to an agent based on the intent that it's detected, it also provides them with the option to start the step-by-step guide that you have associated with the content.

Note the following limitations:

  • You can create only one content association for each content resource in a knowledge base.

  • You can associate a step-by-step guide with multiple content resources.

For more information, see Integrate Amazon Q in Connect with step-by-step guides in the Amazon Connect Administrator Guide.

Examples:

Request syntax with placeholder values


resp = client.create_content_association({
  association: { # required
    amazon_connect_guide_association: {
      flow_id: "GenericArn",
    },
  },
  association_type: "AMAZON_CONNECT_GUIDE", # required, accepts AMAZON_CONNECT_GUIDE
  client_token: "ClientToken",
  content_id: "UuidOrArn", # required
  knowledge_base_id: "UuidOrArn", # required
  tags: {
    "TagKey" => "TagValue",
  },
})

Response structure


resp.content_association.association_data.amazon_connect_guide_association.flow_id #=> String
resp.content_association.association_type #=> String, one of "AMAZON_CONNECT_GUIDE"
resp.content_association.content_arn #=> String
resp.content_association.content_association_arn #=> String
resp.content_association.content_association_id #=> String
resp.content_association.content_id #=> String
resp.content_association.knowledge_base_arn #=> String
resp.content_association.knowledge_base_id #=> String
resp.content_association.tags #=> Hash
resp.content_association.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :association (required, Types::ContentAssociationContents)

    The identifier of the associated resource.

  • :association_type (required, String)

    The type of association.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :content_id (required, String)

    The identifier of the content.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

Returns:

See Also:



1688
1689
1690
1691
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1688

def create_content_association(params = {}, options = {})
  req = build_request(:create_content_association, params)
  req.send_request(options)
end

#create_knowledge_base(params = {}) ⇒ Types::CreateKnowledgeBaseResponse

Creates a knowledge base.

When using this API, you cannot reuse Amazon AppIntegrations DataIntegrations with external knowledge bases such as Salesforce and ServiceNow. If you do, you'll get an InvalidRequestException error.

For example, you're programmatically managing your external knowledge base, and you want to add or remove one of the fields that is being ingested from Salesforce. Do the following:

  1. Call DeleteKnowledgeBase.

  2. Call DeleteDataIntegration.

  3. Call CreateDataIntegration to recreate the DataIntegration or a create different one.

  4. Call CreateKnowledgeBase.

Examples:

Request syntax with placeholder values


resp = client.create_knowledge_base({
  client_token: "NonEmptyString",
  description: "Description",
  knowledge_base_type: "EXTERNAL", # required, accepts EXTERNAL, CUSTOM, QUICK_RESPONSES, MESSAGE_TEMPLATES, MANAGED
  name: "Name", # required
  rendering_configuration: {
    template_uri: "Uri",
  },
  server_side_encryption_configuration: {
    kms_key_id: "NonEmptyString",
  },
  source_configuration: {
    app_integrations: {
      app_integration_arn: "GenericArn", # required
      object_fields: ["NonEmptyString"],
    },
    managed_source_configuration: {
      web_crawler_configuration: {
        crawler_limits: {
          rate_limit: 1,
        },
        exclusion_filters: ["UrlFilterPattern"],
        inclusion_filters: ["UrlFilterPattern"],
        scope: "HOST_ONLY", # accepts HOST_ONLY, SUBDOMAINS
        url_configuration: { # required
          seed_urls: [
            {
              url: "WebUrl",
            },
          ],
        },
      },
    },
  },
  tags: {
    "TagKey" => "TagValue",
  },
  vector_ingestion_configuration: {
    chunking_configuration: {
      chunking_strategy: "FIXED_SIZE", # required, accepts FIXED_SIZE, NONE, HIERARCHICAL, SEMANTIC
      fixed_size_chunking_configuration: {
        max_tokens: 1, # required
        overlap_percentage: 1, # required
      },
      hierarchical_chunking_configuration: {
        level_configurations: [ # required
          {
            max_tokens: 1, # required
          },
        ],
        overlap_tokens: 1, # required
      },
      semantic_chunking_configuration: {
        breakpoint_percentile_threshold: 1, # required
        buffer_size: 1, # required
        max_tokens: 1, # required
      },
    },
    parsing_configuration: {
      bedrock_foundation_model_configuration: {
        model_arn: "BedrockModelArnForParsing", # required
        parsing_prompt: {
          parsing_prompt_text: "ParsingPromptText", # required
        },
      },
      parsing_strategy: "BEDROCK_FOUNDATION_MODEL", # required, accepts BEDROCK_FOUNDATION_MODEL
    },
  },
})

Response structure


resp.knowledge_base.description #=> String
resp.knowledge_base.ingestion_failure_reasons #=> Array
resp.knowledge_base.ingestion_failure_reasons[0] #=> String
resp.knowledge_base.ingestion_status #=> String, one of "SYNC_FAILED", "SYNCING_IN_PROGRESS", "SYNC_SUCCESS", "CREATE_IN_PROGRESS"
resp.knowledge_base.knowledge_base_arn #=> String
resp.knowledge_base.knowledge_base_id #=> String
resp.knowledge_base.knowledge_base_type #=> String, one of "EXTERNAL", "CUSTOM", "QUICK_RESPONSES", "MESSAGE_TEMPLATES", "MANAGED"
resp.knowledge_base.last_content_modification_time #=> Time
resp.knowledge_base.name #=> String
resp.knowledge_base.rendering_configuration.template_uri #=> String
resp.knowledge_base.server_side_encryption_configuration.kms_key_id #=> String
resp.knowledge_base.source_configuration.app_integrations.app_integration_arn #=> String
resp.knowledge_base.source_configuration.app_integrations.object_fields #=> Array
resp.knowledge_base.source_configuration.app_integrations.object_fields[0] #=> String
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.crawler_limits.rate_limit #=> Integer
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.exclusion_filters #=> Array
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.exclusion_filters[0] #=> String
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.inclusion_filters #=> Array
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.inclusion_filters[0] #=> String
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.scope #=> String, one of "HOST_ONLY", "SUBDOMAINS"
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.url_configuration.seed_urls #=> Array
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.url_configuration.seed_urls[0].url #=> String
resp.knowledge_base.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.knowledge_base.tags #=> Hash
resp.knowledge_base.tags["TagKey"] #=> String
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.chunking_strategy #=> String, one of "FIXED_SIZE", "NONE", "HIERARCHICAL", "SEMANTIC"
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.max_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.overlap_percentage #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.hierarchical_chunking_configuration.level_configurations #=> Array
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.hierarchical_chunking_configuration.level_configurations[0].max_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.hierarchical_chunking_configuration.overlap_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.semantic_chunking_configuration.breakpoint_percentile_threshold #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.semantic_chunking_configuration.buffer_size #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.semantic_chunking_configuration.max_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.parsing_configuration.bedrock_foundation_model_configuration.model_arn #=> String
resp.knowledge_base.vector_ingestion_configuration.parsing_configuration.bedrock_foundation_model_configuration.parsing_prompt.parsing_prompt_text #=> String
resp.knowledge_base.vector_ingestion_configuration.parsing_configuration.parsing_strategy #=> String, one of "BEDROCK_FOUNDATION_MODEL"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :description (String)

    The description.

  • :knowledge_base_type (required, String)

    The type of knowledge base. Only CUSTOM knowledge bases allow you to upload your own content. EXTERNAL knowledge bases support integrations with third-party systems whose content is synchronized automatically.

  • :name (required, String)

    The name of the knowledge base.

  • :rendering_configuration (Types::RenderingConfiguration)

    Information about how to render the content.

  • :server_side_encryption_configuration (Types::ServerSideEncryptionConfiguration)

    The configuration information for the customer managed key used for encryption.

    This KMS key must have a policy that allows kms:CreateGrant, kms:DescribeKey, kms:Decrypt, and kms:GenerateDataKey* permissions to the IAM identity using the key to invoke Amazon Q in Connect.

    For more information about setting up a customer managed key for Amazon Q in Connect, see Enable Amazon Q in Connect for your instance.

  • :source_configuration (Types::SourceConfiguration)

    The source of the knowledge base content. Only set this argument for EXTERNAL or Managed knowledge bases.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

  • :vector_ingestion_configuration (Types::VectorIngestionConfiguration)

    Contains details about how to ingest the documents in a data source.

Returns:

See Also:



1895
1896
1897
1898
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 1895

def create_knowledge_base(params = {}, options = {})
  req = build_request(:create_knowledge_base, params)
  req.send_request(options)
end

#create_message_template(params = {}) ⇒ Types::CreateMessageTemplateResponse

Creates an Amazon Q in Connect message template. The name of the message template has to be unique for each knowledge base. The channel subtype of the message template is immutable and cannot be modified after creation. After the message template is created, you can use the $LATEST qualifier to reference the created message template.

Examples:

Request syntax with placeholder values


resp = client.create_message_template({
  channel_subtype: "EMAIL", # required, accepts EMAIL, SMS
  client_token: "ClientToken",
  content: { # required
    email: {
      body: {
        html: {
          content: "NonEmptyUnlimitedString",
        },
        plain_text: {
          content: "NonEmptyUnlimitedString",
        },
      },
      headers: [
        {
          name: "EmailHeaderKey",
          value: "EmailHeaderValue",
        },
      ],
      subject: "NonEmptyUnlimitedString",
    },
    sms: {
      body: {
        plain_text: {
          content: "NonEmptyUnlimitedString",
        },
      },
    },
  },
  default_attributes: {
    agent_attributes: {
      first_name: "MessageTemplateAttributeValue",
      last_name: "MessageTemplateAttributeValue",
    },
    custom_attributes: {
      "MessageTemplateAttributeKey" => "MessageTemplateAttributeValue",
    },
    customer_profile_attributes: {
      account_number: "MessageTemplateAttributeValue",
      additional_information: "MessageTemplateAttributeValue",
      address1: "MessageTemplateAttributeValue",
      address2: "MessageTemplateAttributeValue",
      address3: "MessageTemplateAttributeValue",
      address4: "MessageTemplateAttributeValue",
      billing_address_1: "MessageTemplateAttributeValue",
      billing_address_2: "MessageTemplateAttributeValue",
      billing_address_3: "MessageTemplateAttributeValue",
      billing_address_4: "MessageTemplateAttributeValue",
      billing_city: "MessageTemplateAttributeValue",
      billing_country: "MessageTemplateAttributeValue",
      billing_county: "MessageTemplateAttributeValue",
      billing_postal_code: "MessageTemplateAttributeValue",
      billing_province: "MessageTemplateAttributeValue",
      billing_state: "MessageTemplateAttributeValue",
      birth_date: "MessageTemplateAttributeValue",
      business_email_address: "MessageTemplateAttributeValue",
      business_name: "MessageTemplateAttributeValue",
      business_phone_number: "MessageTemplateAttributeValue",
      city: "MessageTemplateAttributeValue",
      country: "MessageTemplateAttributeValue",
      county: "MessageTemplateAttributeValue",
      custom: {
        "MessageTemplateAttributeKey" => "MessageTemplateAttributeValue",
      },
      email_address: "MessageTemplateAttributeValue",
      first_name: "MessageTemplateAttributeValue",
      gender: "MessageTemplateAttributeValue",
      home_phone_number: "MessageTemplateAttributeValue",
      last_name: "MessageTemplateAttributeValue",
      mailing_address_1: "MessageTemplateAttributeValue",
      mailing_address_2: "MessageTemplateAttributeValue",
      mailing_address_3: "MessageTemplateAttributeValue",
      mailing_address_4: "MessageTemplateAttributeValue",
      mailing_city: "MessageTemplateAttributeValue",
      mailing_country: "MessageTemplateAttributeValue",
      mailing_county: "MessageTemplateAttributeValue",
      mailing_postal_code: "MessageTemplateAttributeValue",
      mailing_province: "MessageTemplateAttributeValue",
      mailing_state: "MessageTemplateAttributeValue",
      middle_name: "MessageTemplateAttributeValue",
      mobile_phone_number: "MessageTemplateAttributeValue",
      party_type: "MessageTemplateAttributeValue",
      phone_number: "MessageTemplateAttributeValue",
      postal_code: "MessageTemplateAttributeValue",
      profile_arn: "MessageTemplateAttributeValue",
      profile_id: "MessageTemplateAttributeValue",
      province: "MessageTemplateAttributeValue",
      shipping_address_1: "MessageTemplateAttributeValue",
      shipping_address_2: "MessageTemplateAttributeValue",
      shipping_address_3: "MessageTemplateAttributeValue",
      shipping_address_4: "MessageTemplateAttributeValue",
      shipping_city: "MessageTemplateAttributeValue",
      shipping_country: "MessageTemplateAttributeValue",
      shipping_county: "MessageTemplateAttributeValue",
      shipping_postal_code: "MessageTemplateAttributeValue",
      shipping_province: "MessageTemplateAttributeValue",
      shipping_state: "MessageTemplateAttributeValue",
      state: "MessageTemplateAttributeValue",
    },
    system_attributes: {
      customer_endpoint: {
        address: "MessageTemplateAttributeValue",
      },
      name: "MessageTemplateAttributeValue",
      system_endpoint: {
        address: "MessageTemplateAttributeValue",
      },
    },
  },
  description: "Description",
  grouping_configuration: {
    criteria: "GroupingCriteria",
    values: ["GroupingValue"],
  },
  knowledge_base_id: "UuidOrArn", # required
  language: "LanguageCode",
  name: "Name", # required
  tags: {
    "TagKey" => "TagValue",
  },
})

Response structure


resp.message_template.attribute_types #=> Array
resp.message_template.attribute_types[0] #=> String, one of "SYSTEM", "AGENT", "CUSTOMER_PROFILE", "CUSTOM"
resp.message_template.channel_subtype #=> String, one of "EMAIL", "SMS"
resp.message_template.content.email.body.html.content #=> String
resp.message_template.content.email.body.plain_text.content #=> String
resp.message_template.content.email.headers #=> Array
resp.message_template.content.email.headers[0].name #=> String
resp.message_template.content.email.headers[0].value #=> String
resp.message_template.content.email.subject #=> String
resp.message_template.content.sms.body.plain_text.content #=> String
resp.message_template.created_time #=> Time
resp.message_template.default_attributes.agent_attributes.first_name #=> String
resp.message_template.default_attributes.agent_attributes.last_name #=> String
resp.message_template.default_attributes.custom_attributes #=> Hash
resp.message_template.default_attributes.custom_attributes["MessageTemplateAttributeKey"] #=> String
resp.message_template.default_attributes.customer_profile_attributes. #=> String
resp.message_template.default_attributes.customer_profile_attributes.additional_information #=> String
resp.message_template.default_attributes.customer_profile_attributes.address1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.birth_date #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_email_address #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.city #=> String
resp.message_template.default_attributes.customer_profile_attributes.country #=> String
resp.message_template.default_attributes.customer_profile_attributes.county #=> String
resp.message_template.default_attributes.customer_profile_attributes.custom #=> Hash
resp.message_template.default_attributes.customer_profile_attributes.custom["MessageTemplateAttributeKey"] #=> String
resp.message_template.default_attributes.customer_profile_attributes.email_address #=> String
resp.message_template.default_attributes.customer_profile_attributes.first_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.gender #=> String
resp.message_template.default_attributes.customer_profile_attributes.home_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.last_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.middle_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.mobile_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.party_type #=> String
resp.message_template.default_attributes.customer_profile_attributes.phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.profile_arn #=> String
resp.message_template.default_attributes.customer_profile_attributes.profile_id #=> String
resp.message_template.default_attributes.customer_profile_attributes.province #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.state #=> String
resp.message_template.default_attributes.system_attributes.customer_endpoint.address #=> String
resp.message_template.default_attributes.system_attributes.name #=> String
resp.message_template.default_attributes.system_attributes.system_endpoint.address #=> String
resp.message_template.description #=> String
resp.message_template.grouping_configuration.criteria #=> String
resp.message_template.grouping_configuration.values #=> Array
resp.message_template.grouping_configuration.values[0] #=> String
resp.message_template.knowledge_base_arn #=> String
resp.message_template.knowledge_base_id #=> String
resp.message_template.language #=> String
resp.message_template.last_modified_by #=> String
resp.message_template.last_modified_time #=> Time
resp.message_template.message_template_arn #=> String
resp.message_template.message_template_content_sha_256 #=> String
resp.message_template.message_template_id #=> String
resp.message_template.name #=> String
resp.message_template.tags #=> Hash
resp.message_template.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :channel_subtype (required, String)

    The channel subtype this message template applies to.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :content (required, Types::MessageTemplateContentProvider)

    The content of the message template.

  • :default_attributes (Types::MessageTemplateAttributes)

    An object that specifies the default values to use for variables in the message template. This object contains different categories of key-value pairs. Each key defines a variable or placeholder in the message template. The corresponding value defines the default value for that variable.

  • :description (String)

    The description of the message template.

  • :grouping_configuration (Types::GroupingConfiguration)

    The configuration information of the grouping of Amazon Q in Connect users.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :language (String)

    The language code value for the language in which the quick response is written. The supported language codes include de_DE, en_US, es_ES, fr_FR, id_ID, it_IT, ja_JP, ko_KR, pt_BR, zh_CN, zh_TW

  • :name (required, String)

    The name of the message template.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

Returns:

See Also:



2182
2183
2184
2185
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2182

def create_message_template(params = {}, options = {})
  req = build_request(:create_message_template, params)
  req.send_request(options)
end

#create_message_template_attachment(params = {}) ⇒ Types::CreateMessageTemplateAttachmentResponse

Uploads an attachment file to the specified Amazon Q in Connect message template. The name of the message template attachment has to be unique for each message template referenced by the $LATEST qualifier. The body of the attachment file should be encoded using base64 encoding. After the file is uploaded, you can use the pre-signed Amazon S3 URL returned in response to download the uploaded file.

Examples:

Request syntax with placeholder values


resp = client.create_message_template_attachment({
  body: "NonEmptyUnlimitedString", # required
  client_token: "ClientToken",
  content_disposition: "ATTACHMENT", # required, accepts ATTACHMENT
  knowledge_base_id: "UuidOrArn", # required
  message_template_id: "UuidOrArnOrEitherWithQualifier", # required
  name: "AttachmentFileName", # required
})

Response structure


resp.attachment.attachment_id #=> String
resp.attachment.content_disposition #=> String, one of "ATTACHMENT"
resp.attachment.name #=> String
resp.attachment.uploaded_time #=> Time
resp.attachment.url #=> String
resp.attachment.url_expiry #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :body (required, String)

    The body of the attachment file being uploaded. It should be encoded using base64 encoding.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

  • :content_disposition (required, String)

    The presentation information for the attachment file.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :message_template_id (required, String)

    The identifier of the message template. Can be either the ID or the ARN. It cannot contain any qualifier.

  • :name (required, String)

    The name of the attachment file being uploaded. The name should include the file extension.

Returns:

See Also:



2252
2253
2254
2255
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2252

def create_message_template_attachment(params = {}, options = {})
  req = build_request(:create_message_template_attachment, params)
  req.send_request(options)
end

#create_message_template_version(params = {}) ⇒ Types::CreateMessageTemplateVersionResponse

Creates a new Amazon Q in Connect message template version from the current content and configuration of a message template. Versions are immutable and monotonically increasing. Once a version is created, you can reference a specific version of the message template by passing in <message-template-id>:<versionNumber> as the message template identifier. An error is displayed if the supplied messageTemplateContentSha256 is different from the messageTemplateContentSha256 of the message template with $LATEST qualifier. If multiple CreateMessageTemplateVersion requests are made while the message template remains the same, only the first invocation creates a new version and the succeeding requests will return the same response as the first invocation.

Examples:

Request syntax with placeholder values


resp = client.create_message_template_version({
  knowledge_base_id: "UuidOrArn", # required
  message_template_content_sha_256: "MessageTemplateContentSha256",
  message_template_id: "UuidOrArnOrEitherWithQualifier", # required
})

Response structure


resp.message_template.attachments #=> Array
resp.message_template.attachments[0].attachment_id #=> String
resp.message_template.attachments[0].content_disposition #=> String, one of "ATTACHMENT"
resp.message_template.attachments[0].name #=> String
resp.message_template.attachments[0].uploaded_time #=> Time
resp.message_template.attachments[0].url #=> String
resp.message_template.attachments[0].url_expiry #=> Time
resp.message_template.attribute_types #=> Array
resp.message_template.attribute_types[0] #=> String, one of "SYSTEM", "AGENT", "CUSTOMER_PROFILE", "CUSTOM"
resp.message_template.channel_subtype #=> String, one of "EMAIL", "SMS"
resp.message_template.content.email.body.html.content #=> String
resp.message_template.content.email.body.plain_text.content #=> String
resp.message_template.content.email.headers #=> Array
resp.message_template.content.email.headers[0].name #=> String
resp.message_template.content.email.headers[0].value #=> String
resp.message_template.content.email.subject #=> String
resp.message_template.content.sms.body.plain_text.content #=> String
resp.message_template.created_time #=> Time
resp.message_template.default_attributes.agent_attributes.first_name #=> String
resp.message_template.default_attributes.agent_attributes.last_name #=> String
resp.message_template.default_attributes.custom_attributes #=> Hash
resp.message_template.default_attributes.custom_attributes["MessageTemplateAttributeKey"] #=> String
resp.message_template.default_attributes.customer_profile_attributes. #=> String
resp.message_template.default_attributes.customer_profile_attributes.additional_information #=> String
resp.message_template.default_attributes.customer_profile_attributes.address1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.birth_date #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_email_address #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.city #=> String
resp.message_template.default_attributes.customer_profile_attributes.country #=> String
resp.message_template.default_attributes.customer_profile_attributes.county #=> String
resp.message_template.default_attributes.customer_profile_attributes.custom #=> Hash
resp.message_template.default_attributes.customer_profile_attributes.custom["MessageTemplateAttributeKey"] #=> String
resp.message_template.default_attributes.customer_profile_attributes.email_address #=> String
resp.message_template.default_attributes.customer_profile_attributes.first_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.gender #=> String
resp.message_template.default_attributes.customer_profile_attributes.home_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.last_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.middle_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.mobile_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.party_type #=> String
resp.message_template.default_attributes.customer_profile_attributes.phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.profile_arn #=> String
resp.message_template.default_attributes.customer_profile_attributes.profile_id #=> String
resp.message_template.default_attributes.customer_profile_attributes.province #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.state #=> String
resp.message_template.default_attributes.system_attributes.customer_endpoint.address #=> String
resp.message_template.default_attributes.system_attributes.name #=> String
resp.message_template.default_attributes.system_attributes.system_endpoint.address #=> String
resp.message_template.description #=> String
resp.message_template.grouping_configuration.criteria #=> String
resp.message_template.grouping_configuration.values #=> Array
resp.message_template.grouping_configuration.values[0] #=> String
resp.message_template.is_active #=> Boolean
resp.message_template.knowledge_base_arn #=> String
resp.message_template.knowledge_base_id #=> String
resp.message_template.language #=> String
resp.message_template.last_modified_by #=> String
resp.message_template.last_modified_time #=> Time
resp.message_template.message_template_arn #=> String
resp.message_template.message_template_content_sha_256 #=> String
resp.message_template.message_template_id #=> String
resp.message_template.name #=> String
resp.message_template.tags #=> Hash
resp.message_template.tags["TagKey"] #=> String
resp.message_template.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :message_template_content_sha_256 (String)

    The checksum value of the message template content that is referenced by the $LATEST qualifier. It can be returned in MessageTemplateData or ExtendedMessageTemplateData. It’s calculated by content, language, defaultAttributes and Attachments of the message template. If not supplied, the message template version will be created based on the message template content that is referenced by the $LATEST qualifier by default.

  • :message_template_id (required, String)

    The identifier of the message template. Can be either the ID or the ARN. It cannot contain any qualifier.

Returns:

See Also:



2407
2408
2409
2410
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2407

def create_message_template_version(params = {}, options = {})
  req = build_request(:create_message_template_version, params)
  req.send_request(options)
end

#create_quick_response(params = {}) ⇒ Types::CreateQuickResponseResponse

Creates an Amazon Q in Connect quick response.

Examples:

Request syntax with placeholder values


resp = client.create_quick_response({
  channels: ["Channel"],
  client_token: "NonEmptyString",
  content: { # required
    content: "QuickResponseContent",
  },
  content_type: "QuickResponseType",
  description: "QuickResponseDescription",
  grouping_configuration: {
    criteria: "GroupingCriteria",
    values: ["GroupingValue"],
  },
  is_active: false,
  knowledge_base_id: "UuidOrArn", # required
  language: "LanguageCode",
  name: "QuickResponseName", # required
  shortcut_key: "ShortCutKey",
  tags: {
    "TagKey" => "TagValue",
  },
})

Response structure


resp.quick_response.channels #=> Array
resp.quick_response.channels[0] #=> String
resp.quick_response.content_type #=> String
resp.quick_response.contents.markdown.content #=> String
resp.quick_response.contents.plain_text.content #=> String
resp.quick_response.created_time #=> Time
resp.quick_response.description #=> String
resp.quick_response.grouping_configuration.criteria #=> String
resp.quick_response.grouping_configuration.values #=> Array
resp.quick_response.grouping_configuration.values[0] #=> String
resp.quick_response.is_active #=> Boolean
resp.quick_response.knowledge_base_arn #=> String
resp.quick_response.knowledge_base_id #=> String
resp.quick_response.language #=> String
resp.quick_response.last_modified_by #=> String
resp.quick_response.last_modified_time #=> Time
resp.quick_response.name #=> String
resp.quick_response.quick_response_arn #=> String
resp.quick_response.quick_response_id #=> String
resp.quick_response.shortcut_key #=> String
resp.quick_response.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "CREATED", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED", "UPDATE_IN_PROGRESS", "UPDATE_FAILED"
resp.quick_response.tags #=> Hash
resp.quick_response.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :channels (Array<String>)

    The Amazon Connect channels this quick response applies to.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :content (required, Types::QuickResponseDataProvider)

    The content of the quick response.

  • :content_type (String)

    The media type of the quick response content.

    • Use application/x.quickresponse;format=plain for a quick response written in plain text.

    • Use application/x.quickresponse;format=markdown for a quick response written in richtext.

  • :description (String)

    The description of the quick response.

  • :grouping_configuration (Types::GroupingConfiguration)

    The configuration information of the user groups that the quick response is accessible to.

  • :is_active (Boolean)

    Whether the quick response is active.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :language (String)

    The language code value for the language in which the quick response is written. The supported language codes include de_DE, en_US, es_ES, fr_FR, id_ID, it_IT, ja_JP, ko_KR, pt_BR, zh_CN, zh_TW

  • :name (required, String)

    The name of the quick response.

  • :shortcut_key (String)

    The shortcut key of the quick response. The value should be unique across the knowledge base.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

Returns:

See Also:



2530
2531
2532
2533
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2530

def create_quick_response(params = {}, options = {})
  req = build_request(:create_quick_response, params)
  req.send_request(options)
end

#create_session(params = {}) ⇒ Types::CreateSessionResponse

Creates a session. A session is a contextual container used for generating recommendations. Amazon Connect creates a new Amazon Q in Connect session for each contact on which Amazon Q in Connect is enabled.

Examples:

Request syntax with placeholder values


resp = client.create_session({
  ai_agent_configuration: {
    "MANUAL_SEARCH" => {
      ai_agent_id: "UuidWithQualifier", # required
    },
  },
  assistant_id: "UuidOrArn", # required
  client_token: "ClientToken",
  description: "Description",
  name: "Name", # required
  tag_filter: {
    and_conditions: [
      {
        key: "TagKey", # required
        value: "TagValue",
      },
    ],
    or_conditions: [
      {
        and_conditions: [
          {
            key: "TagKey", # required
            value: "TagValue",
          },
        ],
        tag_condition: {
          key: "TagKey", # required
          value: "TagValue",
        },
      },
    ],
    tag_condition: {
      key: "TagKey", # required
      value: "TagValue",
    },
  },
  tags: {
    "TagKey" => "TagValue",
  },
})

Response structure


resp.session.ai_agent_configuration #=> Hash
resp.session.ai_agent_configuration["AIAgentType"].ai_agent_id #=> String
resp.session.description #=> String
resp.session.integration_configuration.topic_integration_arn #=> String
resp.session.name #=> String
resp.session.session_arn #=> String
resp.session.session_id #=> String
resp.session.tag_filter.and_conditions #=> Array
resp.session.tag_filter.and_conditions[0].key #=> String
resp.session.tag_filter.and_conditions[0].value #=> String
resp.session.tag_filter.or_conditions #=> Array
resp.session.tag_filter.or_conditions[0].and_conditions #=> Array
resp.session.tag_filter.or_conditions[0].and_conditions[0].key #=> String
resp.session.tag_filter.or_conditions[0].and_conditions[0].value #=> String
resp.session.tag_filter.or_conditions[0].tag_condition.key #=> String
resp.session.tag_filter.or_conditions[0].tag_condition.value #=> String
resp.session.tag_filter.tag_condition.key #=> String
resp.session.tag_filter.tag_condition.value #=> String
resp.session.tags #=> Hash
resp.session.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_agent_configuration (Hash<String,Types::AIAgentConfigurationData>)

    The configuration of the AI Agents (mapped by AI Agent Type to AI Agent version) that should be used by Amazon Q in Connect for this Session.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :client_token (String)

    A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. For more information about idempotency, see Making retries safe with idempotent APIs.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

  • :description (String)

    The description.

  • :name (required, String)

    The name of the session.

  • :tag_filter (Types::TagFilter)

    An object that can be used to specify Tag conditions.

  • :tags (Hash<String,String>)

    The tags used to organize, track, or control access for this resource.

Returns:

See Also:



2648
2649
2650
2651
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2648

def create_session(params = {}, options = {})
  req = build_request(:create_session, params)
  req.send_request(options)
end

#deactivate_message_template(params = {}) ⇒ Types::DeactivateMessageTemplateResponse

Deactivates a specific version of the Amazon Q in Connect message template . After the version is deactivated, you can no longer use the $ACTIVE_VERSION qualifier to reference the version in active status.

Examples:

Request syntax with placeholder values


resp = client.deactivate_message_template({
  knowledge_base_id: "UuidOrArn", # required
  message_template_id: "UuidOrArnOrEitherWithQualifier", # required
  version_number: 1, # required
})

Response structure


resp.message_template_arn #=> String
resp.message_template_id #=> String
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :message_template_id (required, String)

    The identifier of the message template. Can be either the ID or the ARN. It cannot contain any qualifier.

  • :version_number (required, Integer)

    The version number of the message template version to deactivate.

Returns:

See Also:



2692
2693
2694
2695
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2692

def deactivate_message_template(params = {}, options = {})
  req = build_request(:deactivate_message_template, params)
  req.send_request(options)
end

#delete_ai_agent(params = {}) ⇒ Struct

Deletes an Amazon Q in Connect AI Agent.

Examples:

Request syntax with placeholder values


resp = client.delete_ai_agent({
  ai_agent_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_agent_id (required, String)

    The identifier of the Amazon Q in Connect AI Agent. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2720
2721
2722
2723
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2720

def delete_ai_agent(params = {}, options = {})
  req = build_request(:delete_ai_agent, params)
  req.send_request(options)
end

#delete_ai_agent_version(params = {}) ⇒ Struct

Deletes an Amazon Q in Connect AI Agent Version.

Examples:

Request syntax with placeholder values


resp = client.delete_ai_agent_version({
  ai_agent_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
  version_number: 1, # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_agent_id (required, String)

    The identifier of the Amazon Q in Connect AI Agent. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :version_number (required, Integer)

    The version number of the AI Agent version.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2752
2753
2754
2755
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2752

def delete_ai_agent_version(params = {}, options = {})
  req = build_request(:delete_ai_agent_version, params)
  req.send_request(options)
end

#delete_ai_guardrail(params = {}) ⇒ Struct

Deletes an Amazon Q in Connect AI Guardrail.

Examples:

Request syntax with placeholder values


resp = client.delete_ai_guardrail({
  ai_guardrail_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_guardrail_id (required, String)

    The identifier of the Amazon Q in Connect AI Guardrail. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2780
2781
2782
2783
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2780

def delete_ai_guardrail(params = {}, options = {})
  req = build_request(:delete_ai_guardrail, params)
  req.send_request(options)
end

#delete_ai_guardrail_version(params = {}) ⇒ Struct

Delete and Amazon Q in Connect AI Guardrail version.

Examples:

Request syntax with placeholder values


resp = client.delete_ai_guardrail_version({
  ai_guardrail_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
  version_number: 1, # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_guardrail_id (required, String)

    The identifier of the Amazon Q in Connect AI Guardrail.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :version_number (required, Integer)

    The version number of the AI Guardrail version to be deleted.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2811
2812
2813
2814
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2811

def delete_ai_guardrail_version(params = {}, options = {})
  req = build_request(:delete_ai_guardrail_version, params)
  req.send_request(options)
end

#delete_ai_prompt(params = {}) ⇒ Struct

Deletes an Amazon Q in Connect AI Prompt.

Examples:

Request syntax with placeholder values


resp = client.delete_ai_prompt({
  ai_prompt_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_prompt_id (required, String)

    The identifier of the Amazon Q in Connect AI prompt. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2839
2840
2841
2842
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2839

def delete_ai_prompt(params = {}, options = {})
  req = build_request(:delete_ai_prompt, params)
  req.send_request(options)
end

#delete_ai_prompt_version(params = {}) ⇒ Struct

Delete and Amazon Q in Connect AI Prompt version.

Examples:

Request syntax with placeholder values


resp = client.delete_ai_prompt_version({
  ai_prompt_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
  version_number: 1, # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_prompt_id (required, String)

    The identifier of the Amazon Q in Connect AI prompt.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :version_number (required, Integer)

    The version number of the AI Prompt version to be deleted.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2870
2871
2872
2873
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2870

def delete_ai_prompt_version(params = {}, options = {})
  req = build_request(:delete_ai_prompt_version, params)
  req.send_request(options)
end

#delete_assistant(params = {}) ⇒ Struct

Deletes an assistant.

Examples:

Request syntax with placeholder values


resp = client.delete_assistant({
  assistant_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2893
2894
2895
2896
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2893

def delete_assistant(params = {}, options = {})
  req = build_request(:delete_assistant, params)
  req.send_request(options)
end

#delete_assistant_association(params = {}) ⇒ Struct

Deletes an assistant association.

Examples:

Request syntax with placeholder values


resp = client.delete_assistant_association({
  assistant_association_id: "UuidOrArn", # required
  assistant_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_association_id (required, String)

    The identifier of the assistant association. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2921
2922
2923
2924
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2921

def delete_assistant_association(params = {}, options = {})
  req = build_request(:delete_assistant_association, params)
  req.send_request(options)
end

#delete_content(params = {}) ⇒ Struct

Deletes the content.

Examples:

Request syntax with placeholder values


resp = client.delete_content({
  content_id: "UuidOrArn", # required
  knowledge_base_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :content_id (required, String)

    The identifier of the content. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2949
2950
2951
2952
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2949

def delete_content(params = {}, options = {})
  req = build_request(:delete_content, params)
  req.send_request(options)
end

#delete_content_association(params = {}) ⇒ Struct

Deletes the content association.

For more information about content associations--what they are and when they are used--see Integrate Amazon Q in Connect with step-by-step guides in the Amazon Connect Administrator Guide.

Examples:

Request syntax with placeholder values


resp = client.delete_content_association({
  content_association_id: "UuidOrArn", # required
  content_id: "UuidOrArn", # required
  knowledge_base_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :content_association_id (required, String)

    The identifier of the content association. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :content_id (required, String)

    The identifier of the content.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



2988
2989
2990
2991
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 2988

def delete_content_association(params = {}, options = {})
  req = build_request(:delete_content_association, params)
  req.send_request(options)
end

#delete_import_job(params = {}) ⇒ Struct

Deletes the quick response import job.

Examples:

Request syntax with placeholder values


resp = client.delete_import_job({
  import_job_id: "Uuid", # required
  knowledge_base_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :import_job_id (required, String)

    The identifier of the import job to be deleted.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3014
3015
3016
3017
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3014

def delete_import_job(params = {}, options = {})
  req = build_request(:delete_import_job, params)
  req.send_request(options)
end

#delete_knowledge_base(params = {}) ⇒ Struct

Deletes the knowledge base.

When you use this API to delete an external knowledge base such as Salesforce or ServiceNow, you must also delete the Amazon AppIntegrations DataIntegration. This is because you can't reuse the DataIntegration after it's been associated with an external knowledge base. However, you can delete and recreate it. See DeleteDataIntegration and CreateDataIntegration in the Amazon AppIntegrations API Reference.

Examples:

Request syntax with placeholder values


resp = client.delete_knowledge_base({
  knowledge_base_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The knowledge base to delete content from. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3053
3054
3055
3056
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3053

def delete_knowledge_base(params = {}, options = {})
  req = build_request(:delete_knowledge_base, params)
  req.send_request(options)
end

#delete_message_template(params = {}) ⇒ Struct

Deletes an Amazon Q in Connect message template entirely or a specific version of the message template if version is supplied in the request. You can provide the message template identifier as <message-template-id>:<versionNumber> to delete a specific version of the message template. If it is not supplied, the message template and all available versions will be deleted.

Examples:

Request syntax with placeholder values


resp = client.delete_message_template({
  knowledge_base_id: "UuidOrArn", # required
  message_template_id: "UuidOrArnOrEitherWithQualifier", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :message_template_id (required, String)

    The identifier of the message template. Can be either the ID or the ARN.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3086
3087
3088
3089
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3086

def delete_message_template(params = {}, options = {})
  req = build_request(:delete_message_template, params)
  req.send_request(options)
end

#delete_message_template_attachment(params = {}) ⇒ Struct

Deletes the attachment file from the Amazon Q in Connect message template that is referenced by $LATEST qualifier. Attachments on available message template versions will remain unchanged.

Examples:

Request syntax with placeholder values


resp = client.delete_message_template_attachment({
  attachment_id: "Uuid", # required
  knowledge_base_id: "UuidOrArn", # required
  message_template_id: "UuidOrArnOrEitherWithQualifier", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :attachment_id (required, String)

    The identifier of the attachment file.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :message_template_id (required, String)

    The identifier of the message template. Can be either the ID or the ARN. It cannot contain any qualifier.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3120
3121
3122
3123
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3120

def delete_message_template_attachment(params = {}, options = {})
  req = build_request(:delete_message_template_attachment, params)
  req.send_request(options)
end

#delete_quick_response(params = {}) ⇒ Struct

Deletes a quick response.

Examples:

Request syntax with placeholder values


resp = client.delete_quick_response({
  knowledge_base_id: "UuidOrArn", # required
  quick_response_id: "UuidOrArn", # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The knowledge base from which the quick response is deleted. The identifier of the knowledge base.

  • :quick_response_id (required, String)

    The identifier of the quick response to delete.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3147
3148
3149
3150
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3147

def delete_quick_response(params = {}, options = {})
  req = build_request(:delete_quick_response, params)
  req.send_request(options)
end

#get_ai_agent(params = {}) ⇒ Types::GetAIAgentResponse

Gets an Amazon Q in Connect AI Agent.

Examples:

Request syntax with placeholder values


resp = client.get_ai_agent({
  ai_agent_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
})

Response structure


resp.ai_agent.ai_agent_arn #=> String
resp.ai_agent.ai_agent_id #=> String
resp.ai_agent.assistant_arn #=> String
resp.ai_agent.assistant_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.answer_generation_ai_guardrail_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.intent_labeling_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.answer_recommendation_ai_agent_configuration.query_reformulation_ai_prompt_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.answer_generation_ai_guardrail_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.manual_search_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..and_conditions[0].value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions #=> Array
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].and_conditions[0].value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..or_conditions[0].tag_condition.value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.key #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data..tag_condition.value #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.max_results #=> Integer
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_configuration_data.knowledge_base_association_configuration_data.override_knowledge_base_search_type #=> String, one of "HYBRID", "SEMANTIC"
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.association_configurations[0].association_type #=> String, one of "KNOWLEDGE_BASE"
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_ai_guardrail_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_answer_generation_ai_prompt_id #=> String
resp.ai_agent.configuration.self_service_ai_agent_configuration.self_service_pre_processing_ai_prompt_id #=> String
resp.ai_agent.description #=> String
resp.ai_agent.modified_time #=> Time
resp.ai_agent.name #=> String
resp.ai_agent.origin #=> String, one of "SYSTEM", "CUSTOMER"
resp.ai_agent.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_agent.tags #=> Hash
resp.ai_agent.tags["TagKey"] #=> String
resp.ai_agent.type #=> String, one of "MANUAL_SEARCH", "ANSWER_RECOMMENDATION", "SELF_SERVICE"
resp.ai_agent.visibility_status #=> String, one of "SAVED", "PUBLISHED"
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_agent_id (required, String)

    The identifier of the Amazon Q in Connect AI Agent (with or without a version qualifier). Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3253
3254
3255
3256
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3253

def get_ai_agent(params = {}, options = {})
  req = build_request(:get_ai_agent, params)
  req.send_request(options)
end

#get_ai_guardrail(params = {}) ⇒ Types::GetAIGuardrailResponse

Gets the Amazon Q in Connect AI Guardrail.

Examples:

Request syntax with placeholder values


resp = client.get_ai_guardrail({
  ai_guardrail_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
})

Response structure


resp.ai_guardrail.ai_guardrail_arn #=> String
resp.ai_guardrail.ai_guardrail_id #=> String
resp.ai_guardrail.assistant_arn #=> String
resp.ai_guardrail.assistant_id #=> String
resp.ai_guardrail.blocked_input_messaging #=> String
resp.ai_guardrail.blocked_outputs_messaging #=> String
resp.ai_guardrail.content_policy_config.filters_config #=> Array
resp.ai_guardrail.content_policy_config.filters_config[0].input_strength #=> String, one of "NONE", "LOW", "MEDIUM", "HIGH"
resp.ai_guardrail.content_policy_config.filters_config[0].output_strength #=> String, one of "NONE", "LOW", "MEDIUM", "HIGH"
resp.ai_guardrail.content_policy_config.filters_config[0].type #=> String, one of "SEXUAL", "VIOLENCE", "HATE", "INSULTS", "MISCONDUCT", "PROMPT_ATTACK"
resp.ai_guardrail.contextual_grounding_policy_config.filters_config #=> Array
resp.ai_guardrail.contextual_grounding_policy_config.filters_config[0].threshold #=> Float
resp.ai_guardrail.contextual_grounding_policy_config.filters_config[0].type #=> String, one of "GROUNDING", "RELEVANCE"
resp.ai_guardrail.description #=> String
resp.ai_guardrail.modified_time #=> Time
resp.ai_guardrail.name #=> String
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config #=> Array
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config[0].action #=> String, one of "BLOCK", "ANONYMIZE"
resp.ai_guardrail.sensitive_information_policy_config.pii_entities_config[0].type #=> String, one of "ADDRESS", "AGE", "AWS_ACCESS_KEY", "AWS_SECRET_KEY", "CA_HEALTH_NUMBER", "CA_SOCIAL_INSURANCE_NUMBER", "CREDIT_DEBIT_CARD_CVV", "CREDIT_DEBIT_CARD_EXPIRY", "CREDIT_DEBIT_CARD_NUMBER", "DRIVER_ID", "EMAIL", "INTERNATIONAL_BANK_ACCOUNT_NUMBER", "IP_ADDRESS", "LICENSE_PLATE", "MAC_ADDRESS", "NAME", "PASSWORD", "PHONE", "PIN", "SWIFT_CODE", "UK_NATIONAL_HEALTH_SERVICE_NUMBER", "UK_NATIONAL_INSURANCE_NUMBER", "UK_UNIQUE_TAXPAYER_REFERENCE_NUMBER", "URL", "USERNAME", "US_BANK_ACCOUNT_NUMBER", "US_BANK_ROUTING_NUMBER", "US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER", "US_PASSPORT_NUMBER", "US_SOCIAL_SECURITY_NUMBER", "VEHICLE_IDENTIFICATION_NUMBER"
resp.ai_guardrail.sensitive_information_policy_config.regexes_config #=> Array
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].action #=> String, one of "BLOCK", "ANONYMIZE"
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].description #=> String
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].name #=> String
resp.ai_guardrail.sensitive_information_policy_config.regexes_config[0].pattern #=> String
resp.ai_guardrail.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_guardrail.tags #=> Hash
resp.ai_guardrail.tags["TagKey"] #=> String
resp.ai_guardrail.topic_policy_config.topics_config #=> Array
resp.ai_guardrail.topic_policy_config.topics_config[0].definition #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].examples #=> Array
resp.ai_guardrail.topic_policy_config.topics_config[0].examples[0] #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].name #=> String
resp.ai_guardrail.topic_policy_config.topics_config[0].type #=> String, one of "DENY"
resp.ai_guardrail.visibility_status #=> String, one of "SAVED", "PUBLISHED"
resp.ai_guardrail.word_policy_config.managed_word_lists_config #=> Array
resp.ai_guardrail.word_policy_config.managed_word_lists_config[0].type #=> String, one of "PROFANITY"
resp.ai_guardrail.word_policy_config.words_config #=> Array
resp.ai_guardrail.word_policy_config.words_config[0].text #=> String
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_guardrail_id (required, String)

    The identifier of the Amazon Q in Connect AI Guardrail.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3325
3326
3327
3328
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3325

def get_ai_guardrail(params = {}, options = {})
  req = build_request(:get_ai_guardrail, params)
  req.send_request(options)
end

#get_ai_prompt(params = {}) ⇒ Types::GetAIPromptResponse

Gets and Amazon Q in Connect AI Prompt.

Examples:

Request syntax with placeholder values


resp = client.get_ai_prompt({
  ai_prompt_id: "UuidOrArnOrEitherWithQualifier", # required
  assistant_id: "UuidOrArn", # required
})

Response structure


resp.ai_prompt.ai_prompt_arn #=> String
resp.ai_prompt.ai_prompt_id #=> String
resp.ai_prompt.api_format #=> String, one of "ANTHROPIC_CLAUDE_MESSAGES", "ANTHROPIC_CLAUDE_TEXT_COMPLETIONS"
resp.ai_prompt.assistant_arn #=> String
resp.ai_prompt.assistant_id #=> String
resp.ai_prompt.description #=> String
resp.ai_prompt.model_id #=> String
resp.ai_prompt.modified_time #=> Time
resp.ai_prompt.name #=> String
resp.ai_prompt.origin #=> String, one of "SYSTEM", "CUSTOMER"
resp.ai_prompt.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.ai_prompt.tags #=> Hash
resp.ai_prompt.tags["TagKey"] #=> String
resp.ai_prompt.template_configuration.text_full_ai_prompt_edit_template_configuration.text #=> String
resp.ai_prompt.template_type #=> String, one of "TEXT"
resp.ai_prompt.type #=> String, one of "ANSWER_GENERATION", "INTENT_LABELING_GENERATION", "QUERY_REFORMULATION", "SELF_SERVICE_PRE_PROCESSING", "SELF_SERVICE_ANSWER_GENERATION"
resp.ai_prompt.visibility_status #=> String, one of "SAVED", "PUBLISHED"
resp.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ai_prompt_id (required, String)

    The identifier of the Amazon Q in Connect AI prompt.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3376
3377
3378
3379
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3376

def get_ai_prompt(params = {}, options = {})
  req = build_request(:get_ai_prompt, params)
  req.send_request(options)
end

#get_assistant(params = {}) ⇒ Types::GetAssistantResponse

Retrieves information about an assistant.

Examples:

Request syntax with placeholder values


resp = client.get_assistant({
  assistant_id: "UuidOrArn", # required
})

Response structure


resp.assistant.ai_agent_configuration #=> Hash
resp.assistant.ai_agent_configuration["AIAgentType"].ai_agent_id #=> String
resp.assistant.assistant_arn #=> String
resp.assistant.assistant_id #=> String
resp.assistant.capability_configuration.type #=> String, one of "V1", "V2"
resp.assistant.description #=> String
resp.assistant.integration_configuration.topic_integration_arn #=> String
resp.assistant.name #=> String
resp.assistant.server_side_encryption_configuration.kms_key_id #=> String
resp.assistant.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.assistant.tags #=> Hash
resp.assistant.tags["TagKey"] #=> String
resp.assistant.type #=> String, one of "AGENT"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3417
3418
3419
3420
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3417

def get_assistant(params = {}, options = {})
  req = build_request(:get_assistant, params)
  req.send_request(options)
end

#get_assistant_association(params = {}) ⇒ Types::GetAssistantAssociationResponse

Retrieves information about an assistant association.

Examples:

Request syntax with placeholder values


resp = client.get_assistant_association({
  assistant_association_id: "UuidOrArn", # required
  assistant_id: "UuidOrArn", # required
})

Response structure


resp.assistant_association.assistant_arn #=> String
resp.assistant_association.assistant_association_arn #=> String
resp.assistant_association.assistant_association_id #=> String
resp.assistant_association.assistant_id #=> String
resp.assistant_association.association_data.knowledge_base_association.knowledge_base_arn #=> String
resp.assistant_association.association_data.knowledge_base_association.knowledge_base_id #=> String
resp.assistant_association.association_type #=> String, one of "KNOWLEDGE_BASE"
resp.assistant_association.tags #=> Hash
resp.assistant_association.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_association_id (required, String)

    The identifier of the assistant association. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3459
3460
3461
3462
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3459

def get_assistant_association(params = {}, options = {})
  req = build_request(:get_assistant_association, params)
  req.send_request(options)
end

#get_content(params = {}) ⇒ Types::GetContentResponse

Retrieves content, including a pre-signed URL to download the content.

Examples:

Request syntax with placeholder values


resp = client.get_content({
  content_id: "UuidOrArn", # required
  knowledge_base_id: "UuidOrArn", # required
})

Response structure


resp.content.content_arn #=> String
resp.content.content_id #=> String
resp.content.content_type #=> String
resp.content.knowledge_base_arn #=> String
resp.content.knowledge_base_id #=> String
resp.content.link_out_uri #=> String
resp.content. #=> Hash
resp.content.["NonEmptyString"] #=> String
resp.content.name #=> String
resp.content.revision_id #=> String
resp.content.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED", "UPDATE_FAILED"
resp.content.tags #=> Hash
resp.content.tags["TagKey"] #=> String
resp.content.title #=> String
resp.content.url #=> String
resp.content.url_expiry #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :content_id (required, String)

    The identifier of the content. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. This should not be a QUICK_RESPONSES type knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3509
3510
3511
3512
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3509

def get_content(params = {}, options = {})
  req = build_request(:get_content, params)
  req.send_request(options)
end

#get_content_association(params = {}) ⇒ Types::GetContentAssociationResponse

Returns the content association.

For more information about content associations--what they are and when they are used--see Integrate Amazon Q in Connect with step-by-step guides in the Amazon Connect Administrator Guide.

Examples:

Request syntax with placeholder values


resp = client.get_content_association({
  content_association_id: "UuidOrArn", # required
  content_id: "UuidOrArn", # required
  knowledge_base_id: "UuidOrArn", # required
})

Response structure


resp.content_association.association_data.amazon_connect_guide_association.flow_id #=> String
resp.content_association.association_type #=> String, one of "AMAZON_CONNECT_GUIDE"
resp.content_association.content_arn #=> String
resp.content_association.content_association_arn #=> String
resp.content_association.content_association_id #=> String
resp.content_association.content_id #=> String
resp.content_association.knowledge_base_arn #=> String
resp.content_association.knowledge_base_id #=> String
resp.content_association.tags #=> Hash
resp.content_association.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :content_association_id (required, String)

    The identifier of the content association. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :content_id (required, String)

    The identifier of the content.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base.

Returns:

See Also:



3563
3564
3565
3566
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3563

def get_content_association(params = {}, options = {})
  req = build_request(:get_content_association, params)
  req.send_request(options)
end

#get_content_summary(params = {}) ⇒ Types::GetContentSummaryResponse

Retrieves summary information about the content.

Examples:

Request syntax with placeholder values


resp = client.get_content_summary({
  content_id: "UuidOrArn", # required
  knowledge_base_id: "UuidOrArn", # required
})

Response structure


resp.content_summary.content_arn #=> String
resp.content_summary.content_id #=> String
resp.content_summary.content_type #=> String
resp.content_summary.knowledge_base_arn #=> String
resp.content_summary.knowledge_base_id #=> String
resp.content_summary. #=> Hash
resp.content_summary.["NonEmptyString"] #=> String
resp.content_summary.name #=> String
resp.content_summary.revision_id #=> String
resp.content_summary.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED", "UPDATE_FAILED"
resp.content_summary.tags #=> Hash
resp.content_summary.tags["TagKey"] #=> String
resp.content_summary.title #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :content_id (required, String)

    The identifier of the content. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3609
3610
3611
3612
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3609

def get_content_summary(params = {}, options = {})
  req = build_request(:get_content_summary, params)
  req.send_request(options)
end

#get_import_job(params = {}) ⇒ Types::GetImportJobResponse

Retrieves the started import job.

Examples:

Request syntax with placeholder values


resp = client.get_import_job({
  import_job_id: "Uuid", # required
  knowledge_base_id: "UuidOrArn", # required
})

Response structure


resp.import_job.created_time #=> Time
resp.import_job.external_source_configuration.configuration.connect_configuration.instance_id #=> String
resp.import_job.external_source_configuration.source #=> String, one of "AMAZON_CONNECT"
resp.import_job.failed_record_report #=> String
resp.import_job.import_job_id #=> String
resp.import_job.import_job_type #=> String, one of "QUICK_RESPONSES"
resp.import_job.knowledge_base_arn #=> String
resp.import_job.knowledge_base_id #=> String
resp.import_job.last_modified_time #=> Time
resp.import_job. #=> Hash
resp.import_job.["NonEmptyString"] #=> String
resp.import_job.status #=> String, one of "START_IN_PROGRESS", "FAILED", "COMPLETE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.import_job.upload_id #=> String
resp.import_job.url #=> String
resp.import_job.url_expiry #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :import_job_id (required, String)

    The identifier of the import job to retrieve.

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base that the import job belongs to.

Returns:

See Also:



3655
3656
3657
3658
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3655

def get_import_job(params = {}, options = {})
  req = build_request(:get_import_job, params)
  req.send_request(options)
end

#get_knowledge_base(params = {}) ⇒ Types::GetKnowledgeBaseResponse

Retrieves information about the knowledge base.

Examples:

Request syntax with placeholder values


resp = client.get_knowledge_base({
  knowledge_base_id: "UuidOrArn", # required
})

Response structure


resp.knowledge_base.description #=> String
resp.knowledge_base.ingestion_failure_reasons #=> Array
resp.knowledge_base.ingestion_failure_reasons[0] #=> String
resp.knowledge_base.ingestion_status #=> String, one of "SYNC_FAILED", "SYNCING_IN_PROGRESS", "SYNC_SUCCESS", "CREATE_IN_PROGRESS"
resp.knowledge_base.knowledge_base_arn #=> String
resp.knowledge_base.knowledge_base_id #=> String
resp.knowledge_base.knowledge_base_type #=> String, one of "EXTERNAL", "CUSTOM", "QUICK_RESPONSES", "MESSAGE_TEMPLATES", "MANAGED"
resp.knowledge_base.last_content_modification_time #=> Time
resp.knowledge_base.name #=> String
resp.knowledge_base.rendering_configuration.template_uri #=> String
resp.knowledge_base.server_side_encryption_configuration.kms_key_id #=> String
resp.knowledge_base.source_configuration.app_integrations.app_integration_arn #=> String
resp.knowledge_base.source_configuration.app_integrations.object_fields #=> Array
resp.knowledge_base.source_configuration.app_integrations.object_fields[0] #=> String
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.crawler_limits.rate_limit #=> Integer
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.exclusion_filters #=> Array
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.exclusion_filters[0] #=> String
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.inclusion_filters #=> Array
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.inclusion_filters[0] #=> String
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.scope #=> String, one of "HOST_ONLY", "SUBDOMAINS"
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.url_configuration.seed_urls #=> Array
resp.knowledge_base.source_configuration.managed_source_configuration.web_crawler_configuration.url_configuration.seed_urls[0].url #=> String
resp.knowledge_base.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "ACTIVE", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED"
resp.knowledge_base.tags #=> Hash
resp.knowledge_base.tags["TagKey"] #=> String
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.chunking_strategy #=> String, one of "FIXED_SIZE", "NONE", "HIERARCHICAL", "SEMANTIC"
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.max_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.fixed_size_chunking_configuration.overlap_percentage #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.hierarchical_chunking_configuration.level_configurations #=> Array
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.hierarchical_chunking_configuration.level_configurations[0].max_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.hierarchical_chunking_configuration.overlap_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.semantic_chunking_configuration.breakpoint_percentile_threshold #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.semantic_chunking_configuration.buffer_size #=> Integer
resp.knowledge_base.vector_ingestion_configuration.chunking_configuration.semantic_chunking_configuration.max_tokens #=> Integer
resp.knowledge_base.vector_ingestion_configuration.parsing_configuration.bedrock_foundation_model_configuration.model_arn #=> String
resp.knowledge_base.vector_ingestion_configuration.parsing_configuration.bedrock_foundation_model_configuration.parsing_prompt.parsing_prompt_text #=> String
resp.knowledge_base.vector_ingestion_configuration.parsing_configuration.parsing_strategy #=> String, one of "BEDROCK_FOUNDATION_MODEL"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

Returns:

See Also:



3720
3721
3722
3723
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3720

def get_knowledge_base(params = {}, options = {})
  req = build_request(:get_knowledge_base, params)
  req.send_request(options)
end

#get_message_template(params = {}) ⇒ Types::GetMessageTemplateResponse

Retrieves the Amazon Q in Connect message template. The message template identifier can contain an optional qualifier, for example, <message-template-id>:<qualifier>, which is either an actual version number or an Amazon Q Connect managed qualifier $ACTIVE_VERSION | $LATEST. If it is not supplied, then $LATEST is assumed implicitly.

Examples:

Request syntax with placeholder values


resp = client.get_message_template({
  knowledge_base_id: "UuidOrArn", # required
  message_template_id: "UuidOrArnOrEitherWithQualifier", # required
})

Response structure


resp.message_template.attachments #=> Array
resp.message_template.attachments[0].attachment_id #=> String
resp.message_template.attachments[0].content_disposition #=> String, one of "ATTACHMENT"
resp.message_template.attachments[0].name #=> String
resp.message_template.attachments[0].uploaded_time #=> Time
resp.message_template.attachments[0].url #=> String
resp.message_template.attachments[0].url_expiry #=> Time
resp.message_template.attribute_types #=> Array
resp.message_template.attribute_types[0] #=> String, one of "SYSTEM", "AGENT", "CUSTOMER_PROFILE", "CUSTOM"
resp.message_template.channel_subtype #=> String, one of "EMAIL", "SMS"
resp.message_template.content.email.body.html.content #=> String
resp.message_template.content.email.body.plain_text.content #=> String
resp.message_template.content.email.headers #=> Array
resp.message_template.content.email.headers[0].name #=> String
resp.message_template.content.email.headers[0].value #=> String
resp.message_template.content.email.subject #=> String
resp.message_template.content.sms.body.plain_text.content #=> String
resp.message_template.created_time #=> Time
resp.message_template.default_attributes.agent_attributes.first_name #=> String
resp.message_template.default_attributes.agent_attributes.last_name #=> String
resp.message_template.default_attributes.custom_attributes #=> Hash
resp.message_template.default_attributes.custom_attributes["MessageTemplateAttributeKey"] #=> String
resp.message_template.default_attributes.customer_profile_attributes. #=> String
resp.message_template.default_attributes.customer_profile_attributes.additional_information #=> String
resp.message_template.default_attributes.customer_profile_attributes.address1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.address4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.billing_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.birth_date #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_email_address #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.business_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.city #=> String
resp.message_template.default_attributes.customer_profile_attributes.country #=> String
resp.message_template.default_attributes.customer_profile_attributes.county #=> String
resp.message_template.default_attributes.customer_profile_attributes.custom #=> Hash
resp.message_template.default_attributes.customer_profile_attributes.custom["MessageTemplateAttributeKey"] #=> String
resp.message_template.default_attributes.customer_profile_attributes.email_address #=> String
resp.message_template.default_attributes.customer_profile_attributes.first_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.gender #=> String
resp.message_template.default_attributes.customer_profile_attributes.home_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.last_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.mailing_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.middle_name #=> String
resp.message_template.default_attributes.customer_profile_attributes.mobile_phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.party_type #=> String
resp.message_template.default_attributes.customer_profile_attributes.phone_number #=> String
resp.message_template.default_attributes.customer_profile_attributes.postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.profile_arn #=> String
resp.message_template.default_attributes.customer_profile_attributes.profile_id #=> String
resp.message_template.default_attributes.customer_profile_attributes.province #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_1 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_2 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_3 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_address_4 #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_city #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_country #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_county #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_postal_code #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_province #=> String
resp.message_template.default_attributes.customer_profile_attributes.shipping_state #=> String
resp.message_template.default_attributes.customer_profile_attributes.state #=> String
resp.message_template.default_attributes.system_attributes.customer_endpoint.address #=> String
resp.message_template.default_attributes.system_attributes.name #=> String
resp.message_template.default_attributes.system_attributes.system_endpoint.address #=> String
resp.message_template.description #=> String
resp.message_template.grouping_configuration.criteria #=> String
resp.message_template.grouping_configuration.values #=> Array
resp.message_template.grouping_configuration.values[0] #=> String
resp.message_template.is_active #=> Boolean
resp.message_template.knowledge_base_arn #=> String
resp.message_template.knowledge_base_id #=> String
resp.message_template.language #=> String
resp.message_template.last_modified_by #=> String
resp.message_template.last_modified_time #=> Time
resp.message_template.message_template_arn #=> String
resp.message_template.message_template_content_sha_256 #=> String
resp.message_template.message_template_id #=> String
resp.message_template.name #=> String
resp.message_template.tags #=> Hash
resp.message_template.tags["TagKey"] #=> String
resp.message_template.version_number #=> Integer

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. Can be either the ID or the ARN. URLs cannot contain the ARN.

  • :message_template_id (required, String)

    The identifier of the message template. Can be either the ID or the ARN.

Returns:

See Also:



3859
3860
3861
3862
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3859

def get_message_template(params = {}, options = {})
  req = build_request(:get_message_template, params)
  req.send_request(options)
end

#get_next_message(params = {}) ⇒ Types::GetNextMessageResponse

Retrieves next message on an Amazon Q in Connect session.

Examples:

Request syntax with placeholder values


resp = client.get_next_message({
  assistant_id: "UuidOrArn", # required
  next_message_token: "NextToken", # required
  session_id: "UuidOrArn", # required
})

Response structure


resp.conversation_session_data #=> Array
resp.conversation_session_data[0].key #=> String
resp.conversation_session_data[0].value.string_value #=> String
resp.conversation_state.reason #=> String, one of "SUCCESS", "FAILED", "REJECTED"
resp.conversation_state.status #=> String, one of "CLOSED", "READY", "PROCESSING"
resp.next_message_token #=> String
resp.request_message_id #=> String
resp.response.message_id #=> String
resp.response.participant #=> String, one of "CUSTOMER", "AGENT", "BOT"
resp.response.timestamp #=> Time
resp.response.value.text.value #=> String
resp.type #=> String, one of "TEXT"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :assistant_id (required, String)

    The identifier of the Amazon Q in Connect assistant.

  • :next_message_token (required, String)

    The token for the next message. Use the value returned in the SendMessage or previous response in the next request to retrieve the next message.

  • :session_id (required, String)

    The identifier of the Amazon Q in Connect session.

Returns:

See Also:



3913
3914
3915
3916
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3913

def get_next_message(params = {}, options = {})
  req = build_request(:get_next_message, params)
  req.send_request(options)
end

#get_quick_response(params = {}) ⇒ Types::GetQuickResponseResponse

Retrieves the quick response.

Examples:

Request syntax with placeholder values


resp = client.get_quick_response({
  knowledge_base_id: "UuidOrArn", # required
  quick_response_id: "UuidOrArn", # required
})

Response structure


resp.quick_response.channels #=> Array
resp.quick_response.channels[0] #=> String
resp.quick_response.content_type #=> String
resp.quick_response.contents.markdown.content #=> String
resp.quick_response.contents.plain_text.content #=> String
resp.quick_response.created_time #=> Time
resp.quick_response.description #=> String
resp.quick_response.grouping_configuration.criteria #=> String
resp.quick_response.grouping_configuration.values #=> Array
resp.quick_response.grouping_configuration.values[0] #=> String
resp.quick_response.is_active #=> Boolean
resp.quick_response.knowledge_base_arn #=> String
resp.quick_response.knowledge_base_id #=> String
resp.quick_response.language #=> String
resp.quick_response.last_modified_by #=> String
resp.quick_response.last_modified_time #=> Time
resp.quick_response.name #=> String
resp.quick_response.quick_response_arn #=> String
resp.quick_response.quick_response_id #=> String
resp.quick_response.shortcut_key #=> String
resp.quick_response.status #=> String, one of "CREATE_IN_PROGRESS", "CREATE_FAILED", "CREATED", "DELETE_IN_PROGRESS", "DELETE_FAILED", "DELETED", "UPDATE_IN_PROGRESS", "UPDATE_FAILED"
resp.quick_response.tags #=> Hash
resp.quick_response.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :knowledge_base_id (required, String)

    The identifier of the knowledge base. This should be a QUICK_RESPONSES type knowledge base.

  • :quick_response_id (required, String)

    The identifier of the quick response.

Returns:

See Also:



3968
3969
3970
3971
# File 'gems/aws-sdk-qconnect/lib/aws-sdk-qconnect/client.rb', line 3968

def get_quick_response(params = {}, options = {})
  req = build_request(:get_quick_response, params)
  req.send_request(options)
end

#get_recommendations(params = {}) ⇒ Types::GetRecommendationsResponse

This API will be discontinued starting June 1, 2024. To receive generative responses after March 1, 2024, you will need to create a new Assistant in the Amazon Connect console and integrate the Amazon Q in Connect JavaScript library (amazon-q-connectjs) into your applications.

Retrieves recommendations for the specified session. To avoid retrieving the same recommendations in subsequent calls, use NotifyRecommendationsReceived. This API supports long-polling behavior with the waitTimeSeconds parameter. Short poll is the default behavior and only returns recommendations already available. To perform a manual query against an assistant, use QueryAssistant.

Examples:

Request syntax with placeholder values


resp = client.get_recommendations({
  assistant_id: "UuidOrArn", # required
  max_results: 1,
  session_id: "UuidOrArn", # required
  wait_time_seconds: 1,
})

Response structure


resp.recommendations #=> Array
resp.recommendations[0].data.details.content_data.ranking_data.relevance_level #=> String, one of "HIGH", "MEDIUM", "LOW"
resp.recommendations[0].data.details.content_data.ranking_data.relevance_score #=> Float
resp.recommendations[0].data.details.content_data.text_data.excerpt.highlights #=> Array
resp.recommendations[0].data.details.content_data.text_data.excerpt.highlights[0].begin_offset_inclusive #=> Integer
resp.recommendations[0].data.details.content_data.text_data.excerpt.highlights[0].end_offset_exclusive #=> Integer
resp.recommendations[0].data.details.content_data.text_data.excerpt.text #=> String
resp.recommendations[0].data.details.content_data.text_data.title.highlights #=> Array
resp.recommendations[0].data.details.content_data.text_data.title.highlights[0].begin_offset_inclusive #=> Integer
resp.recommendations[0].data.details.content_data.text_data.title.highlights[0].end_offset_exclusive #=> Integer
resp.recommendations[0].data.details.content_data.text_data.title.text #=> String
resp.recommendations[0].data.details.generative_data.completion #=> String
resp.recommendations[0].data.details.generative_data.ranking_data.relevance_level #=> String, one of "HIGH", "MEDIUM", "LOW"
resp.recommendations[0].data.details.generative_data.ranking_data.relevance_score #=> Float
resp.recommendations[0].data.details.generative_data.references #=> Array
resp.recommendations[0].data.details.generative_data.references[0] #=> Types::DataSummary
resp.recommendations[0].data.details.intent_detected_data.intent #=> String
resp.recommendations[0].data.details.intent_detected_data.intent_id #=> String
resp.recommendations[0].data.details.source_content_data.citation_span.begin_offset_inclusive #=> Integer
resp.recommendations[0].data.details.source_content_data.citation_span.end_offset_exclusive #=> Integer
resp.recommendations[0].data.details.source_content_data.id #=> String
resp.recommendations[0].data.details.source_content_data.ranking_data.relevance_level #=> String, one of "HIGH", "MEDIUM", "LOW"
resp.recommendations[0].data.details.source_content_data.ranking_data.relevance_score #=> Float
resp.recommendations[0].data.details.source_content_data.text_data.excerpt.highlights #=> Array
resp.recommendations[0].data.details.source_content_data.text_data.excerpt.highlights[0].begin_offset_inclusive #=> Integer
resp.recommendations[0].data.details.source_content_data.text_data.excerpt.highlights[0].end_offset_exclusive #=> Integer
resp.recommendations[0].data.details.source_content_data.text_data.excerpt.text #=> String
resp.recommendations[0].data.details.source_content_data.text_data.title.highlights #=> Array
resp.recommendations[0].data.details.source_content_data.text_data.title.highlights[0].begin_offset_inclusive #=> Integer
resp.recommendations[0].data.details.source_content_data.text_data.title.highlights[0].end_offset_exclusive #=> Integer
resp.recommendations[0].data.details.source_content_data.text_data.title.text #=> String
resp.recommendations[0].data.details.source_content_data.type #=> String, one of "KNOWLEDGE_CONTENT"
resp.recommendations[0].data.reference.content_reference.content_arn #=> String
resp.recommendations[0].data.reference.content_reference.content_id #=> String
resp.recommendations[0].data.reference.content_reference.knowledge_base_arn #=> String
resp.recommendations[0].data.reference.content_reference.knowledge_base_id #=> String
resp.recommendations[0].data.reference.content_reference.reference_type #=> String, one of "WEB_CRAWLER", "KNOWLEDGE_BASE"
resp.recommendations[0].data.reference.content_reference.source_url #=> String
resp.recommendations[0].data.reference.generative_reference.generation_id #=> String
resp.recommendations[0].data.reference.generative_reference.model_id #=> String
resp.recommendations[0].document.content_reference.content_arn #=> String
resp.recommendations[0].document.content_reference.content_id #=> String
resp.recommendations[0].document.content_reference.knowledge_base_arn #=> String
resp.recommendations[0].document.content_reference.knowledge_base_id #=> String
resp.recommendations[0].document.content_reference.reference_type #=> String, one of "WEB_CRAWLER", "KNOWLEDGE_BASE"
resp.recommendations[0].document.content_reference.source_url #=> String
resp.recommendations[0].document.excerpt.highlights #=> Array
resp.recommendations[0].document.excerpt.highlights[0].begin_offset_inclusive #=> Integer
resp.recommendations[0].document.excerpt.highlights[0].end_offset_exclusive #=> Integer
resp.recommendations[0].document.excerpt.text #=> String
resp.recommendations[0].document.title.highlights #=> Array
resp.recommendations[0].document.title.highlights[0].begin_offset_inclusive #=> Integer
resp.recommendations[0].document.title.highlights[0].end_offset_exclusive #=> Integer
resp.recommendations[0].document.title.text #=> String
resp.recommendations[0].recommendation_id #=> String
resp.recommendations[0].relevance_level #=> String, one of "HIGH", "MEDIUM", "LOW"
resp.recommendations[0].relevance_score #=> Float
resp.recommendations