> ## Documentation Index
> Fetch the complete documentation index at: https://tokenterminal.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# prices

> Tables in tt-primitives.prices

## Tables

### prices\_end\_of\_day

Daily closing prices in USD for tokens across multiple blockchain networks. Used for historical price analysis, portfolio valuation, and time-series comparisons of token performance.

<Accordion title="Columns">
  | Column            | Type        | Description                                                                                                                                                                                   |
  | ----------------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | `timestamp`       | `TIMESTAMP` | Timestamp representing the end of the pricing period for the token. All sample values show midnight UTC (00:00:00), indicating daily snapshot times aligned to the timestamp\_grain.          |
  | `timestamp_grain` | `STRING`    | Granularity of the price snapshot, indicating the time interval at which prices are aggregated. All rows in this table use 'day' for end-of-day pricing.                                      |
  | `chain`           | `STRING`    | Blockchain network identifier where the data originates. Lowercase string naming the specific blockchain network.                                                                             |
  | `token_address`   | `STRING`    | Contract address or module identifier of the token on the specified chain. For Aptos, uses the module format `address::module::type`; for EVM chains, uses hex-encoded 0x-prefixed addresses. |
  | `price_usd`       | `FLOAT64`   | Token price denominated in United States dollars at the timestamp specified. Represents the market value at the daily close based on the timestamp\_grain.                                    |
</Accordion>

<Accordion title="Sample Data">
  | chain | price\_usd              | timestamp                | token\_address                                                               | timestamp\_grain |
  | ----- | ----------------------- | ------------------------ | ---------------------------------------------------------------------------- | ---------------- |
  | aptos | 0.000029422505927217045 | 2025-03-24T00:00:00.000Z | 0x1fccdef89b13d4697064d4eff89d26547f2b08d194b495973642729503a7f38f::RBT::RBT | day              |
  | aptos | 0.000031418972056330546 | 2025-03-01T00:00:00.000Z | 0x1fccdef89b13d4697064d4eff89d26547f2b08d194b495973642729503a7f38f::RBT::RBT | day              |
  | aptos | 0.000026226518556790717 | 2025-03-11T00:00:00.000Z | 0x1fccdef89b13d4697064d4eff89d26547f2b08d194b495973642729503a7f38f::RBT::RBT | day              |
</Accordion>

<Accordion title="Example Query">
  **Query with partition filter**

  ```sql theme={null}
  SELECT *
  FROM `tt-primitives.prices.prices_end_of_day`
  WHERE timestamp >= DATE_SUB(CURRENT_DATE(), INTERVAL 1 MONTH)
  LIMIT 100
  ```
</Accordion>

***

### prices\_per\_day

Daily USD price snapshots for tokens across blockchains, indexed by contract address and chain. Used for historical price analysis, portfolio valuation, and calculating trading returns over time.

<Accordion title="Columns">
  | Column            | Type        | Description                                                                                                                                                                                                         |
  | ----------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | `timestamp`       | `TIMESTAMP` | UTC timestamp representing the start of the day for which the token price is recorded. All sample values show midnight (00:00:00) timestamps, indicating daily price snapshots aggregated at day-level granularity. |
  | `timestamp_grain` | `STRING`    | Specifies the time aggregation level for the price data point. Always set to "day" indicating daily price snapshots at 00:00:00 UTC.                                                                                |
  | `chain`           | `STRING`    | Blockchain network identifier where the data originates. Lowercase string naming the specific blockchain network.                                                                                                   |
  | `token_address`   | `STRING`    | Contract address of the token being priced on the specified chain. Hex-encoded, 0x-prefixed 40-character string for EVM chains like Ethereum.                                                                       |
  | `price_usd`       | `FLOAT64`   | Daily closing price of the token denominated in US dollars. Values typically reflect end-of-day snapshots and may vary slightly around stable price points due to market fluctuations.                              |
</Accordion>

<Accordion title="Sample Data">
  | chain    | price\_usd         | timestamp                | token\_address                             | timestamp\_grain |
  | -------- | ------------------ | ------------------------ | ------------------------------------------ | ---------------- |
  | ethereum | 1.008098252156842  | 2019-04-22T00:00:00.000Z | 0x3afdc9bca9213a35503b077a6072f3d0d5ab0840 | day              |
  | ethereum | 1.0050138359430159 | 2019-04-15T00:00:00.000Z | 0x3afdc9bca9213a35503b077a6072f3d0d5ab0840 | day              |
  | ethereum | 0.9972353851680991 | 2019-04-07T00:00:00.000Z | 0x3afdc9bca9213a35503b077a6072f3d0d5ab0840 | day              |
</Accordion>

<Accordion title="Example Query">
  **Query with partition filter**

  ```sql theme={null}
  SELECT *
  FROM `tt-primitives.prices.prices_per_day`
  WHERE timestamp >= DATE_SUB(CURRENT_DATE(), INTERVAL 1 MONTH)
  LIMIT 100
  ```
</Accordion>

***

### prices\_per\_hour

Hourly USD price snapshots for tokens across multiple blockchain networks, identified by chain and contract address. Used for historical price analysis, portfolio valuation, and calculating returns over time.

<Accordion title="Columns">
  | Column            | Type        | Description                                                                                                                                                                               |
  | ----------------- | ----------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | `timestamp`       | `TIMESTAMP` | UTC timestamp marking the start of the hourly price observation period. Aligned to the top of each hour (e.g., 02:00:00, 08:00:00) as indicated by the hour grain.                        |
  | `timestamp_grain` | `STRING`    | Time granularity of the price observation, indicating the aggregation interval for the data point. All records in this table use "hour" granularity, representing hourly price snapshots. |
  | `chain`           | `STRING`    | Blockchain network identifier where the data originates. Lowercase string naming the specific blockchain network.                                                                         |
  | `token_address`   | `STRING`    | Contract address of the token on the specified chain. Hex-encoded, 0x-prefixed 40-character string for EVM chains.                                                                        |
  | `price_usd`       | `FLOAT64`   | USD-denominated price of the token at the specified timestamp. Represents the market value per token unit, aggregated at hourly intervals.                                                |
</Accordion>

<Accordion title="Sample Data">
  | chain    | price\_usd         | timestamp                | token\_address                             | timestamp\_grain |
  | -------- | ------------------ | ------------------------ | ------------------------------------------ | ---------------- |
  | arbitrum | 2.867440611968693  | 2025-01-19T02:00:00.000Z | 0x040d1edc9569d4bab2d15287dc5a4f10f56a56b8 | hour             |
  | arbitrum | 2.6249961088772356 | 2025-01-21T08:00:00.000Z | 0x040d1edc9569d4bab2d15287dc5a4f10f56a56b8 | hour             |
  | arbitrum | 2.59161125290021   | 2025-01-24T03:00:00.000Z | 0x040d1edc9569d4bab2d15287dc5a4f10f56a56b8 | hour             |
</Accordion>

<Accordion title="Example Query">
  **Query with partition filter**

  ```sql theme={null}
  SELECT *
  FROM `tt-primitives.prices.prices_per_hour`
  WHERE timestamp >= DATE_SUB(CURRENT_DATE(), INTERVAL 1 MONTH)
  LIMIT 100
  ```
</Accordion>

***
