starknet_estimateMessageFee RPC Method
Parameters
MSG_FROM_L1
object
REQUIRED
The Message from L1 object which contains the following fields:
from_address
string
REQUIRED
The address of the L1 contract sending the message
to_address
string
REQUIRED
The target L2 address the message is sent to
entry_point_selector
string
REQUIRED
The selector of the l1_handler in invoke in the target contract
payload
array
REQUIRED
The payload of the message
block_id
string
REQUIRED
The hash of the requested block, the block number (height) of the requested block, or a block tag (latest or pending)
Returns
result
array
Array of fee estimation results
l1_data_gas_consumed
string
The amount of Layer 1 data gas consumed by the transaction
l1_data_gas_price
string
The price per unit of Layer 1 data gas (in WEI)
l1_gas_consumed
string
The amount of Layer 1 execution gas consumed by the transaction
l1_gas_price
string
The price per unit of Layer 1 execution gas (in WEI)
l2_gas_consumed
string
The amount of Layer 2 gas consumed by the transaction
l2_gas_price
string
The price per unit of Layer 2 gas (in WEI)
overall_fee
string
The total estimated fee for the transaction in WEI, computed using all gas consumed and respective prices
unit
string
The unit in which the overall fee is expressed
Request
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free