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

# Trades

### Table Details

| Property            | Value                                           |
| ------------------- | ----------------------------------------------- |
| Table Name          | `aptos.dex.trades`                              |
| Table Status        | Production-Ready                                |
| Unique Key          | `block_timestamp`, `unique_id`                  |
| Clustering Key(s)   | `block_timestamp::date`                         |
| Search Optimization | `transaction_hash`, `project`, `sender_address` |

### Table Columns

| Column Name                     | Data Type         | Description                                                                                                                                                                                                        |
| ------------------------------- | ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| project                         | VARCHAR(16777216) | Business name of the protocol being used (e.g. `uniswap`, `aave`, `lido`, `paraswap`). Consistent across verticals — every table with a `project` column uses this field to identify the top-level protocol brand. |
| protocol                        | VARCHAR(16777216) | Specific version or variant of the protocol (e.g. `uniswap_v3`, `aave_v2`, `stargate_v2`). Qualifies the `project` field with version information.                                                                 |
| liquidity\_pool\_address        | VARCHAR(16777216) | Contract address of the liquidity pool where this trade was executed. Null when the routing path is not emitted by the event (common for aggregator trades).                                                       |
| sender\_address                 | VARCHAR(16777216) | Address that initiated the bridge transfer on the source chain.                                                                                                                                                    |
| recipient\_address              | VARCHAR(16777216) | Address that will receive the tokens on the destination chain. May be null if the destination address is not emitted in the source-chain event.                                                                    |
| coin\_sold\_type                | VARCHAR(16777216) | Type/address of the coin being sold                                                                                                                                                                                |
| coin\_sold\_name                | VARCHAR(16777216) | Name of the coin being sold                                                                                                                                                                                        |
| coin\_sold\_symbol              | VARCHAR(16777216) | Symbol of the coin being sold                                                                                                                                                                                      |
| coin\_sold\_decimals            | NUMBER(38,0)      | Number of decimal places for the coin being sold                                                                                                                                                                   |
| coin\_sold\_amount\_raw\_str    | VARCHAR(16777216) | Raw amount of coin sold as string                                                                                                                                                                                  |
| coin\_sold\_amount\_raw         | FLOAT             | Raw amount of coin sold as float                                                                                                                                                                                   |
| coin\_sold\_amount\_str         | VARCHAR(16777216) | Normalized amount of coin sold as string                                                                                                                                                                           |
| coin\_sold\_amount              | FLOAT             | Normalized amount of coin sold as float                                                                                                                                                                            |
| usd\_sold\_amount               | FLOAT             | USD value of the tokens sold in this swap, computed from the token\_sold price at block time.                                                                                                                      |
| coin\_bought\_type              | VARCHAR(16777216) | Type/address of the coin being bought                                                                                                                                                                              |
| coin\_bought\_name              | VARCHAR(16777216) | Name of the coin being bought                                                                                                                                                                                      |
| coin\_bought\_symbol            | VARCHAR(16777216) | Symbol of the coin being bought                                                                                                                                                                                    |
| coin\_bought\_decimals          | NUMBER(38,0)      | Number of decimal places for the coin being bought                                                                                                                                                                 |
| coin\_bought\_amount\_raw\_str  | VARCHAR(16777216) | Raw amount of coin bought as string                                                                                                                                                                                |
| coin\_bought\_amount\_raw       | FLOAT             | Raw amount of coin bought as float                                                                                                                                                                                 |
| coin\_bought\_amount\_str       | VARCHAR(16777216) | Normalized amount of coin bought as string                                                                                                                                                                         |
| coin\_bought\_amount            | FLOAT             | Normalized amount of coin bought as float                                                                                                                                                                          |
| usd\_bought\_amount             | FLOAT             | USD value of the tokens bought in this swap, computed from the token\_bought price at block time.                                                                                                                  |
| usd\_amount                     | FLOAT             | USD value of the token amount at the time of the event, computed using the hourly USD exchange rate.                                                                                                               |
| transaction\_hash               | VARCHAR(16777216) | Hash of the transaction that produced this record. Uniquely identifies a transaction within the blockchain.                                                                                                        |
| transaction\_version            | NUMBER(38,0)      | Monotonically increasing version number of the transaction on the Aptos blockchain. Aptos uses versions rather than block-scoped transaction indices.                                                              |
| event\_index                    | NUMBER(38,0)      | Zero-based index of this event within its transaction. The specific semantics depend on the chain — on Aptos this is the `event_index` within the transaction; on Cosmos this is within the message.               |
| block\_timestamp                | TIMESTAMP\_NTZ(9) | Timestamp (UTC) of the block that contains this record.                                                                                                                                                            |
| block\_height                   | NUMBER(38,0)      | Number of confirmed blocks between this block and the genesis block (inclusive). Unlike `block_slot`, this only increments for slots that produced a block.                                                        |
| block\_hash                     | VARCHAR(16777216) | Cryptographic hash of the block header that contains this record. Uniquely identifies a block.                                                                                                                     |
| unique\_id                      | VARCHAR(16777216) | Allium's deterministic unique identifier for this row. Generated from the fields that uniquely identify the record (e.g. transaction hash + log index). Stable across full refreshes.                              |
| \_created\_at                   | TIMESTAMP\_NTZ(9) | Timestamp of when the entry was created in the database.                                                                                                                                                           |
| \_updated\_at                   | TIMESTAMP\_NTZ(9) | Timestamp of when the entry was last updated in the database.                                                                                                                                                      |
| \_changed\_since\_full\_refresh | BOOLEAN           | Indicates if the record has changed since the last full data refresh.                                                                                                                                              |
