StorageGateway / Client / list_tapes
list_tapes#
- StorageGateway.Client.list_tapes(**kwargs)#
Lists virtual tapes in your virtual tape library (VTL) and your virtual tape shelf (VTS). You specify the tapes to list by specifying one or more tape Amazon Resource Names (ARNs). If you don’t specify a tape ARN, the operation lists all virtual tapes in both your VTL and VTS.
This operation supports pagination. By default, the operation returns a maximum of up to 100 tapes. You can optionally specify the
Limit
parameter in the body to limit the number of tapes in the response. If the number of tapes returned in the response is truncated, the response includes aMarker
element that you can use in your subsequent request to retrieve the next set of tapes. This operation is only supported in the tape gateway type.See also: AWS API Documentation
Request Syntax
response = client.list_tapes( TapeARNs=[ 'string', ], Marker='string', Limit=123 )
- Parameters:
TapeARNs (list) –
The Amazon Resource Name (ARN) of each of the tapes you want to list. If you don’t specify a tape ARN, the response lists all tapes in both your VTL and VTS.
(string) –
Marker (string) – A string that indicates the position at which to begin the returned list of tapes.
Limit (integer) – An optional number limit for the tapes in the list returned by this call.
- Return type:
dict
- Returns:
Response Syntax
{ 'TapeInfos': [ { 'TapeARN': 'string', 'TapeBarcode': 'string', 'TapeSizeInBytes': 123, 'TapeStatus': 'string', 'GatewayARN': 'string', 'PoolId': 'string', 'RetentionStartDate': datetime(2015, 1, 1), 'PoolEntryDate': datetime(2015, 1, 1) }, ], 'Marker': 'string' }
Response Structure
(dict) –
A JSON object containing the following fields:
ListTapesOutput$Marker
ListTapesOutput$VolumeInfos
TapeInfos (list) –
An array of TapeInfo objects, where each object describes a single tape. If there are no tapes in the tape library or VTS, then the
TapeInfos
is an empty array.(dict) –
Describes a virtual tape.
TapeARN (string) –
The Amazon Resource Name (ARN) of a virtual tape.
TapeBarcode (string) –
The barcode that identifies a specific virtual tape.
TapeSizeInBytes (integer) –
The size, in bytes, of a virtual tape.
TapeStatus (string) –
The status of the tape.
GatewayARN (string) –
The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and Amazon Web Services Region.
PoolId (string) –
The ID of the pool that you want to add your tape to for archiving. The tape in this pool is archived in the S3 storage class that is associated with the pool. When you use your backup application to eject the tape, the tape is archived directly into the storage class (S3 Glacier or S3 Glacier Deep Archive) that corresponds to the pool.
RetentionStartDate (datetime) –
The date that the tape became subject to tape retention lock.
PoolEntryDate (datetime) –
The date that the tape entered the custom tape pool with tape retention lock enabled.
Marker (string) –
A string that indicates the position at which to begin returning the next list of tapes. Use the marker in your next request to continue pagination of tapes. If there are no more tapes to list, this element does not appear in the response body.
Exceptions
StorageGateway.Client.exceptions.InvalidGatewayRequestException
StorageGateway.Client.exceptions.InternalServerError