PolicyViolationError
Defined in: kit/src/policies.ts:243
Thrown before anything is signed when a write breaks a rule in Policies. A rejected
confirm throws UserRejectedError from core instead.
Extends
Section titled “Extends”Error
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new PolicyViolationError(
policy,message):PolicyViolationError
Defined in: kit/src/policies.ts:250
Parameters
Section titled “Parameters”policy
Section titled “policy”"chain" | "maxFee" | "allowlist" | "blocklist" | "method"
message
Section titled “message”string
Returns
Section titled “Returns”PolicyViolationError
Overrides
Section titled “Overrides”Error.constructor
Properties
Section titled “Properties”policy
Section titled “policy”
readonlypolicy:"chain"|"maxFee"|"allowlist"|"blocklist"|"method"
Defined in: kit/src/policies.ts:249
The rule that refused the write. chain means the account’s chain id is unknown, so no rule
could be matched. method means the method is not part of the write surface the policies
can read (see GUARDED_WRITES).