All Products
Search
Document Center

ApsaraDB for MongoDB:DescribeBackupDBs

Last Updated:Jan 26, 2026

Queries the databases at a specified time or the databases in a specified backup set before you restore a database for an ApsaraDB for MongoDB instance.

Operation description

You can call the CreateDBInstance operation to restore a database for an ApsaraDB for MongoDB instance. For more information, see Restore one database of an ApsaraDB for MongoDB instance.

Before you call this operation, make sure that the instance meets the following requirements:

  • The instance was created after March 26, 2019.

  • The instance is located in the China (Qingdao), China (Beijing), China (Zhangjiakou), China (Hohhot), China (Hangzhou), China (Shanghai), China (Shenzhen), or Singapore region. Other regions are not supported.

  • The instance is a replica set instance.

  • The instance runs MongoDB 3.4, MongoDB 4.0, or MongoDB 4.2. In addition, the instance uses local disks to store data.

  • The storage engine of the instance is WiredTiger.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

dds:DescribeBackupDBs

get

*Instance

acs:dds:{#regionId}:{#accountId}:dbinstance/{#dbinstanceId}

None None

Request parameters

Parameter

Type

Required

Description

Example

PageNumber

integer

No

The page number of the page to return. The value must be an integer that is greater than 0. Default value: 1.

1

PageSize

integer

No

The number of entries to return per page. Default value: 30. Valid values: 30, 50, and 100.

30

SourceDBInstance

string

Yes

The ID of the source instance.

dds-bp2286****

RestoreTime

string

No

The point in time to which the instance is restored. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

Note
  • The time can be a point in time within the previous seven days. The time must be earlier than the current time, but later than the time when the instance was created.

  • You must specify one of the RestoreTime and BackupId parameters.

2019-08-22T12:00:00Z

BackupId

string

No

The backup ID.

Note
  • You can call the DescribeBackups operation to query the backup ID.

  • You must specify one of the RestoreTime and BackupId parameters.

5664****

ResourceGroupId

string

No

The ID of the resource group.

rg-ax68****

SourceDBInstance

string

Yes

The ID of the source instance.

dds-bp2286****

Response elements

Element

Type

Description

Example

object

TotalCount

integer

The number of returned databases.

5

Databases

object

Database

array<object>

The details of the databases.

object

DBName

string

The name of the database.

mongodbtest

RequestId

string

The request ID.

1AF0AD89-ED4F-44AD-B65F-BFC1D5CD9455

PageSize

integer

The number of entries returned per page.

30

PageNumber

integer

The page number of the page returned.

1

Examples

Success response

JSON format

{
  "TotalCount": 5,
  "Databases": {
    "Database": [
      {
        "DBName": "mongodbtest"
      }
    ]
  },
  "RequestId": "1AF0AD89-ED4F-44AD-B65F-BFC1D5CD9455",
  "PageSize": 30,
  "PageNumber": 1
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidMeta.WrongFormat Meta information is wrong formatter.
400 InvalidRestoreTime.Format Specified restore time is not valid. The specified RestoreTime value is invalid.
403 InvalidDBName The specified database name is not allowed. The specified database name is invalid.
403 InvalidMeta.TooLarge Meta information is too large. The metadata is too large.
403 SingleDBRestore.BackupSetNotSupport This backup set do not support this operation. Single-database recovery is not supported for the specified time point or backup file.
403 IncorrectDBInstanceType Current DB instance type does not support this operation.
403 IncorrectEngineVersion Current engine version does not support operations.
403 InvalidBackupLogStatus Current backup log enable status does not support this operation. The operation is not supported when log backup is enabled.
403 IncorrectBackupSetState Current backup set state does not support operations..
404 InvalidBackupSetID.NotFound Specifiedbackup set ID does not exist.
404 InvalidBackup.NotFound Theavailable backup does not exist in recovery time. No backup set is available during the specified recovery period.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.