POSTklay_feeHistory
Returns gas fee history for the requested block range. Use this information to set appropriate values for maxFeePerGas and maxPriorityFeePerGas when creating transactions.
Enter the following parameters as an array with the appropriate types.
block count: Enter the block range to query. Block range must be an integer between 1 and 1024. Fewer blocks may be returned if not all requested blocks are available.newest block: Enter the reference block for the query. Block number as hexadecimal string or "latest".reward percentiles: Enter an array of integers for sampling priority fee percentiles. Percentiles are weighted by gas used per block. Percentiles must be integers from 0 to 100 in ascending order.
The number of blocks to query. Enter an integer from 1 to 1024. Fewer blocks than requested may be returned if not all blocks are available.
Use one of block number or block tag to specify the block.
- Block number: Hexadecimal string (e.g. "0x1")
- Block tag: Enum string (e.g. "latest", "earliest", "pending")
earliest: The oldest available block on the chain.finalized: A recently finalized block that can no longer be changed. Primarily used in proof-of-stake (PoS) blockchains.safe: A recent block considered safe by the network (immune to reorgs).latest: The most recent block on the chain (may be subject to reorgs).pending: The next block to be mined, including pending transactions in the mempool.
An array of percentile values used to sample priority fees. Percentiles are weighted by the gas used in each block. Enter integers from 0 to 100 in ascending order.
Oldest block number in the returned range (hex)
Array of priority fees at requested percentiles for each block (in wei, hex)
Array of base fees per gas for each block (in wei, hex). Last element is the next block's expected value.
Array of gas utilization ratios per block (0 to 1)