deleteBandwidthRateLimit method
Deletes the bandwidth rate limits of a gateway. You can delete either the upload and download bandwidth rate limit, or you can delete both. If you delete only one of the limits, the other limit remains unchanged. To specify which gateway to work with, use the Amazon Resource Name (ARN) of the gateway in your request. This operation is supported for the stored volume, cached volume and tape gateway types.
May throw InvalidGatewayRequestException. May throw InternalServerError.
Parameter bandwidthType
:
One of the BandwidthType values that indicates the gateway bandwidth rate
limit to delete.
Valid Values: UPLOAD
| DOWNLOAD
|
ALL
Implementation
Future<DeleteBandwidthRateLimitOutput> deleteBandwidthRateLimit({
required String bandwidthType,
required String gatewayARN,
}) async {
ArgumentError.checkNotNull(bandwidthType, 'bandwidthType');
_s.validateStringLength(
'bandwidthType',
bandwidthType,
3,
25,
isRequired: true,
);
ArgumentError.checkNotNull(gatewayARN, 'gatewayARN');
_s.validateStringLength(
'gatewayARN',
gatewayARN,
50,
500,
isRequired: true,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'StorageGateway_20130630.DeleteBandwidthRateLimit'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'BandwidthType': bandwidthType,
'GatewayARN': gatewayARN,
},
);
return DeleteBandwidthRateLimitOutput.fromJson(jsonResponse.body);
}