Evm_node_lib_dev.Transaction_objectA transaction object value to be returned to users through the RPC server.
The EVM kernel always stores legacy transaction objects, even for transactions using a more recent format (like EIP-1559).
val encoding : t Tezos_base.TzPervasives.Data_encoding.ttype access = {address : Evm_node_lib_dev_encoding.Ethereum_types.address;storage_keys : Evm_node_lib_dev_encoding.Ethereum_types.hex list;}A single access list entry as introduced by EIP-2930. Each entry specifies an address and a list of storage_keys that the transaction plans to access.
A single authorization item as introduced by EIP-7702. Each item authorizes an address to act on behalf of a signer and includes the signature components y_parity, r, and s.
Transaction metadata
val hash : t -> Evm_node_lib_dev_encoding.Ethereum_types.hashhash t returns the hash of the transaction t.
val block_number :
t ->
Evm_node_lib_dev_encoding.Ethereum_types.quantity optionblock_number t returns the number of the block containing the transaction t, if known.
val block_hash :
t ->
Evm_node_lib_dev_encoding.Ethereum_types.block_hash optionblock_hash t returns the hash of the block containing the transaction t, if known.
val transaction_index :
t ->
Evm_node_lib_dev_encoding.Ethereum_types.quantity optiontransaction_index t returns the index of the transaction t within its block, if known.
val chain_id :
t ->
Evm_node_lib_dev_encoding.Ethereum_types.quantity option
Tezos_base.TzPervasives.tzresultchain_id t returns the chain ID associated with the transaction t, if present. This function may fail when applied to legacy transactions whose format does not include or allow reconstruction of the chain ID. In such cases, the information cannot be retrieved from t.
val sender : t -> Evm_node_lib_dev_encoding.Ethereum_types.addresssender t returns the sender address of the transaction t.
val to_ : t -> Evm_node_lib_dev_encoding.Ethereum_types.address optionto_ t returns the recipient address of the transaction t, if present. It is None for contract creation transactions.
val nonce : t -> Evm_node_lib_dev_encoding.Ethereum_types.quantitynonce t returns the nonce of the transaction t, i.e. the number of transactions previously sent from the sender.
val gas : t -> Evm_node_lib_dev_encoding.Ethereum_types.quantitygas t returns the gas limit specified by the transaction t.
val max_fee_per_gas : t -> Evm_node_lib_dev_encoding.Ethereum_types.quantitygas_price t returns the max fee per gas or its equivalent. For legacy and EIP-2930 transactions this is the actual gas price. For EIP-1559 and EIP-7702 transactions this is max_fee_per_gas, which is an upper bound rather than the effective gas price.
val value : t -> Evm_node_lib_dev_encoding.Ethereum_types.quantityvalue t returns the amount of Ether transferred in the transaction t.
val input : t -> Evm_node_lib_dev_encoding.Ethereum_types.hexinput t returns the calldata (data payload) of the transaction t.
access_list t returns the access list attached to the transaction t, if present. It is available for EIP-2930, EIP-1559, and EIP-7702 transactions.
val authorization_list : t -> authorization_item listauthorization_list t returns the authorization list attached to the transaction t, if present. It is available for EIP-7702 transactions.
val decode : string -> t Tezos_base.TzPervasives.tzresultdecode raw_txn decodes a raw RLP-encoded transaction string raw_txn into a transaction object t. The transaction type (Legacy, EIP-2930, EIP-1559, or EIP-7702) is inferred from the first byte of raw_txn.
val is_eip7702 : t -> boolis_eip7702 t returns true if the transaction t is an EIP-7702 transaction, and false otherwise.
val authorization_signer :
authorization_item ->
(Evm_node_lib_dev_encoding.Ethereum_types.address, string) Stdlib.resultauthorization_signer item recovers the signer address from an EIP-7702 authorization_item. This is done by hashing the authorization message according to the EIP-7702 specification and recovering the public key from the signature components contained in item.
type txqueue_content = {pending : t Evm_node_lib_dev_encoding.Ethereum_types.NonceMap.t
Evm_node_lib_dev_encoding.Ethereum_types.AddressMap.t;queued : t Evm_node_lib_dev_encoding.Ethereum_types.NonceMap.t
Evm_node_lib_dev_encoding.Ethereum_types.AddressMap.t;}Internal representation used to satisfy txpool_content requests. A txqueue_content groups transactions known into two categories, organized by sender address and nonce:
pending: transactions ready for executionqueued: transactions valid but not yet executableThis type is not used internally by the tx queue logic itself. It only exists to provide response data to txpool_content queries.
val txqueue_content_encoding :
txqueue_content Tezos_base.TzPervasives.Data_encoding.tEncoding for txqueue_content. Used by txpool_content RPC responses.
val from_store_transaction_object :
Evm_node_lib_dev_encoding.Ethereum_types.legacy_transaction_object ->
tfrom_store_transaction_object obj does not attempt to reconstruct obj to be compliant with its original format, but instead returned the stored data as if it was legacy.
val block_from_legacy :
Evm_node_lib_dev_encoding.Ethereum_types.legacy_transaction_object
Evm_node_lib_dev_encoding.Ethereum_types.block ->
t Evm_node_lib_dev_encoding.Ethereum_types.blockblock_from_legacy block folds over the transactions of block, assuming they are indeed legacy (see from_store_transaction_object).
val reconstruct :
Blueprint_types.payload ->
Evm_node_lib_dev_encoding.Ethereum_types.legacy_transaction_object ->
t Tezos_base.TzPervasives.tzresultreconstruct blueprint_payload obj reconstructs the full transaction object from the raw transaction of obj stored in blueprint_payload.
Fails if blueprint_payload is inconsistent (does not contain the raw transaction, is corrupted, etc.).
val reconstruct_block :
Blueprint_types.payload ->
Evm_node_lib_dev_encoding.Ethereum_types.legacy_transaction_object
Evm_node_lib_dev_encoding.Ethereum_types.block ->
t Evm_node_lib_dev_encoding.Ethereum_types.block
Tezos_base.TzPervasives.tzresultreconstruct_block blueprint_payload block folds over the transactions of block to reconstruct them (see reconstruct).
val rereconstruct :
Blueprint_types.payload ->
t ->
t Tezos_base.TzPervasives.tzresultrereconstruct blueprint_payload obj can be used to retry to reconstruct obj using blueprint_payload, exactly as reconstruct would, in case obj was created with from_store_transaction_object.
rereconstruct blueprint_payload (reconstruct blueprint_payload obj) is a no-op.rereconstruct blueprint_payload (from_store_transaction_object obj) is equivalent to reconstruct blueprint_payload objval rereconstruct_block :
Blueprint_types.payload ->
t Evm_node_lib_dev_encoding.Ethereum_types.block ->
t Evm_node_lib_dev_encoding.Ethereum_types.block
Tezos_base.TzPervasives.tzresultrereconstruct_block can be used to retry to reconstruct a block, exactly as reconstruct_block would, in case block was created with block_from_legacy.
See rereconstruct.