You can call this operation to query the list of stack groups.


OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ListStackGroups

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

RegionId String Yes cn-hangzhou

The region ID of the stack. You can call the DescribeRegions operation to query the most recent region list.

Status String No ACTIVE

The status of the stack group. Valid values:

PageSize Long No 10

The number of entries to return on each page.

Valid values: 1 to 50.

Default value: 10.

PageNumber Long No 1

The number of the page to return.

Pages start from page 1.

Default value: 1.

ResourceGroupId String No rg-acfmxazb4ph6aiy****

The ID of the resource group.

For more information about resource groups, see What is a resource group?.

For more information about common request parameters, see Common parameters.

Response parameters

Parameter Type Example Description
PageNumber Integer 1

The page number of the returned page.

PageSize Integer 10

The number of entries returned per page.

RequestId String 14A07460-EBE7-47CA-9757-12CC4761D47A

The ID of the request.

StackGroups Array of StackGroup

The list of stack groups.

Description String My Stack Group

The description of the stack group.

DriftDetectionTime String 2020-02-27T07:47:47

The time when the last successful drift detection operation was initiated.

ResourceGroupId String rg-acfmxazb4ph6aiy****

The ID of the resource group.

StackGroupDriftStatus String IN_SYNC

The drift status of the stack group in the last successful drift detection. Valid values:

  • DRIFTED: The stack has drifted.
  • NOT_CHECKED: No drift detection is complete on the stack.
  • IN_SYNC: The stack is being synchronized.
StackGroupId String fd0ddef9-9540-4b42-a464-94f77835****

The ID of the stack group.

StackGroupName String MyStackGroup

The name of the stack group.

Status String ACTIVE

The status of the stack group. Valid values:

TotalCount Integer 1

The total number of stack groups.


Sample requests

&<Common request parameters>

Sample success responses

XML format


JSON format

	"PageNumber": 1,
	"TotalCount": 1,
	"PageSize": 10,
	"RequestId": "14A07460-EBE7-47CA-9757-12CC4761D47A",
	"StackGroups": [
			"Status": "ACTIVE",
            "ResourceGroupId": "rg-acfmxazb4ph6aiy****",
			"StackGroupId": "fd0ddef9-9540-4b42-a464-94f77835****",
			"StackGroupName": "MyStackGroup",
            "DriftDetectionTime": "2020-02-27T07:47:47",
            "StackGroupDriftStatus": "IN_SYNC"

Error codes

For a list of error codes, visit the API Error Center.

Error code

Error message

HTTP status code



The specified parameter {name} is invalid, {reason}.


The error message returned because the specified parameter is invalid. name indicates the parameter name, and reason indicates the reason for the error.