updateFlow method
Updates an existing flow.
May throw AccessDeniedException.
May throw ConflictException.
May throw ConnectorAuthenticationException.
May throw ConnectorServerException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ServiceQuotaExceededException.
May throw ValidationException.
Parameter destinationFlowConfigList :
The configuration that controls how Amazon AppFlow transfers data to the
destination connector.
Parameter flowName :
The specified name of the flow. Spaces are not allowed. Use underscores
(_) or hyphens (-) only.
Parameter tasks :
A list of tasks that Amazon AppFlow performs while transferring the data
in the flow run.
Parameter triggerConfig :
The trigger settings that determine how and when the flow runs.
Parameter clientToken :
The clientToken parameter is an idempotency token. It ensures
that your UpdateFlow request completes only once. You choose
the value to pass. For example, if you don't receive a response from your
request, you can safely retry the request with the same
clientToken parameter value.
If you omit a clientToken value, the Amazon Web Services SDK
that you are using inserts a value for you. This way, the SDK can safely
retry requests multiple times after a network error. You must provide your
own value for other use cases.
If you specify input parameters that differ from your first request, an
error occurs. If you use a different value for clientToken,
Amazon AppFlow considers it a new call to UpdateFlow. The
token is active for 8 hours.
Parameter description :
A description of the flow.
Parameter metadataCatalogConfig :
Specifies the configuration that Amazon AppFlow uses when it catalogs the
data that's transferred by the associated flow. When Amazon AppFlow
catalogs the data from a flow, it stores metadata in a data catalog.
Implementation
Future<UpdateFlowResponse> updateFlow({
required List<DestinationFlowConfig> destinationFlowConfigList,
required String flowName,
required SourceFlowConfig sourceFlowConfig,
required List<Task> tasks,
required TriggerConfig triggerConfig,
String? clientToken,
String? description,
MetadataCatalogConfig? metadataCatalogConfig,
}) async {
final $payload = <String, dynamic>{
'destinationFlowConfigList': destinationFlowConfigList,
'flowName': flowName,
'sourceFlowConfig': sourceFlowConfig,
'tasks': tasks,
'triggerConfig': triggerConfig,
'clientToken': clientToken ?? _s.generateIdempotencyToken(),
if (description != null) 'description': description,
if (metadataCatalogConfig != null)
'metadataCatalogConfig': metadataCatalogConfig,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/update-flow',
exceptionFnMap: _exceptionFns,
);
return UpdateFlowResponse.fromJson(response);
}