> ## 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 | `canton.dex.trades` |
| Table Status | Production-Ready |
| Unique Key | `block_timestamp`, `unique_id` |

### 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\_id | VARCHAR(16777216) | Tradecraft pool identifier, for example 'TC CNTN/USDCx #eb7f…-1 CL7' |
| venue\_address | VARCHAR(16777216) | Canton party of the Tradecraft venue that runs the pool |
| vault\_address | VARCHAR(16777216) | Canton party of the vault that holds the pool assets |
| security\_id | VARCHAR(16777216) | Identifier of the tokenized security that the pool trades, for example 'cntn' |
| token\_sold\_admin\_address | VARCHAR(16777216) | Canton party that administers the sold token (the instrument admin). Together with token\_sold\_instrument\_id it identifies the token |
| token\_sold\_instrument\_id | VARCHAR(16777216) | Instrument id of the sold token, unique for its admin party |
| token\_sold\_symbol | VARCHAR(16777216) | Ticker symbol of the token sold in this swap. |
| token\_sold\_amount\_str | VARCHAR(16777216) | Decimal-adjusted amount of the token sold as a string for full precision. |
| token\_sold\_amount | FLOAT | Decimal-adjusted amount of the token sold (token\_sold\_amount\_raw / 10^decimals). |
| token\_bought\_admin\_address | VARCHAR(16777216) | Canton party that administers the bought token (the instrument admin). Together with token\_bought\_instrument\_id it identifies the token |
| token\_bought\_instrument\_id | VARCHAR(16777216) | Instrument id of the bought token, unique for its admin party |
| token\_bought\_symbol | VARCHAR(16777216) | Ticker symbol of the token bought in this swap. |
| token\_bought\_amount\_str | VARCHAR(16777216) | Decimal-adjusted amount of the token bought as a string for full precision. |
| token\_bought\_amount | FLOAT | Decimal-adjusted amount of the token bought (token\_bought\_amount\_raw / 10^decimals). |
| usd\_amount | FLOAT | USD value of the token amount at the time of the event, computed using the hourly USD exchange rate. |
| extra\_fields | VARIANT | Other trade fields from the trade tape: direction, price, size\_shares, shares\_per\_token, display\_label, trade\_time (the tape time, can differ from record\_time by about a second), ledger\_offset, contract ids, and source\_extra\_fields (API fields that have no column) |
| update\_id | VARCHAR(16777216) | Unique identifier of this Canton ledger update |
| record\_time | TIMESTAMP\_NTZ(9) | Time at which this update was recorded by the Canton synchronizer domain |
| migration\_id | NUMBER(38,0) | Identifier of the Canton ledger migration version that produced this event |
| block\_number | NUMBER(38,0) | Sequential number of the block that contains this record. Starts at 0 (genesis block) and increments by 1 for each new block. |
| block\_timestamp | TIMESTAMP\_NTZ(9) | Timestamp (UTC) of the block in which this event was confirmed. |
| \_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. |
| unique\_id | VARCHAR(16777216) | Unique identifier of the trade: update\_id and the contract id the trade creates. One update can hold several trades |
