describeVolumes method
Describes one or more Amazon FSx for NetApp ONTAP or Amazon FSx for OpenZFS volumes.
May throw BadRequest.
May throw InternalServerError.
May throw VolumeNotFound.
Parameter filters :
Enter a filter Name and Values pair to view a
select set of volumes.
Parameter volumeIds :
The IDs of the volumes whose descriptions you want to retrieve.
Implementation
Future<DescribeVolumesResponse> describeVolumes({
List<VolumeFilter>? filters,
int? maxResults,
String? nextToken,
List<String>? volumeIds,
}) async {
_s.validateNumRange(
'maxResults',
maxResults,
1,
2147483647,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'AWSSimbaAPIService_v20180301.DescribeVolumes'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
if (filters != null) 'Filters': filters,
if (maxResults != null) 'MaxResults': maxResults,
if (nextToken != null) 'NextToken': nextToken,
if (volumeIds != null) 'VolumeIds': volumeIds,
},
);
return DescribeVolumesResponse.fromJson(jsonResponse.body);
}