Queries available automatic snapshot policies.

Debugging

You can use API Explorer to perform debugging. API Explorer allows you to perform various operations to simplify API usage. For example, you can retrieve APIs, call APIs, and dynamically generate SDK example code.

Request parameters

Name Type Required Example Description
Action String No DescribeAutoSnapshotPolicyEx

The operation that you want to perform. Set the value to DescribeAutoSnapshotPolicyEx.

AutoSnapshotPolicyId String No p-233e6ylv0

The ID of the automatic snapshot policy.

PageNumber Integer No 1

The page number that you query in the automatic snapshot policy list. Starting value: 1.

Default value: 1.

PageSize Integer No 10

The number of entries per page. Maximum Value: 50

Default value: 10.

RegionId String No cn-hangzhou

The ID of the region to which the automatic snapshot policies belong. You can call DescribeRegions to view the latest regions of Alibaba Cloud.

Response parameters

Name Type Example Description
AutoSnapshotPolicies

The automatic snapshot policy details. It is a set of AutoSnapshotPolicyType data.

 └ AutoSnapshotPolicyId String FinanceJoshua

The ID of the automatic snapshot policy.

 └ AutoSnapshotPolicyName String p-23f2i9s4t

The name of the automatic snapshot policy.

 └ CreationTime String 2014-04-21T12:08:52Z

The creation time of the automatic snapshot policy. The time follows the ISO 8601 standard and uses UTC time. The format is yyyy-MM-ddTHH:mm:ssZ.

 └ DiskNums Integer 2

The number of disks to which the automatic snapshot policy is applied.

 └RegionId String cn-hangzhou

The ID of the region to which the automatic snapshot policy belongs.

 └ RepeatWeekdays String ["6"]

The repeat date for the automatic snapshot. This parameter specifies which days of the week that automatic snapshots are created on. Valid values: 1 to 7, corresponding to the days of a week, where 1 indicates Monday. You can specify multiple dates.

Specified RetentionDays Integer 30

The retention period of the automatic snapshot. Unit: day.

  • -1: The automatic snapshot is retained permanently.
  • 1-65536: The automatic snapshot is retained for the specified number of days.
 └Status String Available 

The status of the automatic snapshot policy. Valid values:

  • Creating
  • Available
 └ TimePoints String ["4", "19"]

The point in time at which the automatic snapshot is created. The smallest interval that snapshots can be taken at is one hour. Valid values: 0 to 23, corresponding to 24 hours in the range of 00:00 to 23:00. You can specify multiple points in time. The parameter is a JSON-formatted array: ["0", "1", ... "23"]. You can specify a maximum of 24 points in time. Separate multiple points in time with commas (,).

 └ VolumeNums Integer 2

The number of disks on which this policy is enabled.

PageNumber Integer 1

The page number that you query in the automatic snapshot policy list.

PageSize Integer 10

The number of entries per page.

RequestId String 473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E

The ID of the request.

TotalCount Integer 2

The total number of automatic snapshot policies.

Examples

Sample requests

https://ecs.aliyuncs.com/?Action=DescribeAutoSnapshotPolicyEx
&RegionId=cn-hangzhou 
&AutoSnapshotPolicyId=p-233e6ylv0 
&PageNumber=1 
&PageSize=10 
&<Common request parameters>

Successful response examples

XML format

<DescribeAutoSnapshotPolicyResponse>
  <AutoSnapshotPolicies>
    <AntoSnapshotPolicy>
      <CreationTime>2014-04-21T12:08:52Z</CreationTime>
      <AutoSnapshotPolicyId>p-23f2i9s4t</AutoSnapshotPolicyId>
      <SettingTimePoints>[“2”, “9”]</SettingTimePoints>
      <SettingRepeatWeekdays>[“3” , “4” , “5” , “7”]</SettingRepeatWeekdays>
      <RetentionDays>-1</RetentionDays>
    </AntoSnapshotPolicy>
    <AntoSnapshotPolicy>
      <CreationTime>2014-07-24T13:00:52Z</CreationTime>
      <AutoSnapshotPolicyId>p-23f2i9s4t</AutoSnapshotPolicyId>
      <SettingTimePoints>[“0”, “1”]</SettingTimePoints>
      <SettingRepeatWeekdays>[“1”, “7”]</SettingRepeatWeekdays>
      <RetentionDays>30</RetentionDays>
    </AntoSnapshotPolicy>
  </AutoSnapshotPolicies>
  <PageNumber>1</PageNumber>
  <PageSize>2</PageSize>
  <TotalCount>2</TotalCount>
  <RequestId>F3CD6886-D8D0-4FEE-B93E-1B73239673DE</RequestId>
</DescribeAutoSnapshotPolicyResponse>

JSON format

{
	"PageNumber":1,
	"TotalCount":2,
	"AutoSnapshotPolicies":{
		" AutoSnapshotPolicy":[
			{
				"CreationTime":"2014-07-24T13:00:52Z",
				"SettingRepeatWeekdays":"[“1”, “7”]",
				"RetentionDays":"30",
				"AutoSnapshotPolicyId":"p-23f2i9s4t",
				"SettingTimePoints":"[“0”, “1”]"
			},
			{
				"CreationTime":"2014-04-21T12:08:52Z",
				"SettingRepeatWeekdays":"[“3” , “4” , “5” , “7”]",
				"RetentionDays":"-1",
				"AutoSnapshotPolicyId":"p-a1fd3g5s1",
				"SettingTimePoints":"[“2”, “9”]"
			}
		]
	},
	"PageSize":2,
	"RequestId":"659F91C6-1949-43B0-90C4-B6342CA757D5"
}

Error codes

View error codes