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

# Trade messages

> Interpret the live trade payload.

Rungst sends a separate message for each matching, successfully decoded, positive-quantity Fomo swap. The addresses below are abbreviated for readability.

```json theme={null}
{
  "signature": "5Kq...x9P",
  "eventIndex": 0,
  "slot": 389123456,
  "blockTime": 1761210872,
  "trader": "7xKX...Qm3",
  "side": "buy",
  "tokenIn": {"mint":"EPjF...Dt1v","amount":"2500000000","decimals":6},
  "tokenOut": {"mint":"TOKEN...pump","amount":"8123456700000","decimals":9},
  "amountUsd": 2500.0,
  "terminal": "fomo",
  "chain": "solana",
  "subscriptionId": "sub_..."
}
```

| Field | Type | Description |
| - | - | - |
| `signature` | string | Solana transaction signature. A transaction can contain more than one decoded swap. |
| `eventIndex` | integer | Index assigned by the decoder to this swap. Together with `signature`, identifies an event for deduplication. |
| `slot` | integer | Solana slot containing the transaction. |
| `blockTime` | integer | Canonical block timestamp, in Unix seconds. |
| `trader` | string | Base58 Solana address of the verified signer attributed through owned token balance changes. |
| `side` | string | `buy` or `sell`, relative to the traded token. |
| `tokenIn` | object | Normalized asset and raw quantity entering the swap. For a buy, this is USDC; for a sell, it is the traded token. |
| `tokenOut` | object | Normalized asset and raw quantity leaving the swap. For a buy, this is the traded token; for a sell, it is USDC. |
| `amountUsd` | number | USDC settlement divided by 1,000,000, using USDC as USD. Network fees are excluded. This is a floating-point value. |
| `terminal` | string | Source terminal; currently `fomo`. |
| `chain` | string | Blockchain; currently `solana`. |
| `subscriptionId` | string | ID of the active subscription that received the trade. IDs are temporary. |

Both `tokenIn` and `tokenOut` contain these fields:

| Field | Type | Description |
| - | - | - |
| `mint` | string | Base58 Solana mint address of the asset. |
| `amount` | string | Exact raw integer amount encoded as a decimal string, before applying decimals. |
| `decimals` | integer | Number of decimal places from transaction metadata. Divide the raw amount by 10 to this power for the token quantity. |

Amounts are exact raw decimal strings. Divide by 10 raised to `decimals` for the token quantity; use a suitable arbitrary-precision representation to avoid rounding. Buys use USDC as `tokenIn`, and sells use USDC as `tokenOut`.

Delivery waits for block metadata and a confirmed or finalized slot update. There is no replay of missed messages or retraction protocol for confirmed trades that later leave the chain. Server-side duplicate suppression covers only a bounded recent window.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.