Overview

The near.staking.pool_balances model provides real-time tracking of staking pool balances and shares based on event logging. It captures the state of validator pools at each balance-changing event.

This model is updated hourly.

Use Cases

This model is particularly useful for:

  • Tracking historical stake changes across validators
  • Accounting shares to NEAR exchange rates across time

Relationship with Daily Balances

This model serves as the source for the near.staking.pool_balances_daily model, which provides daily snapshots of staking validator pool balances. While this model captures real-time events and balance changes, the daily model aggregates this data to provide end-of-day state for each validator pool.

Key differences:

  • This model tracks every balance-changing event (delegation events)
  • The daily model provides a single snapshot of the last balance entry per day per pool
  • This model includes complete transaction tracing

For daily aggregated views of pool balances, refer to the NEAR Daily Pool Balances model.

Column Description

Unique Key: unique_id

ColumnTypeDescription
block_timestampTIMESTAMPTimestamp of the block containing the balance update
pool_idVARCHARIdentifier of the staking pool
balance_strVARCHARPool’s NEAR balance (string format for precision)
balanceFLOATPool’s NEAR balance (float format)
usd_balanceFLAOTUSD equivalent of the pool’s NEAR balance
usd_exchange_rateFLAOTNEAR to USD exchange rate at time of update
shares_strVARCHARTotal shares in the pool (string format)
sharesFLAOTTotal number of shares in the pool
shares_exchange_rateFLAOTExchange rate between shares and NEAR
last_activity_block_timestampTIMESTAMPTimestamp of the pool’s last activity
transaction_hashVARCHARHash of the transaction causing the balance update
transaction_indexBIGINTIndex of the transaction within the block
receipt_idVARCHARUnique identifier of the receipt
receipt_indexBIGINTIndex of the receipt within the block
receipt_outcome_indexBIGINTIndex of the receipt outcome
log_indexBIGINTIndex of the log within the receipt
pseudo_global_indexBIGINTGlobal ordering index
unique_idVARCHARUnique identifier for the balance update event