describeVTLDevices method

Future<DescribeVTLDevicesOutput> describeVTLDevices({
  1. required String gatewayARN,
  2. int? limit,
  3. String? marker,
  4. List<String>? vTLDeviceARNs,
})

Returns a description of virtual tape library (VTL) devices for the specified tape gateway. In the response, AWS Storage Gateway returns VTL device information.

This operation is only supported in the tape gateway type.

May throw InvalidGatewayRequestException. May throw InternalServerError.

Parameter limit : Specifies that the number of VTL devices described be limited to the specified number.

Parameter marker : An opaque string that indicates the position at which to begin describing the VTL devices.

Parameter vTLDeviceARNs : An array of strings, where each string represents the Amazon Resource Name (ARN) of a VTL device.

Implementation

Future<DescribeVTLDevicesOutput> describeVTLDevices({
  required String gatewayARN,
  int? limit,
  String? marker,
  List<String>? vTLDeviceARNs,
}) async {
  ArgumentError.checkNotNull(gatewayARN, 'gatewayARN');
  _s.validateStringLength(
    'gatewayARN',
    gatewayARN,
    50,
    500,
    isRequired: true,
  );
  _s.validateNumRange(
    'limit',
    limit,
    1,
    1152921504606846976,
  );
  _s.validateStringLength(
    'marker',
    marker,
    1,
    1000,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'StorageGateway_20130630.DescribeVTLDevices'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'GatewayARN': gatewayARN,
      if (limit != null) 'Limit': limit,
      if (marker != null) 'Marker': marker,
      if (vTLDeviceARNs != null) 'VTLDeviceARNs': vTLDeviceARNs,
    },
  );

  return DescribeVTLDevicesOutput.fromJson(jsonResponse.body);
}