deleteResiliencyPolicy method
Deletes a resiliency policy. This is a destructive action that can't be undone.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter policyArn :
Amazon Resource Name (ARN) of the resiliency policy. The format for this
ARN is:
arn:partition:resiliencehub:region:account:resiliency-policy/policy-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.
Implementation
Future<DeleteResiliencyPolicyResponse> deleteResiliencyPolicy({
required String policyArn,
String? clientToken,
}) async {
final $payload = <String, dynamic>{
'policyArn': policyArn,
'clientToken': clientToken ?? _s.generateIdempotencyToken(),
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/delete-resiliency-policy',
exceptionFnMap: _exceptionFns,
);
return DeleteResiliencyPolicyResponse.fromJson(response);
}