Queries the details of a compliance package in an account group.
The sample request in this topic shows you how to query the details of the cp-fdc8626622af00f9****
compliance package in the ca-f632626622af0079****
account group.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | GetAggregateCompliancePack |
The operation that you want to perform. Set the value to GetAggregateCompliancePack. |
CompliancePackId | String | Yes | cp-fdc8626622af00f9**** |
The ID of the compliance package. For more information about how to obtain the ID of a compliance package, see ListAggregateCompliancePacks. |
AggregatorId | String | Yes | ca-f632626622af0079**** |
The ID of the account group. For more information about how to obtain the ID of an account group, see ListAggregators. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 6EC7AED1-172F-42AE-9C12-295BC2ADB751 |
The ID of the request. |
CompliancePack | Object |
The details of the compliance package. |
|
Status | String | ACTIVE |
The status of the compliance package. Valid values:
|
RiskLevel | Integer | 1 |
The risk level of the resources that are not compliant with the rules in the compliance package. Valid values:
|
CompliancePackId | String | cp-fdc8626622af00f9**** |
The ID of the compliance package. |
Description | String | The compliance package continuously monitors your resources to check whether the resources are compliant with MLPS 2.0 Level 3. This allows you to perform self-service prechecks and handle resource non-compliance to pass the formal compliance evaluation with efficiency. |
The description of the compliance package. |
ConfigRules | Array of ConfigRules |
The rules enabled in the compliance package. |
|
ManagedRuleIdentifier | String | eip-bandwidth-limit |
The identifier of the managed rule. |
ConfigRuleName | String | eip-bandwidth-limit |
The name of the rule. |
ConfigRuleId | String | cr-a260626622af0005**** |
The ID of the rule. |
ConfigRuleParameters | Array of ConfigRuleParameters |
The input parameter settings of the rule. |
|
Required | Boolean | true |
Indicates whether the input parameter is required. Valid values:
|
ParameterName | String | bandwidth |
The name of the input parameter. |
ParameterValue | String | 10 |
The expected value of the input parameter. |
Description | String | If the available bandwidth of an elastic IP address is greater than or equal to the specified parameter value, the configuration is considered compliant. Default value: 10 MB. |
The description of the rule. |
RiskLevel | Integer | 1 |
The risk level of the resources that are not compliant with the rule. Valid values:
|
CompliancePackName | String | ClassifiedProtectionPreCheck |
The name of the compliance package. |
AccountId | Long | 100931896542**** |
The ID of the management account to which the compliance package belongs. |
AggregatorId | String | ca-f632626622af0079**** |
The ID of the account group. |
CompliancePackTemplateId | String | ct-5f26ff4e06a300c4**** |
The ID of the compliance package template based on which the compliance package was created. |
CreateTimestamp | Long | 1624243657000 |
The timestamp when the compliance package was created. Unit: milliseconds. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=GetAggregateCompliancePack
&CompliancePackId=cp-fdc8626622af00f9****
&AggregatorId=ca-f632626622af0079****
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<GetAggregateCompliancePackResponse>
<RequestId>6EC7AED1-172F-42AE-9C12-295BC2ADB751</RequestId>
<CompliancePack>
<Status>ACTIVE</Status>
<RiskLevel>1</RiskLevel>
<CompliancePackId>cp-fdc8626622af00f9****</CompliancePackId>
<Description>The compliance package continuously monitors your resources to check whether the resources are compliant with MLPS 2.0 Level 3. This allows you to perform self-service prechecks and handle resource non-compliance to pass the formal compliance evaluation with efficiency. </Description>
<ConfigRules>
<ManagedRuleIdentifier>eip-bandwidth-limit</ManagedRuleIdentifier>
<ConfigRuleName>eip-bandwidth-limit</ConfigRuleName>
<ConfigRuleId>cr-a260626622af0005****</ConfigRuleId>
<ConfigRuleParameters>
<Required>true</Required>
<ParameterName>bandwidth</ParameterName>
<ParameterValue>10</ParameterValue>
</ConfigRuleParameters>
<Description>If the available bandwidth of an elastic IP address is greater than or equal to the specified parameter value, the configuration is considered compliant. Default value: 10 MB. </Description>
<RiskLevel>1</RiskLevel>
</ConfigRules>
<CompliancePackName> ClassifiedProtectionPreCheck </CompliancePackName>
<AggregatorId>ca-f632626622af0079****</AggregatorId>
<CompliancePackTemplateId>ct-5f26ff4e06a300c4****</CompliancePackTemplateId>
<CreateTimestamp>1624243657000</CreateTimestamp>
</CompliancePack>
</GetAggregateCompliancePackResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"RequestId" : "6EC7AED1-172F-42AE-9C12-295BC2ADB751",
"CompliancePack" : {
"Status" : "ACTIVE",
"RiskLevel" : 1,
"CompliancePackId" : "cp-fdc8626622af00f9****",
"Description" : "The compliance package continuously monitors your resources to check whether the resources are compliant with MLPS 2.0 Level 3. This allows you to perform self-service prechecks and handle resource non-compliance to pass the formal compliance evaluation with efficiency.",
"ConfigRules" : [ {
"ManagedRuleIdentifier" : "eip-bandwidth-limit",
"ConfigRuleName": "eip-bandwidth-limit",
"ConfigRuleId" : "cr-a260626622af0005****",
"ConfigRuleParameters" : [ {
"Required" : true,
"ParameterName" : "bandwidth",
"ParameterValue" : "10"
} ],
"Description": "If the available bandwidth of an elastic IP address is greater than or equal to the specified parameter value, the configuration is considered compliant. Default value: 10 MB.",
"RiskLevel" : 1
} ],
"CompliancePackName" : "ClassifiedProtectionPreCheck",
"AggregatorId" : "ca-f632626622af0079****",
"CompliancePackTemplateId" : "ct-5f26ff4e06a300c4****",
"CreateTimestamp" : 1624243657000
}
}
Error codes
Http status code | Error code | Error message | Description |
---|---|---|---|
400 | Invalid.AggregatorId.Value | The specified AggregatorId is invalid. | The error message returned because the specified account group ID does not exist or you are not authorized to use the account group. |
400 | Invalid.CompliancePackId.Value | The specified CompliancePackId does not exist. | The error message returned because the specified compliance package ID does not exist. |
404 | AccountNotExisted | Your account does not exist. | The error message returned because your account does not exist. |
503 | ServiceUnavailable | The request has failed due to a temporary failure of the server. | The error message returned because the service is unavailable. |
For a list of error codes, visit the API Error Center.