DescribeRules
Lists all data protection rules.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
bdrc:DescribeRules |
none |
*All Resource
|
None | None |
Request syntax
GET /api/v1/rules HTTP/1.1
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| ResourceType |
string |
No |
The resource type. |
ACS::ECS::Instance |
| NextToken |
string |
No |
The token to retrieve the next page of results. You can obtain this token from the |
cae**********699 |
| MaxResults |
integer |
No |
The number of entries to return on each page. Maximum value: 50. Default value: 10. |
10 |
| ResourceCategoryId |
string |
No |
The resource category ID. |
rc-000***123 |
| ResourceRegionId |
string |
No |
The ID of the region where the resource resides. |
cn-hangzhou |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
BaseResponse<ListResult |
||
| Data |
object |
The returned data. |
|
| Content |
array<object> |
The list of returned records. |
|
|
object |
|||
| RuleId |
string |
The unique ID of the rule. |
rule-bp11ggd8wr762 |
| ProductType |
string |
The product type to which the rule applies. |
ecs |
| ResourceType |
string |
The resource type to which the rule applies. |
ACS::ECS::Instance |
| RuleTemplate |
string |
The rule template. |
ecs-backup |
| CheckStatus |
string |
The check status. Valid values: NOT_CHECKED (Not checked), PASSED (Passed), FAILED (Failed), CHECKING (Checking), and CHECK_FAILED (Check failed). |
PASSED |
| CheckTime |
integer |
The UNIX timestamp that indicates when the check was performed. |
1704157635 |
| TotalResourceCount |
integer |
The total number of resources that were checked. |
1 |
| RiskyResourceCount |
integer |
The number of at-risk resources. |
0 |
| CheckFailedResourceCount |
integer |
The number of resources for which the check failed. |
0 |
| NextToken |
string |
The token that is used to retrieve the next page of results. If this parameter is empty, all results have been returned. |
0975951c75d7b41464c8d08ae17043ca |
| MaxResults |
integer |
The maximum number of entries returned on the current page. |
10 |
| TotalCount |
integer |
The total number of entries that meet the filter criteria. This parameter is optional and is not returned by default. |
42 |
| RequestId |
string |
The unique ID of the request. |
86DEBAC9-AB6A-59AB-9E5C-A540E579ECC9 |
Examples
Success response
JSON format
{
"Data": {
"Content": [
{
"RuleId": "rule-bp11ggd8wr762",
"ProductType": "ecs",
"ResourceType": "ACS::ECS::Instance",
"RuleTemplate": "ecs-backup",
"CheckStatus": "PASSED",
"CheckTime": 1704157635,
"TotalResourceCount": 1,
"RiskyResourceCount": 0,
"CheckFailedResourceCount": 0
}
],
"NextToken": "0975951c75d7b41464c8d08ae17043ca",
"MaxResults": 10,
"TotalCount": 42
},
"RequestId": "86DEBAC9-AB6A-59AB-9E5C-A540E579ECC9"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.