How to estimate gas fees
Transaction fees (or "gas fees") can vary significantly depending on network activity, so having a reliable estimation method is crucial for a smooth user experiences.
To ensure that your transaction doesn't remain in "pending" status for too long, you should include enough to cover the fees:
Minimum gas fee: 2,501 gwei.
Minimum priority fee: 1 gwei.
What does it mean for Chiliz Chain developers?
Just like with any blockchain, you must pay gas for every transaction on Chiliz Chain.
The key is to balance cost-effectiveness with timely confirmations to avoid failing or delayed transactions. Keeping your gas estimates up to date helps prevent both overpaying and underpaying.
How to do it natively
If you want to keep it vanilla, you can rely on a cURL to a Chiliz Chain RPC. See here: How to get the current gas price.
How to do it using Blocknative?
Blocknative builds infrastructure to monitor and manage the complexity of transacting on public blockchain networks.
Blocknative’s Gas API offers a reliable, real-time approach to retrieving gas prices.
Step 1: Get a key
To use Blocknative's Gas API in your project, you will need an API Key.
You will need to join the Gas Network first, which will give you access to your own API key.
Step 2: Implement the call to the Gas API
Once you have an API key, you can request fee estimation for Chiliz.
The simplest way is to call on the API via a REST request. For instance, via command line:
curl -H "Authorization: your-apikey-here" https://api.blocknative.com/gasprices/blockprices?chainid=88888
Learn more in the Blocknative documentation.
Last updated
Was this helpful?