# Bridge

Key Tables:

* **Tokens:** Details of the tokens in the protocol, including address, symbol, and decimals.
* **Pools:** Details of pools in bridge protocols, including token information, pool creation data, and fee rates.
* **LP Snapshot:** Snapshots of liquidity provider positions in pool-based bridge protocols, including token amounts and their USD value.
* **User Snapshot:** User activity snapshots in pool and intent-based bridge protocols, tracking token inflows and outflows.
* **Pool Snapshot:** Snapshot of individual pools, including token volume, fees, and bridged data.
* **Bridge Transactions:** Records of user transactions across bridge protocols, including source/destination chain IDs and token amounts.
* **Maker Snapshot:** Snapshots on makers in intent-based bridge protocols, including tokens supplied and fees collected.
* **Taker Snapshot:** Snapshots on takers in intent-based bridge protocols, including volume bridged and fees paid.
* **Token Snapshot:** Token-level data across bridge protocols, capturing amounts held, bridged volume, and fees collected.

{% tabs %}
{% tab title="Tokens" %}

| Property        | Description                                | Type   |
| --------------- | ------------------------------------------ | ------ |
| token\_address  | The contract address of the token.         | string |
| token\_symbol   | The symbol of the token.                   | string |
| token\_decimals | The decimal amount of the token.           | number |
| chain\_id       | The blockchain ID where the token resides. | number |
| {% endtab %}    |                                            |        |

{% tab title="Pools" %}

| Property                | Description                                                                       | Type    |
| ----------------------- | --------------------------------------------------------------------------------- | ------- |
| timestamp               | The timestamp this pool was created.                                              | number  |
| creation\_block\_number | The block number this pool was created on.                                        | number  |
| token\_address          | The contract address of the token being bridged or pooled.                        | string  |
| token\_index            | The index of the pooled token in the smart contract.                              | number  |
| token\_symbol           | The symbol of the token.                                                          | string  |
| fee\_rate               | The fee rate as a percentage for the pool, if applicable (ie, 2.3% fee as 0.023). | number  |
| pool\_address           | The contract address of the pool.                                                 | string  |
| chain\_id               | Standard chain ID (ie, the chain ID of the network the pool lives on).            | number  |
| bridge\_type            | The type of bridge (ie, pool-based, mint-based, or intent-based).                 | vstring |
| {% endtab %}            |                                                                                   |         |

{% tab title="LP Snapshot" %}

| Property           | Description                                                                                                       | Type   |
| ------------------ | ----------------------------------------------------------------------------------------------------------------- | ------ |
| timestamp          | The timestamp of the snapshot.                                                                                    | number |
| block\_date        | The timestamp truncated (ie, YYYY-MM-DD format for daily snapshots and YYYY-MM-DD HH:00:00 for hourly snapshots). | date   |
| pool\_address      | The address of the pool.                                                                                          | string |
| lp\_address        | The address of the liquidity provider.                                                                            | string |
| token\_address     | The contract address of the token supplied.                                                                       | string |
| token\_index       | The index in the smart contract of this token, default to 0.                                                      | number |
| token\_amount      | The amount of the supplied token, decimal normalized.                                                             | number |
| token\_amount\_usd | The amount supplied, in USD.                                                                                      | number |
| chain\_id          | The standard chain ID where the liquidity provider resides.                                                       | number |
| bridge\_type       | The type of bridge (pool-based, mint-based, or intent-based).                                                     | string |
| {% endtab %}       |                                                                                                                   |        |

{% tab title="User Snapshot" %}

| Property         | Description                                                                                                       | Type   |
| ---------------- | ----------------------------------------------------------------------------------------------------------------- | ------ |
| timestamp        | The timestamp of the snapshot.                                                                                    | number |
| block\_date      | The timestamp truncated (ie, YYYY-MM-DD format for daily snapshots and YYYY-MM-DD HH:00:00 for hourly snapshots). | date   |
| pool\_address    | The contract address of the pool.                                                                                 | string |
| user\_address    | The address of the user this snapshot activity is based on.                                                       | string |
| amount\_in\_usd  | The amount of tokens received on this network by the user in USD during the given snapshot.                       | number |
| amount\_out\_usd | The amount of tokens sent out of this network by the user in USD during the given snapshot.                       | number |
| chain\_id        | The standard chain ID where the bridger resides.                                                                  | number |
| bridge\_type     | The type of bridge (pool-based, mint-based, or intent-based).                                                     | string |
| {% endtab %}     |                                                                                                                   |        |

{% tab title="Pool Snapshot" %}

| Property           | Description                                                                                                       | Type   |
| ------------------ | ----------------------------------------------------------------------------------------------------------------- | ------ |
| timestamp          | The timestamp of the snapshot.                                                                                    | number |
| block\_date        | The timestamp truncated (ie, YYYY-MM-DD format for daily snapshots and YYYY-MM-DD HH:00:00 for hourly snapshots). | date   |
| pool\_address      | The contract address of the pool.                                                                                 | string |
| token\_address     | The contract address of the token being bridged or pooled.                                                        | string |
| token\_index       | The index of the pooled token in the smart contract.                                                              | number |
| token\_symbol      | The symbol of the token.                                                                                          | string |
| token\_amount      | The amount of the supplied token (in a pool-based bridge), decimal normalized.                                    | number |
| token\_amount\_usd | The amount supplied, in USD.                                                                                      | number |
| volume\_usd        | The bridged volume in USD, during this snapshot.                                                                  | number |
| fees\_usd          | The fees collected in USD, during the snapshot period.                                                            | number |
| chain\_id          | The standard chain ID where the pool resides.                                                                     | number |
| bridge\_type       | The type of bridge (pool-based, mint-based, or intent-based).                                                     | string |
| {% endtab %}       |                                                                                                                   |        |

{% tab title="Transactions" %}

| Property               | Description                                                                 | Type   |
| ---------------------- | --------------------------------------------------------------------------- | ------ |
| timestamp              | The timestamp of the transaction.                                           | number |
| block\_number          | The block number of the transaction.                                        | number |
| transaction\_hash      | The hash of the transaction this bridge originated from.                    | string |
| log\_index             | The log index of the transaction.                                           | number |
| source\_chain\_id      | The source standard chain ID.                                               | number |
| destination\_chain\_id | The destination standard chain ID.                                          | number |
| user\_address          | The address of the user initiating the transaction.                         | string |
| token\_address         | The smart contract address of the source chain bridge token.                | string |
| token\_amount          | The amount of the token sent out from the source chain, decimal normalized. | number |
| token\_amount\_usd     | The token amount in USD.                                                    | number |
| solver\_address        | The address of the solver (for intent-based bridges).                       | string |
| pool\_address          | The address of the pool (for pool-based and mint-based bridges).            | string |
| bridge\_type           | The type of bridge (pool-based, mint-based, or intent-based).               | string |
| {% endtab %}           |                                                                             |        |

{% tab title="Maker Snapshot" %}

| Property           | Description                                                                                                       | Type   |
| ------------------ | ----------------------------------------------------------------------------------------------------------------- | ------ |
| timestamp          | The timestamp of the snapshot.                                                                                    | number |
| block\_date        | The timestamp truncated (ie, YYYY-MM-DD format for daily snapshots and YYYY-MM-DD HH:00:00 for hourly snapshots). | date   |
| user\_address      | The address of the maker.                                                                                         | string |
| token\_address     | The smart contract address of the token being supplied by the maker.                                              | string |
| token\_in\_amount  | The amount of the token received, decimal normalized.                                                             | number |
| amount\_in\_usd    | The amount received in USD, during this snapshot.                                                                 | number |
| token\_out\_amount | The amount of the token sent out, decimal normalized.                                                             | string |
| amount\_out\_usd   | The amount sent in USD, during this given snapshot.                                                               | number |
| fees\_usd          | The fees collected in USD, during this snapshot.                                                                  | number |
| chain\_id          | The standard chain ID where the maker resides.                                                                    | string |
| {% endtab %}       |                                                                                                                   |        |

{% tab title="Taker Snapshot" %}

| Property       | Description                                                                                                       | Type   |
| -------------- | ----------------------------------------------------------------------------------------------------------------- | ------ |
| timestamp      | The timestamp of the snapshot.                                                                                    | number |
| block\_date    | The timestamp truncated (ie, YYYY-MM-DD format for daily snapshots and YYYY-MM-DD HH:00:00 for hourly snapshots). | date   |
| user\_address  | The address of the taker.                                                                                         | string |
| token\_address | The smart contract address of the token.                                                                          | string |
| volume\_amount | The amount of volume bridged from the source chain, decimal normalized.                                           | number |
| volume\_usd    | The volume bridged in USD, in the given snapshot.                                                                 | number |
| chain\_id      | The standard chain ID where the taker resides.                                                                    | number |
| {% endtab %}   |                                                                                                                   |        |

{% tab title="Token Snapshot" %}

| Property       | Description                                                                                                       | Type   |
| -------------- | ----------------------------------------------------------------------------------------------------------------- | ------ |
| timestamp      | The timestamp of the snapshot.                                                                                    | number |
| block\_date    | The timestamp truncated (ie, YYYY-MM-DD format for daily snapshots and YYYY-MM-DD HH:00:00 for hourly snapshots). | date   |
| user\_address  | The address of the taker.                                                                                         | string |
| token\_address | The smart contract address of the token.                                                                          | string |
| volume\_amount | The amount of volume bridged from the source chain, decimal normalized.                                           | number |
| volume\_usd    | The volume bridged in USD, in the given snapshot.                                                                 | number |
| chain\_id      | The standard chain ID where the taker resides.                                                                    | number |
| {% endtab %}   |                                                                                                                   |        |
| {% endtabs %}  |                                                                                                                   |        |
