All Products
Search
Document Center

ApsaraDB for MongoDB:DescribeBackups

Last Updated:Nov 06, 2024

Queries the backup sets of an ApsaraDB for MongoDB instance.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
dds:DescribeBackupsget
  • Instance
    acs:dds:{#regionId}:{#accountId}:dbinstance/{#dbinstanceId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
DBInstanceIdstringYes

The instance ID.

Note If you set this parameter to the ID of a sharded cluster instance, you must also specify the NodeId parameter.
dds-bp1a7009eb24****
NodeIdstringNo

The ID of the shard node in the sharded cluster instance.

Note This parameter takes effect only when you set the DBInstanceId parameter to the ID of a sharded cluster instance.
d-bp128a003436****
BackupIdstringNo

The ID of the backup set. You can call the CreateBackup operation to query the backup set ID.

If you set the DBInstanceId parameter to the ID of a sharded cluster instance, the number of backup IDs is the same as the number of shard nodes. Multiple backup IDs are separated with commas (,).

2072****,2072****,2072****
PageNumberintegerNo

The number of the page to return. The value must be a positive integer that does not exceed the maximum value of the INTEGER data type. Default value: 1.

1
PageSizeintegerNo

The number of entries to return per page. Valid values:

  • 30 (default)
  • 50
  • 100
30
StartTimestringNo

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mmZ format. The time must be in UTC.

2022-01-13T13:00Z
EndTimestringNo

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mmZ format. The time must be in UTC. The end time must be later than the start time.

2022-01-14T13:00Z
SrcRegionstringNo

The region ID of the instance.

Note
  • This parameter is required if you want to query the backup sets of a released instance.
  • This parameter is required if you want to query cross-region backups.
  • cn-beijing
    DestRegionstringNo

    The region ID of the Cross-regional backup.

    Note This parameter is required for the Cross-regional backup.
    cn-hangzhou

    Response parameters

    ParameterTypeDescriptionExample
    object

    The information of the backup sets created for the instance.

    TotalCountinteger

    The total number of backup sets.

    1
    RequestIdstring

    The request ID.

    275D43C3-F12F-5224-B375-0C6BF453BD56
    PageSizeinteger

    The number of entries returned per page. Valid values:

    • 30 (default)
    • 50
    • 100
    30
    PageNumberinteger

    The page number of the returned page.

    1
    Backupsarray<object>

    The details of the backup set.

    Backupobject

    The details of the backup set.

    BackupStatusstring

    The status of the backup task. Valid values:

    • Success: The backup task is successful.
    • Failed: The backup task failed.
    Success
    BackupTypestring

    The backup type. Valid values:

    • FullBackup
    • IncrementalBackup
    FullBackup
    BackupStartTimestring

    The start time of the backup. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

    2022-01-14T03:56:17Z
    BackupIntranetDownloadURLstring

    The internal download URL of the backup set.

    Note You can use the URL to download the specified backup set on an Elastic Compute Service (ECS) instance that is in the same virtual private cloud (VPC) as the ApsaraDB for MongoDB instance.
    http://rdsbak-hz-v3.oss-cn-hangzhou-internal.aliyuncs.com/custins5559*****/hins1936****_data_2022052504****_qp.xb?Expires=165361****&OSSAccessKeyId=LTAI4G2wxd32KLGARfi****&Signature=lkFPjOY%2F8adB18vnOCbtmT7ii****&Region=cn-hangzhou
    BackupSizelong

    The size of the backup set. Unit: bytes.

    6168576
    BackupDownloadURLstring

    The URL that is used to download the backup set over the Internet. If the backup set cannot be downloaded, an empty string is returned.

    http://rdsbak-hz-v3.oss-cn-hangzhou.aliyuncs.com/custins5559****/hins1936****_data_2022052504****_qp.xb?Expires=165361****&OSSAccessKeyId=LTAI4G2wxd32KLGARf****&Signature=lkFPjOY%2F8adB18vnOCbtmT7****&Region=cn-hangzhou
    BackupModestring

    The backup mode of the backup set. Valid values:

    • Automated
    • Manual
    Automated
    BackupEndTimestring

    The end time of the backup. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

    2022-01-14T03:57:34Z
    BackupIdinteger

    The ID of the backup set.

    32102****
    BackupDBNamesstring

    The name of the database that has been backed up.

    database
    BackupMethodstring

    The method that is used to generate the backup set. Valid values:

    • Snapshot
    • Physical
    • Logical
    Physical
    BackupJobIdstring

    The ID of the backup task.

    1123xxxx
    BackupNamestring

    The name of the backup set. The parameter is invalid.

    12345678.tar.gz
    BackupScalestring

    The backup granularity. The parameter is invalid.

    DBInstance
    IsAvailboolean

    Availability of the backup set.

    • 0: unavailable
    • 1: available
    1
    EngineVersionstring

    Version of the backuped instance.

    • 6.0
    • 5.0
    • 4.4
    • 4.2
    • 4.0
    • 3.4
    4.2

    Examples

    Sample success responses

    JSONformat

    {
      "TotalCount": 1,
      "RequestId": "275D43C3-F12F-5224-B375-0C6BF453BD56",
      "PageSize": 30,
      "PageNumber": 1,
      "Backups": {
        "Backup": [
          {
            "BackupStatus": "Success",
            "BackupType": "FullBackup",
            "BackupStartTime": "2022-01-14T03:56:17Z",
            "BackupIntranetDownloadURL": "http://rdsbak-hz-v3.oss-cn-hangzhou-internal.aliyuncs.com/custins5559*****/hins1936****_data_2022052504****_qp.xb?Expires=165361****&OSSAccessKeyId=LTAI4G2wxd32KLGARfi****&Signature=lkFPjOY%2F8adB18vnOCbtmT7ii****&Region=cn-hangzhou",
            "BackupSize": 6168576,
            "BackupDownloadURL": "http://rdsbak-hz-v3.oss-cn-hangzhou.aliyuncs.com/custins5559****/hins1936****_data_2022052504****_qp.xb?Expires=165361****&OSSAccessKeyId=LTAI4G2wxd32KLGARf****&Signature=lkFPjOY%2F8adB18vnOCbtmT7****&Region=cn-hangzhou",
            "BackupMode": "Automated",
            "BackupEndTime": "2022-01-14T03:57:34Z",
            "BackupId": 0,
            "BackupDBNames": "database",
            "BackupMethod": "Physical",
            "BackupJobId": "1123xxxx",
            "BackupName": "12345678.tar.gz",
            "BackupScale": "DBInstance",
            "IsAvail": true,
            "EngineVersion": "4.2"
          }
        ]
      }
    }

    Error codes

    HTTP status codeError codeError message
    400InvalidStartTime.MalformedThe Specified parameter StartTime is not valid.
    400InvalidEndTime.MalformedThe Specified parameter EndTime is not valid.
    400InvalidStartTimeAndEndTime.MalformedThe Specified parameter StartTime or EndTime is not valid.
    400InvalidPageSize.MalformedThe specified parameter PageSize is not valid.

    For a list of error codes, visit the Service error codes.

    Change history

    Change timeSummary of changesOperation
    2024-10-29The Error code has changed. The response structure of the API has changedView Change Details
    2024-04-12The Error code has changed. The response structure of the API has changedView Change Details
    2024-03-25The Error code has changed. The response structure of the API has changedView Change Details
    2024-02-22The Error code has changed. The response structure of the API has changedView Change Details
    2023-12-07The Error code has changedView Change Details