Credit Debit
Credit Debit tables contain the amount and direction (credit/debit) of every transfer event of all assets (ETH, ERC20, ERC721 and ERC1155) across all Ethereum wallets. This table will include two rows for every event, with one row representing credit and one row representing debit. Asset-specific tables are also available for query.
Difference with transfers
Unlike token transfers, data here is organized into credit and debit rows (similar to the accounting concept called "double entry book").
Methodology
Using an ERC20 token as an example, a token transfer will be represented as follows:
from_address | to_address | amount | event |
---|---|---|---|
X | Y | 1250 | X transfers 1250 tokens to Y |
In credit debit, it will be represented two rows.
address | counterparty_address | amount | event |
---|---|---|---|
X | Y | -1250 | X decrease 1250 tokens to Y |
Y | X | 1250 | Y increase 1250 tokens from |
Sample Query
Debit and credit of ETH from a particular transaction.
Getting the cumulative change of USDC holdings in Uniswap v3 USDC-WETH pool in the last 30 days
Table Columns
Column Name | Description | Example (Credit) | Example (Debit) |
---|---|---|---|
address | Address of the account that was credited or debited |
|
|
counterparty_address | The address of counter party of this credit or debit transfer. |
|
|
token_address | Token address of the asset transferred.
Note: Native ETH does not have a contract address, but for convention, it is labelled as: |
|
|
token_name | Name of the asset transferred. |
|
|
token_symbol | Token symbol of the asset transferred. |
|
|
raw_amount | Amount of tokens moved (unnormalized). For ERC721 and ERC1155 tokens, there are no decimals division involved. |
|
|
amount | Amount of token moved, normalized.
|
|
|
usd_amount | The amount of tokens moved, in $USD. |
|
|
usd_exchange_rate | Token symbol of this token. |
|
|
transaction_hash | Transaction hash that this transfer belongs to. |
|
|
block_timestamp | The timestamp of the block that the corresponding transaction of this transfer belongs to. This is also the timestamp when this transfer occurred. |
|
|
block_number | The block number that the corresponding transaction of this transfer belongs to. |
|
|
block_hash | The block hash that the corresponding transaction of this transfer belongs to. |
|
|
token_type | The type of asset transferred. Currently supports ETH, ERC20, ERC721 and ERC1155 tokens. |
|
|
unique_id | Unique id generated to each transfer. Includes transaction hash, log index and credit and debit transaction type. |
|
|
Last updated