In this example, the information about a stack group named \\`MyStackGroup\\` is queried. The stack group is granted self-managed permissions and created in the China (Hangzhou) region.
Operation description
For more information about common request parameters, see Common parameters.
Debugging
Authorization information
There is currently no authorization information disclosed in the API.
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The name of the stack group. The name must be unique within a region. The name can be up to 255 characters in length, and can contain digits, letters, hyphens (-), and underscores (_). It must start with a digit or letter. Note
You must specify one of the StackGroupName and StackGroupId parameters.
| cn-hangzhou |
StackGroupName | string | No | The ID of the stack group. Note
You must specify one of the StackGroupName and StackGroupId parameters.
| MyStackGroup |
StackGroupId | string | No | The ID of the request. | fd0ddef9-9540-4b42-a464-94f77835**** |
Error code | Error message | HTTP status code | Description |
---|---|---|---|
StackGroupNotFound | The StackGroup ({name}) could not be found. | 404 | The error message returned because the specified stack group does not exist. name indicates the name of the stack group. |
Response parameters
The operation that you want to perform. Set the value to GetStackGroup.
Examples
Sample success responses
JSON
format
{
"RequestId": "14A07460-EBE7-47CA-9757-12CC4761D47A",
"StackGroup": {
"StackGroupId": "fd0ddef9-9540-4b42-a464-94f77835****",
"Status": "ACTIVE",
"AdministrationRoleName": "AliyunROSStackGroupAdministrationRole",
"Parameters": [
{
"ParameterKey": "Amount",
"ParameterValue": "12"
}
],
"Description": "StackGroup Description",
"StackGroupName": "MyStackGroup",
"ExecutionRoleName": "AliyunROSStackGroupExecutionRole",
"TemplateBody": "{\"ROSTemplateFormatVersion\": \"2015-09-01\"}",
"StackGroupDriftDetectionDetail": {
"DriftDetectionTime": "2020-02-27T07:47:47",
"TotalStackInstancesCount": 2,
"FailedStackInstancesCount": 0,
"DriftDetectionStatus": "COMPLETED",
"StackGroupDriftStatus": "DRIFTED",
"InProgressStackInstancesCount": 0,
"InSyncStackInstancesCount": 1,
"CancelledStackInstancesCount": 0,
"DriftedStackInstancesCount": 1
},
"ResourceGroupId": "rg-acfmxazb4ph6aiy****",
"PermissionModel": "SELF_MANAGED",
"AutoDeployment": {
"Enabled": true,
"RetainStacksOnAccountRemoval": true
},
"RdFolderIds": [
"[\"fd-4PvlVLOL8v\"]"
],
"TemplateContent": "{\n \"ROSTemplateFormatVersion\": \"2015-09-01\"\n}"
}
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2024-05-10 | The response structure of the API has changed | View Change Details |
2023-05-10 | The response structure of the API has changed | View Change Details |