Crate alloy_rpc_types

Crate alloy_rpc_types 

Source
Expand description

§alloy-rpc-types

Meta-crate for all Ethereum JSON-RPC types.

Re-exports§

pub use alloy_rpc_types_admin as admin;admin
pub use alloy_rpc_types_anvil as anvil;anvil
pub use alloy_rpc_types_any as any;any
pub use alloy_rpc_types_beacon as beacon;beacon
pub use alloy_rpc_types_debug as debug;debug
pub use alloy_rpc_types_engine as engine;engine
pub use alloy_rpc_types_eth as eth;eth
pub use alloy_rpc_types_mev as mev;mev
pub use alloy_rpc_types_trace as trace;trace
pub use alloy_rpc_types_txpool as txpool;txpool

Modules§

erc4337eth
This module provides implementations for ERC-4337.
erroreth
Commonly used errors for the eth_ namespace.
pubsubeth and serde
Ethereum types for pub-sub
simulateeth
‘eth_simulateV1’ Request / Response types: https://github.com/ethereum/execution-apis/pull/484
stateeth
bindings for state overrides in eth_call
transactioneth
RPC types for transactions

Structs§

AccessListeth
AccessList as defined in EIP-2930
AccessListItemeth
A list of addresses and storage keys that the transaction plans to access. Accesses outside the list are possible, but become more expensive.
AccessListResulteth
AccessListResult for handling errors from eth_createAccessList
Accounteth
Represents an TrieAccount in the account trie.
AccountInfoeth
Account information.
AnyReceiptEnvelopeeth
Receipt envelope, as defined in EIP-2718.
Authorizationeth
An unsigned EIP-7702 authorization.
BadBlocketh
Bad block representation.
BlobTransactionSidecareth
This represents a set of blobs, and its corresponding commitments and proofs.
BlobTransactionSidecarEip7594eth
This represents a set of blobs, and its corresponding commitments and cell proofs.
Blocketh
Block representation for RPC.
BlockOverrideseth
BlockOverrides is a set of header fields to override.
BlockTransactionHasheseth
An iterator over the transaction hashes of a block.
BloomFiltereth
Helper type to represent a bloom filter used for matching logs.
Bundleeth
Bundle of transactions
ChainStatuseth
Chain status.
EIP1186AccountProofResponseeth and serde
Response for EIP-1186 account proof eth_getProof
EIP1186StorageProofeth and serde
Data structure with proof for one single storage-entry
EthCallResponseeth
CallResponse for eth_callMany
ExtAccountInfoeth
Extended account information (used by parity_allAccountInfo).
FeeHistoryeth
Response type for eth_feeHistory
FillTransactioneth
Response type for eth_fillTransaction.
Filtereth
Filter for logs.
FilterReceiptsItereth
Iterator that yields logs from receipts that match a filter.
FilterSeteth
FilterSet is a set of values that will be used to filter logs.
FilteredParamseth
Support for matching Filters
Headereth
RPC representation of block header, wrapping a consensus header.
Indexeth
A hex encoded or decimal index that’s intended to be used as a rust index, hence it’s deserialized into a usize.
Logeth
Ethereum Log emitted by a transaction
PackedUserOperationeth
PackedUserOperation in the spec: Entry Point V0.7
PeerEthProtocolInfoeth
Peer Ethereum protocol information
PeerInfoeth
Peer connection information
PeerNetworkInfoeth
Peer network information
PeerProtocolsInfoeth
Peer protocols information
Peerseth
Peers info
PipProtocolInfoeth
Peer PIP protocol information
RawLogeth
Ethereum Log
Receipteth
Receipt containing result of transaction execution.
ReceiptWithBloometh
Receipt with calculated bloom filter.
RecoveredAccounteth
account derived from a signature as well as information that tells if it is valid for the current chain
RpcBlockHasheth
A block hash which may have a boolean requireCanonical field.
RpcModules
Represents the rpc_modules response, which returns the list of all available modules on that transport and their version
SendUserOperationResponseeth
Response to sending a user operation.
SignedAuthorizationeth
A signed EIP-7702 authorization.
Stageeth
The detail of the sync stages.
StateContexteth
State context for callMany
SyncInfoeth
Syncing info
Transactioneth
Transaction object used in RPC.
TransactionInfoeth
Additional fields in the context of a (maybe) pending block that contains this transaction.
TransactionInputeth
Helper type that supports both data and input fields that map to transaction input data.
TransactionReceipteth
Transaction receipt
TransactionRequesteth
Represents all transaction requests to/from RPC.
TransactionStatseth
Propagation statistics for pending transaction.
TxGasAndRewardeth
Internal struct to calculate reward percentiles
UserOperationeth
UserOperation in the spec: Entry Point V0.6
UserOperationGasEstimationeth
Represents the gas estimation for a user operation.
UserOperationReceipteth
Represents the receipt of a user operation.
Withdrawaleth
Withdrawal represents a validator withdrawal from the consensus layer.
Withdrawalseth
Represents a collection of Withdrawals.
Worketh
The result of an eth_getWork request

Enums§

BlockErroreth
Error that can occur when converting other types to blocks
BlockIdeth
A Block Identifier. https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1898.md
BlockNumberOrTageth
A block Number (or tag - “latest”, “earliest”, “pending”)
BlockTransactionseth
Block Transactions depending on the boolean attribute of eth_getBlockBy*, or if used by eth_getUncle*
BlockTransactionsKindeth
Determines how the transactions field of block should be filled.
ConversionErroreth
Error variants when converting from crate::Transaction to alloy_consensus::Signed transaction.
FilterBlockErroreth
Represents errors that can occur when setting block filters in FilterBlockOption.
FilterBlockOptioneth
Represents the target range of blocks for the filter
FilterChangeseth
Response of the eth_getFilterChanges RPC.
FilterIdeth
Owned equivalent of a SubscriptionId
PendingTransactionFilterKindeth
Specifies the kind of information you wish to receive from the eth_newPendingTransactionFilter RPC endpoint.
ReceiptEnvelopeeth
Receipt envelope, as defined in EIP-2718.
SendUserOperationeth
Send User Operation
SyncStatuseth
Sync status
TransactionIndexeth
Represents a transaction index where -1 means all transactions
TransactionInputKindeth
Represents how a TransactionRequest handles input/data fields.
ValueOrArrayeth
Union type for representing a single value or a vector of values inside a filter.

Traits§

TransactionTraiteth
Represents a minimal EVM transaction. Currently, EIP-1559, EIP-4844, and EIP-7702 support dynamic fees. We call these transactions “dynamic fee transactions”. We call non dynamic fee transactions(EIP-155, EIP-2930) “legacy fee transactions”.

Functions§

calc_blob_gaspriceeth
Calculates the blob gas price from the header’s excess blob gas field.
calc_excess_blob_gaseth
Calculates the excess_blob_gas from the parent header’s blob_gas_used and excess_blob_gas.
logs_bloometh
Calculate receipt logs bloom.

Type Aliases§

BlockHashOrNumbereth
A block hash or a block number
BlockNumHasheth
A block number and a hash
ForkBlocketh
Block number and hash of the forked block.
Topiceth
A single topic