CheckCapacity
Returns the web ACL capacity unit (WCU) requirements for a specified scope and set of rules. You can use this to check the capacity requirements for the rules you want to use in a RuleGroup or WebACL.
AWS WAF uses WCUs to calculate and control the operating resources that are used to run your rules, rule groups, and web ACLs. AWS WAF calculates capacity differently for each rule type, to reflect the relative cost of each rule. Simple rules that cost little to run use fewer WCUs than more complex rules that use more processing power. Rule group capacity is fixed at creation, which helps users plan their web ACL WCU usage when they use a rule group. For more information, see AWS WAF web ACL capacity units (WCU) in the AWS WAF Developer Guide.
Request Syntax
{
"Rules": [
{
"Action": {
"Allow": {
"CustomRequestHandling": {
"InsertHeaders": [
{
"Name": "string",
"Value": "string"
}
]
}
},
"Block": {
"CustomResponse": {
"CustomResponseBodyKey": "string",
"ResponseCode": number,
"ResponseHeaders": [
{
"Name": "string",
"Value": "string"
}
]
}
},
"Captcha": {
"CustomRequestHandling": {
"InsertHeaders": [
{
"Name": "string",
"Value": "string"
}
]
}
},
"Challenge": {
"CustomRequestHandling": {
"InsertHeaders": [
{
"Name": "string",
"Value": "string"
}
]
}
},
"Count": {
"CustomRequestHandling": {
"InsertHeaders": [
{
"Name": "string",
"Value": "string"
}
]
}
},
"Monetize": {
"PriceMultiplier": "string"
}
},
"CaptchaConfig": {
"ImmunityTimeProperty": {
"ImmunityTime": number
}
},
"ChallengeConfig": {
"ImmunityTimeProperty": {
"ImmunityTime": number
}
},
"Name": "string",
"OverrideAction": {
"Count": {
"CustomRequestHandling": {
"InsertHeaders": [
{
"Name": "string",
"Value": "string"
}
]
}
},
"None": {
}
},
"Priority": number,
"RuleLabels": [
{
"Name": "string"
}
],
"Statement": {
"AndStatement": {
"Statements": [
"Statement"
]
},
"AsnMatchStatement": {
"AsnList": [ number ],
"ForwardedIPConfig": {
"FallbackBehavior": "string",
"HeaderName": "string"
}
},
"ByteMatchStatement": {
"FieldToMatch": {
"AllQueryArguments": {
},
"Body": {
"OversizeHandling": "string"
},
"Cookies": {
"MatchPattern": {
"All": {
},
"ExcludedCookies": [ "string" ],
"IncludedCookies": [ "string" ]
},
"MatchScope": "string",
"OversizeHandling": "string"
},
"HeaderOrder": {
"OversizeHandling": "string"
},
"Headers": {
"MatchPattern": {
"All": {
},
"ExcludedHeaders": [ "string" ],
"IncludedHeaders": [ "string" ]
},
"MatchScope": "string",
"OversizeHandling": "string"
},
"JA3Fingerprint": {
"FallbackBehavior": "string"
},
"JA4Fingerprint": {
"FallbackBehavior": "string"
},
"JsonBody": {
"InvalidFallbackBehavior": "string",
"MatchPattern": {
"All": {
},
"IncludedPaths": [ "string" ]
},
"MatchScope": "string",
"OversizeHandling": "string"
},
"Method": {
},
"QueryString": {
},
"SingleHeader": {
"Name": "string"
},
"SingleQueryArgument": {
"Name": "string"
},
"UriFragment": {
"FallbackBehavior": "string"
},
"UriPath": {
}
},
"PositionalConstraint": "string",
"PreParseTextTransformations": [
{
"Priority": number,
"Type": "string"
}
],
"SearchString": blob,
"TextTransformations": [
{
"Priority": number,
"Type": "string"
}
]
},
"GeoMatchStatement": {
"CountryCodes": [ "string" ],
"ForwardedIPConfig": {
"FallbackBehavior": "string",
"HeaderName": "string"
}
},
"IPSetReferenceStatement": {
"ARN": "string",
"IPSetForwardedIPConfig": {
"FallbackBehavior": "string",
"HeaderName": "string",
"Position": "string"
}
},
"LabelMatchStatement": {
"Key": "string",
"Scope": "string"
},
"ManagedRuleGroupStatement": {
"ExcludedRules": [
{
"Name": "string"
}
],
"ManagedRuleGroupConfigs": [
{
"AWSManagedRulesACFPRuleSet": {
"CreationPath": "string",
"EnableRegexInPath": boolean,
"RegistrationPagePath": "string",
"RequestInspection": {
"AddressFields": [
{
"Identifier": "string"
}
],
"EmailField": {
"Identifier": "string"
},
"PasswordField": {
"Identifier": "string"
},
"PayloadType": "string",
"PhoneNumberFields": [
{
"Identifier": "string"
}
],
"UsernameField": {
"Identifier": "string"
}
},
"ResponseInspection": {
"BodyContains": {
"FailureStrings": [ "string" ],
"SuccessStrings": [ "string" ]
},
"Header": {
"FailureValues": [ "string" ],
"Name": "string",
"SuccessValues": [ "string" ]
},
"Json": {
"FailureValues": [ "string" ],
"Identifier": "string",
"