Executes evaluation rules to evaluate resources.
Debugging
Authorization information
There is currently no authorization information disclosed in the API.
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
ResourceEvaluateItems | object [] | Yes | The resources that you want to evaluate. | |
ResourceLogicalId | string | No | The logical ID of the resource. | ResourceLogicId-test |
ResourceType | string | No | The type of the resource. | ACS::ECS::Instance |
Rules | object [] | No | The evaluation rules. | |
Identifier | string | No | The identifier of the evaluation rule. For more information about how to obtain the identifier of an evaluation rule, see ListManagedRules . | ecs-instance-deletion-protection-enabled |
InputParameters | string | No | The input parameters of the evaluation rule. | {} |
ResourceProperties | string | No | The properties of the resource. | { "ImageId": "ubuntu_18_04_64_20G_alibase_20190624.vhd", "SecurityGroupId": "sg-bp15ed6xe1yxeycg****", "HostName": "LocalHostName", "RegionId": "cn-hangzhou" } |
EnableManagedRules | boolean | No | Specifies whether to enable the managed rule. Valid values:
Note
After you create an evaluation rule, a managed rule that has the same settings as the evaluation rule is created. After you create a resource, the managed rule can be used to continuously check the compliance of the resource.
| false |
For more information about common request parameters, see Common parameters.
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "129ECF1C-7897-1131-BD0F-4B588AC05400",
"ResourceEvaluations": [
{
"ResourceLogicalId": "ResourceLogicId-test",
"ResourceType": "ACS::ECS::Instance",
"Rules": [
{
"Identifier": "ecs-instance-deletion-protection-enabled",
"ComplianceType": "NON_COMPLIANT",
"Annotation": "{\\\"configuration\\\":\\\"false\\\",\\\"desiredValue\\\":\\\"True\\\",\\\"operator\\\":\\\"StringEquals\\\",\\\"property\\\":\\\"$.DeletionProtection\\\"}",
"HelpUrl": "https://example.aliyundoc.com"
}
]
}
]
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||
---|---|---|---|---|
2023-06-13 | The internal configuration of the API is changed, but the call is not affected | see changesets | ||
|