createDataIntegrationAssociation method
Creates and persists a DataIntegrationAssociation resource.
May throw AccessDeniedException.
May throw InternalServiceError.
May throw InvalidRequestException.
May throw ResourceNotFoundException.
May throw ResourceQuotaExceededException.
May throw ThrottlingException.
Parameter dataIntegrationIdentifier :
A unique identifier for the DataIntegration.
Parameter clientAssociationMetadata :
The mapping of metadata to be extracted from the data.
Parameter clientId :
The identifier for the client that is associated with the DataIntegration
association.
Parameter clientToken :
A unique, case-sensitive identifier that you provide to ensure the
idempotency of the request. If not provided, the Amazon Web Services SDK
populates this field. For more information about idempotency, see Making
retries safe with idempotent APIs.
Parameter destinationURI :
The URI of the data destination.
Parameter executionConfiguration :
The configuration for how the files should be pulled from the source.
Implementation
Future<CreateDataIntegrationAssociationResponse>
createDataIntegrationAssociation({
required String dataIntegrationIdentifier,
Map<String, String>? clientAssociationMetadata,
String? clientId,
String? clientToken,
String? destinationURI,
ExecutionConfiguration? executionConfiguration,
Map<String, Map<String, List<String>>>? objectConfiguration,
}) async {
final $payload = <String, dynamic>{
if (clientAssociationMetadata != null)
'ClientAssociationMetadata': clientAssociationMetadata,
if (clientId != null) 'ClientId': clientId,
'ClientToken': clientToken ?? _s.generateIdempotencyToken(),
if (destinationURI != null) 'DestinationURI': destinationURI,
if (executionConfiguration != null)
'ExecutionConfiguration': executionConfiguration,
if (objectConfiguration != null)
'ObjectConfiguration': objectConfiguration,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri:
'/dataIntegrations/${Uri.encodeComponent(dataIntegrationIdentifier)}/associations',
exceptionFnMap: _exceptionFns,
);
return CreateDataIntegrationAssociationResponse.fromJson(response);
}