deleteApp method

Future<DeleteAppResponse> deleteApp({
  1. required String appArn,
  2. String? clientToken,
  3. bool? forceDelete,
})

Deletes an Resilience Hub application. This is a destructive action that can't be undone.

May throw ConflictException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ThrottlingException. May throw ValidationException.

Parameter appArn : Amazon Resource Name (ARN) of the Resilience Hub application. The format for this ARN is: arn:partition:resiliencehub:region:account:app/app-id. For more information about ARNs, see Amazon Resource Names (ARNs) in the Amazon Web Services General Reference guide.

Parameter clientToken : Used for an idempotency token. A client token is a unique, case-sensitive string of up to 64 ASCII characters. You should not reuse the same client token for other API requests.

Parameter forceDelete : A boolean option to force the deletion of an Resilience Hub application.

Implementation

Future<DeleteAppResponse> deleteApp({
  required String appArn,
  String? clientToken,
  bool? forceDelete,
}) async {
  final $payload = <String, dynamic>{
    'appArn': appArn,
    'clientToken': clientToken ?? _s.generateIdempotencyToken(),
    if (forceDelete != null) 'forceDelete': forceDelete,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'POST',
    requestUri: '/delete-app',
    exceptionFnMap: _exceptionFns,
  );
  return DeleteAppResponse.fromJson(response);
}