Ignores one or more resources that are evaluated as non-compliant by a rule.

After you ignore a resource that is evaluated as non-compliant by a rule, the resource is still evaluated by the rule, but the compliance result becomes Ignored.

The sample request in this topic shows you how to ignore the lb-hp3a3b4ztyfm2plgm**** resource that is evaluated as non-compliant by the cr-7e72626622af0051**** rule in the 100931896542**** account. The ID of the region in which the resource resides is cn-beijing, and the type of the resource is ACS::SLB::LoadBalancer.

Debugging

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 IgnoreEvaluationResults

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

ConfigRuleId String Yes cr-7e72626622af0051****

The ID of the rule.

For more information about how to obtain the ID of a rule, see ListConfigRules.

Resources Array Yes

The resources to be ignored.

ResourceAccountId Long Yes 100931896542****

The ID of the Alibaba Cloud account to which the resource belongs.

ResourceType String Yes ACS::SLB::LoadBalancer

The type of the resource.

For more information about how to obtain the type of a resource, see ListDiscoveredResources.

Region String Yes cn-beijing

The ID of the region in which the resource resides.

For more information about how to obtain the ID of the region in which a resource resides, see ListDiscoveredResources.

ResourceId String Yes lb-hp3a3b4ztyfm2plgm****

The ID of the resource.

For more information about how to obtain the ID of a resource, see ListDiscoveredResources.

Reason String No No compliance evaluation is required for the resource.

The reason why you ignore the resource.

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

Response parameters

Parameter Type Example Description
RequestId String 1840CBF2-0B0B-59F2-9E84-07B38267A279

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/?Action=IgnoreEvaluationResults
&ConfigRuleId=cr-7e72626622af0051****
&Resources=[{"ResourceAccountId":"100931896542****","ResourceType":"ACS::SLB::LoadBalancer","Region":"cn-beijing","ResourceId":"lb-hp3a3b4ztyfm2plgm****"}]
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<IgnoreEvaluationResultsResponse>
    <RequestId>1840CBF2-0B0B-59F2-9E84-07B38267A279</RequestId>
</IgnoreEvaluationResultsResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "1840CBF2-0B0B-59F2-9E84-07B38267A279"
}

Error codes

HTTP status code Error code Error message Description
400 NoPermission You are not authorized to perform this operation. The error message returned because you are not authorized to perform the specified operation.
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.