Skip to content

update_blueprint async

update_blueprint(
    blueprint_arn: BlueprintArn,
    schema: BlueprintSchema,
    *,
    config_overrides: Optional[AsyncBedrockDataAutomationClientConfig] = None,
    blueprint_stage: Optional[BlueprintStage] = None,
    encryption_configuration: Optional[EncryptionConfiguration] = None,
) -> UpdateBlueprintResponse

Updates an existing Amazon Bedrock Data Automation Blueprint

Parameters:

  • blueprint_arn (BlueprintArn) –

    ARN generated at the server side when a Blueprint is created

Raises:

Source code in docs_src/capo_bedrock_data_automation/_services/async_bedrock_data_automation.py
async def update_blueprint(
    self,
    blueprint_arn: "capo_bedrock_data_automation.types.blueprint_arn.BlueprintArn",
    schema: "capo_bedrock_data_automation.types.blueprint_schema.BlueprintSchema",
    *,
    config_overrides: Optional[AsyncBedrockDataAutomationClientConfig] = None,
    blueprint_stage: Optional[
        "capo_bedrock_data_automation.types.blueprint_stage.BlueprintStage"
    ] = None,
    encryption_configuration: Optional[
        "capo_bedrock_data_automation.types.encryption_configuration.EncryptionConfiguration"
    ] = None,
) -> "capo_bedrock_data_automation.types.update_blueprint_response.UpdateBlueprintResponse":
    """Updates an existing Amazon Bedrock Data Automation Blueprint

    Args:
        blueprint_arn: ARN generated at the server side when a Blueprint is created

    Raises:
        capo_bedrock_data_automation.errors.access_denied_exception.AccessDeniedException: This exception is thrown when a request is denied per access permissions
        capo_bedrock_data_automation.errors.conflict_exception.ConflictException: This exception is thrown when there is a conflict performing an operation
        capo_bedrock_data_automation.errors.internal_server_exception.InternalServerException: This exception is thrown if there was an unexpected error during processing of request
        capo_bedrock_data_automation.errors.resource_not_found_exception.ResourceNotFoundException: This exception is thrown when a resource referenced by the operation does not exist
        capo_bedrock_data_automation.errors.throttling_exception.ThrottlingException: This exception is thrown when the number of requests exceeds the limit
        capo_bedrock_data_automation.errors.validation_exception.ValidationException: This exception is thrown when the request's input validation fails
        capo_bedrock_data_automation.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_bedrock_data_automation.types.update_blueprint_request.UpdateBlueprintRequest]",
    ) -> AsyncOperationResponse[
        "capo_bedrock_data_automation.types.update_blueprint_response.UpdateBlueprintResponse"
    ]:
        import capo_bedrock_data_automation._operations.amazon_bedrock_keystone_build_time_service.update_blueprint

        (
            output,
            http_response,
        ) = await capo_bedrock_data_automation._operations.amazon_bedrock_keystone_build_time_service.update_blueprint.async_update_blueprint(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_input(
        input_: "capo_bedrock_data_automation.types.update_blueprint_request.UpdateBlueprintRequest",
    ) -> dict[str, Any]:
        import capo_bedrock_data_automation.types.update_blueprint_request

        return capo_bedrock_data_automation.types.update_blueprint_request.redact_sensitive(
            input_
        )

    def _redact_output(
        output: "capo_bedrock_data_automation.types.update_blueprint_response.UpdateBlueprintResponse",
    ) -> dict[str, Any]:
        import capo_bedrock_data_automation.types.update_blueprint_response

        return capo_bedrock_data_automation.types.update_blueprint_response.redact_sensitive(
            output
        )

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging(
            "UpdateBlueprint",
            redact_input=_redact_input,
            redact_output=_redact_output,
        ),
    )
    input_: capo_bedrock_data_automation.types.update_blueprint_request.UpdateBlueprintRequest = {
        "blueprint_arn": blueprint_arn,
        "schema": schema,
    }
    if blueprint_stage is not None:
        input_["blueprint_stage"] = blueprint_stage
    if encryption_configuration is not None:
        input_["encryption_configuration"] = encryption_configuration

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output