CheckCapacity
Source:
src/AWS/WAFv2/CheckCapacity.ts
Runtime binding for wafv2:CheckCapacity — compute the web ACL capacity
units (WCU) a set of rules would consume, e.g. before updating an IP set
or constructing rules dynamically.
Provide WAFv2.CheckCapacityHttp on the hosting Lambda Function to
satisfy the requirement.
Account Operations
Section titled “Account Operations”// init — grants wafv2:CheckCapacityconst checkCapacity = yield* AWS.WAFv2.CheckCapacity();
// runtimeconst { Capacity } = yield* checkCapacity({ Scope: "REGIONAL", Rules: [rule],});