All Products
Search
Document Center

Cloud Config:ListRemediations

Last Updated:Jun 17, 2024

Queries the information about the execution of remediation templates.

Operation description

This topic provides an example on how to query the remediation templates for the rule whose ID is cr-6b7c626622af00b4****.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
config:ListRemediationsList
  • All Resources
    *
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ConfigRuleIdsstringNo

The rule IDs. Separate multiple rule IDs with commas (,).

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

cr-6b7c626622af00b4****
PageNumberlongNo

The page number. Pages start from page 1.

1
PageSizelongNo

The number of entries per page. Valid values: 1 to 50.

10

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

Response parameters

ParameterTypeDescriptionExample
object

None

RequestIdstring

The request ID.

0146963A-20C0-4E75-B93A-7D622B5FD7C8
Remediationsobject []

The converted configuration of the remediation template. This parameter is returned only for an OOS remediation template.

LastSuccessfulInvocationTypestring

The mode of the last successful execution of the remediation template. Valid values:

  • NON_EXECUTION: The remediation template was not executed.
  • AUTO_EXECUTION: The remediation template was automatically executed.
  • MANUAL_EXECUTION: The remediation template was manually executed.
  • NOT_CONFIG: The execution mode was not specified.
AUTO_EXECUTION
RemediationTemplateIdstring

The ID of the remediation template.

ACS-OSS-PutBucketAcl
RemediationIdstring

The ID of the remediation template.

crr-6b7c626622af0026****
RemediationSourceTypestring

The source of remediation. Valid values:

  • ALIYUN: official template.
  • CUSTOM: custom template.
  • NONE: none.
ALIYUN
RemediationTypestring

The type of the remediation template. Valid values:

  • OOS: Operation Orchestration Service (official remediation)
  • FC: Function Compute (custom remediation)
OOS
LastSuccessfulInvocationIdstring

The ID of the last successful execution of the remediation template.

bd7629fb-cac8-42fe-bcb1-e362c5a6****
AccountIdlong

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

100931896542****
InvokeTypestring

The execution mode of the remediation template. Valid values:

  • NON_EXECUTION: The remediation template was not executed.
  • AUTO_EXECUTION: The remediation template was automatically executed.
  • MANUAL_EXECUTION: The remediation template was manually executed.
  • NOT_CONFIG: The execution mode was not specified.
AUTO_EXECUTION
ConfigRuleIdstring

The rule ID.

cr-6b7c626622af00b4****
LastSuccessfulInvocationTimelong

The timestamp of the last successful execution of the remediation template Unit: milliseconds.

1625451393589
RemediationOriginParamsstring

The converted configuration of the remediation template. This parameter is available only for an OOS remediation template.

{"bucketName": "{resourceId}", "regionId": "{regionId}", "permissionName": "private"}
PageNumberlong

The page number. Pages start from page 1.

1
PageSizelong

The number of entries per page. Valid values: 1 to 50.

10
TotalCountstring

The total number of remediation settings.

1

Examples

Sample success responses

JSONformat

{
  "RequestId": "0146963A-20C0-4E75-B93A-7D622B5FD7C8",
  "Remediations": [
    {
      "LastSuccessfulInvocationType": "AUTO_EXECUTION",
      "RemediationTemplateId": "ACS-OSS-PutBucketAcl",
      "RemediationId": "crr-6b7c626622af0026****",
      "RemediationSourceType": "ALIYUN",
      "RemediationType": "OOS",
      "LastSuccessfulInvocationId": "bd7629fb-cac8-42fe-bcb1-e362c5a6****",
      "AccountId": 0,
      "InvokeType": "AUTO_EXECUTION",
      "ConfigRuleId": "cr-6b7c626622af00b4****",
      "LastSuccessfulInvocationTime": 1625451393589,
      "RemediationOriginParams": "{\"bucketName\": \"{resourceId}\", \"regionId\": \"{regionId}\", \"permissionName\": \"private\"}"
    }
  ],
  "PageNumber": 1,
  "PageSize": 10,
  "TotalCount": "1"
}

Error codes

HTTP status codeError codeError messageDescription
404AccountNotExistedYour account does not exist.The specified account does not exist.
503ServiceUnavailableThe request has failed due to a temporary failure of the server.The request has failed due to a temporary failure of the server.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2023-04-24The Error code has changed. The request parameters of the API has changed. The response structure of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 404
    delete Error Codes: 503
Input ParametersThe request parameters of the API has changed.
    Added Input Parameters: PageNumber
    Added Input Parameters: PageSize
Output ParametersThe response structure of the API has changed.