putRetentionSettings method
- required String accountId,
- required RetentionSettings retentionSettings,
Puts retention settings for the specified Amazon Chime Enterprise account. We recommend using AWS CloudTrail to monitor usage of this API for your account. For more information, see Logging Amazon Chime API Calls with AWS CloudTrail in the Amazon Chime Administration Guide.
To turn off existing retention settings, remove the number of days from the corresponding RetentionDays field in the RetentionSettings object. For more information about retention settings, see Managing Chat Retention Policies in the Amazon Chime Administration Guide.
May throw BadRequestException.
May throw ConflictException.
May throw ForbiddenException.
May throw NotFoundException.
May throw ServiceFailureException.
May throw ServiceUnavailableException.
May throw ThrottledClientException.
May throw UnauthorizedClientException.
Parameter accountId :
The Amazon Chime account ID.
Parameter retentionSettings :
The retention settings.
Implementation
Future<PutRetentionSettingsResponse> putRetentionSettings({
required String accountId,
required RetentionSettings retentionSettings,
}) async {
final $payload = <String, dynamic>{
'RetentionSettings': retentionSettings,
};
final response = await _protocol.send(
payload: $payload,
method: 'PUT',
requestUri:
'/accounts/${Uri.encodeComponent(accountId)}/retention-settings',
exceptionFnMap: _exceptionFns,
);
return PutRetentionSettingsResponse.fromJson(response);
}