Queries the information of one or more auto provisioning groups.
Debugging
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.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
ecs:DescribeAutoProvisioningGroups | get |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID of the auto provisioning group. | cn-hangzhou |
PageNumber | integer | No | The page number. Pages start from page 1. Default value: 1. | 1 |
PageSize | integer | No | The number of entries per page. Valid values: 1 to 100. Default value: 10. | 2 |
AutoProvisioningGroupName | string | No | The name of the auto provisioning group. | testAutoProvisioningGroupName |
ResourceGroupId | string | No | The ID of the resource group to which the auto provisioning group belongs. | rg-bp67acfmxazb4p**** |
AutoProvisioningGroupId | array | No | The ID of the auto provisioning group. You can specify up to 20 IDs. | |
string | No | The ID of the auto provisioning group. | apg-sn54avj8htgvtyh8**** | |
AutoProvisioningGroupStatus | array | No | The status of the auto provisioning group. | |
string | No | The status of auto provisioning group N. Valid values:
| active | |
Tag | array<object> | No | The tags that are added to the auto provisioning group. | |
object | No | |||
Key | string | No | The key of tag N that is added to the auto provisioning group. Valid values of N: 1 to 20. The tag key cannot be an empty string. The tag key can be up to 128 characters in length and cannot contain http:// or https://. The tag key cannot start with acs: or aliyun. | TestKey |
Value | string | No | The value of tag N that is added to the auto provisioning group. Valid values of N: 1 to 20. The tag value can be an empty string. The tag key can be up to 128 characters in length and cannot contain http:// or https://. | TestValue |
Response parameters
Examples
Sample success responses
JSON
format
{
"PageSize": 10,
"RequestId": "745CEC9F-0DD7-4451-9FE7-8B752F39****",
"PageNumber": 1,
"TotalCount": 10,
"AutoProvisioningGroups": {
"AutoProvisioningGroup": [
{
"CreationTime": "2019-04-01T15:10:20Z",
"AutoProvisioningGroupName": "EcsDocTest",
"Status": "submitted",
"TerminateInstances": false,
"MaxSpotPrice": 2,
"State": "fulfilled",
"LaunchTemplateId": "lt-bp1fgzds4bdogu03****",
"ValidFrom": "2019-04-01T15:10:20Z",
"LaunchTemplateVersion": "1",
"TerminateInstancesWithExpiration": true,
"RegionId": "cn-hangzhou",
"ValidUntil": "2019-06-01T15:10:20Z",
"AutoProvisioningGroupType": "maintain",
"AutoProvisioningGroupId": "apg-sn54avj8htgvtyh8****",
"ExcessCapacityTerminationPolicy": "termination",
"ResourceGroupId": "rg-bp67acfmxazb4p****",
"LaunchTemplateConfigs": {
"LaunchTemplateConfig": [
{
"MaxPrice": 3,
"Priority": 1,
"VSwitchId": "vsw-sn5bsitu4lfzgc5o7****",
"WeightedCapacity": 2,
"InstanceType": "ecs.g5.large"
}
]
},
"SpotOptions": {
"InstancePoolsToUseCount": 2,
"AllocationStrategy": "diversified",
"InstanceInterruptionBehavior": "stop"
},
"PayAsYouGoOptions": {
"AllocationStrategy": "prioritized"
},
"TargetCapacitySpecification": {
"SpotTargetCapacity": 20,
"PayAsYouGoTargetCapacity": 30,
"DefaultTargetCapacityType": "Spot",
"TotalTargetCapacity": 60
},
"Tags": {
"Tag": [
{
"TagKey": "TestKey",
"TagValue": "TestValue"
}
]
}
}
]
}
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | MissingParamter.RegionId | The regionId should not be null. | The RegionId parameter is required. |
400 | InvalidName.Malformed | The specified parameter "AutoProvisioningGroupName" is not valid. | - |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-02-29 | The Error code has changed. The request parameters of the API has changed. The response structure of the API has changed | View Change Details |
2024-01-04 | The Error code has changed. The request parameters of the API has changed. The response structure of the API has changed | View Change Details |