Skip to content

[General] Gas price estimation on ZKsync chains #832

Discussion options

You must be logged in to vote

Hey! Here’s some clarification:

  1. Gas Price Estimation:
    Yes, it’s recommended to use zks_estimateFee. This works seamlessly with the zksync-ethers and viem SDKs.

  2. EIP-1559 Parameters:
    In fact maxFeePerGas is utilized and includes the base fee, so it’s sufficient to use that in transactions. maxPriorityFeePerGas is not utilized, as ZKsync doesn’t have a concept of priority fees. The server likely returns 0 for this parameter. We're currently fixing the documentation to make this clearer and fix that error.

  3. gasPerPubdata Parameter:
    This is only required for eip-712 transactions. You can continue using the eip-1559 format, which ZKsync supports well. Transaction inclusion shouldn’t differ…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by JackHamer09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
General
Labels
general General question
2 participants