Queries hot parameter protection rules for HTTP requests.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
mse:ListWebFlowRules |
list |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| Namespace |
string |
No |
The namespace. |
default |
| AppName |
string |
Yes |
The application name. |
spring-cloud-a |
| ResourceSearchKey |
string |
No |
The interface keyword that you can search from protection rules. This parameter is mutually exclusive with the Resource parameter. |
flow |
| AppId |
string |
No |
The application ID. |
b22qb1****@2f0586be4b1**** |
| Resource |
string |
No |
The interface to which the protection rule applies. This parameter is mutually exclusive with the ResourceSearchKey parameter. |
/flow |
| PageIndex |
integer |
No |
The first page to export. Default value: 1. |
1 |
| PageSize |
integer |
No |
The number of entries to return on each page. |
10 |
| AcceptLanguage |
string |
No |
The language in which the returned results are displayed. Valid values: zh (default): Chinese. en: English. |
zh |
Response elements
|
Parameter |
Type |
Description |
Example |
|
object |
|||
| Code |
integer |
The response code. |
200 |
| Message |
string |
The returned message. |
OK |
| RequestId |
string |
The request ID. |
4AE73569-304C-5AA9-AE11-C1D99C7D1689 |
| Success |
boolean |
Indicates whether the request was successful. Valid values:
|
true |
| Data |
object |
The data returned. |
|
| Result |
array |
The returned results. |
|
|
object |
Rule information |
||
| Namespace |
string |
The namespace. |
default |
| StatIntervalMs |
integer |
The length of the time window. Unit: milliseconds. |
1000 |
| RuleId |
string |
The rule ID. |
1 |
| AppName |
string |
The application name. |
spring-cloud-a |
| Resource |
string |
The name of the interface resource. |
/flow |
| ResourceType |
integer |
The resource type
|
1 |
| ControlBehavior |
integer |
The flow control method. Valid values:
|
0 |
| Burst |
integer |
The number of additional requests allowed for burst requests. The effect is equivalent to the maximum number of tokens for the token bucket algorithm. |
0 |
| MaxQueueingTimeMs |
integer |
The timeout period for queuing when the ControlBehavior parameter is set to 2. Unit: milliseconds. |
200 |
| ResourceMode |
integer |
The resource mode. Valid values:
|
0 |
| Threshold |
number |
The threshold. |
20 |
| Enable |
boolean |
Indicates whether the rule is enabled or disabled.
|
true |
| ParamItem |
string |
The parameter description item, which is a JSON string containing the following key-value pairs:
|
{"fieldName":"testKey","matchStrategy":2,"parseStrategy":2,"pattern":"testValue"} |
| AppId |
string |
The application ID. |
hkhon1XXXX@c3df23522bXXXXX |
| MetricType |
integer |
The threshold type. Valid values:
|
1 |
| RegionId |
string |
The region ID. |
cn-hangzhou |
| FallbackObject |
string |
The behavior that was bound to the rule. |
{\"appName\":\"spring-cloud-a\",\"fallbackBehavior\":{\"webFallbackMode\":0,\"webRespContentType\":0,\"webRespMessage\":\"Blocked\",\"webRespStatusCode\":429},\"id\":977,\"name\":\"Fallback\",\"namespace\":\"default\",\"resourceClassification\":1} |
| PageNumber |
integer |
The page number. |
1 |
| PageSize |
integer |
The number of entries returned per page. |
10 |
| TotalSize |
integer |
The total number of queried rules. |
36 |
| HttpStatusCode |
integer |
The HTTP status code. |
200 |
Examples
Success response
JSON format
{
"Code": 200,
"Message": "OK",
"RequestId": "4AE73569-304C-5AA9-AE11-C1D99C7D1689",
"Success": true,
"Data": {
"Result": [
{
"Namespace": "default",
"StatIntervalMs": 1000,
"RuleId": "1",
"AppName": "spring-cloud-a",
"Resource": "/flow",
"ResourceType": 1,
"ControlBehavior": 0,
"Burst": 0,
"MaxQueueingTimeMs": 200,
"ResourceMode": 0,
"Threshold": 20,
"Enable": true,
"ParamItem": "{\"fieldName\":\"testKey\",\"matchStrategy\":2,\"parseStrategy\":2,\"pattern\":\"testValue\"}",
"AppId": "hkhon1XXXX@c3df23522bXXXXX",
"MetricType": 1,
"RegionId": "cn-hangzhou",
"FallbackObject": "{\\\"appName\\\":\\\"spring-cloud-a\\\",\\\"fallbackBehavior\\\":{\\\"webFallbackMode\\\":0,\\\"webRespContentType\\\":0,\\\"webRespMessage\\\":\\\"Blocked\\\",\\\"webRespStatusCode\\\":429},\\\"id\\\":977,\\\"name\\\":\\\"Fallback\\\",\\\"namespace\\\":\\\"default\\\",\\\"resourceClassification\\\":1}"
}
],
"PageNumber": 1,
"PageSize": 10,
"TotalSize": 36
},
"HttpStatusCode": 200
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | IllegalRequest | Invalid request:%s | Invalid request: %s |
| 400 | InvalidParameter | Parameter error:%s | Request parameter error: %s |
| 500 | InternalError | Console error. Try again later:%s | Console error. Try again later: %s |
| 403 | NoPermission | You are not authorized to perform this operation:%s | You do not have the permission to use this interface:%s |
| 404 | NotFound | Not found:%s | The resource does not exist:%s |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.