startNotebookImport method
Starts a notebook import in Amazon SageMaker Unified Studio. This operation imports a notebook from an Amazon Simple Storage Service location into a project.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ServiceQuotaExceededException.
May throw ThrottlingException.
May throw ValidationException.
Parameter domainIdentifier :
The identifier of the Amazon SageMaker Unified Studio domain in which to
import the notebook.
Parameter name :
The name of the imported notebook. The name must be between 1 and 256
characters.
Parameter owningProjectIdentifier :
The identifier of the project that will own the imported notebook.
Parameter sourceLocation :
The source location of the notebook to import. This specifies the Amazon
Simple Storage Service URI of the notebook file.
Parameter clientToken :
A unique, case-sensitive identifier to ensure idempotency of the request.
This field is automatically populated if not provided.
Parameter description :
The description of the imported notebook.
Implementation
Future<StartNotebookImportOutput> startNotebookImport({
required String domainIdentifier,
required String name,
required String owningProjectIdentifier,
required SourceLocation sourceLocation,
String? clientToken,
String? description,
}) async {
final $payload = <String, dynamic>{
'name': name,
'owningProjectIdentifier': owningProjectIdentifier,
'sourceLocation': sourceLocation,
'clientToken': clientToken ?? _s.generateIdempotencyToken(),
if (description != null) 'description': description,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri:
'/v2/domains/${Uri.encodeComponent(domainIdentifier)}/notebook-imports',
exceptionFnMap: _exceptionFns,
);
return StartNotebookImportOutput.fromJson(response);
}