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

# Sui Token Transfers

> Curated and enriched fungible token transfer activity on the Sui blockchain.

export const TableSample = ({tableName, tableSchema}) => <>
    <div className="hidden dark:block">
      <iframe src={`https://dune.com/embeds/3419983/5785629?table_schema_t6f0df=${tableSchema}&table_name_t6f0df=${tableName}&darkMode=true`} style={{
  width: '100%',
  height: '500px',
  border: 'none',
  marginTop: '10px'
}} />
    </div>
    <div className="dark:hidden">
      <iframe src={`https://dune.com/embeds/3419983/5785629?table_schema_t6f0df=${tableSchema}&table_name_t6f0df=${tableName}`} style={{
  width: '100%',
  height: '500px',
  border: 'none',
  marginTop: '10px'
}} />
    </div>
  </>;

The `tokens_sui.transfers` table contains curated fungible token transfer activity for Sui `Coin<T>` assets indexed on Dune. Because Sui is object-based, the table reconstructs token movement from coin-object ownership and balance changes, then combines that with explicit mint and burn supply events.

This dataset includes:

* Cross-address transfer rows derived from `Coin<T>` object ownership and balance deltas
* Event-native mint and burn rows derived from Sui treasury events
* Metadata enrichment for symbol and decimals
* USD valuation when an hourly USD price is available for the token

<Info>
  The table aims to capture standard Sui `Coin<T>` transfer activity. Because Sui transfers are object-based, some rows represent balance adjustments caused by coin object ownership changes rather than a direct transfer between two addresses.
</Info>

### Utility

The Sui transfers table provides a consistent view of fungible token movement on Sui, enabling you to:

* Track wallet-to-wallet coin movement across Sui addresses
* Analyze transfer volume by coin, wallet, and day
* Separate regular transfers from mint and burn activity
* Investigate object-based balance changes and supply updates in one table

### Methodology

Sui token movement is modeled differently than EVM and Aptos transfers. The official Sui docs describe Sui as an object-based chain, and fungible assets using the Coin standard are represented as `Coin<T>` objects. The same docs also note that minting and burning require the token's `TreasuryCap`. Dune's Sui transfers model aligns to that design and reconstructs transfer rows from `Coin<T>` object history plus treasury supply events.

The `tokens_sui.transfers` table is built as follows:

* It starts from Sui `Coin<T>` object lifecycle and owner-net transfer models, keeping non-zero balance changes and ownership changes.
* Cross-address transfers are reconstructed from object ownership changes and balance deltas, including transfers with and without balance changes.
* Event-native treasury mint and burn rows are added from supply events, and overlapping legacy object rows are removed when those event-native supply rows exist.
* Symbol and decimals are enriched from Sui coin metadata in `sui_coin_info`.
* `amount_usd` is calculated from hourly Sui token pricing when a price is available for that hour.

### Pricing Methodology

The `price_usd` and `amount_usd` columns come from Dune's external hourly price feed for Sui tokens. If a token has a price for that hour, the transfer row gets a USD price and value. If not, both columns stay `NULL`.

This approach is meant to keep transfer valuations stable and avoid obvious outliers from thin or noisy onchain pricing. For tokens outside Dune's trusted token set, very large computed USD values are set to `NULL` instead of being shown.

For more details on Dune's pricing methodology, see the [Prices documentation](/data-catalog/curated/prices/overview).

## Table Schema

| Column                 | Type            | Description                                                   |
| ---------------------- | --------------- | ------------------------------------------------------------- |
| `unique_key`           | `VARCHAR`       | Surrogate key to identify a unique transfer row               |
| `blockchain`           | `VARCHAR`       | Blockchain identifier (`sui`)                                 |
| `block_month`          | `DATE`          | Month bucket derived from `block_time`                        |
| `block_date`           | `DATE`          | Block date                                                    |
| `block_time`           | `TIMESTAMP`     | Block timestamp                                               |
| `checkpoint`           | `DECIMAL(20,0)` | Sui checkpoint number                                         |
| `tx_digest`            | `VARCHAR`       | Sui transaction digest                                        |
| `token_standard`       | `VARCHAR`       | Token standard label for the transfer record                  |
| `from`                 | `VARBINARY`     | Transfer sender address                                       |
| `to`                   | `VARBINARY`     | Transfer receiver address                                     |
| `contract_address`     | `VARBINARY`     | Package address extracted from `coin_type`                    |
| `coin_type`            | `VARCHAR`       | Full Sui coin type                                            |
| `symbol`               | `VARCHAR`       | Token symbol from Sui coin metadata                           |
| `decimals`             | `INTEGER`       | Display decimals from Sui coin metadata                       |
| `amount_raw`           | `DECIMAL(38,0)` | Raw token amount before decimal adjustment                    |
| `amount`               | `DOUBLE`        | Transfer amount in display units                              |
| `price_usd`            | `DOUBLE`        | Hourly USD price used to calculate `amount_usd`               |
| `amount_usd`           | `DOUBLE`        | USD value of the transfer                                     |
| `balance_delta`        | `DECIMAL(38,0)` | Signed balance change associated with the transfer row        |
| `object_id`            | `VARBINARY`     | Sui coin object identifier when applicable                    |
| `version`              | `DECIMAL(20,0)` | Coin object version when applicable                           |
| `object_status`        | `VARCHAR`       | Object lifecycle status for the coin object row               |
| `owner_type`           | `VARCHAR`       | Sui owner type associated with the row                        |
| `coin_balance`         | `DECIMAL(38,0)` | Coin object balance at this version                           |
| `prev_balance`         | `DECIMAL(38,0)` | Previous observed balance for the same object                 |
| `prev_owner`           | `VARBINARY`     | Previous observed owner for the same object                   |
| `has_ownership_change` | `BOOLEAN`       | Whether ownership changed between consecutive object versions |
| `transfer_type`        | `VARCHAR`       | Transfer label describing the row's reconstruction path       |
| `is_supply_event`      | `BOOLEAN`       | True for event-native mint/burn rows                          |
| `supply_event_type`    | `VARCHAR`       | Mint/burn label for supply-event rows                         |
| `transfer_direction`   | `VARCHAR`       | Direction label derived from the balance movement             |
| `_updated_at`          | `TIMESTAMP`     | Timestamp when this row was last written                      |

<TableSample tableSchema="tokens_sui" tableName="transfers" />

## Sample Queries

**Query recent priced token transfers for a specific Sui address**

This query returns the most recent incoming and outgoing token transfers for a wallet where USD pricing is available:

```sql theme={null}
SELECT
    block_time,
    tx_digest,
    symbol,
    transfer_type,
    CASE
        WHEN "from" = 0xd3ae6e1c897c97a5a50c696227dfea5719ddaaa5450cb70e35ff78339a173445 THEN 'Outgoing'
        WHEN "to" = 0xd3ae6e1c897c97a5a50c696227dfea5719ddaaa5450cb70e35ff78339a173445 THEN 'Incoming'
    END AS direction,
    amount,
    amount_usd
FROM tokens_sui.transfers
WHERE (
        "from" = 0xd3ae6e1c897c97a5a50c696227dfea5719ddaaa5450cb70e35ff78339a173445
        OR "to" = 0xd3ae6e1c897c97a5a50c696227dfea5719ddaaa5450cb70e35ff78339a173445
    )
    AND amount_usd IS NOT NULL
    AND block_time > now() - interval '30' day
ORDER BY block_time DESC
LIMIT 100
```

**Calculate daily transfer volume for a specific Sui coin**

This query aggregates daily transfer activity for one Sui coin type:

```sql theme={null}
SELECT
    block_date,
    symbol,
    COUNT(*) AS num_rows,
    SUM(amount) AS total_amount,
    SUM(amount_usd) AS total_amount_usd
FROM tokens_sui.transfers
WHERE coin_type = '0x2::sui::SUI'
    AND is_supply_event = false
    AND block_date >= current_date - interval '30' day
GROUP BY 1, 2
ORDER BY 1 DESC
```

**Query recent mint and burn events for a Sui coin**

This query returns recent supply-changing events for a Sui coin with active mint and burn activity:

```sql theme={null}
SELECT
    block_time,
    tx_digest,
    symbol,
    supply_event_type AS flow_type,
    amount,
    amount_usd
FROM tokens_sui.transfers
WHERE coin_type = '0xdba34672e30cb065b1f93e3ab55318768fd6fef66c15942c9f7cb846e2f900e7::usdc::usdc'
    AND is_supply_event = true
    AND block_time > now() - interval '30' day
ORDER BY block_time DESC
LIMIT 100
```
