deleteTapePool method
Delete a custom tape pool. A custom tape pool can only be deleted if there are no tapes in the pool and if there are no automatic tape creation policies that reference the custom tape pool.
May throw InvalidGatewayRequestException. May throw InternalServerError.
Parameter poolARN
:
The Amazon Resource Name (ARN) of the custom tape pool to delete.
Implementation
Future<DeleteTapePoolOutput> deleteTapePool({
required String poolARN,
}) async {
ArgumentError.checkNotNull(poolARN, 'poolARN');
_s.validateStringLength(
'poolARN',
poolARN,
50,
500,
isRequired: true,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'StorageGateway_20130630.DeleteTapePool'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'PoolARN': poolARN,
},
);
return DeleteTapePoolOutput.fromJson(jsonResponse.body);
}