createProject method

Future<CreateProjectResponse> createProject({
  1. required String datasetName,
  2. required String name,
  3. required String recipeName,
  4. required String roleArn,
  5. Sample? sample,
  6. Map<String, String>? tags,
})

Creates a new DataBrew project.

May throw ConflictException. May throw InternalServerException. May throw ServiceQuotaExceededException. May throw ValidationException.

Parameter datasetName : The name of an existing dataset to associate this project with.

Parameter name : A unique name for the new project. Valid characters are alphanumeric (A-Z, a-z, 0-9), hyphen (-), period (.), and space.

Parameter recipeName : The name of an existing recipe to associate with the project.

Parameter roleArn : The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role to be assumed for this request.

Parameter tags : Metadata tags to apply to this project.

Implementation

Future<CreateProjectResponse> createProject({
  required String datasetName,
  required String name,
  required String recipeName,
  required String roleArn,
  Sample? sample,
  Map<String, String>? tags,
}) async {
  final $payload = <String, dynamic>{
    'DatasetName': datasetName,
    'Name': name,
    'RecipeName': recipeName,
    'RoleArn': roleArn,
    if (sample != null) 'Sample': sample,
    if (tags != null) 'Tags': tags,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/projects',
    exceptionFnMap: _exceptionFns,
  );
  return CreateProjectResponse.fromJson(response);
}