create_knowledge_base
async
¶
create_knowledge_base(
name: Name,
knowledge_base_type: KnowledgeBaseType,
*,
config_overrides: Optional[AsyncQConnectClientConfig] = None,
client_token: Optional[NonEmptyString] = None,
source_configuration: Optional[SourceConfiguration] = None,
rendering_configuration: Optional[RenderingConfiguration] = None,
vector_ingestion_configuration: Optional[VectorIngestionConfiguration] = None,
server_side_encryption_configuration: Optional[
ServerSideEncryptionConfiguration
] = None,
description: Optional[Description] = None,
tags: Optional[Tags] = None,
) -> 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:
-
Call DeleteKnowledgeBase.
-
Call DeleteDataIntegration.
-
Call CreateDataIntegration to recreate the DataIntegration or a create different one.
-
Call CreateKnowledgeBase.
Parameters:
-
client_token(Optional[NonEmptyString], default:None) –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.
-
name(Name) –The name of the knowledge base.
-
knowledge_base_type(KnowledgeBaseType) –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.
-
source_configuration(Optional[SourceConfiguration], default:None) –The source of the knowledge base content. Only set this argument for EXTERNAL or Managed knowledge bases.
-
rendering_configuration(Optional[RenderingConfiguration], default:None) –Information about how to render the content.
-
vector_ingestion_configuration(Optional[VectorIngestionConfiguration], default:None) –Contains details about how to ingest the documents in a data source.
-
server_side_encryption_configuration(Optional[ServerSideEncryptionConfiguration], default:None) –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, andkms: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.
-
description(Optional[Description], default:None) –The description.
-
tags(Optional[Tags], default:None) –The tags used to organize, track, or control access for this resource.
Raises:
-
AccessDeniedException–You do not have sufficient access to perform this action.
-
ConflictException–The request could not be processed because of conflict in the current state of the resource. For example, if you're using a
CreateAPI (such asCreateAssistant) that accepts name, a conflicting resource (usually with the same name) is being created or mutated. -
ServiceQuotaExceededException–You've exceeded your service quota. To perform the requested action, remove some of the relevant resources, or use service quotas to request a service quota increase.
-
UnauthorizedException–You do not have permission to perform this action.
-
ValidationException–The input fails to satisfy the constraints specified by a service.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_qconnect/_services/async_q_connect.py
4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 | |