updateAutomatedReasoningPolicy method
Updates an existing Automated Reasoning policy with new rules, variables, or configuration. This creates a new version of the policy while preserving the previous version.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw TooManyTagsException.
May throw ValidationException.
Parameter policyArn :
The Amazon Resource Name (ARN) of the Automated Reasoning policy to
update. This must be the ARN of a draft policy.
Parameter policyDefinition :
The updated policy definition containing the formal logic rules,
variables, and types.
Parameter description :
The updated description for the Automated Reasoning policy.
Parameter name :
The updated name for the Automated Reasoning policy.
Implementation
Future<UpdateAutomatedReasoningPolicyResponse>
updateAutomatedReasoningPolicy({
required String policyArn,
required AutomatedReasoningPolicyDefinition policyDefinition,
String? description,
String? name,
}) async {
final $payload = <String, dynamic>{
'policyDefinition': policyDefinition,
if (description != null) 'description': description,
if (name != null) 'name': name,
};
final response = await _protocol.send(
payload: $payload,
method: 'PATCH',
requestUri:
'/automated-reasoning-policies/${Uri.encodeComponent(policyArn)}',
exceptionFnMap: _exceptionFns,
);
return UpdateAutomatedReasoningPolicyResponse.fromJson(response);
}