Skip to main content

IAllowanceTypes

Asset Tokenization Studio Team

IAllowanceTypes

Events and errors emitted by the ERC-20 allowance surface.

Events​

Approval​

event Approval(address indexed owner, address indexed spender, uint256 value)

Emitted when owner authorises spender to spend up to value tokens on their behalf, whether via {IAllowance.approve}, {IAllowance.increaseAllowance} or {IAllowance.decreaseAllowance}.

Mirrors the ERC-20 Approval event. value is the resulting, absolute allowance after the update — not the delta applied.

Parameters​

NameTypeDescription
owner indexedaddressAddress whose tokens may be spent.
spender indexedaddressAddress authorised to spend on owner's behalf.
valueuint256Allowance of spender over owner's tokens after the update.

Errors​

InsufficientAllowance​

error InsufficientAllowance(address spender, address from)

Reverts when spender attempts to consume more allowance than from has granted.

Raised by transferFrom-style flows and by {IAllowance.decreaseAllowance} when the subtracted amount exceeds the current allowance.

Parameters​

NameTypeDescription
spenderaddressAddress attempting to spend on behalf of from.
fromaddressAddress whose allowance is being consumed.

SpenderWithZeroAddress​

error SpenderWithZeroAddress()

Reverts when the zero address is supplied as spender in an allowance update.