getResourceSyncStatus method

Future<GetResourceSyncStatusOutput> getResourceSyncStatus({
  1. required String resourceName,
  2. required SyncConfigurationType syncType,
})

Returns the status of the sync with the Git repository for a specific Amazon Web Services resource.

May throw AccessDeniedException. May throw InternalServerException. May throw InvalidInputException. May throw ResourceNotFoundException. May throw ThrottlingException.

Parameter resourceName : The name of the Amazon Web Services resource for the sync status with the Git repository.

Parameter syncType : The sync type for the sync status with the Git repository.

Implementation

Future<GetResourceSyncStatusOutput> getResourceSyncStatus({
  required String resourceName,
  required SyncConfigurationType syncType,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.0',
    'X-Amz-Target': 'CodeStar_connections_20191201.GetResourceSyncStatus'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'ResourceName': resourceName,
      'SyncType': syncType.value,
    },
  );

  return GetResourceSyncStatusOutput.fromJson(jsonResponse.body);
}