Lending
Deposits
The <chain>.lending.deposits
table contains deposit events from Aave v1, v2, v3 and Compound v2 and v3 and Morpho Blue protocols, consolidated into a single table for easy querying.
This table tracks all deposit activities across major lending protocols, providing comprehensive information about deposit amounts, tokens, participants, and transaction details.
Table Columns
Unique Key: unique_id
Column | Data Type | Description |
---|---|---|
project | VARCHAR | Name of the lending project |
protocol | VARCHAR | Underlying protocol that the lending protocol is utilising |
lending_event | VARCHAR | Type of lending event (always ‘deposits’ for this table) |
event_name | VARCHAR | Name of the event |
market_address | VARCHAR | Address of the lending market |
depositor_address | VARCHAR | Address of the depositor |
target_address | VARCHAR | Address of the target recipient of the deposit tokens |
token_address | VARCHAR | Address of the token deposited |
token_name | VARCHAR | Name of the token deposited |
token_symbol | VARCHAR | Symbol of the token deposited |
token_decimals | INTEGER | Number of decimals of the token deposited |
raw_amount_str | VARCHAR | Raw amount of the token deposited, in string to retain precision |
raw_amount | FLOAT | Raw amount of the token deposited |
amount_str | VARCHAR | Normalised amount of the token deposited, in string to retain precision |
amount | FLOAT | Normalised amount of the token deposited |
usd_amount | FLOAT | USD amount of the token deposited at the time of the transaction |
usd_exchange_rate | FLOAT | Hourly USD exchange rate of the token deposited |
receipt_token_address | VARCHAR | Address of the receipt token received (e.g., aToken, cToken) |
extra_fields | VARIANT | Extra fields from the event |
transaction_hash | VARCHAR | Transaction hash of the event |
transaction_index | INTEGER | Index of the transaction in the block |
transaction_from_address | VARCHAR | Address of the sender of the transaction |
transaction_to_address | VARCHAR | Address of the recipient of the transaction |
log_index | INTEGER | Index of the log in the transaction |
topic0 | VARCHAR | Topic 0 of the event |
block_number | INTEGER | Block number of the event |
block_timestamp | TIMESTAMP_NTZ(9) | Timestamp of the block |
block_hash | VARCHAR | Hash of the block |
unique_id | VARCHAR | Unique ID of the event |
created_at | TIMESTAMP_NTZ(9) | Timestamp of when the event was created |
updated_at | TIMESTAMP_NTZ(9) | Timestamp of when the event was last updated |