EstimateFeeResponse

@Serializable
data class EstimateFeeResponse(val l1GasConsumed: Uint64, val l1GasPrice: Uint128, val l2GasConsumed: Uint64, val l2GasPrice: Uint128, val l1DataGasConsumed: Uint64, val l1DataGasPrice: Uint128, val overallFee: Uint128, val feeUnit: PriceUnit? = null) : StarknetResponse

Constructors

Link copied to clipboard
constructor(l1GasConsumed: Uint64, l1GasPrice: Uint128, l2GasConsumed: Uint64, l2GasPrice: Uint128, l1DataGasConsumed: Uint64, l1DataGasPrice: Uint128, overallFee: Uint128, feeUnit: PriceUnit? = null)

Properties

Link copied to clipboard
@SerialName(value = "unit")
val feeUnit: PriceUnit? = null
Link copied to clipboard
@SerialName(value = "l1_data_gas_consumed")
val l1DataGasConsumed: Uint64
Link copied to clipboard
@SerialName(value = "l1_data_gas_price")
val l1DataGasPrice: Uint128
Link copied to clipboard
@SerialName(value = "l1_gas_consumed")
val l1GasConsumed: Uint64
Link copied to clipboard
@SerialName(value = "l1_gas_price")
val l1GasPrice: Uint128
Link copied to clipboard
@SerialName(value = "l2_gas_consumed")
val l2GasConsumed: Uint64
Link copied to clipboard
@SerialName(value = "l2_gas_price")
val l2GasPrice: Uint128
Link copied to clipboard
@SerialName(value = "overall_fee")
val overallFee: Uint128

Functions

Link copied to clipboard
fun toMaxFee(multiplier: Double = 1.5): Felt

Convert estimated fee to max fee with applied multiplier.

Link copied to clipboard
fun toResourceBounds(amountMultiplier: Double = 1.5, unitPriceMultiplier: Double = 1.5): ResourceBoundsMapping

Convert estimated fee to resource bounds with applied multipliers.