Links

Data Model

Current Version : MCDW v1.0 (Nov-2023)

Blocks

Column Name
Data Type
Layer
Definition
Nullable
updated_at
timestamp
TECH
Technical field. Timestamp of the process that has updated the row in the table, updated every time the record in changed. UTC timestamp (including milliseconds).
N
chain_id
number
TECH
Technical field. Unique identifier of the chain. For all EVM compliant chains, the identifier matches Chainlist.
N
chain_generation
number
TECH
Technical field. Tracks instances when a chain is restarted - the Optimism dataset only includes 5th generation data.
N
block_id
varchar
TECH
Technical field. Unique identifier of the block across chains and generations, constructed by concatenating chain_id, generation and block number, separated by underscore.
N
block_number
number
RAW
Number of the block. Numbering is incremental, starting at 0 (Genesis) with new blocks added at the end of the chain.
N
block_hash
varchar
RAW
Hash of the block content (KECCAK-256). Unique for every block in the same chain.
N
block_timestamp
timestamp
RAW
Timestamp of the block. Unique for every block and inherited by calls, events, transactions and diffs happening in the same block. UTC timestamp (including milliseconds).
N
block_date
varchar
TECH
Technical field. Date of the block - precomputed to be used for analytics purposes, inherited by calls, events, transactions and diffs happening in the same block.
N
size
number
RAW
Size of the block in bytes.
N
gas_limit
number
RAW
Maximum amount of gas that can be included in the block, set by the network, expressed in gas units.
N
base_fee_per_gas
number
RAW
Minimum multiplier for used gas in order to include a transaction in a block.
Y
gas_used
number
RAW
Total amount of gas actually consumed by the block execution, expressed in gas units.
N
tx_count
number
RAW
Count of transactions included in the block, successful or reverted. For empty blocks, tx_count = 0
N
extra_data
varchar
DECODED
Arbitrary binary data included by a miner of a block, decoded.
Y
processed
boolean
TECH
Technical field. Defines processing status of a block by the decoding ETL process: NULL = block has not finished loading and should not be picked up for decoding FALSE = block has not been processed. block is considered raw. TRUE = block was processed by the ETL process (including all of it's related elements).
Y

Transactions

Column Name
Data Type
Layer
Definition
Nullable
updated_at
timestamp
TECH
Technical field. Timestamp of the process that has updated the row in the table, updated every time the record in changed. UTC timestamp (including milliseconds).
N
chain_id
number
TECH
Technical field. Unique identifier of the chain (identifiers from Chainlist are used for all EVM compliant chains).
N
chain_generation
number
TECH
Technical field. Traks instances when a chain is restarted - the Optimism dataset only includes 5th generation data.
N
block_id
varchar
TECH
Technical field. Unique identifier of the block across chains and generations, constructed by concatenating chain_id, generation and block number, separated by underscore.
N
block_number
number
RAW
Number of the block. Numbering is incremental, starting at 0 (Genesis) with new blocks added at the end of the chain.
N
block_timestamp
timestamp
RAW
Timestamp of the block. Unique for every block and inherited by calls, events, transactions and diffs happening in the same block. UTC timestamp (including miliseconds).
N
block_date
varchar
TECH
Technical field. Date of the block - precomputed to be used for analytics purposes, inherited by calls, events, transactions and diffs happening in the same block.
N
tx_id
varchar
TECH
Technical field. Unique identifier of the transaction accross chains, constructed by concatenating block id and transaction index, separated by underscores.
N
tx_hash
varchar
RAW
Hash of the transaction (KECCAK-256). Unique for every transaction.
N
tx_index
number
RAW
Index of the transactions within a block, starting at 0.
N
tx_type
number
RAW
Transaction type. Can take one of the following values: 0 - User Transactions. Represent pre-EIP-2718 transactions 1 - User Transactions. Represent legacy transactions post EIP-2718 2 - User Transactions. Represent EIP-1559 transactions 126 - System Transactions. They can be transactions importing L1 data into Optimism or User-deposited transactions
N
from_address
varchar
RAW
Address of the transaction sender (calling address). It is always an Externally Owned Address.
N
from_name
varchar
DECODED
Name of the transaction sender (calling address) as decoded by Token Flow processes (ABI or inferred from similar functions). Contains calling address if not found.
Y
nonce
number
RAW
Sender counter of signed transactions, used to avoid sending the same transaction twice.
N
to_address
varchar
RAW
Address of the transaction receiver (called address): - EOA or smart contract address for pure Ether transfer; - Smart contract address for function calls;
Y
to_name
varchar
DECODED
Name of the transaction receiver (called address) as decoded by Token Flow processes (ABI or inferred from similar functions). Contains called address if decoding was not possible.
Y
function_signature
varchar
RAW
Binary signature of the called function. 0x in case of pure Ether transfers.
Y
tx_value
number
RAW
Ether amount transferred, in WEI. Value must be divided by 10^18 to obtain Ether amount. 0 if no Ether transfer happened.
N
gas_limit
number
RAW
Gas staked by the transaction before its execution. Maximum amount that can be used before the transaction is reverted, expressed in gas units.
N
gas_price
number
RAW
Ether amount the transaction sender is willing to pay per unit of gas as a fee to the miner.
Y
max_fee_per_gas
number
RAW
Maximum fee the transaction sender is willing to pay for the gas (base fee + priority fee).
Y
max_priority_fee_per_gas
number
RAW
Maximum amount of gas paid for the blobs of data stored on-chain.
Y
gas_used
number
RAW
Gas used by the execution of a transaction, expressed in gas units.
N
gas_refund
number
RAW
Gas amount returned after the transaction execution, expressed in gas units.
Y
created_address
varchar
RAW
Address of created contract
Y
reverted
boolean
RAW
Flags persistent (false) or reverted (true) calls. Reverted diffs can originate from technical failures (code errors), gas limits (more gas needed than was staked) or contract logic.
N
exception_error
varchar
RAW
Error description for failed transactions, as generated by the Ethereum Virtual Machine. Empty for successful transactions.
Y
revert_reason
varchar
RAW
Error description for reverted transactions, as provided by the smart contract. Empty for successful transactions.
Y
queue_origin
varchar
RAW
Origin of the transaction in the queue. Can have 2 values: * sequencer - for transactions that were sent directly to the sequencer for processing, usually L2 smart contracts added directly to the sequencer's queue. * l1 - for transactions that were crearted as L1 to L2 messages. These transactions were usually initiated on L1 and involve communication with L2. They may be processed differently from transactions sent directly to the sequencer and may have specific handling requirements.
Y
l1_tx_origin
varchar
RAW
Address of the entity that initiated or sent the message from L1 to L2. NULL if transaction origin is sequencer.
Y
l1_block_number
number
RAW
Number of the block on Ethereum (L1) where the transaction was processed.
Y
l1_block_timestamp
timestamp
RAW
Timestamp of the Ethereum (L1) block where the transaction was processed. UTC timestamp (including miliseconds).
Y
queue_index
number
RAW
Index of the transaction within the sequencer's queue. For Optimism, transactions can be queued before being processed by the sequencer. The queue index helps to identify the order in which transactions will be handled. Lower values of queue index indicate that the transaction was placed earlier in the queue and is likely to be processed sooner.
Y
l1_fee
number
RAW
Total fee in Ether paid by the transaction sender for the gas used in the transaction on Ethereum (L1). Value computed as l1_gas_price and l1_gas_used
Y
l1_fee_scalar
float
RAW
Additional multiplier added to the actual Ethereum (L1) gas used to account for dynamic costs on L1 and may adjust the gas fee based on various factors.
Y
l1_gas_price
number
RAW
Ether amount the transaction sender is willing to pay per unit of gas as a fee to the miner on Ethereum (L1).
Y
l1_gas_used
number
RAW
Gas amount actually used by the transaction, expressed in gas units on Ethereum (L1).
Y
mint
number
RAW
ETH value to mint on L2
Y
processed
boolean
TECH
Technical field. Defines processing status of a block by the decoding ETL process: FALSE = transaction has not been processed and is considered raw. TRUE = transaction was processed by the ETL process (including all of it's related elements).
N

Calls

Column Name
Data Type
Layer
Definition
Nullable
updated_at
timestamp
TECH
Technical field. Timestamp of the process that has updated the row in the table, updated every time the record in changed. UTC timestamp (including milliseconds).
N
chain_id
number
TECH
Technical field. Unique identifier of the chain (identifiers from Chainlist are used for all EVM compliant chains).
N
chain_generation
number
TECH
Technical field. Traks instances when a chain is restarted - the Optimism dataset only includes 5th generation data.
N
block_id
varchar
TECH
Technical field. Unique identifier of the block across chains and generations, constructed by concatenating chain_id, generation and block number, separated by underscore.
N
block_number
number
RAW
Number of the block. Numbering is incremental, starting at 0 (Genesis) with new blocks added at the end of the chain.
N
block_timestamp
timestamp
RAW
Timestamp of the block. Unique for every block and inherited by calls, events, transactions and diffs happening in the same block. UTC timestamp (including miliseconds).
N
block_date
varchar
TECH
Technical field. Date of the block - precomputed to be used for analytics purposes, inherited by calls, events, transactions and diffs happening in the same block.
N
tx_id
varchar
TECH
Technical field. Unique identifier of the transaction accross chains, constructed by concatenating block id and transaction index, separated by underscores.
N
tx_hash
varchar
RAW
Hash of the transaction (KECCAK-256). Unique for every transaction.
N
call_id
varchar
TECH
Technical field. Unique identifier of the call accross chains, constructed by concatenating block id, transaction index and call path, separated by underscores. For top level calls, call_path is not included.
N
call_path
varchar
TECH
Position of the call in the transaction execution tree: * empty string for top level calls (call_depth = 0) * concatenation call_path of the parent call and number of the sub call, starting at 0 (call_path='0_2_1' means second subcall of third subcall of first subcall in a transaction)
N
order_index
number
TECH
Technical field. Sequence of actions (call, events, diffs) that happened in a block.
Y
call_depth
number
TECH
Depth of the call in the transaction execution tree, incremental, starting at 0 for top level calls (call_path='0_2_1' depth= 3 means three level down in the execution tree).
N
call_type
varchar
RAW
Possible call types.Possible call types. Can take one of the following values: * call - standard function call * callcode - allows a contract to invoke a function from another contract while maintaining the context of the calling contract. Replaced by delegatecall due to security concerns. * delegatecall - executes the code of the called contract in the context of calling contract operating on its storage. * staticcall - function call that is not allowed to change the storage. * create - deployment of a new contract (column CALL_DATA contains the contract code and constructor arguments). * selfdestruct - contract destruction call.
N
from_address
varchar
RAW
Address of the call sender (calling address): * externally owned address for top level calls; * smart contract address for any other call.
N
from_name
varchar
DECODED
Name of the call sender (calling address) as decoded by Token Flow processes (ABI or inferred from similar functions). Contains calling address if not found.
Y
to_address
varchar
RAW
Address of the call receiver (called address): * EOA or smart contract address for pure Ether transfer; * Smart contract address for function calls; * Address used as code library when call_type = ‘delegatecall’
Y
to_name
varchar
DECODED
Name of the call receiver (called address) as decoded by Token Flow processes (ABI or inferred from similar functions). Contains called address if decoding was unsuccessful.
Y
function_signature
varchar
RAW
Binary signature of the called function. 0x in case of pure Ether transfers.
Y
function_name
varchar
DECODED
Name of the function, decoded by Token Flow processes (ABI or inferred from similar functions). Contains function_signature if decoding was unsuccessful.
Y
call_value
number
RAW
Ether amount transferred, in WEI. Division by 10^18 to obtain Ether amount. 0 if no Ether transfer happened.
N
arguments
json*
DECODED
List of function arguments as key:value pairs as decoded by Token Flow processes (ABI or inferred from similar functions). Contains call_data if decoding was unsuccessful.
Y
raw_arguments
json*
DECODED
Decoded function arguments in a form of array where each element is the dictionary of argument's name, raw_value and decoded_value. It preserves the arguments order so can be used to get for example the first argument regardless of its name. Arguments are decoded using the same strategy as for ARGUMENTS field.
Y
outputs
json*
DECODED
List of function outputs as key:value pairs, as decoded by Token Flow processes (ABI or inferred from similar functions). Key is the output name and value is the decoded value. Contains a single output_data argument if decoding was unsuccessful.
Y
raw_outputs
json*
DECODED
Function outputs in a form of array where each element is the dictionary of output's name, raw_value and decoded_value. It preserves the outputs order so can be used to get for example the n-th output regardless of its name.
Y
gas_limit
number
RAW
Gas staked by the function call before its execution. Maximum amount that can be used before the function call is reverted, expressed in gas units.
N
gas_used
number
RAW
Gas used by the execution of a specific function within a smart contract, expressed in gas units.
N
gas_refund
number
RAW
Gas amount returned after the function call execution, expressed in gas units.
Y
created_address
varchar
RAW
Created address in the case of 'CREATE' call. NULL for any other call type.
Y
executed
boolean
RAW
Flags successfully executed (true) or failed (false) calls.
N
exception_error
varchar
RAW
Error description for failed calls, as generated by the Ethereum Virtual Machine. NULL for successful calls.
Y
reverted
boolean
RAW
Flags persistent (false) or reverted (true) calls. Reverted diffs can originate from technical failures (code errors), gas limits (more gas needed than was staked) or contract logic.
N
revert_reason
varchar
RAW
Error description for reverted calls, as provided by the smart contract. NULL for successful calls.
Y
processed
boolean
TECH
Technical field. Defines processing status of a block by the decoding ETL process: FALSE = call has not been processed and it's considered raw TRUE = call was processed (including all of it's related elements).
N
decoded
boolean
TECH
Technical field. Flags the success (true) or failure (false) of the decoding process: NULL = used only when the data is loading TRUE = decoding process was successful (function_signature = function_name) FALSE = decoding process was unsuccessful
Y
abi_inferred
boolean
TECH
Flags whether the function semantics used for decoding was taken from the called contract's ABI (False) or it was inferred from other contracts (True). Flag is not changed if contract ABI is sourced after the processing of this record.
Y

Events

Column Name
Data Type
Layer
Definition
Nullable
updated_at
timestamp
TECH
Technical field. Timestamp of the process that has updated the row in the table, updated every time the record in changed. UTC timestamp (including milliseconds).
N
chain_id
number
TECH
Technical field. Unique identifier of the chain (identifiers from Chainlist are used for all EVM compliant chains).
N
chain_generation
number
TECH
Technical field. Tracks instances when a chain is restarted - the Optimism dataset only includes 5th generation data.
N
block_id
varchar
TECH
Technical field. Unique identifier of the block across chains and generations, constructed by concatenating chain_id, generation and block number, separated by underscore.
N
block_number
number
RAW
Number of the block. Numbering is incremental, starting at 0 (Genesis) with new blocks added at the end of the chain.
N
block_timestamp
timestamp
RAW
Timestamp of the block. Unique for every block and inherited by calls, events, transactions and diffs happening in the same block. UTC timestamp (including milliseconds).
N
block_date
varchar
TECH
Technical field. Date of the block - precomputed to be used for analytics purposes, inherited by calls, events, transactions and diffs happening in the same block.
N
tx_id
varchar
TECH
Technical field. Unique identifier of the transaction across chains, constructed by concatenating block id and transaction index, separated by underscores.
N
tx_hash
varchar
RAW
Hash of the transaction (KECCAK-256). Unique for every transaction.
N
call_id
varchar
TECH
Technical field. Unique identifier of the call accross chains, constructed by concatenating block id, transaction index and call path, separated by underscores. For top level calls, call_path is not included.
N
event_id
varchar
TECH
Technical field. Unique identifier of the event, constructed by concatenating block_id and order_index, separated by underscores.
N
log_index
number
RAW
Index of the successful event within a block, stating at 0. Reverted events are not stored on-chain and do not have log_index (NULL)
Y
order_index
number
TECH
Technical field. Sequence of actions (call, events, diffs) that happened in a block.
Y
contract_address
varchar
RAW
Smart contract address that emitted the event. For DELEGATECALLS, events are emitted by calling contracts and the ABI is defined by the called contract.
N
contract_name
varchar
DECODED
Name of the smart contract that generated the event, as decoded by Token Flow processes (ABI or inferred). Contains contract address if not found.
Y
implementation
varchar
RAW
Smart contract address that provides the event semantics (ABI) - called contract for DELEGATECALLS or calling contract for the rest of the call types.
N
event_signature
varchar
RAW
Raw hexadecimal indexed content of the event (topic 0).
N
event_name
varchar
DECODED
Name of the event, as decoded by Token Flow processes (ABI or inferred from similar functions). Contains event_signature if not found.
Y
raw_parameters
json*
DECODED
List of event parameters, where for each element there are the following elements: name, raw, type, value. Parameters order is preserved. Parameters are decoded using the same strategy as for PARAMETERS field.
Y
parameters
json*
DECODED
List of event parameters as key:value pairs, as decoded by Token Flow processes (ABI or inferred from similar functions). Key is the output name and value is the decoded value. Contains 'topic_parameter_1-3' and 'data_parameter_0-n' argument if decoding was unsuccessful.
Y
reverted
boolean
RAW
Flags persistent (false) or reverted (true) calls. Reverted diffs can originate from technical failures (code errors), gas limits (more gas needed than was staked) or contract logic.
N
processed
boolean
TECH
Technical field. Defines processing status of a block by the decoding ETL process.
N
decoded
boolean
TECH
Technical field. Flags the success (true) or failure (false) of the decoding process: NULL = used only when the data is loading TRUE = decoding process was successful (event_signature = event_name) FALSE = decoding process was unsuccessful
Y
abi_inferred
boolean
TECH
Flags whether the function semantics used for decoding was taken from the called contract's ABI (False) or it was inferred from other contracts (True).
Y

State_diffs

Column Name
Data Type
Layer
Definition
Nullable
updated_at
timestamp
TECH
Technical field. Timestamp of the process that has updated the row in the table, updated every time the record in changed. UTC timestamp (including miliseconds).
N
chain_id
number
TECH
Technical field. Unique identifier of the chain (identifiers from Chainlist are used for all EVM compliant chains).
N
chain_generation
number
TECH
Technical field. Traks instances when the chain is restarted - the Optimism dataset only includes 5th generation data.
N
block_id
varchar
TECH
Technical field. Unique identifier of the block across chains and generations, constructed by concatenating chain_id, generation and block number, separated by underscore.
N
block_number
number
RAW
Number of the block. Numbering is incremental, starting at 0 (Genesis) with new blocks added at the end of the chain.
N
block_timestamp
timestamp
RAW
Timestamp of the block. Unique for every block and inherited by calls, events, transactions and diffs happening in the same block. UTC timestamp (including milliseconds).
N
block_date
varchar
TECH
Technical field. Date of the block - precomputed to be used for analytics purposes, inherited by calls, events, transactions and diffs happening in the same block.
N
tx_id
varchar
TECH
Technical field. Unique identifier of the transaction accross chains, constructed by concatenating block id and transaction index, separated by underscores. Exception: Empty string ('') is used if the state diff originated in the block.
N*
tx_hash
varchar
RAW
Hash of the transaction (KECCAK-256). Unique for every transaction. Empty if the state diff originated in the block.
N
call_id
varchar
TECH
Technical field. Unique identifier of the call accross chains, constructed by concatenating block id, transaction index and call path, separated by underscores. Exception: Empty string ('') is used if the state diff originated in the block.
N*
state_diff_id
varchar
TECH
Technical field. Unique identifier of the state_diff, constructed by concatenating the block id and order index, separated by underscores.
N
order_index
number
TECH
Technical field. Sequence of actions (call, events, diffs) that happened in a block.
Y
address
varchar
RAW
Blockchain address that the change applies to.
N
state_field
varchar
RAW
Name of the state field that is being changed.
N
reason
varchar
RAW
Reason for the state change. This field should be used in combination with state_field.
N
prev_value
varchar
RAW
State field value before the change.
N
curr_value
varchar
RAW
State field value after the change.
N
reverted
boolean
RAW
Flags persistent (false) or reverted (true) calls. Reverted diffs can originate from technical failures (code errors), gas limits (more gas needed than was staked) or contract logic.
N
processed
boolean
TECH
Technical field. Defines processing status of a block by the decoding ETL process.
N

Storage_diffs

Column Name
Data Type
Layer
Definition
Nullable
updated_at
timestamp
TECH
Technical field. Timestamp of the process that has updated the row in the table, updated every time the record in changed. UTC timestamp (including milliseconds).
N
chain_id
number
TECH
Technical field. Unique identifier of the chain (identifiers from Chainlist are used for all EVM compliant chains).
N
chain_generation
number
TECH
Technical field. Traks instances when a chain is restarted - the Optimism dataset only includes 5th generation data.
N
block_id
varchar
TECH
Technical field. Unique identifier of the block across chains and generations, constructed by concatenating chain_id, generation and block number, separated by underscore.
N
block_number
number
RAW
Number of the block. Numbering is incremental, starting at 0 (Genesis) with new blocks added at the end of the chain.
N
block_timestamp
timestamp
RAW
Timestamp of the block. Unique for every block and inherited by calls, events, transactions and diffs happening in the same block. UTC timestamp (including miliseconds).
N
block_date
varchar
TECH
Technical field. Date of the block - precomputed to be used for analytics purposes, inherited by calls, events, transactions and diffs happening in the same block.
N
tx_id
varchar