ModuleSDK
Accounts
encodeValidatorNonce

encodeValidatorNonce

Encodes the validator address in the nonce key to use in ERC-7579 accounts.

Usage

const nonce = await getAccountNonce(publicClient, {
  address: account.address,
  entryPointAddress: entryPoint07Address,
  key: encodeValidatorNonce({ account, validator: validatorModule }),
})

Parameters

account

The account object.

validator

The validator module object.

Returns

  • Type bigint

The encoded validator nonce key to query the ERC-4337 EntryPoint with.