All Products
Search
Document Center

ApsaraDB for MongoDB:DescribeAdvancedBackupPolicy

Last Updated:Oct 08, 2026

Queries the advanced backup policy.

Operation description

Queries the advanced backup policy. This operation supports only cloud disk replica set and cloud disk sharded cluster instances.

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:DescribeAdvancedBackupPolicy

get

*Instance

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

None None

Request parameters

Parameter

Type

Required

Description

Example

DBInstanceId

string

Yes

The instance ID.

dds-bp18b0934e70****

Response elements

Element

Type

Description

Example

object

RequestId

string

The request ID.

111E7B16-0A87-4CBA-B271-F34AD61E099F

DBInstanceId

string

The instance ID.

dds-bp14bf67a76d****

PreferredBackupTime

string

The backup time in the format of HH:mmZ-HH:mmZ (UTC time).

09:00Z-10:00Z

SnapshotBackupType

string

The snapshot backup type. Valid values:

  • Flash: backup within seconds.

  • Standard: standard backup.

Valid values:

  • Standard :

    Standard backup.

  • Flash :

    Backup within seconds.

Standard

BackupRetentionPolicyOnClusterDeletion

integer

The backup data retention policy. Valid values:

  • 0: All backup sets of the instance are immediately deleted when the instance is released.

  • 1: The last backup set is retained using long-term retention (LTR) when the instance is released.

  • 2: All backup sets are retained using long-term retention (LTR) when the instance is released.

Valid values:

  • 0 :

    Immediately delete all backup sets.

  • 1 :

    Retain the last backup set using long-term retention (LTR).

  • 2 :

    Retain all backup sets using long-term retention (LTR).

2

PreferredNextBackupTime

string

The time range within which the backup starts. The format is HH:mmZ-HH:mmZ (UTC time), such as 01:00Z-02:00Z. The backup starts at a time within this time range.

2024-06-19T19:11Z

AdvancedBackupDataPolicies

array<object>

The list of backup policies.

object

PolicyId

string

The backup policy ID.

xxxxxx

ActionType

string

The action type. Valid values:

  • DELETE: delete.

  • CREATE: create.

  • UPDATE: update.

xx

RetentionType

string

The retention epoch type of the backup set. Valid values:

  • never: long-term retention (LTR).

  • delay: retention for a fixed number of days.

Valid values:

  • never :

    Long-term retention (LTR).

  • delay :

    Retention for a fixed number of days.

delay

RetentionPeriod

integer

The number of days to retain the backup.

7

BackupPolicy

string

The scheduling type of the advanced backup policy. Valid values:

  • dayOfWeek: weekly scheduling.

  • dayOfMonth: monthly scheduling.

  • dayOfYear: yearly scheduling.

  • backupInterval: fixed-interval scheduling (high-frequency backup).

Valid values:

  • dayOfWeek :

    Weekly scheduling.

  • dayOfMonth :

    Monthly scheduling.

  • dayOfYear :

    Yearly scheduling.

  • backupInterval :

    Fixed-interval scheduling (high-frequency backup)

dayOfWeek

PreferredBackupPeriod

string

The backup cycle.

  • If BackupPolicy=dayOfWeek: 1,2,3,4,5,6,7 indicates Monday through Sunday.

  • If BackupPolicy=dayOfMonth: 1,3,-1 indicates the 1st, 3rd, and last day of each month.

  • If BackupPolicy=dayOfYear: 01-07 indicates January 7th.

  • If BackupPolicy=backupInterval: 30 indicates a backup every 30 minutes.

1,2,3

SrcRegion

string

The region where the instance resides.

cn-beijing

SrcType

string

The source type of the backup policy. Valid values:

  • db: same-region backup.

  • level1: cross-region backup.

Valid values:

  • level1 :

    Cross-region backup.

  • db :

    Same-region backup.

db

DestRegion

string

The destination region of the backup policy.

cn-beijing

DestType

string

The destination type of the backup policy. Valid values:

  • level1: same-region backup.

  • level2Cross: cross-region backup.

Valid values:

  • level1 :

    Same-region backup.

  • level2Cross :

    Cross-region backup.

level1

PreserveOneEachHour

boolean

Specifies whether to enable sparse backup within an hour. Valid values:

  • true: When the backup frequency is in minutes, all snapshots taken within 1 hour of the current time are retained. For snapshots taken more than 1 hour but within 24 hours of the current time, only the first snapshot after each full hour is retained.

  • false: Sparse backup within an hour is shutdown. All snapshots within the high-frequency backup retention period are retained.

False

AdvancedBackupLogPolicies

array<object>

The list of log backup policies.

object

EnableLogBackup

integer

Indicates whether log backup is enabled. Valid values:

  • 1: enabled.

  • 0: disabled.

Valid values:

  • 0 :

    Disabled.

  • 1 :

    Enabled.

1

RetentionType

string

The retention epoch type of the log backup. Valid values:

  • never: long-term retention (LTR).

  • delay: retention for a fixed number of days.

Valid values:

  • never :

    Long-term retention (LTR).

  • delay :

    Retention for a fixed number of days.

delay

RetentionPeriod

string

The number of days to retain the log backup. This parameter takes effect only when RetentionType is set to delay.

4

SrcRegion

string

The region where the source instance resides.

cn-hangzhou

SrcType

string

The source type of the log backup policy. Valid values:

  • db: same-region backup.

  • level1: cross-region backup.

Valid values:

  • level1 :

    Cross-region backup.

  • db :

    Same-region backup.

et

DestRegion

string

The destination region of the log backup policy.

cn-guangzhou

DestType

string

The destination type of the log backup policy. Valid values:

  • level1: same-region backup.

  • level2Cross: cross-region backup.

Valid values:

  • level1 :

    Same-region backup.

  • level2Cross :

    Cross-region backup.

RDS

PolicyId

string

The log backup policy ID. This field exists only for cross-region log backup policies.

xxxx

Examples

Success response

JSON format

{
  "RequestId": "111E7B16-0A87-4CBA-B271-F34AD61E099F",
  "DBInstanceId": "dds-bp14bf67a76d****",
  "PreferredBackupTime": "09:00Z-10:00Z",
  "SnapshotBackupType": "Standard",
  "BackupRetentionPolicyOnClusterDeletion": 2,
  "PreferredNextBackupTime": "2024-06-19T19:11Z",
  "AdvancedBackupDataPolicies": [
    {
      "PolicyId": "xxxxxx",
      "ActionType": " xx",
      "RetentionType": "delay",
      "RetentionPeriod": 7,
      "BackupPolicy": "dayOfWeek",
      "PreferredBackupPeriod": "1,2,3",
      "SrcRegion": "cn-beijing",
      "SrcType": "db",
      "DestRegion": "cn-beijing",
      "DestType": "level1",
      "PreserveOneEachHour": true
    }
  ],
  "AdvancedBackupLogPolicies": [
    {
      "EnableLogBackup": 1,
      "RetentionType": "delay",
      "RetentionPeriod": "4",
      "SrcRegion": "cn-hangzhou",
      "SrcType": "et",
      "DestRegion": "cn-guangzhou",
      "DestType": "RDS",
      "PolicyId": "xxxx"
    }
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidPreferredBackupPeriod.Malformed Specified parameter PreferredBackupPeriod is not valid.
400 InvalidPreferredBackupTime.Malformed Specified parameter PreferredBackupTime is not valid.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.