Menu
AWS Storage Gateway Service
API Reference (API Version 2013-06-30)

DescribeTapes

Returns a description of the specified Amazon Resource Name (ARN) of virtual tapes. If a TapeARN is not specified, returns a description of all virtual tapes associated with the specified gateway. This operation is only supported in the tape gateway type.

Request Syntax

{
   "GatewayARN": "string",
   "Limit": number,
   "Marker": "string",
   "TapeARNs": [ "string" ]
}

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

GatewayARN

The Amazon Resource Name (ARN) of the gateway. Use the ListGateways operation to return a list of gateways for your account and region.

Type: String

Length Constraints: Minimum length of 50. Maximum length of 500.

Required: Yes

Limit

Specifies that the number of virtual tapes described be limited to the specified number.

Note

Amazon Web Services may impose its own limit, if this field is not set.

Type: Integer

Valid Range: Minimum value of 1.

Required: No

Marker

A marker value, obtained in a previous call to DescribeTapes. This marker indicates which page of results to retrieve.

If not specified, the first page of results is retrieved.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1000.

Required: No

TapeARNs

Specifies one or more unique Amazon Resource Names (ARNs) that represent the virtual tapes you want to describe. If this parameter is not specified, Tape gateway returns a description of all virtual tapes associated with the specified gateway.

Type: Array of strings

Length Constraints: Minimum length of 50. Maximum length of 500.

Pattern: ^arn:(aws|aws-cn):storagegateway:[a-z\-0-9]+:[0-9]+:tape\/[0-9A-Z]{7,16}$

Required: No

Response Syntax

{
   "Marker": "string",
   "Tapes": [ 
      { 
         "Progress": number,
         "TapeARN": "string",
         "TapeBarcode": "string",
         "TapeCreatedDate": number,
         "TapeSizeInBytes": number,
         "TapeStatus": "string",
         "TapeUsedInBytes": number,
         "VTLDevice": "string"
      }
   ]
}

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

Marker

An opaque string which can be used as part of a subsequent DescribeTapes call to retrieve the next page of results.

If a response does not contain a marker, then there are no more results to be retrieved.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1000.

Tapes

An array of virtual tape descriptions.

Type: Array of Tape objects

Errors

For information about the errors that are common to all actions, see Common Errors.

InternalServerError

An internal server error has occurred during the request. For more information, see the error and message fields.

HTTP Status Code: 400

InvalidGatewayRequestException

An exception occurred because an invalid gateway request was issued to the service. For more information, see the error and message fields.

HTTP Status Code: 400

Example

Get descriptions of specific tapes

In the following request you obtain descriptions of tapes in the tape gateway with ID sgw-12A3456B. The request identifies specific tapes by specifying ARNs for the tapes. In the ARN, the trailing string, for example "TEST04A2A1"- is the tape barcode value. The string 999999999999 is your account number.

Sample Request

{"GatewayARN": "arn:aws:storagegateway:us-east-2:999999999999:gateway/sgw-12A3456B",
 "TapeARNs":
  ["arn:aws:storagegateway:us-east-2:999999999999:tape/TEST04A2A1",
   "arn:aws:storagegateway:us-east-2:999999999999:tape/TEST05A2A0"]
}}}
            

Sample Response

{"Tapes":
  [
    {"TapeARN": "arn:aws:storagegateway:us-east-2:999999999999:tape/TEST04A2A1",
     "TapeBarcode": "TEST04A2A1",
     "TapeSizeInBytes": 107374182400,
     "TapeStatus": "AVAILABLE"},
    {"TapeARN": "arn:aws:storagegateway:us-east-2:999999999999:tape/TEST05A2A0",
     "TapeBarcode": "TEST05A2A0",
     "TapeSizeInBytes": 107374182400,
     "TapeStatus": "AVAILABLE"}
  ]
}
}
            

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: