updateMacieSession method

Future<void> updateMacieSession({
  1. FindingPublishingFrequency? findingPublishingFrequency,
  2. MacieStatus? status,
})

Suspends or re-enables Amazon Macie, or updates the configuration settings for a Macie account.

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

Parameter findingPublishingFrequency : Specifies how often to publish updates to policy findings for the account. This includes publishing updates to Security Hub and Amazon EventBridge (formerly Amazon CloudWatch Events).

Parameter status : Specifies a new status for the account. Valid values are: ENABLED, resume all Amazon Macie activities for the account; and, PAUSED, suspend all Macie activities for the account.

Implementation

Future<void> updateMacieSession({
  FindingPublishingFrequency? findingPublishingFrequency,
  MacieStatus? status,
}) async {
  final $payload = <String, dynamic>{
    if (findingPublishingFrequency != null)
      'findingPublishingFrequency': findingPublishingFrequency.value,
    if (status != null) 'status': status.value,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'PATCH',
    requestUri: '/macie',
    exceptionFnMap: _exceptionFns,
  );
}