deleteHealthCheck method

Future<void> deleteHealthCheck({
  1. required String healthCheckId,
})

Deletes a health check. If you're using AWS Cloud Map and you configured Cloud Map to create a Route 53 health check when you register an instance, you can't use the Route 53 DeleteHealthCheck command to delete the health check. The health check is deleted automatically when you deregister the instance; there can be a delay of several hours before the health check is deleted from Route 53.

May throw NoSuchHealthCheck. May throw HealthCheckInUse. May throw InvalidInput.

Parameter healthCheckId : The ID of the health check that you want to delete.

Implementation

Future<void> deleteHealthCheck({
  required String healthCheckId,
}) async {
  ArgumentError.checkNotNull(healthCheckId, 'healthCheckId');
  _s.validateStringLength(
    'healthCheckId',
    healthCheckId,
    0,
    64,
    isRequired: true,
  );
  await _protocol.send(
    method: 'DELETE',
    requestUri:
        '/2013-04-01/healthcheck/${Uri.encodeComponent(healthCheckId)}',
    exceptionFnMap: _exceptionFns,
  );
}