Versions in this module Expand all Collapse all v0 v0.0.3 Feb 22, 2024 v0.0.2 Feb 22, 2024 Changes in this version + func AccessList(ctx context.Context, b Backend, blockNrOrHash rpc.BlockNumberOrHash, ...) (acl types.AccessList, gasUsed uint64, vmErr error, err error) + func DoCall(ctx context.Context, b Backend, args TransactionArgs, ...) (*core.ExecutionResult, error) + func DoEstimateGas(ctx context.Context, b Backend, args TransactionArgs, ...) (hexutil.Uint64, error) + func GetAPIs(apiBackend Backend) []rpc.API + func RPCMarshalBlock(ctx context.Context, block *types.Block, inclTx bool, fullTx bool, ...) (map[string]interface{}, error) + func RPCMarshalHeader(head *types.Header) map[string]interface + func SubmitTransaction(ctx context.Context, b Backend, tx *types.Transaction) (common.Hash, error) + type AccountResult struct + AccountProof []string + Address common.Address + Balance *hexutil.Big + CodeHash common.Hash + Nonce hexutil.Uint64 + StorageHash common.Hash + StorageProof []StorageResult + type AddrLocker struct + func (l *AddrLocker) LockAddr(address common.Address) + func (l *AddrLocker) UnlockAddr(address common.Address) + type Backend interface + AccountManager func() *accounts.Manager + BlockByHash func(ctx context.Context, hash common.Hash) (*types.Block, error) + BlockByNumber func(ctx context.Context, number rpc.BlockNumber) (*types.Block, error) + BlockByNumberOrHash func(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) (*types.Block, error) + BloomStatus func() (uint64, uint64) + ChainConfig func() *params.ChainConfig + ChainDb func() ethdb.Database + CurrentBlock func() *types.Header + CurrentHeader func() *types.Header + Engine func() consensus.Engine + ExtRPCEnabled func() bool + FeeHistory func(ctx context.Context, blockCount uint64, lastBlock rpc.BlockNumber, ...) (*big.Int, [][]*big.Int, []*big.Int, []float64, error) + Genesis func() *types.Block + GetBody func(ctx context.Context, hash common.Hash, number rpc.BlockNumber) (*types.Body, error) + GetEVM func(ctx context.Context, msg *core.Message, state *state.StateDB, ...) *vm.EVM + GetLogs func(ctx context.Context, blockHash common.Hash, number uint64) ([][]*types.Log, error) + GetPoolNonce func(ctx context.Context, addr common.Address) (uint64, error) + GetPoolTransaction func(txHash common.Hash) *types.Transaction + GetPoolTransactions func() (types.Transactions, error) + GetReceipts func(ctx context.Context, hash common.Hash) (types.Receipts, error) + GetTd func(ctx context.Context, hash common.Hash) *big.Int + GetTransaction func(ctx context.Context, txHash common.Hash) (*types.Transaction, common.Hash, uint64, uint64, error) + HeaderByHash func(ctx context.Context, hash common.Hash) (*types.Header, error) + HeaderByNumber func(ctx context.Context, number rpc.BlockNumber) (*types.Header, error) + HeaderByNumberOrHash func(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) (*types.Header, error) + HistoricalRPCService func() *rpc.Client + PendingBlockAndReceipts func() (*types.Block, types.Receipts) + RPCEVMTimeout func() time.Duration + RPCGasCap func() uint64 + RPCTxFeeCap func() float64 + SendTx func(ctx context.Context, signedTx *types.Transaction) error + ServiceFilter func(ctx context.Context, session *bloombits.MatcherSession) + SetHead func(number uint64) + StateAndHeaderByNumber func(ctx context.Context, number rpc.BlockNumber) (*state.StateDB, *types.Header, error) + StateAndHeaderByNumberOrHash func(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) (*state.StateDB, *types.Header, error) + Stats func() (pending int, queued int) + SubscribeChainEvent func(ch chan<- core.ChainEvent) event.Subscription + SubscribeChainHeadEvent func(ch chan<- core.ChainHeadEvent) event.Subscription + SubscribeChainSideEvent func(ch chan<- core.ChainSideEvent) event.Subscription + SubscribeLogsEvent func(ch chan<- []*types.Log) event.Subscription + SubscribeNewTxsEvent func(chan<- core.NewTxsEvent) event.Subscription + SubscribePendingLogsEvent func(ch chan<- []*types.Log) event.Subscription + SubscribeRemovedLogsEvent func(ch chan<- core.RemovedLogsEvent) event.Subscription + SuggestGasTipCap func(ctx context.Context) (*big.Int, error) + SyncProgress func() ethereum.SyncProgress + TxPoolContent func() (map[common.Address][]*types.Transaction, ...) + TxPoolContentFrom func(addr common.Address) ([]*types.Transaction, []*types.Transaction) + UnprotectedAllowed func() bool + type BlockChainAPI struct + func NewBlockChainAPI(b Backend) *BlockChainAPI + func (api *BlockChainAPI) ChainId() *hexutil.Big + func (s *BlockChainAPI) BlockNumber() hexutil.Uint64 + func (s *BlockChainAPI) Call(ctx context.Context, args TransactionArgs, ...) (hexutil.Bytes, error) + func (s *BlockChainAPI) CreateAccessList(ctx context.Context, args TransactionArgs, ...) (*accessListResult, error) + func (s *BlockChainAPI) EstimateGas(ctx context.Context, args TransactionArgs, ...) (hexutil.Uint64, error) + func (s *BlockChainAPI) GetBalance(ctx context.Context, address common.Address, ...) (*hexutil.Big, error) + func (s *BlockChainAPI) GetBlockByHash(ctx context.Context, hash common.Hash, fullTx bool) (map[string]interface{}, error) + func (s *BlockChainAPI) GetBlockByNumber(ctx context.Context, number rpc.BlockNumber, fullTx bool) (map[string]interface{}, error) + func (s *BlockChainAPI) GetBlockReceipts(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) ([]map[string]interface{}, error) + func (s *BlockChainAPI) GetCode(ctx context.Context, address common.Address, ...) (hexutil.Bytes, error) + func (s *BlockChainAPI) GetHeaderByHash(ctx context.Context, hash common.Hash) map[string]interface{} + func (s *BlockChainAPI) GetHeaderByNumber(ctx context.Context, number rpc.BlockNumber) (map[string]interface{}, error) + func (s *BlockChainAPI) GetProof(ctx context.Context, address common.Address, storageKeys []string, ...) (*AccountResult, error) + func (s *BlockChainAPI) GetStorageAt(ctx context.Context, address common.Address, hexKey string, ...) (hexutil.Bytes, error) + func (s *BlockChainAPI) GetUncleByBlockHashAndIndex(ctx context.Context, blockHash common.Hash, index hexutil.Uint) (map[string]interface{}, error) + func (s *BlockChainAPI) GetUncleByBlockNumberAndIndex(ctx context.Context, blockNr rpc.BlockNumber, index hexutil.Uint) (map[string]interface{}, error) + func (s *BlockChainAPI) GetUncleCountByBlockHash(ctx context.Context, blockHash common.Hash) *hexutil.Uint + func (s *BlockChainAPI) GetUncleCountByBlockNumber(ctx context.Context, blockNr rpc.BlockNumber) *hexutil.Uint + type BlockOverrides struct + BaseFee *hexutil.Big + BlobBaseFee *hexutil.Big + Coinbase *common.Address + Difficulty *hexutil.Big + GasLimit *hexutil.Uint64 + Number *hexutil.Big + Random *common.Hash + Time *hexutil.Uint64 + func (diff *BlockOverrides) Apply(blockCtx *vm.BlockContext) + type ChainContext struct + func NewChainContext(ctx context.Context, backend ChainContextBackend) *ChainContext + func (context *ChainContext) Engine() consensus.Engine + func (context *ChainContext) GetHeader(hash common.Hash, number uint64) *types.Header + type ChainContextBackend interface + Engine func() consensus.Engine + HeaderByNumber func(context.Context, rpc.BlockNumber) (*types.Header, error) + type DebugAPI struct + func NewDebugAPI(b Backend) *DebugAPI + func (api *DebugAPI) ChainConfig() *params.ChainConfig + func (api *DebugAPI) ChaindbCompact() error + func (api *DebugAPI) ChaindbProperty(property string) (string, error) + func (api *DebugAPI) DbAncient(kind string, number uint64) (hexutil.Bytes, error) + func (api *DebugAPI) DbAncients() (uint64, error) + func (api *DebugAPI) DbGet(key string) (hexutil.Bytes, error) + func (api *DebugAPI) GetRawBlock(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) (hexutil.Bytes, error) + func (api *DebugAPI) GetRawHeader(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) (hexutil.Bytes, error) + func (api *DebugAPI) GetRawReceipts(ctx context.Context, blockNrOrHash rpc.BlockNumberOrHash) ([]hexutil.Bytes, error) + func (api *DebugAPI) PrintBlock(ctx context.Context, number uint64) (string, error) + func (api *DebugAPI) SetHead(number hexutil.Uint64) + func (s *DebugAPI) GetRawTransaction(ctx context.Context, hash common.Hash) (hexutil.Bytes, error) + type EthereumAPI struct + func NewEthereumAPI(b Backend) *EthereumAPI + func (s *EthereumAPI) FeeHistory(ctx context.Context, blockCount math.HexOrDecimal64, lastBlock rpc.BlockNumber, ...) (*feeHistoryResult, error) + func (s *EthereumAPI) GasPrice(ctx context.Context) (*hexutil.Big, error) + func (s *EthereumAPI) MaxPriorityFeePerGas(ctx context.Context) (*hexutil.Big, error) + func (s *EthereumAPI) Syncing() (interface{}, error) + type EthereumAccountAPI struct + func NewEthereumAccountAPI(am *accounts.Manager) *EthereumAccountAPI + func (s *EthereumAccountAPI) Accounts() []common.Address + type NetAPI struct + func NewNetAPI(net *p2p.Server, networkVersion uint64) *NetAPI + func (s *NetAPI) Listening() bool + func (s *NetAPI) PeerCount() hexutil.Uint + func (s *NetAPI) Version() string + type OverrideAccount struct + Balance **hexutil.Big + Code *hexutil.Bytes + Nonce *hexutil.Uint64 + State *map[common.Hash]common.Hash + StateDiff *map[common.Hash]common.Hash + type PersonalAccountAPI struct + func NewPersonalAccountAPI(b Backend, nonceLock *AddrLocker) *PersonalAccountAPI + func (s *PersonalAccountAPI) DeriveAccount(url string, path string, pin *bool) (accounts.Account, error) + func (s *PersonalAccountAPI) EcRecover(ctx context.Context, data, sig hexutil.Bytes) (common.Address, error) + func (s *PersonalAccountAPI) ImportRawKey(privkey string, password string) (common.Address, error) + func (s *PersonalAccountAPI) InitializeWallet(ctx context.Context, url string) (string, error) + func (s *PersonalAccountAPI) ListAccounts() []common.Address + func (s *PersonalAccountAPI) ListWallets() []rawWallet + func (s *PersonalAccountAPI) LockAccount(addr common.Address) bool + func (s *PersonalAccountAPI) NewAccount(password string) (common.AddressEIP55, error) + func (s *PersonalAccountAPI) OpenWallet(url string, passphrase *string) error + func (s *PersonalAccountAPI) SendTransaction(ctx context.Context, args TransactionArgs, passwd string) (common.Hash, error) + func (s *PersonalAccountAPI) Sign(ctx context.Context, data hexutil.Bytes, addr common.Address, passwd string) (hexutil.Bytes, error) + func (s *PersonalAccountAPI) SignTransaction(ctx context.Context, args TransactionArgs, passwd string) (*SignTransactionResult, error) + func (s *PersonalAccountAPI) UnlockAccount(ctx context.Context, addr common.Address, password string, duration *uint64) (bool, error) + func (s *PersonalAccountAPI) Unpair(ctx context.Context, url string, pin string) error + type RPCTransaction struct + Accesses *types.AccessList + BlobVersionedHashes []common.Hash + BlockHash *common.Hash + BlockNumber *hexutil.Big + ChainID *hexutil.Big + DepositReceiptVersion *hexutil.Uint64 + From common.Address + Gas hexutil.Uint64 + GasFeeCap *hexutil.Big + GasPrice *hexutil.Big + GasTipCap *hexutil.Big + Hash common.Hash + Input hexutil.Bytes + IsSystemTx *bool + MaxFeePerBlobGas *hexutil.Big + Mint *hexutil.Big + Nonce hexutil.Uint64 + R *hexutil.Big + S *hexutil.Big + SourceHash *common.Hash + To *common.Address + TransactionIndex *hexutil.Uint64 + Type hexutil.Uint64 + V *hexutil.Big + Value *hexutil.Big + YParity *hexutil.Uint64 + func NewRPCPendingTransaction(tx *types.Transaction, current *types.Header, config *params.ChainConfig) *RPCTransaction + type SignTransactionResult struct + Raw hexutil.Bytes + Tx *types.Transaction + type StateOverride map[common.Address]OverrideAccount + func (diff *StateOverride) Apply(state *state.StateDB) error + type StorageResult struct + Key string + Proof []string + Value *hexutil.Big + type TransactionAPI struct + func NewTransactionAPI(b Backend, nonceLock *AddrLocker) *TransactionAPI + func (s *TransactionAPI) FillTransaction(ctx context.Context, args TransactionArgs) (*SignTransactionResult, error) + func (s *TransactionAPI) GetBlockTransactionCountByHash(ctx context.Context, blockHash common.Hash) *hexutil.Uint + func (s *TransactionAPI) GetBlockTransactionCountByNumber(ctx context.Context, blockNr rpc.BlockNumber) *hexutil.Uint + func (s *TransactionAPI) GetRawTransactionByBlockHashAndIndex(ctx context.Context, blockHash common.Hash, index hexutil.Uint) hexutil.Bytes + func (s *TransactionAPI) GetRawTransactionByBlockNumberAndIndex(ctx context.Context, blockNr rpc.BlockNumber, index hexutil.Uint) hexutil.Bytes + func (s *TransactionAPI) GetRawTransactionByHash(ctx context.Context, hash common.Hash) (hexutil.Bytes, error) + func (s *TransactionAPI) GetTransactionByBlockHashAndIndex(ctx context.Context, blockHash common.Hash, index hexutil.Uint) *RPCTransaction + func (s *TransactionAPI) GetTransactionByBlockNumberAndIndex(ctx context.Context, blockNr rpc.BlockNumber, index hexutil.Uint) *RPCTransaction + func (s *TransactionAPI) GetTransactionByHash(ctx context.Context, hash common.Hash) (*RPCTransaction, error) + func (s *TransactionAPI) GetTransactionCount(ctx context.Context, address common.Address, ...) (*hexutil.Uint64, error) + func (s *TransactionAPI) GetTransactionReceipt(ctx context.Context, hash common.Hash) (map[string]interface{}, error) + func (s *TransactionAPI) PendingTransactions() ([]*RPCTransaction, error) + func (s *TransactionAPI) Resend(ctx context.Context, sendArgs TransactionArgs, gasPrice *hexutil.Big, ...) (common.Hash, error) + func (s *TransactionAPI) SendRawTransaction(ctx context.Context, input hexutil.Bytes) (common.Hash, error) + func (s *TransactionAPI) SendTransaction(ctx context.Context, args TransactionArgs) (common.Hash, error) + func (s *TransactionAPI) Sign(addr common.Address, data hexutil.Bytes) (hexutil.Bytes, error) + func (s *TransactionAPI) SignTransaction(ctx context.Context, args TransactionArgs) (*SignTransactionResult, error) + type TransactionArgs struct + AccessList *types.AccessList + BlobFeeCap *hexutil.Big + BlobHashes []common.Hash + ChainID *hexutil.Big + Data *hexutil.Bytes + From *common.Address + Gas *hexutil.Uint64 + GasPrice *hexutil.Big + Input *hexutil.Bytes + MaxFeePerGas *hexutil.Big + MaxPriorityFeePerGas *hexutil.Big + Nonce *hexutil.Uint64 + To *common.Address + Value *hexutil.Big + func (args *TransactionArgs) IsEIP4844() bool + func (args *TransactionArgs) ToMessage(globalGasCap uint64, baseFee *big.Int) (*core.Message, error) + func (args *TransactionArgs) ToTransaction() *types.Transaction + type TxPoolAPI struct + func NewTxPoolAPI(b Backend) *TxPoolAPI + func (s *TxPoolAPI) Content() map[string]map[string]map[string]*RPCTransaction + func (s *TxPoolAPI) ContentFrom(addr common.Address) map[string]map[string]*RPCTransaction + func (s *TxPoolAPI) Inspect() map[string]map[string]map[string]string + func (s *TxPoolAPI) Status() map[string]hexutil.Uint