update_prompt
¶
update_prompt(
name: PromptName,
prompt_identifier: PromptIdentifier,
*,
config_overrides: Optional[BedrockAgentClientConfig] = None,
description: Optional[PromptDescription] = None,
customer_encryption_key_arn: Optional[KmsKeyArn] = None,
default_variant: Optional[PromptVariantName] = None,
variants: Optional[PromptVariantList] = None,
) -> UpdatePromptResponse
Modifies a prompt in your prompt library. Include both fields that you want to keep and fields that you want to replace. For more information, see Prompt management in Amazon Bedrock and Edit prompts in your prompt library in the Amazon Bedrock User Guide.
Parameters:
-
name(PromptName) –A name for the prompt.
-
description(Optional[PromptDescription], default:None) –A description for the prompt.
-
customer_encryption_key_arn(Optional[KmsKeyArn], default:None) –The Amazon Resource Name (ARN) of the KMS key to encrypt the prompt.
-
default_variant(Optional[PromptVariantName], default:None) –The name of the default variant for the prompt. This value must match the
namefield in the relevant PromptVariant object. -
variants(Optional[PromptVariantList], default:None) –A list of objects, each containing details about a variant of the prompt.
-
prompt_identifier(PromptIdentifier) –The unique identifier of the prompt.
Raises:
-
AccessDeniedException–The request is denied because of missing access permissions.
-
ConflictException–There was a conflict performing an operation.
-
InternalServerException–An internal server error occurred. Retry your request.
-
ResourceNotFoundException–The specified resource Amazon Resource Name (ARN) was not found. Check the Amazon Resource Name (ARN) and try your request again.
-
ServiceQuotaExceededException–The number of requests exceeds the service quota. Resubmit your request later.
-
ThrottlingException–The number of requests exceeds the limit. Resubmit your request later.
-
ValidationException–Input validation failed. Check your request parameters and retry the request.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_bedrock_agent/_services/bedrock_agent.py
5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 | |