Fee

@Serializable
sealed class Fee

Represents a transaction fee structure.

Fee models:

maxFeeWei is the total maximum fee (L2 execution + L1 data when l1FeeWei is set). Use it for display, balance checks, and "send max" (e.g. balance - fee.maxFeeWei).

Inheritors

Properties

Link copied to clipboard
abstract val gasLimit: BigInteger

Gas limit for the transaction.

Link copied to clipboard
abstract val l1FeeWei: BigInteger?

L1 data fee in wei (Base/OP Stack L2s). Null on L1 or when not estimated.

Link copied to clipboard
abstract val maxFeeWei: BigInteger

Maximum total fee in the network's smallest unit (e.g. wei). Includes L2 execution cost and, on L2s (e.g. Base), l1FeeWei when set. Serialized so Flutter can use it without duplicating logic; use for total cost and reserving balance.