diff --git a/ethclient/ethclient.go b/ethclient/ethclient.go index 3d8facac6c..e12c05c552 100644 --- a/ethclient/ethclient.go +++ b/ethclient/ethclient.go @@ -604,6 +604,15 @@ func (ec *Client) SuggestGasTipCap(ctx context.Context) (*big.Int, error) { return (*big.Int)(&hex), nil } +// BlobBaseFee retrieves the current blob base fee. +func (ec *Client) BlobBaseFee(ctx context.Context) (*big.Int, error) { + var hex hexutil.Big + if err := ec.c.CallContext(ctx, &hex, "eth_blobBaseFee"); err != nil { + return nil, err + } + return (*big.Int)(&hex), nil +} + type feeHistoryResultMarshaling struct { OldestBlock *hexutil.Big `json:"oldestBlock"` Reward [][]*hexutil.Big `json:"reward,omitempty"`