createDataIntegrationFlow method
Enables you to programmatically create a data pipeline to ingest data from source systems such as Amazon S3 buckets, to a predefined Amazon Web Services Supply Chain dataset (product, inbound_order) or a temporary dataset along with the data transformation query provided with the API.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ServiceQuotaExceededException.
May throw ThrottlingException.
May throw ValidationException.
Parameter instanceId :
The Amazon Web Services Supply Chain instance identifier.
Parameter name :
Name of the DataIntegrationFlow.
Parameter sources :
The source configurations for DataIntegrationFlow.
Parameter target :
The target configurations for DataIntegrationFlow.
Parameter transformation :
The transformation configurations for DataIntegrationFlow.
Parameter tags :
The tags of the DataIntegrationFlow to be created
Implementation
Future<CreateDataIntegrationFlowResponse> createDataIntegrationFlow({
required String instanceId,
required String name,
required List<DataIntegrationFlowSource> sources,
required DataIntegrationFlowTarget target,
required DataIntegrationFlowTransformation transformation,
Map<String, String>? tags,
}) async {
final $payload = <String, dynamic>{
'sources': sources,
'target': target,
'transformation': transformation,
if (tags != null) 'tags': tags,
};
final response = await _protocol.send(
payload: $payload,
method: 'PUT',
requestUri:
'/api/data-integration/instance/${Uri.encodeComponent(instanceId)}/data-integration-flows/${Uri.encodeComponent(name)}',
exceptionFnMap: _exceptionFns,
);
return CreateDataIntegrationFlowResponse.fromJson(response);
}