Websites - Get WAF Rules
Get the web application firewall rules associated with the given website.
GET https://api.powerplatform.com/powerpages/environments/{environmentId}/websites/{id}/getWafRules?api-version=2022-03-01-preview
GET https://api.powerplatform.com/powerpages/environments/{environmentId}/websites/{id}/getWafRules?ruleType={ruleType}&api-version=2022-03-01-preview
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
environment
|
path | True |
string |
The environment ID. |
|
id
|
path | True |
string |
Website unique identifier (ID). |
|
api-version
|
query | True |
string |
The API version. |
|
rule
|
query |
string |
Type of web application firewall rules to retrieve. |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
Success |
|
| 400 Bad Request |
Bad Request |
|
| 401 Unauthorized |
Unauthorized |
|
| 404 Not Found |
Not Found |
Security
oauth2
Microsoft Entra ID OAuth2
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize?resource=https://api.powerplatform.com
Scopes
| Name | Description |
|---|---|
| .default | .default |
Definitions
| Name | Description |
|---|---|
|
Custom |
|
| Details | |
| Error | |
|
Error |
|
|
Managed |
|
|
Match |
|
|
Rule |
|
| Rules | |
|
Waf |
Action to take for the rule |
|
Waf |
|
|
Web |
CustomRule
| Name | Type | Description |
|---|---|---|
| action |
enum:
|
Action to take when the rule matches |
| enabledState |
enum:
|
State of the rule |
| matchConditions | ||
| name |
string |
Name of the custom rule |
| priority |
integer (int32) |
Priority of the rule |
| rateLimitDurationInMinutes |
integer (int32) |
Duration in minutes for rate limiting |
| rateLimitThreshold |
integer (int32) |
Threshold for rate limiting |
| ruleType |
Details
| Name | Type | Description |
|---|---|---|
| code |
string |
Error code |
| message |
string |
Error message |
| target |
string |
Target parameter |
Error
| Name | Type | Description |
|---|---|---|
| code |
string |
Error code |
| details |
Details[] |
|
| message |
string |
Error message |
| target |
string |
Target parameter |
ErrorMessage
| Name | Type | Description |
|---|---|---|
| error |
ManagedRules
| Name | Type | Description |
|---|---|---|
| Exclusions |
string[] |
List of exclusions for the rule set |
| RuleGroupOverrides | ||
| RuleSetAction |
enum:
|
Action to take for the rule set |
| RuleSetType |
string |
Type of the managed rule set |
| RuleSetVersion |
string |
Version of the managed rule set |
MatchConditions
| Name | Type | Description |
|---|---|---|
| matchValue |
string[] |
Values to match |
| matchVariable |
string |
Variable to match |
| negateCondition |
boolean |
Whether to negate the condition |
| operator |
enum:
|
Operator for the match condition |
| selector |
string |
Selector for the match variable |
| transforms |
string[] |
Transformations to apply |
RuleGroupOverrides
| Name | Type | Description |
|---|---|---|
| Exclusions |
string[] |
List of exclusions for the rule group |
| RuleGroupName |
string |
Name of the rule group |
| Rules |
Rules[] |
Rules
| Name | Type | Description |
|---|---|---|
| Action |
Action to take for the rule |
|
| EnabledState |
enum:
|
State of the rule |
| Exclusions |
string[] |
List of exclusions for the rule |
| RuleId |
string |
ID of the rule |
WafRuleAction
Action to take for the rule
| Value | Description |
|---|---|
| Allow | |
| Block | |
| Log | |
| AnomalyScoring |
WafRuleType
| Value | Description |
|---|---|
| MatchRule | |
| RateLimitRule |
WebApplicationFirewallConfiguration
| Name | Type | Description |
|---|---|---|
| CustomRules | ||
| ManagedRules |