Lists the rulesets under the current WAF execution phase. Queries basic information and status of rulesets with paging support.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
esa:ListWafRulesets |
get |
*Site
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| SiteId |
integer |
Yes |
The site ID. You can call the ListSites operation to obtain the site ID. |
1 |
| SiteVersion |
integer |
No |
The version number of the site configuration. For sites with configuration version management enabled, you can use this parameter to specify the site version for which the configuration takes effect. Default value: 0. |
0 |
| Phase |
string |
Yes |
The WAF rule execution phase. Valid values:
|
http_bot |
| QueryArgs |
object |
No |
The query parameters, passed in JSON format, including various filter conditions. |
http_bot |
| NameLike |
string |
No |
The fuzzy match string for the ruleset name. |
example |
| AnyLike |
string |
No |
The fuzzy match string for the ruleset ID, ruleset name, rule ID, or rule name. |
example |
| OrderBy |
string |
No |
The column by which to sort the results. |
id |
| Desc |
boolean |
No |
Specifies whether to sort the results in descending order. |
|
| PageNumber |
integer |
No |
The page number. Specifies the current page number for paging queries. |
1 |
| PageSize |
integer |
No |
The page size. Specifies the number of records per page for paging queries. |
20 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
Schema of Response |
||
| RequestId |
string |
The request ID. |
36af3fcc-43d0-441c-86b1-428951dc8225 |
| SiteUsage |
integer |
The number of WAF rulesets used by the site in this WAF execution phase. |
5 |
| InstanceUsage |
integer |
The number of WAF rulesets used by the instance in this WAF execution phase. |
10 |
| TotalCount |
integer |
The total number of records after filtering. |
5 |
| Rulesets |
array<object> |
The list of rulesets, including detailed information about each ruleset. |
|
|
object |
The ruleset information. |
||
| UpdateTime |
string |
The last modification time of the ruleset. Format: RFC 3339 / ISO 8601, UTC time zone (ending with Z). Example: 2026-06-10T14:23:45Z |
2024-01-01T00:00:00Z |
| Id |
integer |
The ID of the WAF ruleset. You can call the ListWafRulesets operation to obtain the ruleset ID. |
10000001 |
| Name |
string |
The ruleset name. |
example |
| Status |
string |
The ruleset status. |
on |
| Phase |
string |
The WAF rule execution phase. Valid values:
|
http_bot |
| Types |
array |
The list of rule types. |
|
|
string |
The rule type. |
http_custom_cc |
|
| Target |
string |
The protection target type in http_bot. |
web |
| Fields |
array |
The list of match objects. |
|
|
string |
The match object. |
http.request.headers |
|
| PageNumber |
integer |
The current page number. |
1 |
| PageSize |
integer |
The page size. |
20 |
Examples
Success response
JSON format
{
"RequestId": "36af3fcc-43d0-441c-86b1-428951dc8225",
"SiteUsage": 5,
"InstanceUsage": 10,
"TotalCount": 5,
"Rulesets": [
{
"UpdateTime": "2024-01-01T00:00:00Z",
"Id": 10000001,
"Name": "example",
"Status": "on",
"Phase": "http_bot",
"Types": [
"http_custom_cc"
],
"Target": "web",
"Fields": [
"http.request.headers"
]
}
],
"PageNumber": 1,
"PageSize": 20
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidParameter | The specified parameter is invalid. | The specified parameter is invalid. |
| 400 | InternalException | Failed to call the service. Try again later or contact technical support. | Failed to call the service. Try again later or contact technical support. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.