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

# Market Volume Spike

> Get notified when a market's volume exceeds its baseline by a configured ratio.

<Note>
  **Event:** `market_volume_spike` \
  **Endpoint:** `wss://api.struct.to/ws/alerts` \
  **Cost:** 0.2 credits per event
</Note>

Get notified when a market's volume exceeds its baseline by a configured ratio. The `spike_ratio` filter is required and defines the volume multiplier threshold.

## Filters

| Filter          | Type      | Required | Description                                                                    |
| --------------- | --------- | -------- | ------------------------------------------------------------------------------ |
| `spike_ratio`   | number    | Yes      | Volume multiplier threshold, must be greater than 1.0 (e.g. 2.0 = 2x baseline) |
| `condition_ids` | string\[] | No       | Restrict to specific conditions (max 500)                                      |
| `timeframes`    | string\[] | No       | Timeframe windows: `1m`, `5m`, `30m`, `1h`, `6h`, `24h`, `7d`, `30d` (max 500) |
| `window_secs`   | number    | No       | Snapshot baseline reset interval in seconds (1-600)                            |

## Subscribe

```json theme={null}
{
  "op": "subscribe",
  "event": "market_volume_spike",
  "spike_ratio": 2.0,
  "timeframes": ["5m", "1h"]
}
```

## Response

```json theme={null}
{
  "event": "market_volume_spike",
  "timestamp": 1775913505260,
  "data": {
    "condition_id": "0x4fec624c0ff2bfae89956cebd6fbc9c58f995f824382dc587dc5a32a4b15940b",
    "question": "Will candidate X win the 2028 election?",
    "market_slug": "will-candidate-x-win",
    "event_slug": "us-presidential-election-2028",
    "image_url": "https://polymarket-upload.s3.us-east-2.amazonaws.com/will-candidate-x-win.png",
    "timeframe": "5m",
    "current_volume_usd": 24500.00,
    "snapshot_volume_usd": 11200.00,
    "delta_volume_usd": 13300.00,
    "spike_pct": 118.75,
    "txns": 63,
    "fees": 245.00
  }
}
```
