Scout Chart Creator
  • Overview
  • Get Started
    • Tutorial 1: NMR Daily Transaction Count
    • Tutorial 2: LPT Weekly Volume (USD)
    • Tutorial 3: NMR vs LPT Daily comparison
  • Pipeline
    • Filter
    • Project
    • Group
      • Accumulators
    • Sort
    • Unwind
    • Custom
  • Data Source
    • Transactions
    • States
    • Contracts
    • Aragon
    • Livepeer
    • dYdX
    • Set
    • Token holders
  • Operators
    • Math operators
    • Logic operators
    • Function operators
    • Array operators
    • String operators
  • Config
  • Protocols
    • Dodo
      • 24H trade volume
      • Deposit & Withdraw
    • Livepeer
    • dYdX
      • Making sense of the trade data
    • MakerDao
    • Pickle Finance
      • Example: Daily deposit and withdraw of jar 0.88
      • Example: Listing all borrows of a strategy
  • FAQ
    • Dealing with "logs" field in "Transaction"
    • How to handle "Query Timeout" error?
    • How to use a variable in a Pipeline
  • Research
    • The circulating supply of DODO tokens
    • How are bitcoins doing on Ethereum? (as of Jan 20th 2021)
Powered by GitBook
On this page

Was this helpful?

  1. Data Source

Transactions

Contains all the decoded Ethereum transactions since block 6800000 (Nov-30-2018 UTC). New transactions are automatically decoded based on the smart contracts that Scout has at that time.

PreviousData SourceNextStates

Last updated 4 years ago

Was this helpful?

Here is how Scout organizes the Ethereum transaction data. To make it easy to remember, we are comparing what a transaction looks like on Scout with that on Etherscan.

  • transactionHash: The unique identification of a transaction.

  • contractAddress: Most transactions nowadays have a smart contract involved. This is the address of that smart contract. If the value is null, it means this transaction is a contract creation transaction.

What is a smart contract log?

When the smart contract is executed, this is what the log BidPlaced looks like on the blockchain.

  • blockNumber and blockTimestamp: The block number and the time when this transaction happened. BlockTimestamp is in UTC format.

  • function: The smart contract function that was executed in this transaction. This is another useful field you would use to track protocol/dApp metrics. Only one function can be executed in a transaction. The function is an object type and it also contains a few children fields:

    • name: The name of a function. Different smart contracts can have the exact same function names. For example, every ERC20 token contract has a function called "transfer". To identity a specific function, it's best to use both the name of this function and the contractAddress of a transaction.

    • params: These are the parameters of a function. If you are not a coder and don't understand what "the parameters of a function" means, it's totally fine. Just remember that from time to time, important metrics data will be stored in this field as well.

What is a smart contract function?

function bidAndWithdraw(address rebalancingSetToken, uint256 quantity, bool allowPartialFill)

That is a function called bidAndWithdraw. When the rebalance of a Set portfolio is initiated on the Set Protocol, this is one of the functions which will be executed on the Ethereum blockchain. A blockchain transaction is basically the footprints left by the smart contract after its execution. In that transaction, you can find the name field of the function is bidAndWithdraw. The params fields are _rebalancingSetToken, _quantity, and _allowPartialFill .

  • success: It has two values. If the transaction was successful, the value is true; If not, the value is false.

  • gasPrice: The price of the gas when the transaction was executed. The unit is in Wei.

What does "decode" mean? Decoding is a process of combing the raw Ethereum transaction data with the relevant smart contract information. After that process, the Ethereum data becomes more friendly to read and work with.

We try to keep the post-decoding format of the Ethereum transaction data as close to its original form as possible.

Now, let's dive into each data field of the Transactions data source: (Fields marked withare the most important ones.)

from: The party that initiated this transaction. It is always an , commonly known as a wallet address.

logs: This is the most important field to track protocol metrics. A single transaction can contain multiple logs. Software developers typically put logs inside a smart contract. When certain actions of the smart contract are executed, logs are the footprints that a smart contract leaves on the Ethereum blockchain.

Let's use smart contract as an example. Below is a code snippet of where the logBidPlacedis located in that smart contract: emit BidPlaced( _rebalancingSetToken, msg.sender, executionQuantity, tokenArray, inflowUnitArray, outflowUnitArray )

methodId: This is a value encoded based on the name and parameters of a function. Its uniqueness is not completely guaranteed. Most time, you don't need to pay attention to this value. More technical details can be found .

Let's still use smart contract as an example. In this contract, you can find the below code snippet:

🌶️
🌶️
Externally Owned Account
RebalanceAuctionModule
here
RebalanceAuctionModule
Transaction
Logs section
TLDR: The essentials of Ethereum transaction data