async def create_blueprint(
self,
blueprint_name: "capo_bedrock_data_automation.types.blueprint_name.BlueprintName",
type: "capo_bedrock_data_automation.types.type.Type",
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,
client_token: Optional[
"capo_bedrock_data_automation.types.client_token.ClientToken"
] = None,
encryption_configuration: Optional[
"capo_bedrock_data_automation.types.encryption_configuration.EncryptionConfiguration"
] = None,
tags: Optional["capo_bedrock_data_automation.types.tag_list.TagList"] = None,
) -> "capo_bedrock_data_automation.types.create_blueprint_response.CreateBlueprintResponse":
"""Creates an Amazon Bedrock Data Automation Blueprint
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.service_quota_exceeded_exception.ServiceQuotaExceededException: This exception is thrown when a request is made beyond the service quota
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.create_blueprint_request.CreateBlueprintRequest]",
) -> AsyncOperationResponse[
"capo_bedrock_data_automation.types.create_blueprint_response.CreateBlueprintResponse"
]:
import capo_bedrock_data_automation._operations.amazon_bedrock_keystone_build_time_service.create_blueprint
(
output,
http_response,
) = await capo_bedrock_data_automation._operations.amazon_bedrock_keystone_build_time_service.create_blueprint.async_create_blueprint(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
def _redact_input(
input_: "capo_bedrock_data_automation.types.create_blueprint_request.CreateBlueprintRequest",
) -> dict[str, Any]:
import capo_bedrock_data_automation.types.create_blueprint_request
return capo_bedrock_data_automation.types.create_blueprint_request.redact_sensitive(
input_
)
def _redact_output(
output: "capo_bedrock_data_automation.types.create_blueprint_response.CreateBlueprintResponse",
) -> dict[str, Any]:
import capo_bedrock_data_automation.types.create_blueprint_response
return capo_bedrock_data_automation.types.create_blueprint_response.redact_sensitive(
output
)
interceptors_, options_ = self.operation_options(
config_overrides,
OperationLogging(
"CreateBlueprint",
redact_input=_redact_input,
redact_output=_redact_output,
),
)
input_: capo_bedrock_data_automation.types.create_blueprint_request.CreateBlueprintRequest = {
"blueprint_name": blueprint_name,
"type": type,
"schema": schema,
}
if blueprint_stage is not None:
input_["blueprint_stage"] = blueprint_stage
if client_token is None:
client_token = str(uuid.uuid4())
input_["client_token"] = client_token
if encryption_configuration is not None:
input_["encryption_configuration"] = encryption_configuration
if tags is not None:
input_["tags"] = tags
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output