@structbuild/sdk 0.1.18 → 0.1.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -117,7 +117,7 @@ export interface paths {
117
117
  };
118
118
  }
119
119
  export interface webhooks {
120
- "first-trade": {
120
+ "trader-first-trade": {
121
121
  parameters: {
122
122
  query?: never;
123
123
  header?: never;
@@ -130,14 +130,14 @@ export interface webhooks {
130
130
  * First trade callback
131
131
  * @description Fired when a tracked trader executes their first trade on a market
132
132
  */
133
- post: operations["first-trade"];
133
+ post: operations["trader-first-trade"];
134
134
  delete?: never;
135
135
  options?: never;
136
136
  head?: never;
137
137
  patch?: never;
138
138
  trace?: never;
139
139
  };
140
- "new-market": {
140
+ "trader-new-market": {
141
141
  parameters: {
142
142
  query?: never;
143
143
  header?: never;
@@ -150,14 +150,14 @@ export interface webhooks {
150
150
  * New market entry callback
151
151
  * @description Fired when a trader places their first trade in a specific market/condition (fires once per trader+market pair)
152
152
  */
153
- post: operations["new-market"];
153
+ post: operations["trader-new-market"];
154
154
  delete?: never;
155
155
  options?: never;
156
156
  head?: never;
157
157
  patch?: never;
158
158
  trace?: never;
159
159
  };
160
- "whale-trade": {
160
+ "trader-whale-trade": {
161
161
  parameters: {
162
162
  query?: never;
163
163
  header?: never;
@@ -168,16 +168,16 @@ export interface webhooks {
168
168
  put?: never;
169
169
  /**
170
170
  * Whale trade callback
171
- * @description Fired when a trade exceeds the configured USD threshold within the configured probability range (e.g. >$10k between 5–95% probability). Requires `min_usd_value` in the subscription filter.
171
+ * @description Fired when a trade meets the configured criteria. Use `min_usd_value` to filter by minimum trade size (optional, defaults to 0 — matches all trades), and `min_probability`/`max_probability` to restrict to a probability range.
172
172
  */
173
- post: operations["whale-trade"];
173
+ post: operations["trader-whale-trade"];
174
174
  delete?: never;
175
175
  options?: never;
176
176
  head?: never;
177
177
  patch?: never;
178
178
  trace?: never;
179
179
  };
180
- "global-pnl": {
180
+ "trader-global-pnl": {
181
181
  parameters: {
182
182
  query?: never;
183
183
  header?: never;
@@ -190,14 +190,14 @@ export interface webhooks {
190
190
  * Global PnL callback
191
191
  * @description Fired when a trader's global PnL crosses a configured threshold
192
192
  */
193
- post: operations["global-pnl"];
193
+ post: operations["trader-global-pnl"];
194
194
  delete?: never;
195
195
  options?: never;
196
196
  head?: never;
197
197
  patch?: never;
198
198
  trace?: never;
199
199
  };
200
- "market-pnl": {
200
+ "trader-market-pnl": {
201
201
  parameters: {
202
202
  query?: never;
203
203
  header?: never;
@@ -210,14 +210,14 @@ export interface webhooks {
210
210
  * Market PnL callback
211
211
  * @description Fired when a trader's market-level PnL crosses a configured threshold
212
212
  */
213
- post: operations["market-pnl"];
213
+ post: operations["trader-market-pnl"];
214
214
  delete?: never;
215
215
  options?: never;
216
216
  head?: never;
217
217
  patch?: never;
218
218
  trace?: never;
219
219
  };
220
- "event-pnl": {
220
+ "trader-event-pnl": {
221
221
  parameters: {
222
222
  query?: never;
223
223
  header?: never;
@@ -230,7 +230,7 @@ export interface webhooks {
230
230
  * Event PnL callback
231
231
  * @description Fired when a trader's event-level PnL crosses a configured threshold
232
232
  */
233
- post: operations["event-pnl"];
233
+ post: operations["trader-event-pnl"];
234
234
  delete?: never;
235
235
  options?: never;
236
236
  head?: never;
@@ -308,7 +308,7 @@ export interface webhooks {
308
308
  put?: never;
309
309
  /**
310
310
  * Market volume milestone callback
311
- * @description Fired when a market's trading volume reaches a milestone threshold
311
+ * @description Fired once per org when a market's trading volume crosses a milestone in the specified timeframe. **`timeframes` is required** (e.g. `["1h", "24h"]`) — valid values: `1m`, `5m`, `30m`, `1h`, `6h`, `24h`, `7d`, `30d`. Optional `milestone_amounts` restricts to specific USD thresholds (e.g. `[10000, 100000]`). Optional `condition_ids` restricts to specific markets. Each milestone fires at most once per minute per org.
312
312
  */
313
313
  post: operations["market-volume-milestone"];
314
314
  delete?: never;
@@ -328,7 +328,7 @@ export interface webhooks {
328
328
  put?: never;
329
329
  /**
330
330
  * Event volume milestone callback
331
- * @description Fired when an event's trading volume reaches a milestone threshold
331
+ * @description Fired once per org when an event's trading volume crosses a milestone in the specified timeframe. **`timeframes` is required** (e.g. `["1h", "24h"]`) — valid values: `1m`, `5m`, `30m`, `1h`, `6h`, `24h`, `7d`, `30d`. Optional `milestone_amounts` restricts to specific USD thresholds. Optional `event_slugs` restricts to specific events. Each milestone fires at most once per minute per org.
332
332
  */
333
333
  post: operations["event-volume-milestone"];
334
334
  delete?: never;
@@ -348,7 +348,7 @@ export interface webhooks {
348
348
  put?: never;
349
349
  /**
350
350
  * Position volume milestone callback
351
- * @description Fired when a position's trading volume reaches a milestone threshold
351
+ * @description Fired once per org when a position's trading volume crosses a milestone in the specified timeframe. **`timeframes` is required** (e.g. `["1h", "24h"]`) — valid values: `1m`, `5m`, `30m`, `1h`, `6h`, `24h`, `7d`, `30d`. Optional `milestone_amounts` restricts to specific USD thresholds. Optional `position_ids` or `condition_ids` restrict to specific positions/markets. Each milestone fires at most once per minute per org.
352
352
  */
353
353
  post: operations["position-volume-milestone"];
354
354
  delete?: never;
@@ -368,7 +368,7 @@ export interface webhooks {
368
368
  put?: never;
369
369
  /**
370
370
  * Probability spike callback
371
- * @description Fired when a position's probability changes by more than a configured percentage
371
+ * @description Fired when a position's probability changes by at least `min_probability_change_pct` percent (relative to open) within the specified timeframe. Valid timeframes: `1m`, `5m`, `30m`, `1h`, `6h`, `24h`, `7d`, `30d`. Optional filters: `position_ids`, `outcomes`, `timeframes`. `probability_change_pct` in the payload is relative (e.g. `83.3` for a move from 30%→55%) and can be negative for downward moves. A hard minimum of 5% relative change is applied before any subscription filter.
372
372
  */
373
373
  post: operations["probability-spike"];
374
374
  delete?: never;
@@ -377,7 +377,7 @@ export interface webhooks {
377
377
  patch?: never;
378
378
  trace?: never;
379
379
  };
380
- "volume-spike": {
380
+ "market-volume-spike": {
381
381
  parameters: {
382
382
  query?: never;
383
383
  header?: never;
@@ -387,10 +387,50 @@ export interface webhooks {
387
387
  get?: never;
388
388
  put?: never;
389
389
  /**
390
- * Volume spike callback
391
- * @description Fired when a market's volume in a timeframe exceeds the user-defined baseline by the configured ratio (e.g. 2x baseline). Requires `baseline_volume_usd` and `spike_ratio` in the subscription filter.
390
+ * Market volume spike callback
391
+ * @description Fired when a market's volume in a timeframe exceeds the user-defined baseline by the configured ratio (e.g. 2x baseline). Requires `baseline_volume_usd` and `spike_ratio` in the subscription filter. Optional `timeframes` restricts to specific windows — valid values: `1m`, `5m`, `30m`, `1h`, `6h`, `24h`, `7d`, `30d`. Optional `condition_ids` restricts to specific markets.
392
392
  */
393
- post: operations["volume-spike"];
393
+ post: operations["market-volume-spike"];
394
+ delete?: never;
395
+ options?: never;
396
+ head?: never;
397
+ patch?: never;
398
+ trace?: never;
399
+ };
400
+ "event-volume-spike": {
401
+ parameters: {
402
+ query?: never;
403
+ header?: never;
404
+ path?: never;
405
+ cookie?: never;
406
+ };
407
+ get?: never;
408
+ put?: never;
409
+ /**
410
+ * Event volume spike callback
411
+ * @description Fired when an event's aggregated volume in a timeframe exceeds the user-defined baseline by the configured ratio. Requires `baseline_volume_usd` and `spike_ratio` in the subscription filter. Optional `timeframes` and `event_slugs` filter by timeframe and event. 1-minute cooldown per org prevents repeated firing.
412
+ */
413
+ post: operations["event-volume-spike"];
414
+ delete?: never;
415
+ options?: never;
416
+ head?: never;
417
+ patch?: never;
418
+ trace?: never;
419
+ };
420
+ "position-volume-spike": {
421
+ parameters: {
422
+ query?: never;
423
+ header?: never;
424
+ path?: never;
425
+ cookie?: never;
426
+ };
427
+ get?: never;
428
+ put?: never;
429
+ /**
430
+ * Position volume spike callback
431
+ * @description Fired when a position's volume in a timeframe exceeds the user-defined baseline by the configured ratio. Requires `baseline_volume_usd` and `spike_ratio` in the subscription filter. Optional `position_ids`, `condition_ids`, `outcomes`, and `timeframes` for narrowing scope. 1-minute cooldown per org prevents repeated firing.
432
+ */
433
+ post: operations["position-volume-spike"];
394
434
  delete?: never;
395
435
  options?: never;
396
436
  head?: never;
@@ -408,7 +448,7 @@ export interface webhooks {
408
448
  put?: never;
409
449
  /**
410
450
  * Close to bond callback
411
- * @description Fired when a position's probability enters the bond zone (e.g. YES 95% or 5%). Requires `min_probability` and/or `max_probability` in the subscription filter.
451
+ * @description Fired when a trade occurs at a near-certain-outcome price. **At least one of `min_probability` or `max_probability` is required.** Use `min_probability` (e.g. `0.95`) to trigger when YES is near-certain; use `max_probability` (e.g. `0.05`) for NO near-certain. Optional filters: `position_outcome_indices` — restrict by outcome index (`0` = Yes/Up, `1` = No; position 0 usually represents Yes/Up in binary markets); `condition_ids` — restrict to specific markets; `position_ids` — restrict to specific outcome tokens; `outcomes` — restrict by outcome name (e.g. `"Yes"`, `"No"`); `event_slugs` — restrict to specific events. Deduplication: each org is notified at most once per 6 hours while a position remains in the bond zone.
412
452
  */
413
453
  post: operations["close-to-bond"];
414
454
  delete?: never;
@@ -428,7 +468,7 @@ export interface webhooks {
428
468
  put?: never;
429
469
  /**
430
470
  * Market created callback
431
- * @description Fired when a new prediction market is detected on-chain (ConditionPreparation event), enriched with Gamma API metadata. Filterable by `tags`, `condition_ids`, and `event_slugs`.
471
+ * @description Fired when a new prediction market is detected on-chain (ConditionPreparation event), enriched with Gamma API metadata. Filterable by `tags`, `condition_ids`, `event_slugs`, and `exclude_shorterm_market_timeframes`. By default (`filter_no_metadata: true`) markets without Gamma metadata (no title, category, or tags) are suppressed — set `filter_no_metadata: false` to receive bare on-chain markets as well.
432
472
  */
433
473
  post: operations["market-created"];
434
474
  delete?: never;
@@ -437,9 +477,93 @@ export interface webhooks {
437
477
  patch?: never;
438
478
  trace?: never;
439
479
  };
480
+ "asset-price-tick": {
481
+ parameters: {
482
+ query?: never;
483
+ header?: never;
484
+ path?: never;
485
+ cookie?: never;
486
+ };
487
+ get?: never;
488
+ put?: never;
489
+ /**
490
+ * Asset price tick callback
491
+ * @description Fired on every raw Chainlink price tick received from the WebSocket feed for crypto assets (BTC, ETH, SOL, XRP). Use `asset_symbols` to restrict to specific assets (empty = all). Use `min_usd_value` as a minimum price filter.
492
+ */
493
+ post: operations["asset-price-tick"];
494
+ delete?: never;
495
+ options?: never;
496
+ head?: never;
497
+ patch?: never;
498
+ trace?: never;
499
+ };
500
+ "asset-price-window-update": {
501
+ parameters: {
502
+ query?: never;
503
+ header?: never;
504
+ path?: never;
505
+ cookie?: never;
506
+ };
507
+ get?: never;
508
+ put?: never;
509
+ /**
510
+ * Asset price window update callback
511
+ * @description Fired twice per candle: once when the window opens (`update_type: "open"`) and once when it closes with a confirmed close price (`update_type: "close"`). Use `asset_symbols` to restrict to specific assets (BTC, ETH, SOL, XRP). Use `timeframes` to restrict to specific candle sizes — valid values: `"5m"`, `"15m"`, `"1h"`, `"24h"`.
512
+ */
513
+ post: operations["asset-price-window-update"];
514
+ delete?: never;
515
+ options?: never;
516
+ head?: never;
517
+ patch?: never;
518
+ trace?: never;
519
+ };
440
520
  }
441
521
  export interface components {
442
522
  schemas: {
523
+ /** @description Webhook payload for an asset price tick. */
524
+ AssetPriceTickPayload: {
525
+ /** @description Asset symbol: "BTC", "ETH", "SOL", or "XRP" */
526
+ symbol: string;
527
+ /**
528
+ * Format: double
529
+ * @description Current price from the Chainlink feed
530
+ */
531
+ price: number;
532
+ /**
533
+ * Format: int64
534
+ * @description Tick timestamp as reported by the WebSocket feed (milliseconds since epoch)
535
+ */
536
+ timestamp_ms: number;
537
+ };
538
+ /** @description Webhook payload for an asset price window open or close. */
539
+ AssetPriceWindowUpdatePayload: {
540
+ /** @description Asset symbol: "BTC", "ETH", "SOL", or "XRP" */
541
+ symbol: string;
542
+ /** @description Time-window variant: "5m", "15m", "1h", or "24h" */
543
+ variant: string;
544
+ /**
545
+ * Format: int64
546
+ * @description Window start timestamp (milliseconds since epoch)
547
+ */
548
+ start_time: number;
549
+ /**
550
+ * Format: int64
551
+ * @description Window end timestamp (milliseconds since epoch)
552
+ */
553
+ end_time: number;
554
+ /**
555
+ * Format: double
556
+ * @description Opening price at start_time
557
+ */
558
+ open_price: number;
559
+ /**
560
+ * Format: double
561
+ * @description Closing price at end_time (0.0 on an "open" update — not yet available)
562
+ */
563
+ close_price: number;
564
+ /** @description "open" when the window starts, "close" when the window is complete */
565
+ update_type: string;
566
+ };
443
567
  /** @description Close-to-bond webhook payload */
444
568
  CloseToBondPayload: {
445
569
  /** @description Trader address (the limit-order maker) */
@@ -454,7 +578,7 @@ export interface components {
454
578
  outcome?: string | null;
455
579
  /**
456
580
  * Format: int32
457
- * @description Outcome index (0 = Yes, 1 = No)
581
+ * @description Outcome index (0 = Yes/Up, 1 = No). Position 0 usually represents Yes/Up.
458
582
  */
459
583
  outcome_index?: number | null;
460
584
  /** @description Market question */
@@ -620,6 +744,41 @@ export interface components {
620
744
  */
621
745
  txns: number;
622
746
  };
747
+ /** @description Event volume spike webhook payload */
748
+ EventVolumeSpikePayload: {
749
+ event_slug: string;
750
+ timeframe: string;
751
+ /**
752
+ * Format: double
753
+ * @description Current aggregated event volume that triggered the spike (USD)
754
+ */
755
+ current_volume_usd: number;
756
+ /**
757
+ * Format: double
758
+ * @description User's baseline volume for comparison (USD)
759
+ */
760
+ baseline_volume_usd: number;
761
+ /**
762
+ * Format: double
763
+ * @description Spike ratio threshold that was triggered
764
+ */
765
+ spike_ratio: number;
766
+ /**
767
+ * Format: double
768
+ * @description Calculated threshold that was crossed (baseline * ratio)
769
+ */
770
+ threshold_usd: number;
771
+ /**
772
+ * Format: int64
773
+ * @description Total transactions in this timeframe
774
+ */
775
+ txns: number;
776
+ /**
777
+ * Format: double
778
+ * @description Total fees in this timeframe
779
+ */
780
+ fees: number;
781
+ };
623
782
  /** @description First trade webhook payload with zero-copy Arc<str> for string sharing */
624
783
  FirstTradePayload: {
625
784
  /** @description Trader/taker address (zero-copy Arc) */
@@ -820,6 +979,41 @@ export interface components {
820
979
  /** Format: int64 */
821
980
  last_trade_at?: number | null;
822
981
  };
982
+ /** @description Volume spike webhook payload */
983
+ MarketVolumeSpikePayload: {
984
+ condition_id: string;
985
+ timeframe: string;
986
+ /**
987
+ * Format: double
988
+ * @description Current volume that triggered the spike (USD)
989
+ */
990
+ current_volume_usd: number;
991
+ /**
992
+ * Format: double
993
+ * @description User's baseline volume for comparison (USD)
994
+ */
995
+ baseline_volume_usd: number;
996
+ /**
997
+ * Format: double
998
+ * @description Spike ratio threshold that was triggered
999
+ */
1000
+ spike_ratio: number;
1001
+ /**
1002
+ * Format: double
1003
+ * @description Calculated threshold that was crossed (baseline * ratio)
1004
+ */
1005
+ threshold_usd: number;
1006
+ /**
1007
+ * Format: int64
1008
+ * @description Total transactions in this timeframe
1009
+ */
1010
+ txns: number;
1011
+ /**
1012
+ * Format: double
1013
+ * @description Total fees in this timeframe
1014
+ */
1015
+ fees: number;
1016
+ };
823
1017
  /**
824
1018
  * @description New market entry webhook payload
825
1019
  *
@@ -901,7 +1095,7 @@ export interface components {
901
1095
  * @description Polymarket webhook event types
902
1096
  * @enum {string}
903
1097
  */
904
- PolymarketWebhookEvent: "first_trade" | "new_market" | "whale_trade" | "global_pnl" | "market_pnl" | "event_pnl" | "condition_metrics" | "event_metrics" | "position_metrics" | "volume_milestone" | "event_volume_milestone" | "position_volume_milestone" | "probability_spike" | "volume_spike" | "close_to_bond" | "market_created";
1098
+ PolymarketWebhookEvent: "trader_first_trade" | "trader_new_market" | "trader_whale_trade" | "trader_global_pnl" | "trader_market_pnl" | "trader_event_pnl" | "condition_metrics" | "event_metrics" | "position_metrics" | "market_volume_milestone" | "event_volume_milestone" | "position_volume_milestone" | "probability_spike" | "market_volume_spike" | "event_volume_spike" | "position_volume_spike" | "close_to_bond" | "market_created" | "asset_price_tick" | "asset_price_window_update";
905
1099
  /**
906
1100
  * @description Polymarket-specific webhook filters
907
1101
  *
@@ -916,7 +1110,7 @@ export interface components {
916
1110
  * - event_metrics: event_slugs, min_volume_usd, max_volume_usd, min_fees, min_txns, timeframes
917
1111
  * - position_metrics: position_ids, condition_ids, outcomes, min_volume_usd, max_volume_usd, min_buy_usd, min_sell_volume_usd, min_fees, min_txns, min_price_change_pct, min_probability_change_pct, timeframes
918
1112
  * - volume_milestone: condition_ids, timeframes, milestone_amounts
919
- * - close_to_bond: min_probability (high zone threshold), max_probability (low zone threshold), condition_ids, position_ids, outcomes, timeframes
1113
+ * - close_to_bond: min_probability (high zone threshold), max_probability (low zone threshold), condition_ids, position_ids, outcomes, position_outcome_indices, event_slugs
920
1114
  *
921
1115
  * Implements Hash + Eq manually (f64 fields use bit representation)
922
1116
  */
@@ -995,6 +1189,11 @@ export interface components {
995
1189
  position_ids?: string[];
996
1190
  /** @description Filter by outcomes (e.g., "Yes", "No") - for position PnL webhooks */
997
1191
  outcomes?: string[];
1192
+ /**
1193
+ * @description Filter by position outcome index — for close_to_bond. Position 0 usually represents Yes/Up, 1 = No.
1194
+ * When non-empty, only trades whose outcome_index is in this list will match.
1195
+ */
1196
+ position_outcome_indices?: number[];
998
1197
  /**
999
1198
  * Format: double
1000
1199
  * @description Minimum fees - for metrics webhooks
@@ -1047,6 +1246,17 @@ export interface components {
1047
1246
  * Example: Excludes "btc-updown-5m-1771678800" when "5m" is in the list
1048
1247
  */
1049
1248
  exclude_shorterm_market_timeframes?: string[];
1249
+ /**
1250
+ * @description Filter by crypto asset symbol — for `asset_price_tick` and `asset_price_window_update` webhooks.
1251
+ * Valid values: "BTC", "ETH", "SOL", "XRP". Empty = all assets.
1252
+ */
1253
+ asset_symbols?: string[];
1254
+ /**
1255
+ * @description When `true` (default), skip markets that have no Gamma metadata (title, category, tags).
1256
+ * Bare on-chain markets detected before Gamma enrichment arrives will be suppressed.
1257
+ * Set to `false` to receive all `market_created` events regardless of metadata availability.
1258
+ */
1259
+ filter_no_metadata?: boolean;
1050
1260
  };
1051
1261
  /** @description Position metrics webhook payload (Arc-optimized, no internal metadata) */
1052
1262
  PositionMetricsPayload: {
@@ -1137,6 +1347,45 @@ export interface components {
1137
1347
  */
1138
1348
  sells: number;
1139
1349
  };
1350
+ /** @description Position volume spike webhook payload */
1351
+ PositionVolumeSpikePayload: {
1352
+ position_id: string;
1353
+ condition_id: string;
1354
+ outcome?: string | null;
1355
+ /** Format: int32 */
1356
+ outcome_index?: number | null;
1357
+ timeframe: string;
1358
+ /**
1359
+ * Format: double
1360
+ * @description Current position volume that triggered the spike (USD)
1361
+ */
1362
+ current_volume_usd: number;
1363
+ /**
1364
+ * Format: double
1365
+ * @description User's baseline volume for comparison (USD)
1366
+ */
1367
+ baseline_volume_usd: number;
1368
+ /**
1369
+ * Format: double
1370
+ * @description Spike ratio threshold that was triggered
1371
+ */
1372
+ spike_ratio: number;
1373
+ /**
1374
+ * Format: double
1375
+ * @description Calculated threshold that was crossed (baseline * ratio)
1376
+ */
1377
+ threshold_usd: number;
1378
+ /**
1379
+ * Format: int64
1380
+ * @description Total transactions in this timeframe
1381
+ */
1382
+ txns: number;
1383
+ /**
1384
+ * Format: double
1385
+ * @description Total fees in this timeframe
1386
+ */
1387
+ fees: number;
1388
+ };
1140
1389
  /** @description Position probability spike webhook payload */
1141
1390
  ProbabilitySpikePayload: {
1142
1391
  position_id: string;
@@ -1232,41 +1481,6 @@ export interface components {
1232
1481
  */
1233
1482
  txns: number;
1234
1483
  };
1235
- /** @description Volume spike webhook payload */
1236
- VolumeSpikePayload: {
1237
- condition_id: string;
1238
- timeframe: string;
1239
- /**
1240
- * Format: double
1241
- * @description Current volume that triggered the spike (USD)
1242
- */
1243
- current_volume_usd: number;
1244
- /**
1245
- * Format: double
1246
- * @description User's baseline volume for comparison (USD)
1247
- */
1248
- baseline_volume_usd: number;
1249
- /**
1250
- * Format: double
1251
- * @description Spike ratio threshold that was triggered
1252
- */
1253
- spike_ratio: number;
1254
- /**
1255
- * Format: double
1256
- * @description Calculated threshold that was crossed (baseline * ratio)
1257
- */
1258
- threshold_usd: number;
1259
- /**
1260
- * Format: int64
1261
- * @description Total transactions in this timeframe
1262
- */
1263
- txns: number;
1264
- /**
1265
- * Format: double
1266
- * @description Total fees in this timeframe
1267
- */
1268
- fees: number;
1269
- };
1270
1484
  /** @description Single event type entry for the events list */
1271
1485
  WebhookEventInfo: {
1272
1486
  /** @description Event type identifier (e.g. "first_trade") */
@@ -1297,6 +1511,8 @@ export interface components {
1297
1511
  event_slugs?: string[];
1298
1512
  /** @description Filter by outcomes (e.g. "Yes", "No") — for position metrics / close_to_bond */
1299
1513
  outcomes?: string[];
1514
+ /** @description Filter by position outcome index — for close_to_bond. Position 0 = Yes/Up, 1 = No. */
1515
+ position_outcome_indices?: number[];
1300
1516
  /**
1301
1517
  * Format: double
1302
1518
  * @description Minimum USD trade size (for whale_trade / first_trade)
@@ -1377,7 +1593,11 @@ export interface components {
1377
1593
  * @description Minimum probability change percentage — for probability_spike
1378
1594
  */
1379
1595
  min_probability_change_pct?: number | null;
1380
- /** @description Timeframes to track (e.g. ["1m", "5m", "1h", "24h", "7d", "30d"]) — for metrics webhooks */
1596
+ /**
1597
+ * @description Timeframes to filter by (e.g. ["1h", "24h", "7d"]) — **required** for volume_milestone
1598
+ * webhooks (market/event/position), optional for metrics webhooks.
1599
+ * Valid values: "1m", "5m", "30m", "1h", "6h", "24h", "7d", "30d".
1600
+ */
1381
1601
  timeframes?: string[];
1382
1602
  /** @description Milestone amounts to trigger on (USD) — for volume_milestone webhooks */
1383
1603
  milestone_amounts?: number[];
@@ -1393,6 +1613,11 @@ export interface components {
1393
1613
  spike_ratio?: number | null;
1394
1614
  /** @description Exclude short-term trading markets by timeframe pattern (e.g. ["5m", "15m"]) */
1395
1615
  exclude_shorterm_market_timeframes?: string[];
1616
+ /**
1617
+ * @description Filter by crypto asset symbol — for `asset_price_tick` and `asset_price_window_update`.
1618
+ * Valid values: "BTC", "ETH", "SOL", "XRP". Empty = all assets (send everything).
1619
+ */
1620
+ asset_symbols?: string[];
1396
1621
  };
1397
1622
  /** @description List webhooks response */
1398
1623
  WebhookListResponseBody: {
@@ -1427,6 +1652,11 @@ export interface components {
1427
1652
  description?: string | null;
1428
1653
  /** @description Whether an HMAC secret is configured */
1429
1654
  has_secret: boolean;
1655
+ /**
1656
+ * Format: int64
1657
+ * @description Credits consumed by this webhook in the last 24 hours
1658
+ */
1659
+ credits_used_24h?: number;
1430
1660
  };
1431
1661
  /**
1432
1662
  * @description Webhook status
@@ -1837,7 +2067,7 @@ export interface operations {
1837
2067
  };
1838
2068
  };
1839
2069
  };
1840
- "first-trade": {
2070
+ "trader-first-trade": {
1841
2071
  parameters: {
1842
2072
  query?: never;
1843
2073
  header?: never;
@@ -1866,7 +2096,7 @@ export interface operations {
1866
2096
  };
1867
2097
  };
1868
2098
  };
1869
- "new-market": {
2099
+ "trader-new-market": {
1870
2100
  parameters: {
1871
2101
  query?: never;
1872
2102
  header?: never;
@@ -1895,7 +2125,7 @@ export interface operations {
1895
2125
  };
1896
2126
  };
1897
2127
  };
1898
- "whale-trade": {
2128
+ "trader-whale-trade": {
1899
2129
  parameters: {
1900
2130
  query?: never;
1901
2131
  header?: never;
@@ -1924,7 +2154,7 @@ export interface operations {
1924
2154
  };
1925
2155
  };
1926
2156
  };
1927
- "global-pnl": {
2157
+ "trader-global-pnl": {
1928
2158
  parameters: {
1929
2159
  query?: never;
1930
2160
  header?: never;
@@ -1953,7 +2183,7 @@ export interface operations {
1953
2183
  };
1954
2184
  };
1955
2185
  };
1956
- "market-pnl": {
2186
+ "trader-market-pnl": {
1957
2187
  parameters: {
1958
2188
  query?: never;
1959
2189
  header?: never;
@@ -1982,7 +2212,7 @@ export interface operations {
1982
2212
  };
1983
2213
  };
1984
2214
  };
1985
- "event-pnl": {
2215
+ "trader-event-pnl": {
1986
2216
  parameters: {
1987
2217
  query?: never;
1988
2218
  header?: never;
@@ -2214,7 +2444,7 @@ export interface operations {
2214
2444
  };
2215
2445
  };
2216
2446
  };
2217
- "volume-spike": {
2447
+ "market-volume-spike": {
2218
2448
  parameters: {
2219
2449
  query?: never;
2220
2450
  header?: never;
@@ -2223,7 +2453,65 @@ export interface operations {
2223
2453
  };
2224
2454
  requestBody: {
2225
2455
  content: {
2226
- "application/json": components["schemas"]["VolumeSpikePayload"];
2456
+ "application/json": components["schemas"]["MarketVolumeSpikePayload"];
2457
+ };
2458
+ };
2459
+ responses: {
2460
+ /** @description Webhook delivery acknowledged */
2461
+ 200: {
2462
+ headers: {
2463
+ [name: string]: unknown;
2464
+ };
2465
+ content?: never;
2466
+ };
2467
+ /** @description Server error (will retry) */
2468
+ 500: {
2469
+ headers: {
2470
+ [name: string]: unknown;
2471
+ };
2472
+ content?: never;
2473
+ };
2474
+ };
2475
+ };
2476
+ "event-volume-spike": {
2477
+ parameters: {
2478
+ query?: never;
2479
+ header?: never;
2480
+ path?: never;
2481
+ cookie?: never;
2482
+ };
2483
+ requestBody: {
2484
+ content: {
2485
+ "application/json": components["schemas"]["EventVolumeSpikePayload"];
2486
+ };
2487
+ };
2488
+ responses: {
2489
+ /** @description Webhook delivery acknowledged */
2490
+ 200: {
2491
+ headers: {
2492
+ [name: string]: unknown;
2493
+ };
2494
+ content?: never;
2495
+ };
2496
+ /** @description Server error (will retry) */
2497
+ 500: {
2498
+ headers: {
2499
+ [name: string]: unknown;
2500
+ };
2501
+ content?: never;
2502
+ };
2503
+ };
2504
+ };
2505
+ "position-volume-spike": {
2506
+ parameters: {
2507
+ query?: never;
2508
+ header?: never;
2509
+ path?: never;
2510
+ cookie?: never;
2511
+ };
2512
+ requestBody: {
2513
+ content: {
2514
+ "application/json": components["schemas"]["PositionVolumeSpikePayload"];
2227
2515
  };
2228
2516
  };
2229
2517
  responses: {
@@ -2301,4 +2589,62 @@ export interface operations {
2301
2589
  };
2302
2590
  };
2303
2591
  };
2592
+ "asset-price-tick": {
2593
+ parameters: {
2594
+ query?: never;
2595
+ header?: never;
2596
+ path?: never;
2597
+ cookie?: never;
2598
+ };
2599
+ requestBody: {
2600
+ content: {
2601
+ "application/json": components["schemas"]["AssetPriceTickPayload"];
2602
+ };
2603
+ };
2604
+ responses: {
2605
+ /** @description Webhook delivery acknowledged */
2606
+ 200: {
2607
+ headers: {
2608
+ [name: string]: unknown;
2609
+ };
2610
+ content?: never;
2611
+ };
2612
+ /** @description Server error (will retry) */
2613
+ 500: {
2614
+ headers: {
2615
+ [name: string]: unknown;
2616
+ };
2617
+ content?: never;
2618
+ };
2619
+ };
2620
+ };
2621
+ "asset-price-window-update": {
2622
+ parameters: {
2623
+ query?: never;
2624
+ header?: never;
2625
+ path?: never;
2626
+ cookie?: never;
2627
+ };
2628
+ requestBody: {
2629
+ content: {
2630
+ "application/json": components["schemas"]["AssetPriceWindowUpdatePayload"];
2631
+ };
2632
+ };
2633
+ responses: {
2634
+ /** @description Webhook delivery acknowledged */
2635
+ 200: {
2636
+ headers: {
2637
+ [name: string]: unknown;
2638
+ };
2639
+ content?: never;
2640
+ };
2641
+ /** @description Server error (will retry) */
2642
+ 500: {
2643
+ headers: {
2644
+ [name: string]: unknown;
2645
+ };
2646
+ content?: never;
2647
+ };
2648
+ };
2649
+ };
2304
2650
  }