ethereum, ethclient: add FeeHistory support (#25403)
Co-authored-by: Felix Lange <fjl@twurst.com>
This commit is contained in:
co-authored by
Felix Lange
parent
377c7d799f
commit
9ad508018e
@@ -201,6 +201,15 @@ type GasPricer interface {
|
||||
SuggestGasPrice(ctx context.Context) (*big.Int, error)
|
||||
}
|
||||
|
||||
// FeeHistory provides recent fee market data that consumers can use to determine
|
||||
// a reasonable maxPriorityFeePerGas value.
|
||||
type FeeHistory struct {
|
||||
OldestBlock *big.Int // block coresponding to first response value
|
||||
Reward [][]*big.Int // list every txs priority fee per block
|
||||
BaseFee []*big.Int // list of each block's base fee
|
||||
GasUsedRatio []float64 // ratio of gas used out of the total available limit
|
||||
}
|
||||
|
||||
// A PendingStateReader provides access to the pending state, which is the result of all
|
||||
// known executable transactions which have not yet been included in the blockchain. It is
|
||||
// commonly used to display the result of ’unconfirmed’ actions (e.g. wallet value
|
||||
|
||||
Reference in New Issue
Block a user