EvmLegacyFee

@Serializable
@SerialName(value = "evm_legacy")
data class EvmLegacyFee(val maxFeeWei: BigInteger, val l1FeeWei: BigInteger? = null, val gasLimit: BigInteger, val gasPrice: BigInteger) : Fee

Represents a legacy EVM fee structure (pre-EIP-1559).

In the legacy model, the fee is calculated as: totalFee = gasPrice * gasLimit

The entire gasPrice goes to the miner/validator as a tip.

See also

Constructors

Link copied to clipboard
constructor(maxFeeWei: BigInteger, l1FeeWei: BigInteger? = null, gasLimit: BigInteger, gasPrice: BigInteger)
constructor(gasPrice: BigInteger, gasLimit: BigInteger, l1FeeWei: BigInteger? = null)

Properties

Link copied to clipboard
@Serializable(with = BigIntegerSerializer::class)
open override val gasLimit: BigInteger

The maximum amount of gas units this transaction can consume

Link copied to clipboard
@Serializable(with = BigIntegerSerializer::class)
val gasPrice: BigInteger

The price per unit of gas in wei

Link copied to clipboard
@Serializable(with = BigIntegerSerializer::class)
open override val l1FeeWei: BigInteger?

L1 data fee in wei on L2s (e.g. Base); null on L1. Included in maxFeeWei.

Link copied to clipboard
@Serializable(with = BigIntegerSerializer::class)
open override 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.