Skip to content

Authorization Errors

Authorization.InvalidError

Thrown when an EIP-7702 Authorization tuple is structurally invalid.

Examples

import { Authorization } from 'ox'
 
Authorization.fromTuple([
  '0x1',
  '0xbe95c3f554e9fc85ec51be69a3d807a0d55bcf2c',
  '0x3',
  '0x1'
])
Authorization.InvalidError: Invalid authorization.
Details: Expected [chainId, address, nonce] or [chainId, address, nonce, yParity, r, s].

Source: src/core/Authorization.ts