Skip to content

approveAllowance

function approveAllowance(client, options): Promise<`0x${string}`>;

Defined in: packages/synapse-core/src/erc20.ts:119

Approve the allowance of the ERC20 token to the payments contract.

ParameterTypeDescription
clientClient<Transport, Chain, Account>The client to use.
optionsERC20ApproveAllowanceOptionsThe props to use.

Promise<`0x${string}`>

The hash of the approve transaction.

  • SimulateContractErrorType if the simulate contract fails.
  • WriteContractErrorType if the write contract fails.