Menu
Amazon Relational Database Service
API Reference (API Version 2014-10-31)

DescribeDBSnapshots

Returns information about DB snapshots. This API action supports pagination.

Request Parameters

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

DBInstanceIdentifier

The ID of the DB instance to retrieve the list of DB snapshots for. This parameter can't be used in conjunction with DBSnapshotIdentifier. This parameter is not case-sensitive.

Constraints:

  • If supplied, must match the identifier of an existing DBInstance.

Type: String

Required: No

DBSnapshotIdentifier

A specific DB snapshot identifier to describe. This parameter can't be used in conjunction with DBInstanceIdentifier. This value is stored as a lowercase string.

Constraints:

  • If supplied, must match the identifier of an existing DBSnapshot.

  • If this identifier is for an automated snapshot, the SnapshotType parameter must also be specified.

Type: String

Required: No

Filters.Filter.N

This parameter is not currently supported.

Type: Array of Filter objects

Required: No

IncludePublic

True to include manual DB snapshots that are public and can be copied or restored by any AWS account, and otherwise false. The default is false.

You can share a manual DB snapshot as public by using the ModifyDBSnapshotAttribute API.

Type: Boolean

Required: No

IncludeShared

True to include shared manual DB snapshots from other AWS accounts that this AWS account has been given permission to copy or restore, and otherwise false. The default is false.

You can give an AWS account permission to restore a manual DB snapshot from another AWS account by using the ModifyDBSnapshotAttribute API action.

Type: Boolean

Required: No

Marker

An optional pagination token provided by a previous DescribeDBSnapshots request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.

Type: String

Required: No

MaxRecords

The maximum number of records to include in the response. If more records exist than the specified MaxRecords value, a pagination token called a marker is included in the response so that the remaining results can be retrieved.

Default: 100

Constraints: Minimum 20, maximum 100.

Type: Integer

Required: No

SnapshotType

The type of snapshots to be returned. You can specify one of the following values:

  • automated - Return all DB snapshots that have been automatically taken by Amazon RDS for my AWS account.

  • manual - Return all DB snapshots that have been taken by my AWS account.

  • shared - Return all manual DB snapshots that have been shared to my AWS account.

  • public - Return all DB snapshots that have been marked as public.

If you don't specify a SnapshotType value, then both automated and manual snapshots are returned. Shared and public DB snapshots are not included in the returned results by default. You can include shared snapshots with these results by setting the IncludeShared parameter to true. You can include public snapshots with these results by setting the IncludePublic parameter to true.

The IncludeShared and IncludePublic parameters don't apply for SnapshotType values of manual or automated. The IncludePublic parameter doesn't apply when SnapshotType is set to shared. The IncludeShared parameter doesn't apply when SnapshotType is set to public.

Type: String

Required: No

Response Elements

The following elements are returned by the service.

DBSnapshots.DBSnapshot.N

A list of DBSnapshot instances.

Type: Array of DBSnapshot objects

Marker

An optional pagination token provided by a previous request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.

Type: String

Errors

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

DBSnapshotNotFound

DBSnapshotIdentifier does not refer to an existing DB snapshot.

HTTP Status Code: 404

Example

Sample Request


https://rds.us-west-2.amazonaws.com/
   ?Action=DescribeDBSnapshots
   &IncludePublic=false
   &IncludeShared=true
   &MaxRecords=100
   &SignatureMethod=HmacSHA256
   &SignatureVersion=4
   &Version=2014-09-01
   &X-Amz-Algorithm=AWS4-HMAC-SHA256
   &X-Amz-Credential=AKIADQKE4SARGYLE/20140421/us-west-2/rds/aws4_request
   &X-Amz-Date=20140421T194732Z
   &X-Amz-SignedHeaders=content-type;host;user-agent;x-amz-content-sha256;x-amz-date
   &X-Amz-Signature=4aa31bdcf7b5e00dadffbd6dc8448a31871e283ffe270e77890e15487354bcca

Sample Response


<DescribeDBSnapshotsResponse xmlns="http://rds.amazonaws.com/doc/2014-09-01/">
  <DescribeDBSnapshotsResult>
    <DBSnapshots>
      <DBSnapshot>
        <Port>3306</Port>
        <OptionGroupName>default:mysql-5-6</OptionGroupName>
        <Engine>mysql</Engine>
        <Status>available</Status>
        <SnapshotType>manual</SnapshotType>
        <LicenseModel>general-public-license</LicenseModel>
        <EngineVersion>5.6.13</EngineVersion>
        <DBInstanceIdentifier>my-mysqlexampledb</DBInstanceIdentifier>
        <DBSnapshotIdentifier>my-test-restore-snapshot</DBSnapshotIdentifier>
        <SnapshotCreateTime>2014-03-28T19:57:16.707Z</SnapshotCreateTime>
        <AvailabilityZone>us-west-2b</AvailabilityZone>
        <InstanceCreateTime>2014-01-29T22:58:24.231Z</InstanceCreateTime>
        <PercentProgress>100</PercentProgress>
        <AllocatedStorage>5</AllocatedStorage>
        <MasterUsername>awsmyuser</MasterUsername>
      </DBSnapshot>
      <DBSnapshot>
        <Port>3306</Port>
        <OptionGroupName>default:mysql-5-6</OptionGroupName>
        <Engine>mysql</Engine>
        <Status>available</Status>
        <SnapshotType>automated</SnapshotType>
        <LicenseModel>general-public-license</LicenseModel>
        <EngineVersion>5.6.13</EngineVersion>
        <DBInstanceIdentifier>my-mysqlexampledb</DBInstanceIdentifier>
        <DBSnapshotIdentifier>rds:my-mysqlexampledb-2014-04-19-10-08</DBSnapshotIdentifier>
        <SnapshotCreateTime>2014-04-19T10:09:09.790Z</SnapshotCreateTime>
        <AvailabilityZone>us-west-2b</AvailabilityZone>
        <InstanceCreateTime>2014-01-29T22:58:24.231Z</InstanceCreateTime>
        <PercentProgress>100</PercentProgress>
        <AllocatedStorage>5</AllocatedStorage>
        <MasterUsername>awsmyuser</MasterUsername>
      </DBSnapshot>
      <DBSnapshot>
        <Port>3306</Port>
        <OptionGroupName>default:mysql-5-6</OptionGroupName>
        <Engine>mysql</Engine>
        <Status>available</Status>
        <SnapshotType>automated</SnapshotType>
        <LicenseModel>general-public-license</LicenseModel>
        <EngineVersion>5.6.13</EngineVersion>
        <DBInstanceIdentifier>my-mysqlexampledb</DBInstanceIdentifier>
        <DBSnapshotIdentifier>rds:my-mysqlexampledb-2014-04-20-10-09</DBSnapshotIdentifier>
        <SnapshotCreateTime>2014-04-20T10:09:15.446Z</SnapshotCreateTime>
        <AvailabilityZone>us-west-2b</AvailabilityZone>
        <InstanceCreateTime>2014-01-29T22:58:24.231Z</InstanceCreateTime>
        <PercentProgress>100</PercentProgress>
        <AllocatedStorage>5</AllocatedStorage>
        <MasterUsername>awsmyuser</MasterUsername>
      </DBSnapshot>
    </DBSnapshots>
  </DescribeDBSnapshotsResult>
  <ResponseMetadata>
    <RequestId>b7769930-b98c-11d3-f272-7cd6cce12cc5</RequestId>
  </ResponseMetadata>
</DescribeDBSnapshotsResponse>

See Also

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