@structbuild/sdk 0.6.1 → 0.6.3

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.
@@ -88,6 +88,11 @@ export interface components {
88
88
  };
89
89
  /** @description Subscription filters for the `asset_price_tick` event. All fields are optional. */
90
90
  AssetPriceTickFilters: {
91
+ /**
92
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
93
+ * successful delivery. Applies to any webhook event.
94
+ */
95
+ one_shot?: boolean | null;
91
96
  /** @description Restrict to these crypto assets. Empty = all assets. */
92
97
  asset_symbols?: components["schemas"]["WebhookAssetSymbol"][] | null;
93
98
  };
@@ -108,6 +113,11 @@ export interface components {
108
113
  };
109
114
  /** @description Subscription filters for the `asset_price_window_update` event. All fields are optional. */
110
115
  AssetPriceWindowUpdateFilters: {
116
+ /**
117
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
118
+ * successful delivery. Applies to any webhook event.
119
+ */
120
+ one_shot?: boolean | null;
111
121
  /** @description Restrict to these crypto assets. Empty = all assets. */
112
122
  asset_symbols?: components["schemas"]["WebhookAssetSymbol"][] | null;
113
123
  /** @description Restrict to these candle sizes. Empty = all sizes. */
@@ -159,73 +169,170 @@ export interface components {
159
169
  AssetWindowFilterTimeframe: "5m" | "15m" | "1h" | "4h" | "1d" | "24h";
160
170
  /** @description Category PnL webhook payload. */
161
171
  CategoryPnlPayload: {
172
+ /** @description Trader wallet address. */
162
173
  trader?: string | null;
174
+ /** @description Category. */
163
175
  category?: string | null;
164
176
  /** @description Aggregation timeframe: "1d", "7d", "30d", or "lifetime" */
165
177
  timeframe: string;
166
- /** Format: double */
178
+ /**
179
+ * Format: double
180
+ * @description Realized pnl in USD.
181
+ */
167
182
  realized_pnl_usd?: number | null;
168
- /** Format: int64 */
183
+ /**
184
+ * Format: int64
185
+ * @description Markets in this category.
186
+ */
169
187
  markets_in_category?: number | null;
170
- /** Format: int64 */
188
+ /**
189
+ * Format: int64
190
+ * @description Markets traded.
191
+ */
171
192
  markets_traded?: number | null;
172
- /** Format: int64 */
193
+ /**
194
+ * Format: int64
195
+ * @description Number of outcomes traded.
196
+ */
173
197
  outcomes_traded?: number | null;
174
- /** Format: int64 */
198
+ /**
199
+ * Format: int64
200
+ * @description Total buy count.
201
+ */
175
202
  total_buys?: number | null;
176
- /** Format: int64 */
203
+ /**
204
+ * Format: int64
205
+ * @description Total sell count.
206
+ */
177
207
  total_sells?: number | null;
178
- /** Format: int64 */
208
+ /**
209
+ * Format: int64
210
+ * @description Total redemption count.
211
+ */
179
212
  total_redemptions?: number | null;
180
- /** Format: int64 */
213
+ /**
214
+ * Format: int64
215
+ * @description Total merge count.
216
+ */
181
217
  total_merges?: number | null;
182
- /** Format: int64 */
218
+ /**
219
+ * Format: int64
220
+ * @description Total split count.
221
+ */
183
222
  total_splits?: number | null;
184
- /** Format: double */
223
+ /**
224
+ * Format: double
225
+ * @description Total volume in USD.
226
+ */
185
227
  total_volume_usd?: number | null;
186
- /** Format: double */
228
+ /**
229
+ * Format: double
230
+ * @description Buy in USD.
231
+ */
187
232
  buy_usd?: number | null;
188
- /** Format: double */
233
+ /**
234
+ * Format: double
235
+ * @description Sell in USD.
236
+ */
189
237
  sell_usd?: number | null;
190
- /** Format: double */
238
+ /**
239
+ * Format: double
240
+ * @description Redemption in USD.
241
+ */
191
242
  redemption_usd?: number | null;
192
- /** Format: double */
243
+ /**
244
+ * Format: double
245
+ * @description Merge in USD.
246
+ */
193
247
  merge_usd?: number | null;
194
- /** Format: double */
248
+ /**
249
+ * Format: double
250
+ * @description Convert collateral in USD.
251
+ */
195
252
  convert_collateral_usd?: number | null;
196
- /** Format: double */
253
+ /**
254
+ * Format: double
255
+ * @description Split volume in USD.
256
+ */
197
257
  split_volume_usd?: number | null;
198
- /** Format: double */
258
+ /**
259
+ * Format: double
260
+ * @description Total fees amount.
261
+ */
199
262
  total_fees?: number | null;
200
- /** Format: double */
263
+ /**
264
+ * Format: double
265
+ * @description Total shares bought.
266
+ */
201
267
  total_shares_bought?: number | null;
202
- /** Format: int64 */
268
+ /**
269
+ * Format: int64
270
+ * @description Markets won.
271
+ */
203
272
  markets_won?: number | null;
204
- /** Format: int64 */
273
+ /**
274
+ * Format: int64
275
+ * @description Markets lost.
276
+ */
205
277
  markets_lost?: number | null;
206
- /** Format: double */
278
+ /**
279
+ * Format: double
280
+ * @description Market win rate percent.
281
+ */
207
282
  market_win_rate_pct?: number | null;
208
- /** Format: double */
283
+ /**
284
+ * Format: double
285
+ * @description Average hold time seconds.
286
+ */
209
287
  avg_hold_time_seconds?: number | null;
210
- /** Format: double */
288
+ /**
289
+ * Format: double
290
+ * @description Best trade pnl in USD.
291
+ */
211
292
  best_trade_pnl_usd?: number | null;
293
+ /** @description Best trade condition id. */
212
294
  best_trade_condition_id?: string | null;
213
- /** Format: double */
295
+ /**
296
+ * Format: double
297
+ * @description Worst trade pnl in USD.
298
+ */
214
299
  worst_trade_pnl_usd?: number | null;
300
+ /** @description Worst trade condition id. */
215
301
  worst_trade_condition_id?: string | null;
216
- /** Format: double */
302
+ /**
303
+ * Format: double
304
+ * @description Total wins in USD.
305
+ */
217
306
  total_wins_usd?: number | null;
218
- /** Format: double */
307
+ /**
308
+ * Format: double
309
+ * @description Total losses in USD.
310
+ */
219
311
  total_losses_usd?: number | null;
220
- /** Format: double */
312
+ /**
313
+ * Format: double
314
+ * @description Average win in USD.
315
+ */
221
316
  avg_win_usd?: number | null;
222
- /** Format: double */
317
+ /**
318
+ * Format: double
319
+ * @description Average loss in USD.
320
+ */
223
321
  avg_loss_usd?: number | null;
224
- /** Format: double */
322
+ /**
323
+ * Format: double
324
+ * @description Profit factor.
325
+ */
225
326
  profit_factor?: number | null;
226
- /** Format: int64 */
327
+ /**
328
+ * Format: int64
329
+ * @description First trade timestamp.
330
+ */
227
331
  first_trade_at?: number | null;
228
- /** Format: int64 */
332
+ /**
333
+ * Format: int64
334
+ * @description Last trade timestamp.
335
+ */
229
336
  last_trade_at?: number | null;
230
337
  };
231
338
  /**
@@ -233,6 +340,15 @@ export interface components {
233
340
  * `min_probability` or `max_probability` is required (enforced at runtime).
234
341
  */
235
342
  CloseToBondFilters: {
343
+ /**
344
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
345
+ * successful delivery. Applies to any webhook event.
346
+ */
347
+ one_shot?: boolean | null;
348
+ /** @description Restrict to markets carrying any of these tags or category names (case-insensitive). Empty = all. */
349
+ tags?: string[] | null;
350
+ /** @description Restrict to markets in any of these series (by slug, case-insensitive). Empty = all. */
351
+ series_slugs?: string[] | null;
236
352
  /**
237
353
  * Format: double
238
354
  * @description Trigger when the YES outcome price is ≥ this value (e.g. 0.95 for 95% certainty). At least one of `min_probability` or `max_probability` must be set.
@@ -329,15 +445,31 @@ export interface components {
329
445
  threshold: number;
330
446
  };
331
447
  ConditionHolderMetricsFilters: {
448
+ /** @description Market condition IDs to match. */
332
449
  condition_ids?: string[];
450
+ /**
451
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
452
+ * successful delivery. Applies to any webhook event.
453
+ */
454
+ one_shot?: boolean | null;
333
455
  };
334
456
  ConditionHolderMetricsPayload: {
335
- /** Format: int32 */
457
+ /**
458
+ * Format: int32
459
+ * @description Unix timestamp in seconds.
460
+ */
336
461
  ts: number;
337
- /** Format: int64 */
462
+ /**
463
+ * Format: int64
464
+ * @description Block number.
465
+ */
338
466
  block: number;
467
+ /** @description Market condition ID. */
339
468
  condition_id: string;
340
- /** Format: int32 */
469
+ /**
470
+ * Format: int32
471
+ * @description Number of holders.
472
+ */
341
473
  holder_count: number;
342
474
  };
343
475
  /** @description Payload delivered when a market's volume or transaction metrics cross a configured threshold */
@@ -444,6 +576,7 @@ export interface components {
444
576
  };
445
577
  /** @description Delete webhook response */
446
578
  DeleteWebhookResponse: {
579
+ /** @description Whether the webhook was deleted. */
447
580
  deleted: boolean;
448
581
  };
449
582
  /**
@@ -496,19 +629,91 @@ export interface components {
496
629
  event_slug?: string | null;
497
630
  };
498
631
  EventHolderMetricsFilters: {
632
+ /** @description Event slugs to match. */
499
633
  event_slugs?: string[];
634
+ /**
635
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
636
+ * successful delivery. Applies to any webhook event.
637
+ */
638
+ one_shot?: boolean | null;
500
639
  };
501
640
  EventHolderMetricsPayload: {
502
- /** Format: int32 */
641
+ /**
642
+ * Format: int32
643
+ * @description Unix timestamp in seconds.
644
+ */
503
645
  ts: number;
504
- /** Format: int64 */
646
+ /**
647
+ * Format: int64
648
+ * @description Block number.
649
+ */
505
650
  block: number;
651
+ /** @description Event slug. */
506
652
  event_slug: string;
507
- /** Format: int32 */
653
+ /**
654
+ * Format: int32
655
+ * @description Number of holders.
656
+ */
508
657
  holder_count: number;
509
658
  };
659
+ /**
660
+ * @description Subscription filters for the `event_liquidity` event.
661
+ *
662
+ * At least one of `min_liquidity_usd`, `max_liquidity_usd`, or `one_shot` must be set.
663
+ * Thresholds are edge-triggered: a callback fires when liquidity crosses the threshold,
664
+ * then re-arms once it crosses back (unless `one_shot`).
665
+ */
666
+ EventLiquidityFilters: {
667
+ /**
668
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
669
+ * successful delivery.
670
+ */
671
+ one_shot?: boolean | null;
672
+ /**
673
+ * Format: double
674
+ * @description Fire when total liquidity crosses up through this USD value.
675
+ */
676
+ min_liquidity_usd?: number | null;
677
+ /**
678
+ * Format: double
679
+ * @description Fire when total liquidity crosses down through this USD value.
680
+ */
681
+ max_liquidity_usd?: number | null;
682
+ /** @description **Required.** Events to receive liquidity updates for. */
683
+ event_slugs: string[];
684
+ };
685
+ /** @description Event liquidity webhook payload. */
686
+ EventLiquidityPayload: {
687
+ /** @description Event slug. */
688
+ event_slug: string;
689
+ /**
690
+ * Format: double
691
+ * @description Total order-book liquidity in USD at the time of firing.
692
+ */
693
+ liquidity_usd: number;
694
+ /**
695
+ * Format: double
696
+ * @description The threshold (USD) that was crossed.
697
+ */
698
+ threshold_usd: number;
699
+ /**
700
+ * @description `"above"` when liquidity crossed up through `min_liquidity_usd`,
701
+ * `"below"` when it crossed down through `max_liquidity_usd`.
702
+ */
703
+ direction: string;
704
+ /**
705
+ * Format: int64
706
+ * @description Update timestamp (Unix millis).
707
+ */
708
+ liquidity_updated_at: number;
709
+ };
510
710
  /** @description Subscription filters for the `event_metrics` event. All fields are optional. */
511
711
  EventMetricsFilters: {
712
+ /**
713
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
714
+ * successful delivery. Applies to any webhook event.
715
+ */
716
+ one_shot?: boolean | null;
512
717
  /** @description Restrict to these events. Empty = all events. */
513
718
  event_slugs?: string[] | null;
514
719
  /** @description Restrict to these aggregation windows. */
@@ -518,13 +723,25 @@ export interface components {
518
723
  * @description Only fire when aggregated event volume ≥ this value (USD).
519
724
  */
520
725
  min_volume_usd?: number | null;
521
- /** Format: double */
726
+ /**
727
+ * Format: double
728
+ * @description Maximum volume USD.
729
+ */
522
730
  max_volume_usd?: number | null;
523
- /** Format: int64 */
731
+ /**
732
+ * Format: int64
733
+ * @description Minimum transactions.
734
+ */
524
735
  min_txns?: number | null;
525
- /** Format: int64 */
736
+ /**
737
+ * Format: int64
738
+ * @description Minimum unique traders.
739
+ */
526
740
  min_unique_traders?: number | null;
527
- /** Format: double */
741
+ /**
742
+ * Format: double
743
+ * @description Minimum fees.
744
+ */
528
745
  min_fees?: number | null;
529
746
  /** @description When `true`, suppress webhooks for short-term "updown" markets. Default: `false`. */
530
747
  exclude_shortterm_markets?: boolean | null;
@@ -598,6 +815,11 @@ export interface components {
598
815
  };
599
816
  /** @description Subscription filters for the `event_volume_milestone` event. */
600
817
  EventVolumeMilestoneFilters: {
818
+ /**
819
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
820
+ * successful delivery. Applies to any webhook event.
821
+ */
822
+ one_shot?: boolean | null;
601
823
  /** @description **Required.** Aggregation windows to monitor. */
602
824
  timeframes: components["schemas"]["MetricFilterTimeframe"][];
603
825
  /** @description Restrict to these events. */
@@ -609,7 +831,9 @@ export interface components {
609
831
  };
610
832
  /** @description Event volume milestone webhook payload */
611
833
  EventVolumeMilestonePayload: {
834
+ /** @description Event slug. */
612
835
  event_slug: string;
836
+ /** @description Metric timeframe. */
613
837
  timeframe: string;
614
838
  /**
615
839
  * Format: double
@@ -634,6 +858,11 @@ export interface components {
634
858
  };
635
859
  /** @description Subscription filters for the `event_volume_spike` event. `spike_ratio` is required. */
636
860
  EventVolumeSpikeFilters: {
861
+ /**
862
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
863
+ * successful delivery. Applies to any webhook event.
864
+ */
865
+ one_shot?: boolean | null;
637
866
  /**
638
867
  * Format: double
639
868
  * @description **Required.** Multiplier threshold (must be > 1.0). Fires when current volume >= snapshot × ratio.
@@ -653,9 +882,13 @@ export interface components {
653
882
  };
654
883
  /** @description Event volume spike webhook payload */
655
884
  EventVolumeSpikePayload: {
885
+ /** @description Event slug. */
656
886
  event_slug: string;
887
+ /** @description Event title. */
657
888
  event_title?: string | null;
889
+ /** @description Image URL. */
658
890
  image_url?: string | null;
891
+ /** @description Metric timeframe. */
659
892
  timeframe: string;
660
893
  /**
661
894
  * Format: double
@@ -690,26 +923,50 @@ export interface components {
690
923
  };
691
924
  /** @description Exit Markers webhook payload — one position open->closed transition. */
692
925
  ExitMarkersPayload: {
926
+ /** @description Trader wallet address. */
693
927
  trader: string;
928
+ /** @description Outcome token ID. */
694
929
  position_id: string;
930
+ /** @description Market condition ID. */
695
931
  condition_id: string;
932
+ /** @description Event slug. */
696
933
  event_slug: string;
934
+ /** @description Market slug. */
697
935
  market_slug: string;
936
+ /** @description Title. */
698
937
  title: string;
938
+ /** @description Market question. */
699
939
  question: string;
940
+ /** @description Image URL. */
700
941
  image_url: string;
942
+ /** @description Outcome name. */
701
943
  outcome: string;
702
- /** Format: int32 */
944
+ /**
945
+ * Format: int32
946
+ * @description Outcome index.
947
+ */
703
948
  outcome_index?: number | null;
704
- /** Format: double */
949
+ /**
950
+ * Format: double
951
+ * @description Pnl in USD.
952
+ */
705
953
  pnl_usd: number;
706
- /** Format: double */
954
+ /**
955
+ * Format: double
956
+ * @description Pnl percent.
957
+ */
707
958
  pnl_pct: number;
708
- /** Format: double */
959
+ /**
960
+ * Format: double
961
+ * @description Cost basis in USD.
962
+ */
709
963
  cost_basis_usd: number;
710
964
  /** @description resolved_win | resolved_loss | sold_win | sold_loss */
711
965
  reason: string;
712
- /** Format: int64 */
966
+ /**
967
+ * Format: int64
968
+ * @description Block number.
969
+ */
713
970
  block: number;
714
971
  /**
715
972
  * Format: int32
@@ -785,6 +1042,7 @@ export interface components {
785
1042
  };
786
1043
  /** @description Global PnL webhook payload. */
787
1044
  GlobalPnlPayload: {
1045
+ /** @description Trader wallet address. */
788
1046
  trader?: string | null;
789
1047
  /** @description Aggregation timeframe: "1d", "7d", "30d", or "lifetime" */
790
1048
  timeframe: string;
@@ -793,87 +1051,203 @@ export interface components {
793
1051
  * @description Realized PnL for the timeframe (matches REST `/pnl/global`).
794
1052
  */
795
1053
  realized_pnl_usd?: number | null;
796
- /** Format: int64 */
1054
+ /**
1055
+ * Format: int64
1056
+ * @description Events traded.
1057
+ */
797
1058
  events_traded?: number | null;
798
- /** Format: int64 */
1059
+ /**
1060
+ * Format: int64
1061
+ * @description Markets traded.
1062
+ */
799
1063
  markets_traded?: number | null;
800
- /** Format: int64 */
1064
+ /**
1065
+ * Format: int64
1066
+ * @description Total buy count.
1067
+ */
801
1068
  total_buys?: number | null;
802
- /** Format: int64 */
1069
+ /**
1070
+ * Format: int64
1071
+ * @description Total sell count.
1072
+ */
803
1073
  total_sells?: number | null;
804
- /** Format: int64 */
1074
+ /**
1075
+ * Format: int64
1076
+ * @description Total redemption count.
1077
+ */
805
1078
  total_redemptions?: number | null;
806
- /** Format: int64 */
1079
+ /**
1080
+ * Format: int64
1081
+ * @description Total merge count.
1082
+ */
807
1083
  total_merges?: number | null;
808
- /** Format: int64 */
1084
+ /**
1085
+ * Format: int64
1086
+ * @description Total split count.
1087
+ */
809
1088
  total_splits?: number | null;
810
- /** Format: double */
1089
+ /**
1090
+ * Format: double
1091
+ * @description Total volume in USD.
1092
+ */
811
1093
  total_volume_usd?: number | null;
812
- /** Format: double */
1094
+ /**
1095
+ * Format: double
1096
+ * @description Buy volume in USD.
1097
+ */
813
1098
  buy_volume_usd?: number | null;
814
- /** Format: double */
1099
+ /**
1100
+ * Format: double
1101
+ * @description Sell volume in USD.
1102
+ */
815
1103
  sell_volume_usd?: number | null;
816
- /** Format: double */
1104
+ /**
1105
+ * Format: double
1106
+ * @description Redemption volume in USD.
1107
+ */
817
1108
  redemption_volume_usd?: number | null;
818
- /** Format: double */
1109
+ /**
1110
+ * Format: double
1111
+ * @description Merge volume in USD.
1112
+ */
819
1113
  merge_volume_usd?: number | null;
820
- /** Format: double */
1114
+ /**
1115
+ * Format: double
1116
+ * @description Convert collateral in USD.
1117
+ */
821
1118
  convert_collateral_usd?: number | null;
822
- /** Format: double */
1119
+ /**
1120
+ * Format: double
1121
+ * @description Split volume in USD.
1122
+ */
823
1123
  split_volume_usd?: number | null;
824
- /** Format: int64 */
1124
+ /**
1125
+ * Format: int64
1126
+ * @description Maker rebate count.
1127
+ */
825
1128
  maker_rebate_count?: number | null;
826
- /** Format: double */
1129
+ /**
1130
+ * Format: double
1131
+ * @description Maker rebate in USD.
1132
+ */
827
1133
  maker_rebate_usd?: number | null;
828
- /** Format: int64 */
1134
+ /**
1135
+ * Format: int64
1136
+ * @description Reward count.
1137
+ */
829
1138
  reward_count?: number | null;
830
- /** Format: double */
1139
+ /**
1140
+ * Format: double
1141
+ * @description Reward in USD.
1142
+ */
831
1143
  reward_usd?: number | null;
832
- /** Format: int64 */
1144
+ /**
1145
+ * Format: int64
1146
+ * @description Yield count.
1147
+ */
833
1148
  yield_count?: number | null;
834
- /** Format: double */
1149
+ /**
1150
+ * Format: double
1151
+ * @description Yield in USD.
1152
+ */
835
1153
  yield_usd?: number | null;
836
- /** Format: int64 */
1154
+ /**
1155
+ * Format: int64
1156
+ * @description Total credit count.
1157
+ */
837
1158
  total_credit_count?: number | null;
838
- /** Format: double */
1159
+ /**
1160
+ * Format: double
1161
+ * @description Total credit in USD.
1162
+ */
839
1163
  total_credit_usd?: number | null;
840
- /** Format: int64 */
1164
+ /**
1165
+ * Format: int64
1166
+ * @description Markets won.
1167
+ */
841
1168
  markets_won?: number | null;
842
- /** Format: int64 */
1169
+ /**
1170
+ * Format: int64
1171
+ * @description Markets lost.
1172
+ */
843
1173
  markets_lost?: number | null;
844
- /** Format: double */
1174
+ /**
1175
+ * Format: double
1176
+ * @description Market win rate percent.
1177
+ */
845
1178
  market_win_rate_pct?: number | null;
846
- /** Format: double */
1179
+ /**
1180
+ * Format: double
1181
+ * @description Total wins in USD.
1182
+ */
847
1183
  total_wins_usd?: number | null;
848
- /** Format: double */
1184
+ /**
1185
+ * Format: double
1186
+ * @description Total losses in USD.
1187
+ */
849
1188
  total_losses_usd?: number | null;
850
- /** Format: double */
1189
+ /**
1190
+ * Format: double
1191
+ * @description Average win in USD.
1192
+ */
851
1193
  avg_win_usd?: number | null;
852
- /** Format: double */
1194
+ /**
1195
+ * Format: double
1196
+ * @description Average loss in USD.
1197
+ */
853
1198
  avg_loss_usd?: number | null;
854
- /** Format: double */
1199
+ /**
1200
+ * Format: double
1201
+ * @description Profit factor.
1202
+ */
855
1203
  profit_factor?: number | null;
856
- /** Format: double */
1204
+ /**
1205
+ * Format: double
1206
+ * @description Average hold time seconds.
1207
+ */
857
1208
  avg_hold_time_seconds?: number | null;
858
- /** Format: double */
1209
+ /**
1210
+ * Format: double
1211
+ * @description Total fees amount.
1212
+ */
859
1213
  total_fees?: number | null;
860
- /** Format: double */
1214
+ /**
1215
+ * Format: double
1216
+ * @description Best trade pnl in USD.
1217
+ */
861
1218
  best_trade_pnl_usd?: number | null;
1219
+ /** @description Best trade condition id. */
862
1220
  best_trade_condition_id?: string | null;
863
- /** Format: double */
1221
+ /**
1222
+ * Format: double
1223
+ * @description Worst trade pnl in USD.
1224
+ */
864
1225
  worst_trade_pnl_usd?: number | null;
1226
+ /** @description Worst trade condition id. */
865
1227
  worst_trade_condition_id?: string | null;
866
- /** Format: int64 */
1228
+ /**
1229
+ * Format: int64
1230
+ * @description First trade timestamp.
1231
+ */
867
1232
  first_trade_at?: number | null;
868
- /** Format: int64 */
1233
+ /**
1234
+ * Format: int64
1235
+ * @description Last trade timestamp.
1236
+ */
869
1237
  last_trade_at?: number | null;
870
1238
  };
871
1239
  /** @description Response for GET /v1/webhook/events */
872
1240
  ListEventsResponse: {
1241
+ /** @description Supported webhook events. */
873
1242
  events: components["schemas"]["WebhookEventInfo"][];
874
1243
  };
875
1244
  /** @description Subscription filters for the `market_created` event. All fields are optional. */
876
1245
  MarketCreatedFilters: {
1246
+ /**
1247
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1248
+ * successful delivery. Applies to any webhook event.
1249
+ */
1250
+ one_shot?: boolean | null;
877
1251
  /** @description Restrict to markets with these tags or category names (case-insensitive match). */
878
1252
  tags?: string[] | null;
879
1253
  /** @description Restrict to markets belonging to these events. */
@@ -924,8 +1298,116 @@ export interface components {
924
1298
  /** @description Whether this is a neg-risk market */
925
1299
  neg_risk: boolean;
926
1300
  };
1301
+ /** @description Subscription filters for the `market_disputed` event. All fields are optional. */
1302
+ MarketDisputedFilters: {
1303
+ /**
1304
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1305
+ * successful delivery. Applies to any webhook event.
1306
+ */
1307
+ one_shot?: boolean | null;
1308
+ /** @description Restrict to these markets. */
1309
+ condition_ids?: string[] | null;
1310
+ /** @description Restrict to markets in these events. */
1311
+ event_slugs?: string[] | null;
1312
+ /** @description When `true`, suppress webhooks for short-term "updown" markets. Default: `false`. */
1313
+ exclude_shortterm_markets?: boolean | null;
1314
+ };
1315
+ /** @description Market-disputed webhook payload */
1316
+ MarketDisputedPayload: {
1317
+ /** @description Condition ID (the contested market), when resolvable */
1318
+ condition_id?: string | null;
1319
+ /** @description Which oracle event produced this dispute: `"dispute_price"` or `"assertion_disputed"`. */
1320
+ dispute_kind: string;
1321
+ /** @description Address that filed the dispute */
1322
+ disputer: string;
1323
+ /** @description Address that made the disputed proposal/assertion, when known */
1324
+ proposer?: string | null;
1325
+ /** @description The proposed outcome that was disputed, when known (e.g. "Yes", "No") */
1326
+ proposed_outcome?: string | null;
1327
+ /**
1328
+ * Format: double
1329
+ * @description The proposed price (0.0–1.0) that was disputed (`DisputePrice` only)
1330
+ */
1331
+ proposed_price?: number | null;
1332
+ /** @description Market question */
1333
+ question?: string | null;
1334
+ /** @description Market slug */
1335
+ market_slug?: string | null;
1336
+ /** @description Event slug */
1337
+ event_slug?: string | null;
1338
+ /** @description Market image URL */
1339
+ image_url?: string | null;
1340
+ /** @description Transaction hash of the dispute event */
1341
+ hash: string;
1342
+ /**
1343
+ * Format: int64
1344
+ * @description Block number
1345
+ */
1346
+ block?: number | null;
1347
+ /**
1348
+ * Format: int64
1349
+ * @description Confirmed timestamp (Unix seconds)
1350
+ */
1351
+ confirmed_at?: number | null;
1352
+ };
1353
+ /**
1354
+ * @description Subscription filters for the `market_liquidity` event.
1355
+ *
1356
+ * At least one of `min_liquidity_usd`, `max_liquidity_usd`, or `one_shot` must be set.
1357
+ * Thresholds are edge-triggered: a callback fires when liquidity crosses the threshold,
1358
+ * then re-arms once it crosses back (unless `one_shot`).
1359
+ */
1360
+ MarketLiquidityFilters: {
1361
+ /**
1362
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1363
+ * successful delivery.
1364
+ */
1365
+ one_shot?: boolean | null;
1366
+ /**
1367
+ * Format: double
1368
+ * @description Fire when total liquidity crosses up through this USD value.
1369
+ */
1370
+ min_liquidity_usd?: number | null;
1371
+ /**
1372
+ * Format: double
1373
+ * @description Fire when total liquidity crosses down through this USD value.
1374
+ */
1375
+ max_liquidity_usd?: number | null;
1376
+ /** @description **Required.** Markets to receive liquidity updates for. */
1377
+ condition_ids: string[];
1378
+ };
1379
+ /** @description Market liquidity webhook payload. */
1380
+ MarketLiquidityPayload: {
1381
+ /** @description Market condition ID. */
1382
+ condition_id: string;
1383
+ /**
1384
+ * Format: double
1385
+ * @description Total order-book liquidity in USD at the time of firing.
1386
+ */
1387
+ liquidity_usd: number;
1388
+ /**
1389
+ * Format: double
1390
+ * @description The threshold (USD) that was crossed.
1391
+ */
1392
+ threshold_usd: number;
1393
+ /**
1394
+ * @description `"above"` when liquidity crossed up through `min_liquidity_usd`,
1395
+ * `"below"` when it crossed down through `max_liquidity_usd`.
1396
+ */
1397
+ direction: string;
1398
+ /**
1399
+ * Format: int64
1400
+ * @description Update timestamp (Unix millis).
1401
+ */
1402
+ liquidity_updated_at: number;
1403
+ };
927
1404
  /** @description Subscription filters for the `condition_metrics` event. All fields are optional. */
928
1405
  MarketMetricsFilters: {
1406
+ /**
1407
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1408
+ * successful delivery. Applies to any webhook event.
1409
+ */
1410
+ one_shot?: boolean | null;
929
1411
  /** @description Restrict to these markets. Empty = all markets. */
930
1412
  condition_ids?: string[] | null;
931
1413
  /** @description Restrict to these aggregation windows. Empty = all windows. */
@@ -958,51 +1440,168 @@ export interface components {
958
1440
  };
959
1441
  /** @description Market PnL webhook payload. */
960
1442
  MarketPnlPayload: {
1443
+ /** @description Trader wallet address. */
961
1444
  trader?: string | null;
1445
+ /** @description Market condition ID. */
962
1446
  condition_id?: string | null;
1447
+ /** @description Event slug. */
963
1448
  event_slug?: string | null;
1449
+ /** @description Category. */
964
1450
  category?: string | null;
965
1451
  /** @description Aggregation timeframe: "1d", "7d", "30d", or "lifetime" */
966
1452
  timeframe: string;
967
- /** Format: double */
1453
+ /**
1454
+ * Format: double
1455
+ * @description Realized pnl in USD.
1456
+ */
968
1457
  realized_pnl_usd?: number | null;
969
- /** Format: double */
1458
+ /**
1459
+ * Format: double
1460
+ * @description Current shares balance.
1461
+ */
970
1462
  current_shares_balance?: number | null;
971
- /** Format: int64 */
1463
+ /**
1464
+ * Format: int64
1465
+ * @description Number of outcomes traded.
1466
+ */
972
1467
  outcomes_traded?: number | null;
973
- /** Format: int64 */
1468
+ /**
1469
+ * Format: int64
1470
+ * @description Total buy count.
1471
+ */
974
1472
  total_buys?: number | null;
975
- /** Format: int64 */
1473
+ /**
1474
+ * Format: int64
1475
+ * @description Total sell count.
1476
+ */
976
1477
  total_sells?: number | null;
977
- /** Format: int64 */
1478
+ /**
1479
+ * Format: int64
1480
+ * @description Total redemption count.
1481
+ */
978
1482
  total_redemptions?: number | null;
979
- /** Format: int64 */
1483
+ /**
1484
+ * Format: int64
1485
+ * @description Total merge count.
1486
+ */
980
1487
  total_merges?: number | null;
981
- /** Format: int64 */
1488
+ /**
1489
+ * Format: int64
1490
+ * @description Total split count.
1491
+ */
982
1492
  total_splits?: number | null;
983
- /** Format: double */
1493
+ /**
1494
+ * Format: double
1495
+ * @description Buy in USD.
1496
+ */
984
1497
  buy_usd?: number | null;
985
- /** Format: double */
1498
+ /**
1499
+ * Format: double
1500
+ * @description Sell in USD.
1501
+ */
986
1502
  sell_usd?: number | null;
987
- /** Format: double */
1503
+ /**
1504
+ * Format: double
1505
+ * @description Redemption in USD.
1506
+ */
988
1507
  redemption_usd?: number | null;
989
- /** Format: double */
1508
+ /**
1509
+ * Format: double
1510
+ * @description Merge in USD.
1511
+ */
990
1512
  merge_usd?: number | null;
991
- /** Format: double */
1513
+ /**
1514
+ * Format: double
1515
+ * @description Convert collateral in USD.
1516
+ */
992
1517
  convert_collateral_usd?: number | null;
993
- /** Format: double */
1518
+ /**
1519
+ * Format: double
1520
+ * @description Split volume in USD.
1521
+ */
994
1522
  split_volume_usd?: number | null;
995
- /** Format: double */
1523
+ /**
1524
+ * Format: double
1525
+ * @description Total fees amount.
1526
+ */
996
1527
  total_fees?: number | null;
997
- /** Format: double */
1528
+ /**
1529
+ * Format: double
1530
+ * @description Total shares bought.
1531
+ */
998
1532
  total_shares_bought?: number | null;
999
- /** Format: int64 */
1533
+ /**
1534
+ * Format: int64
1535
+ * @description First trade timestamp.
1536
+ */
1000
1537
  first_trade_at?: number | null;
1001
- /** Format: int64 */
1538
+ /**
1539
+ * Format: int64
1540
+ * @description Last trade timestamp.
1541
+ */
1002
1542
  last_trade_at?: number | null;
1003
1543
  };
1544
+ /** @description Subscription filters for the `market_resolved` event. All fields are optional. */
1545
+ MarketResolvedFilters: {
1546
+ /**
1547
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1548
+ * successful delivery. Applies to any webhook event.
1549
+ */
1550
+ one_shot?: boolean | null;
1551
+ /** @description Restrict to these markets. */
1552
+ condition_ids?: string[] | null;
1553
+ /** @description Restrict to markets in these events. */
1554
+ event_slugs?: string[] | null;
1555
+ /** @description Only fire when the winning outcome matches one of these (e.g. \["Yes"\]). */
1556
+ outcomes?: string[] | null;
1557
+ /** @description When `true`, suppress webhooks for short-term "updown" markets. Default: `false`. */
1558
+ exclude_shortterm_markets?: boolean | null;
1559
+ };
1560
+ /** @description Market-resolved webhook payload */
1561
+ MarketResolvedPayload: {
1562
+ /** @description Condition ID (the resolved market) */
1563
+ condition_id: string;
1564
+ /** @description Winning outcome name when known (e.g. "Yes", "No") */
1565
+ winning_outcome?: string | null;
1566
+ /**
1567
+ * Format: double
1568
+ * @description Settled price (0.0–1.0) when the resolution event carries one
1569
+ * (`QuestionResolved` only). 1.0 = full YES, 0.0 = full NO, 0.5 = split.
1570
+ */
1571
+ settled_price?: number | null;
1572
+ /**
1573
+ * @description Which oracle event produced this resolution: `"question_resolved"`,
1574
+ * `"question_emergency_resolved"`, `"condition_resolution"`, or `"neg_risk_outcome_reported"`.
1575
+ */
1576
+ resolution_kind: string;
1577
+ /** @description Market question */
1578
+ question?: string | null;
1579
+ /** @description Market slug */
1580
+ market_slug?: string | null;
1581
+ /** @description Event slug */
1582
+ event_slug?: string | null;
1583
+ /** @description Market image URL */
1584
+ image_url?: string | null;
1585
+ /** @description Transaction hash of the resolution event */
1586
+ hash: string;
1587
+ /**
1588
+ * Format: int64
1589
+ * @description Block number
1590
+ */
1591
+ block?: number | null;
1592
+ /**
1593
+ * Format: int64
1594
+ * @description Confirmed timestamp (Unix seconds)
1595
+ */
1596
+ confirmed_at?: number | null;
1597
+ };
1004
1598
  /** @description Subscription filters for the `market_volume_milestone` event. */
1005
1599
  MarketVolumeMilestoneFilters: {
1600
+ /**
1601
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1602
+ * successful delivery. Applies to any webhook event.
1603
+ */
1604
+ one_shot?: boolean | null;
1006
1605
  /** @description **Required.** Aggregation windows to monitor (e.g. \["1h", "24h"\]). */
1007
1606
  timeframes: components["schemas"]["MetricFilterTimeframe"][];
1008
1607
  /** @description Restrict to these markets. Empty = all markets. */
@@ -1012,6 +1611,11 @@ export interface components {
1012
1611
  };
1013
1612
  /** @description Subscription filters for the `market_volume_spike` event. `spike_ratio` is required. */
1014
1613
  MarketVolumeSpikeFilters: {
1614
+ /**
1615
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1616
+ * successful delivery. Applies to any webhook event.
1617
+ */
1618
+ one_shot?: boolean | null;
1015
1619
  /**
1016
1620
  * Format: double
1017
1621
  * @description **Required.** Multiplier threshold (must be > 1.0). Fires when current volume >= snapshot × ratio. The snapshot is set automatically on first data and resets after each fire.
@@ -1029,11 +1633,17 @@ export interface components {
1029
1633
  };
1030
1634
  /** @description Market volume spike webhook payload */
1031
1635
  MarketVolumeSpikePayload: {
1636
+ /** @description Market condition ID. */
1032
1637
  condition_id: string;
1638
+ /** @description Market question. */
1033
1639
  question?: string | null;
1640
+ /** @description Market slug. */
1034
1641
  market_slug?: string | null;
1642
+ /** @description Event slug. */
1035
1643
  event_slug?: string | null;
1644
+ /** @description Image URL. */
1036
1645
  image_url?: string | null;
1646
+ /** @description Metric timeframe. */
1037
1647
  timeframe: string;
1038
1648
  /**
1039
1649
  * Format: double
@@ -1243,6 +1853,7 @@ export interface components {
1243
1853
  /**
1244
1854
  * @description CLOB V2 builder code (lower-cased `0x...` bytes32 hex). Absent on V1
1245
1855
  * trades; may be `0x0000…` for V2 trades placed without a builder code.
1856
+ * CLOB builder code.
1246
1857
  */
1247
1858
  builder_code?: string | null;
1248
1859
  /**
@@ -1314,6 +1925,11 @@ export interface components {
1314
1925
  });
1315
1926
  /** @description Subscription filters for the `oracle_events` event. All fields are optional. */
1316
1927
  OracleEventsFilters: {
1928
+ /**
1929
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
1930
+ * successful delivery. Applies to any webhook event.
1931
+ */
1932
+ one_shot?: boolean | null;
1317
1933
  /** @description Restrict to these event types (case-insensitive). Empty = all. */
1318
1934
  oracle_event_types?: components["schemas"]["OracleEventFilterType"][] | null;
1319
1935
  /** @description Restrict to events for these condition IDs. */
@@ -1340,11 +1956,15 @@ export interface components {
1340
1956
  * @description Polymarket webhook event types
1341
1957
  * @enum {string}
1342
1958
  */
1343
- PolymarketWebhookEvent: "trader_first_trade" | "trader_new_market" | "trader_whale_trade" | "trader_new_trade" | "trader_trade_event" | "trader_global_pnl" | "trader_market_pnl" | "trader_category_pnl" | "trader_position_resolved" | "trader_exit_markers" | "position_holder_metrics" | "condition_holder_metrics" | "event_holder_metrics" | "condition_metrics" | "event_metrics" | "tag_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" | "price_spike" | "oracle_events";
1959
+ PolymarketWebhookEvent: "trader_first_trade" | "trader_new_market" | "trader_whale_trade" | "trader_new_trade" | "trader_trade_event" | "trader_global_pnl" | "trader_market_pnl" | "trader_category_pnl" | "trader_position_resolved" | "trader_exit_markers" | "position_holder_metrics" | "condition_holder_metrics" | "event_holder_metrics" | "condition_metrics" | "event_metrics" | "tag_metrics" | "position_metrics" | "position_liquidity" | "market_liquidity" | "event_liquidity" | "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" | "price_spike" | "oracle_events" | "price_threshold" | "market_resolved" | "market_disputed";
1344
1960
  /**
1345
1961
  * @description Polymarket-specific webhook filters
1346
1962
  *
1347
- * Different webhook handlers use different subsets of these fields:
1963
+ * Different webhook handlers use different subsets of these fields.
1964
+ * The trade-driven events `price_spike`, `probability_spike`, and
1965
+ * `close_to_bond` additionally accept `tags` (matches a market's tags OR its
1966
+ * category) and `series_slugs` (matches the market's parent series); these are
1967
+ * resolved from the tags/series the crawler enriches onto each trade.
1348
1968
  * - first_trade: wallet_addresses, min_usd_value, min_probability, max_probability, condition_ids, event_slugs, tags
1349
1969
  * - new_market: wallet_addresses, condition_ids, event_slugs, min_usd_value, min_probability, max_probability
1350
1970
  * - whale_trade: min_usd_value (required), min_probability, max_probability, condition_ids, event_slugs
@@ -1356,10 +1976,10 @@ export interface components {
1356
1976
  * - tag_metrics: tags, min_volume_usd, max_volume_usd, min_fees, min_txns, timeframes
1357
1977
  * - 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
1358
1978
  * - volume_milestone: condition_ids, timeframes, milestone_amounts
1359
- * - close_to_bond: min_probability (high zone threshold), max_probability (low zone threshold), condition_ids, position_ids, outcomes, position_outcome_indices, event_slugs, exclude_shortterm_markets
1979
+ * - close_to_bond: min_probability (high zone threshold), max_probability (low zone threshold), condition_ids, tags, series_slugs, position_ids, outcomes, position_outcome_indices, event_slugs, exclude_shortterm_markets
1360
1980
  * - market_created: event_slugs, tags, exclude_shortterm_markets
1361
- * - probability_spike: condition_ids, event_slugs, outcomes, min_probability, max_probability, min_probability_change_pct, spike_direction, window_secs, exclude_shortterm_markets
1362
- * - price_spike: condition_ids, event_slugs, outcomes, min_price_change_pct, spike_direction, window_secs, exclude_shortterm_markets
1981
+ * - probability_spike: condition_ids, event_slugs, tags, series_slugs, outcomes, min_probability, max_probability, min_probability_change_pct, spike_direction, window_secs, exclude_shortterm_markets
1982
+ * - price_spike: condition_ids, event_slugs, tags, series_slugs, outcomes, min_price_change_pct, spike_direction, window_secs, exclude_shortterm_markets
1363
1983
  * - trader_new_trade: wallet_addresses, min_usd_value, min_probability, max_probability, condition_ids, event_slugs, trade_types, exclude_shortterm_markets
1364
1984
  * - trader_trade_event: wallet_addresses, min_usd_value, min_probability, max_probability, condition_ids, event_slugs, trade_types, exclude_shortterm_markets
1365
1985
  * - trader_first_trade: wallet_addresses, min_usd_value, min_probability, max_probability, exclude_shortterm_markets
@@ -1371,21 +1991,43 @@ export interface components {
1371
1991
  * Implements Hash + Eq manually (f64 fields use bit representation)
1372
1992
  */
1373
1993
  PolymarketWebhookFilter: {
1374
- /** @description Filter by wallet addresses (for first_trade, normalized to lowercase). Max 500 entries. */
1994
+ /**
1995
+ * @description Filter by wallet addresses (for first_trade, normalized to lowercase). Max 500 entries.
1996
+ * Wallet addresses to match.
1997
+ */
1375
1998
  wallet_addresses?: string[];
1376
- /** @description Filter by trader addresses (for PnL webhooks, normalized to lowercase). Max 500 entries. */
1999
+ /**
2000
+ * @description Filter by trader addresses (for PnL webhooks, normalized to lowercase). Max 500 entries.
2001
+ * Trader wallet addresses to match.
2002
+ */
1377
2003
  traders?: string[];
1378
- /** @description Filter by market/condition IDs. Max 500 entries. */
2004
+ /**
2005
+ * @description Filter by market/condition IDs. Max 500 entries.
2006
+ * Market condition IDs to match.
2007
+ */
1379
2008
  condition_ids?: string[];
1380
2009
  /**
1381
2010
  * Format: double
1382
2011
  * @description Filter by minimum USD value (for trades)
1383
2012
  */
1384
2013
  min_usd_value?: number | null;
1385
- /** @description Filter by event slugs. Max 500 entries. */
2014
+ /**
2015
+ * @description Filter by event slugs. Max 500 entries.
2016
+ * Event slugs to match.
2017
+ */
1386
2018
  event_slugs?: string[];
1387
- /** @description Filter by tags. Max 500 entries. */
2019
+ /**
2020
+ * @description Filter by tags or category names (case-insensitive). Matches a market's
2021
+ * tags or its category label. Max 500 entries.
2022
+ * Tags to match.
2023
+ */
1388
2024
  tags?: string[];
2025
+ /**
2026
+ * @description Filter by series slugs (case-insensitive). Matches a market's parent
2027
+ * series. Max 500 entries.
2028
+ * Series slugs to match.
2029
+ */
2030
+ series_slugs?: string[];
1389
2031
  /**
1390
2032
  * Format: double
1391
2033
  * @description Minimum probability threshold (0.0 - 1.0)
@@ -1416,6 +2058,18 @@ export interface components {
1416
2058
  * @description Maximum volume (USD) - for metrics webhooks
1417
2059
  */
1418
2060
  max_volume_usd?: number | null;
2061
+ /**
2062
+ * Format: double
2063
+ * @description Minimum order-book liquidity (USD) - for liquidity webhooks.
2064
+ * Fires when liquidity crosses up through this value.
2065
+ */
2066
+ min_liquidity_usd?: number | null;
2067
+ /**
2068
+ * Format: double
2069
+ * @description Maximum order-book liquidity (USD) - for liquidity webhooks.
2070
+ * Fires when liquidity crosses down through this value.
2071
+ */
2072
+ max_liquidity_usd?: number | null;
1419
2073
  /**
1420
2074
  * Format: double
1421
2075
  * @description Minimum buy volume (USD) - for PnL and metrics webhooks
@@ -1441,16 +2095,26 @@ export interface components {
1441
2095
  * @description Maximum net shares - for position PnL webhooks
1442
2096
  */
1443
2097
  max_net_shares?: number | null;
1444
- /** @description Filter by position IDs - for position PnL webhooks. Max 500 entries. */
2098
+ /**
2099
+ * @description Filter by position IDs - for position PnL webhooks. Max 500 entries.
2100
+ * Outcome token IDs to match.
2101
+ */
1445
2102
  position_ids?: string[];
1446
- /** @description Filter by outcomes (e.g., "Yes", "No") - for position PnL webhooks. Max 500 entries. */
2103
+ /**
2104
+ * @description Filter by outcomes (e.g., "Yes", "No") - for position PnL webhooks. Max 500 entries.
2105
+ * Outcome names to match.
2106
+ */
1447
2107
  outcomes?: string[];
1448
2108
  /**
1449
2109
  * @description Filter by position outcome index — for close_to_bond. Position 0 usually represents Yes/Up, 1 = No.
1450
2110
  * When non-empty, only trades whose outcome_index is in this list will match. Max 500 entries.
2111
+ * Outcome indices to match.
1451
2112
  */
1452
2113
  position_outcome_indices?: number[];
1453
- /** @description Filter by trade type (e.g. "OrderFilled", "Redemption", "Merge", "Split"). Empty = default behavior per handler. */
2114
+ /**
2115
+ * @description Filter by trade type (e.g. "OrderFilled", "Redemption", "Merge", "Split"). Empty = default behavior per handler.
2116
+ * Trade types to match.
2117
+ */
1454
2118
  trade_types?: string[];
1455
2119
  /**
1456
2120
  * Format: double
@@ -1482,9 +2146,15 @@ export interface components {
1482
2146
  * @description Minimum probability change percentage - for position metrics webhooks
1483
2147
  */
1484
2148
  min_probability_change_pct?: number | null;
1485
- /** @description Timeframes to track - for metrics webhooks (1m, 5m, 30m, 1h, 6h, 24h, 7d, 30d). */
2149
+ /**
2150
+ * @description Timeframes to track - for metrics webhooks (1m, 5m, 30m, 1h, 6h, 24h, 7d, 30d).
2151
+ * Metric timeframes to match.
2152
+ */
1486
2153
  timeframes?: components["schemas"]["WebhookTimeframe"][];
1487
- /** @description Milestone amounts to track - for volume milestone webhooks (e.g., 10000, 100000, 1000000). Max 500 entries. */
2154
+ /**
2155
+ * @description Milestone amounts to track - for volume milestone webhooks (e.g., 10000, 100000, 1000000). Max 500 entries.
2156
+ * Milestone amounts to match.
2157
+ */
1488
2158
  milestone_amounts?: number[];
1489
2159
  /**
1490
2160
  * Format: double
@@ -1503,6 +2173,7 @@ export interface components {
1503
2173
  /**
1504
2174
  * @description Filter by crypto asset symbol — for `asset_price_tick` and `asset_price_window_update` webhooks.
1505
2175
  * Valid values: "BTC", "ETH", "SOL", "XRP", "DOGE", "BNB", "HYPE". Empty = all assets.
2176
+ * Asset symbols to match.
1506
2177
  */
1507
2178
  asset_symbols?: components["schemas"]["WebhookAssetSymbol"][];
1508
2179
  spike_direction?: null | components["schemas"]["SpikeDirection"];
@@ -1526,31 +2197,127 @@ export interface components {
1526
2197
  * `QuestionInitialized`, `QuestionPaused`, `QuestionUnpaused`,
1527
2198
  * `QuestionFlagged`, `QuestionUnflagged`, `ConditionResolution`,
1528
2199
  * `NegRiskOutcomeReported`. Empty = all types.
2200
+ * Oracle event types to match.
1529
2201
  */
1530
2202
  oracle_event_types?: string[];
2203
+ /**
2204
+ * @description Fire-and-delete: when `true`, the subscription is deleted after its first
2205
+ * successful delivery. Works on any webhook event. (`price_threshold`
2206
+ * additionally requires `position_ids` or `condition_ids`.)
2207
+ */
2208
+ one_shot?: boolean;
2209
+ /**
2210
+ * @description For `price_threshold` — when `true`, fire immediately if the first observed
2211
+ * price is already past the target (no prior baseline). Default `false`.
2212
+ */
2213
+ fire_if_already_past?: boolean;
1531
2214
  };
1532
2215
  PositionHolderMetricsFilters: {
2216
+ /** @description Outcome token IDs to match. */
1533
2217
  position_ids?: string[];
2218
+ /**
2219
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
2220
+ * successful delivery. Applies to any webhook event.
2221
+ */
2222
+ one_shot?: boolean | null;
1534
2223
  };
1535
2224
  PositionHolderMetricsPayload: {
1536
- /** Format: int32 */
2225
+ /**
2226
+ * Format: int32
2227
+ * @description Unix timestamp in seconds.
2228
+ */
1537
2229
  ts: number;
1538
- /** Format: int64 */
2230
+ /**
2231
+ * Format: int64
2232
+ * @description Block number.
2233
+ */
1539
2234
  block: number;
2235
+ /** @description Outcome token ID. */
1540
2236
  position_id: string;
1541
- /** Format: int32 */
2237
+ /**
2238
+ * Format: int32
2239
+ * @description Number of holders.
2240
+ */
1542
2241
  holder_count: number;
1543
- /** Format: double */
2242
+ /**
2243
+ * Format: double
2244
+ * @description Total shares held.
2245
+ */
1544
2246
  total_balance: number;
1545
- /** Format: double */
2247
+ /**
2248
+ * Format: double
2249
+ * @description Total holder cost basis in USD.
2250
+ */
1546
2251
  total_cost_basis: number;
1547
- /** Format: int32 */
2252
+ /**
2253
+ * Format: int32
2254
+ * @description Number of market-level holders.
2255
+ */
1548
2256
  condition_holder_count?: number | null;
1549
- /** Format: int32 */
2257
+ /**
2258
+ * Format: int32
2259
+ * @description Number of event-level holders.
2260
+ */
1550
2261
  event_holder_count?: number | null;
1551
2262
  };
2263
+ /**
2264
+ * @description Subscription filters for the `position_liquidity` event.
2265
+ *
2266
+ * At least one of `min_liquidity_usd`, `max_liquidity_usd`, or `one_shot` must be set.
2267
+ * Thresholds are edge-triggered: a callback fires when liquidity crosses the threshold,
2268
+ * then re-arms once it crosses back (unless `one_shot`).
2269
+ */
2270
+ PositionLiquidityFilters: {
2271
+ /**
2272
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
2273
+ * successful delivery.
2274
+ */
2275
+ one_shot?: boolean | null;
2276
+ /**
2277
+ * Format: double
2278
+ * @description Fire when liquidity crosses up through this USD value.
2279
+ */
2280
+ min_liquidity_usd?: number | null;
2281
+ /**
2282
+ * Format: double
2283
+ * @description Fire when liquidity crosses down through this USD value.
2284
+ */
2285
+ max_liquidity_usd?: number | null;
2286
+ /** @description **Required.** Outcome token IDs to receive liquidity updates for. */
2287
+ position_ids: string[];
2288
+ };
2289
+ /** @description Position liquidity webhook payload. */
2290
+ PositionLiquidityPayload: {
2291
+ /** @description Outcome token (position) ID. */
2292
+ position_id: string;
2293
+ /**
2294
+ * Format: double
2295
+ * @description Order-book liquidity in USD at the time of firing.
2296
+ */
2297
+ liquidity_usd: number;
2298
+ /**
2299
+ * Format: double
2300
+ * @description The threshold (USD) that was crossed.
2301
+ */
2302
+ threshold_usd: number;
2303
+ /**
2304
+ * @description `"above"` when liquidity crossed up through `min_liquidity_usd`,
2305
+ * `"below"` when it crossed down through `max_liquidity_usd`.
2306
+ */
2307
+ direction: string;
2308
+ /**
2309
+ * Format: int64
2310
+ * @description Update timestamp (Unix millis).
2311
+ */
2312
+ liquidity_updated_at: number;
2313
+ };
1552
2314
  /** @description Subscription filters for the `position_metrics` event. All fields are optional. */
1553
2315
  PositionMetricsFilters: {
2316
+ /**
2317
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
2318
+ * successful delivery. Applies to any webhook event.
2319
+ */
2320
+ one_shot?: boolean | null;
1554
2321
  /** @description Restrict to these outcome token IDs. */
1555
2322
  position_ids?: string[] | null;
1556
2323
  /** @description Restrict to positions within these markets. */
@@ -1564,15 +2331,30 @@ export interface components {
1564
2331
  * @description Only fire when position volume ≥ this value (USD).
1565
2332
  */
1566
2333
  min_volume_usd?: number | null;
1567
- /** Format: double */
2334
+ /**
2335
+ * Format: double
2336
+ * @description Maximum volume USD.
2337
+ */
1568
2338
  max_volume_usd?: number | null;
1569
- /** Format: double */
2339
+ /**
2340
+ * Format: double
2341
+ * @description Minimum buy USD.
2342
+ */
1570
2343
  min_buy_usd?: number | null;
1571
- /** Format: double */
2344
+ /**
2345
+ * Format: double
2346
+ * @description Minimum sell volume USD.
2347
+ */
1572
2348
  min_sell_volume_usd?: number | null;
1573
- /** Format: int64 */
2349
+ /**
2350
+ * Format: int64
2351
+ * @description Minimum transactions.
2352
+ */
1574
2353
  min_txns?: number | null;
1575
- /** Format: int64 */
2354
+ /**
2355
+ * Format: int64
2356
+ * @description Minimum unique traders.
2357
+ */
1576
2358
  min_unique_traders?: number | null;
1577
2359
  /**
1578
2360
  * Format: double
@@ -1584,7 +2366,10 @@ export interface components {
1584
2366
  * @description Only fire when probability change % ≥ this value.
1585
2367
  */
1586
2368
  min_probability_change_pct?: number | null;
1587
- /** Format: double */
2369
+ /**
2370
+ * Format: double
2371
+ * @description Minimum fees.
2372
+ */
1588
2373
  min_fees?: number | null;
1589
2374
  };
1590
2375
  /** @description Payload delivered when a position's volume or transaction metrics cross a configured threshold */
@@ -1670,47 +2455,110 @@ export interface components {
1670
2455
  * @description Builder-attributed fees in USD
1671
2456
  */
1672
2457
  builder_fees?: number | null;
1673
- /** Format: int64 */
2458
+ /**
2459
+ * Format: int64
2460
+ * @description Transaction count.
2461
+ */
1674
2462
  txns?: number | null;
1675
- /** Format: int64 */
2463
+ /**
2464
+ * Format: int64
2465
+ * @description Buy count.
2466
+ */
1676
2467
  buys?: number | null;
1677
- /** Format: int64 */
2468
+ /**
2469
+ * Format: int64
2470
+ * @description Sell count.
2471
+ */
1678
2472
  sells?: number | null;
1679
- /** Format: int64 */
2473
+ /**
2474
+ * Format: int64
2475
+ * @description Builder-attributed transaction count.
2476
+ */
1680
2477
  builder_txns?: number | null;
1681
- /** Format: int64 */
2478
+ /**
2479
+ * Format: int64
2480
+ * @description Builder-attributed buy count.
2481
+ */
1682
2482
  builder_buys?: number | null;
1683
- /** Format: int64 */
2483
+ /**
2484
+ * Format: int64
2485
+ * @description Builder-attributed sell count.
2486
+ */
1684
2487
  builder_sells?: number | null;
1685
- /** Format: int64 */
2488
+ /**
2489
+ * Format: int64
2490
+ * @description Unique traders.
2491
+ */
1686
2492
  unique_traders?: number | null;
1687
- /** Format: int64 */
2493
+ /**
2494
+ * Format: int64
2495
+ * @description Unique makers.
2496
+ */
1688
2497
  unique_makers?: number | null;
1689
- /** Format: int64 */
2498
+ /**
2499
+ * Format: int64
2500
+ * @description Unique takers.
2501
+ */
1690
2502
  unique_takers?: number | null;
1691
- /** Format: int64 */
2503
+ /**
2504
+ * Format: int64
2505
+ * @description Unique builder traders.
2506
+ */
1692
2507
  unique_builder_traders?: number | null;
1693
- /** Format: double */
2508
+ /**
2509
+ * Format: double
2510
+ * @description Opening price.
2511
+ */
1694
2512
  price_open?: number | null;
1695
- /** Format: double */
2513
+ /**
2514
+ * Format: double
2515
+ * @description Closing price.
2516
+ */
1696
2517
  price_close?: number | null;
1697
- /** Format: double */
2518
+ /**
2519
+ * Format: double
2520
+ * @description Highest price.
2521
+ */
1698
2522
  price_high?: number | null;
1699
- /** Format: double */
2523
+ /**
2524
+ * Format: double
2525
+ * @description Lowest price.
2526
+ */
1700
2527
  price_low?: number | null;
1701
- /** Format: double */
2528
+ /**
2529
+ * Format: double
2530
+ * @description Opening implied probability.
2531
+ */
1702
2532
  probability_open?: number | null;
1703
- /** Format: double */
2533
+ /**
2534
+ * Format: double
2535
+ * @description Closing implied probability.
2536
+ */
1704
2537
  probability_close?: number | null;
1705
- /** Format: double */
2538
+ /**
2539
+ * Format: double
2540
+ * @description Highest implied probability.
2541
+ */
1706
2542
  probability_high?: number | null;
1707
- /** Format: double */
2543
+ /**
2544
+ * Format: double
2545
+ * @description Lowest implied probability.
2546
+ */
1708
2547
  probability_low?: number | null;
1709
- /** Format: double */
2548
+ /**
2549
+ * Format: double
2550
+ * @description Average shares per trade.
2551
+ */
1710
2552
  avg_trade_shares?: number | null;
1711
- /** Format: double */
2553
+ /**
2554
+ * Format: double
2555
+ * @description Average shares per buy.
2556
+ */
1712
2557
  avg_buy_shares?: number | null;
1713
- /** Format: double */
2558
+ /**
2559
+ * Format: double
2560
+ * @description Average shares per sell.
2561
+ */
1714
2562
  avg_sell_shares?: number | null;
1715
2563
  };
1716
2564
  PositionResolvedPayload: {
@@ -1854,6 +2702,11 @@ export interface components {
1854
2702
  };
1855
2703
  /** @description Subscription filters for the `position_volume_milestone` event. */
1856
2704
  PositionVolumeMilestoneFilters: {
2705
+ /**
2706
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
2707
+ * successful delivery. Applies to any webhook event.
2708
+ */
2709
+ one_shot?: boolean | null;
1857
2710
  /** @description **Required.** Aggregation windows to monitor. */
1858
2711
  timeframes: components["schemas"]["MetricFilterTimeframe"][];
1859
2712
  /** @description Restrict to these outcome token IDs. */
@@ -1867,11 +2720,18 @@ export interface components {
1867
2720
  };
1868
2721
  /** @description Position volume milestone webhook payload */
1869
2722
  PositionVolumeMilestonePayload: {
2723
+ /** @description Market condition ID. */
1870
2724
  condition_id?: string | null;
2725
+ /** @description Outcome token ID. */
1871
2726
  position_id: string;
2727
+ /** @description Outcome name. */
1872
2728
  outcome?: string | null;
1873
- /** Format: int32 */
2729
+ /**
2730
+ * Format: int32
2731
+ * @description Outcome index.
2732
+ */
1874
2733
  outcome_index?: number | null;
2734
+ /** @description Metric timeframe. */
1875
2735
  timeframe: string;
1876
2736
  /**
1877
2737
  * Format: double
@@ -1916,6 +2776,11 @@ export interface components {
1916
2776
  };
1917
2777
  /** @description Subscription filters for the `position_volume_spike` event. `spike_ratio` is required. */
1918
2778
  PositionVolumeSpikeFilters: {
2779
+ /**
2780
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
2781
+ * successful delivery. Applies to any webhook event.
2782
+ */
2783
+ one_shot?: boolean | null;
1919
2784
  /**
1920
2785
  * Format: double
1921
2786
  * @description **Required.** Multiplier threshold (must be > 1.0). Fires when current volume >= snapshot × ratio.
@@ -1937,15 +2802,26 @@ export interface components {
1937
2802
  };
1938
2803
  /** @description Position volume spike webhook payload */
1939
2804
  PositionVolumeSpikePayload: {
2805
+ /** @description Outcome token ID. */
1940
2806
  position_id: string;
2807
+ /** @description Market condition ID. */
1941
2808
  condition_id: string;
2809
+ /** @description Market question. */
1942
2810
  question?: string | null;
2811
+ /** @description Market slug. */
1943
2812
  market_slug?: string | null;
2813
+ /** @description Event slug. */
1944
2814
  event_slug?: string | null;
2815
+ /** @description Image URL. */
1945
2816
  image_url?: string | null;
2817
+ /** @description Outcome name. */
1946
2818
  outcome?: string | null;
1947
- /** Format: int32 */
2819
+ /**
2820
+ * Format: int32
2821
+ * @description Outcome index.
2822
+ */
1948
2823
  outcome_index?: number | null;
2824
+ /** @description Metric timeframe. */
1949
2825
  timeframe: string;
1950
2826
  /**
1951
2827
  * Format: double
@@ -1980,6 +2856,11 @@ export interface components {
1980
2856
  };
1981
2857
  /** @description Subscription filters for the `price_spike` event. */
1982
2858
  PriceSpikeFilters: {
2859
+ /**
2860
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
2861
+ * successful delivery. Applies to any webhook event.
2862
+ */
2863
+ one_shot?: boolean | null;
1983
2864
  /** @description Restrict to specific outcome token IDs. Empty = all positions. */
1984
2865
  position_ids?: string[] | null;
1985
2866
  /** @description Restrict to specific market condition IDs. Empty = all markets. */
@@ -1988,6 +2869,10 @@ export interface components {
1988
2869
  event_slugs?: string[] | null;
1989
2870
  /** @description Restrict to these outcome names (e.g. \["Yes", "No"\]). */
1990
2871
  outcomes?: string[] | null;
2872
+ /** @description Restrict to markets carrying any of these tags or category names (case-insensitive). Empty = all. */
2873
+ tags?: string[] | null;
2874
+ /** @description Restrict to markets in any of these series (by slug, case-insensitive). Empty = all. */
2875
+ series_slugs?: string[] | null;
1991
2876
  /**
1992
2877
  * Format: double
1993
2878
  * @description Minimum price percentage move to trigger (e.g. `10` for a 10% move).
@@ -2024,14 +2909,24 @@ export interface components {
2024
2909
  };
2025
2910
  /** @description Position price spike webhook payload */
2026
2911
  PriceSpikePayload: {
2912
+ /** @description Outcome token ID. */
2027
2913
  position_id: string;
2914
+ /** @description Market condition ID. */
2028
2915
  condition_id?: string | null;
2916
+ /** @description Market question. */
2029
2917
  question?: string | null;
2918
+ /** @description Market slug. */
2030
2919
  market_slug?: string | null;
2920
+ /** @description Event slug. */
2031
2921
  event_slug?: string | null;
2922
+ /** @description Image URL. */
2032
2923
  image_url?: string | null;
2924
+ /** @description Outcome name. */
2033
2925
  outcome?: string | null;
2034
- /** Format: int32 */
2926
+ /**
2927
+ * Format: int32
2928
+ * @description Outcome index.
2929
+ */
2035
2930
  outcome_index?: number | null;
2036
2931
  /**
2037
2932
  * Format: double
@@ -2051,8 +2946,126 @@ export interface components {
2051
2946
  */
2052
2947
  spike_pct: number;
2053
2948
  };
2949
+ /** @description Subscription filters for the `price_threshold` event. */
2950
+ PriceThresholdFilters: {
2951
+ /** @description Restrict to markets carrying any of these tags or category names (case-insensitive). Empty = all. */
2952
+ tags?: string[] | null;
2953
+ /** @description Restrict to markets in any of these series (by slug, case-insensitive). Empty = all. */
2954
+ series_slugs?: string[] | null;
2955
+ /**
2956
+ * Format: double
2957
+ * @description Upward target — fire when the YES price crosses up to ≥ this value (e.g. 0.75 for 75%). At least one of `min_probability` or `max_probability` must be set.
2958
+ */
2959
+ min_probability?: number | null;
2960
+ /**
2961
+ * Format: double
2962
+ * @description Downward target — fire when the YES price crosses down to ≤ this value (e.g. 0.25).
2963
+ */
2964
+ max_probability?: number | null;
2965
+ /** @description When `true`, delete the subscription after its first delivery (fire-and-delete). Requires `position_ids` or `condition_ids`. Default: `false`. */
2966
+ one_shot?: boolean | null;
2967
+ /** @description When `true`, fire immediately if the first observed price is already past the target (no prior baseline). Default: `false` (wait for an actual crossing). */
2968
+ fire_if_already_past?: boolean | null;
2969
+ /** @description Restrict to these markets. */
2970
+ condition_ids?: string[] | null;
2971
+ /** @description Restrict to these outcome token IDs. */
2972
+ position_ids?: string[] | null;
2973
+ /** @description Restrict to markets in these events. */
2974
+ event_slugs?: string[] | null;
2975
+ /** @description Restrict to these outcome names (e.g. \["Yes", "No"\]). */
2976
+ outcomes?: string[] | null;
2977
+ /** @description Restrict by outcome index. 0 = Yes/Up, 1 = No. Position 0 usually represents the Up/Yes side in binary markets. */
2978
+ position_outcome_indices?: number[] | null;
2979
+ /** @description When `true`, suppress webhooks for short-term "updown" markets. Default: `false`. */
2980
+ exclude_shortterm_markets?: boolean | null;
2981
+ };
2982
+ /** @description Price-threshold crossing webhook payload */
2983
+ PriceThresholdPayload: {
2984
+ /** @description Trader address (the limit-order maker) */
2985
+ trader: string;
2986
+ /** @description Taker address (the order filler — often the exchange contract) */
2987
+ taker: string;
2988
+ /** @description Position ID (ERC1155 token ID) */
2989
+ position_id: string;
2990
+ /** @description Condition ID (parent market) */
2991
+ condition_id?: string | null;
2992
+ /** @description Outcome name (e.g. "Yes", "No") */
2993
+ outcome?: string | null;
2994
+ /**
2995
+ * Format: int32
2996
+ * @description Outcome index (0 = Yes/Up, 1 = No). Position 0 usually represents Yes/Up.
2997
+ */
2998
+ outcome_index?: number | null;
2999
+ /** @description Market question */
3000
+ question?: string | null;
3001
+ /** @description Market slug */
3002
+ market_slug?: string | null;
3003
+ /** @description Event slug */
3004
+ event_slug?: string | null;
3005
+ /** @description Trade ID */
3006
+ trade_id: string;
3007
+ /** @description Transaction hash */
3008
+ hash: string;
3009
+ /**
3010
+ * Format: int64
3011
+ * @description Block number
3012
+ */
3013
+ block: number;
3014
+ /**
3015
+ * Format: int64
3016
+ * @description Confirmed timestamp (Unix seconds)
3017
+ */
3018
+ confirmed_at: number;
3019
+ /**
3020
+ * Format: double
3021
+ * @description USD size of the trade
3022
+ */
3023
+ amount_usd: number;
3024
+ /**
3025
+ * Format: double
3026
+ * @description Outcome shares traded
3027
+ */
3028
+ shares_amount: number;
3029
+ /**
3030
+ * Format: double
3031
+ * @description Fee paid (USD)
3032
+ */
3033
+ fee: number;
3034
+ /** @description Trade side ("Buy" or "Sell") */
3035
+ side: string;
3036
+ /**
3037
+ * Format: double
3038
+ * @description Last observed price before this trade (the baseline the crossing is measured from)
3039
+ */
3040
+ previous_price: number;
3041
+ /**
3042
+ * Format: double
3043
+ * @description Price per share (0.0–1.0) that crossed the threshold
3044
+ */
3045
+ price: number;
3046
+ /**
3047
+ * Format: double
3048
+ * @description Implied probability of the outcome (0.0–1.0)
3049
+ */
3050
+ probability?: number | null;
3051
+ /**
3052
+ * @description Crossing direction: `"up"` (crossed up to the `min_probability` target) or
3053
+ * `"down"` (crossed down to the `max_probability` target)
3054
+ */
3055
+ direction: string;
3056
+ /**
3057
+ * Format: double
3058
+ * @description The target threshold from the subscriber's filter that was crossed
3059
+ */
3060
+ threshold: number;
3061
+ };
2054
3062
  /** @description Subscription filters for the `probability_spike` event. */
2055
3063
  ProbabilitySpikeFilters: {
3064
+ /**
3065
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3066
+ * successful delivery. Applies to any webhook event.
3067
+ */
3068
+ one_shot?: boolean | null;
2056
3069
  /** @description Restrict to specific outcome token IDs. Empty = all positions. */
2057
3070
  position_ids?: string[] | null;
2058
3071
  /** @description Restrict to specific market condition IDs. Empty = all markets. */
@@ -2071,6 +3084,10 @@ export interface components {
2071
3084
  * @description Maximum YES probability (0-1).
2072
3085
  */
2073
3086
  max_probability?: number | null;
3087
+ /** @description Restrict to markets carrying any of these tags or category names (case-insensitive). Empty = all. */
3088
+ tags?: string[] | null;
3089
+ /** @description Restrict to markets in any of these series (by slug, case-insensitive). Empty = all. */
3090
+ series_slugs?: string[] | null;
2074
3091
  /**
2075
3092
  * Format: double
2076
3093
  * @description Minimum probability percentage move to trigger (e.g. `10` for a 10% move).
@@ -2097,14 +3114,24 @@ export interface components {
2097
3114
  };
2098
3115
  /** @description Position probability spike webhook payload */
2099
3116
  ProbabilitySpikePayload: {
3117
+ /** @description Outcome token ID. */
2100
3118
  position_id: string;
3119
+ /** @description Market condition ID. */
2101
3120
  condition_id?: string | null;
3121
+ /** @description Market question. */
2102
3122
  question?: string | null;
3123
+ /** @description Market slug. */
2103
3124
  market_slug?: string | null;
3125
+ /** @description Event slug. */
2104
3126
  event_slug?: string | null;
3127
+ /** @description Image URL. */
2105
3128
  image_url?: string | null;
3129
+ /** @description Outcome name. */
2106
3130
  outcome?: string | null;
2107
- /** Format: int32 */
3131
+ /**
3132
+ * Format: int32
3133
+ * @description Outcome index.
3134
+ */
2108
3135
  outcome_index?: number | null;
2109
3136
  /**
2110
3137
  * Format: double
@@ -2415,6 +3442,11 @@ export interface components {
2415
3442
  SpikeDirection: "up" | "down" | "both";
2416
3443
  /** @description Subscription filters for the `tag_metrics` event. All fields are optional. */
2417
3444
  TagMetricsFilters: {
3445
+ /**
3446
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3447
+ * successful delivery. Applies to any webhook event.
3448
+ */
3449
+ one_shot?: boolean | null;
2418
3450
  /** @description Restrict to these tags. Empty = all tags. */
2419
3451
  tags?: string[] | null;
2420
3452
  /** @description Restrict to these aggregation windows. */
@@ -2424,13 +3456,25 @@ export interface components {
2424
3456
  * @description Only fire when aggregated tag volume >= this value (USD).
2425
3457
  */
2426
3458
  min_volume_usd?: number | null;
2427
- /** Format: double */
3459
+ /**
3460
+ * Format: double
3461
+ * @description Maximum volume USD.
3462
+ */
2428
3463
  max_volume_usd?: number | null;
2429
- /** Format: int64 */
3464
+ /**
3465
+ * Format: int64
3466
+ * @description Minimum transactions.
3467
+ */
2430
3468
  min_txns?: number | null;
2431
- /** Format: int64 */
3469
+ /**
3470
+ * Format: int64
3471
+ * @description Minimum unique traders.
3472
+ */
2432
3473
  min_unique_traders?: number | null;
2433
- /** Format: double */
3474
+ /**
3475
+ * Format: double
3476
+ * @description Minimum fees.
3477
+ */
2434
3478
  min_fees?: number | null;
2435
3479
  };
2436
3480
  /** @description Payload delivered when a tag's aggregated volume or transaction metrics cross a configured threshold */
@@ -2508,6 +3552,11 @@ export interface components {
2508
3552
  TradeEventFilterType: "OrderFilled" | "OrdersMatched" | "MakerRebate" | "Reward" | "Yield" | "Redemption" | "Merge" | "Split" | "Cancelled" | "PositionsConverted" | "Initialization" | "Proposal" | "Dispute" | "Settled" | "Resolution" | "ConditionResolution" | "Reset" | "Flag" | "Unflag" | "Pause" | "Unpause" | "ManualResolution" | "NegRiskOutcomeReported" | "RegisterToken";
2509
3553
  /** @description Subscription filters for the `trader_category_pnl` event. All fields are optional. */
2510
3554
  TraderCategoryPnlFilters: {
3555
+ /**
3556
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3557
+ * successful delivery. Applies to any webhook event.
3558
+ */
3559
+ one_shot?: boolean | null;
2511
3560
  /** @description Track only these trader wallet addresses. Empty = all traders. */
2512
3561
  traders?: string[] | null;
2513
3562
  /** @description Restrict to these market categories (e.g. `politics`, `sports`). */
@@ -2557,6 +3606,11 @@ export interface components {
2557
3606
  };
2558
3607
  /** @description Subscription filters for the `trader_pnl_exits` event. All fields are optional. */
2559
3608
  TraderExitMarkersFilters: {
3609
+ /**
3610
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3611
+ * successful delivery. Applies to any webhook event.
3612
+ */
3613
+ one_shot?: boolean | null;
2560
3614
  /** @description Track only these trader wallet addresses. Empty = all traders. */
2561
3615
  traders?: string[] | null;
2562
3616
  /** @description Restrict to these markets. */
@@ -2566,6 +3620,11 @@ export interface components {
2566
3620
  };
2567
3621
  /** @description Subscription filters for the `trader_first_trade` event. All fields are optional. */
2568
3622
  TraderFirstTradeFilters: {
3623
+ /**
3624
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3625
+ * successful delivery. Applies to any webhook event.
3626
+ */
3627
+ one_shot?: boolean | null;
2569
3628
  /** @description Only fire for trades by these wallet addresses (lowercase). Empty = all traders. */
2570
3629
  wallet_addresses?: string[] | null;
2571
3630
  /** @description Restrict to trades in these markets. Empty = all markets. */
@@ -2592,6 +3651,11 @@ export interface components {
2592
3651
  };
2593
3652
  /** @description Subscription filters for the `trader_global_pnl` event. All fields are optional. */
2594
3653
  TraderGlobalPnlFilters: {
3654
+ /**
3655
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3656
+ * successful delivery. Applies to any webhook event.
3657
+ */
3658
+ one_shot?: boolean | null;
2595
3659
  /** @description Track only these trader wallet addresses. Empty = all traders. */
2596
3660
  traders?: string[] | null;
2597
3661
  /**
@@ -2639,6 +3703,11 @@ export interface components {
2639
3703
  };
2640
3704
  /** @description Subscription filters for the `trader_market_pnl` event. All fields are optional. */
2641
3705
  TraderMarketPnlFilters: {
3706
+ /**
3707
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3708
+ * successful delivery. Applies to any webhook event.
3709
+ */
3710
+ one_shot?: boolean | null;
2642
3711
  /** @description Track only these trader wallet addresses. */
2643
3712
  traders?: string[] | null;
2644
3713
  /** @description Restrict to these markets. */
@@ -2682,6 +3751,11 @@ export interface components {
2682
3751
  };
2683
3752
  /** @description Subscription filters for the `trader_new_market` event. All fields are optional. */
2684
3753
  TraderNewMarketFilters: {
3754
+ /**
3755
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3756
+ * successful delivery. Applies to any webhook event.
3757
+ */
3758
+ one_shot?: boolean | null;
2685
3759
  /** @description Only fire for these wallet addresses (lowercase). Empty = all traders. */
2686
3760
  wallet_addresses?: string[] | null;
2687
3761
  /** @description Restrict to these markets. */
@@ -2708,6 +3782,11 @@ export interface components {
2708
3782
  };
2709
3783
  /** @description Subscription filters for the `trader_new_trade` event. All fields are optional. */
2710
3784
  TraderNewTradeFilters: {
3785
+ /**
3786
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3787
+ * successful delivery. Applies to any webhook event.
3788
+ */
3789
+ one_shot?: boolean | null;
2711
3790
  /** @description Only fire for trades by these wallet addresses. Empty = all traders. */
2712
3791
  wallet_addresses?: string[] | null;
2713
3792
  /** @description Restrict to these markets. */
@@ -2736,6 +3815,11 @@ export interface components {
2736
3815
  };
2737
3816
  /** @description Subscription filters for the `trader_position_resolved` event. All fields are optional. */
2738
3817
  TraderPositionResolvedFilters: {
3818
+ /**
3819
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3820
+ * successful delivery. Applies to any webhook event.
3821
+ */
3822
+ one_shot?: boolean | null;
2739
3823
  /** @description Track only these trader wallet addresses. Empty = all traders. */
2740
3824
  traders?: string[] | null;
2741
3825
  /** @description Restrict to these markets. */
@@ -2754,6 +3838,11 @@ export interface components {
2754
3838
  * `event_slug` in the typed webhook payload.
2755
3839
  */
2756
3840
  TraderTradeEventFilters: {
3841
+ /**
3842
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3843
+ * successful delivery. Applies to any webhook event.
3844
+ */
3845
+ one_shot?: boolean | null;
2757
3846
  /** @description Only fire for events associated with these wallet addresses. Empty = all traders. */
2758
3847
  wallet_addresses?: string[] | null;
2759
3848
  /** @description Restrict to these markets. For `PositionsConverted`, this also matches the NegRisk `market_id`. */
@@ -2782,6 +3871,11 @@ export interface components {
2782
3871
  };
2783
3872
  /** @description Subscription filters for the `trader_whale_trade` event. All fields are optional. */
2784
3873
  TraderWhaleTradeFilters: {
3874
+ /**
3875
+ * @description Fire-and-delete: when `true`, delete the subscription after its first
3876
+ * successful delivery. Applies to any webhook event.
3877
+ */
3878
+ one_shot?: boolean | null;
2785
3879
  /** @description Only fire for trades by these wallet addresses. Empty = all traders. */
2786
3880
  wallet_addresses?: string[] | null;
2787
3881
  /** @description Restrict to these markets. */
@@ -2820,7 +3914,9 @@ export interface components {
2820
3914
  };
2821
3915
  /** @description Volume milestone webhook payload */
2822
3916
  VolumeMilestonePayload: {
3917
+ /** @description Market condition ID. */
2823
3918
  condition_id: string;
3919
+ /** @description Metric timeframe. */
2824
3920
  timeframe: string;
2825
3921
  /**
2826
3922
  * Format: double
@@ -2882,8 +3978,16 @@ export interface components {
2882
3978
  position_ids?: string[];
2883
3979
  /** @description Filter by event slugs. Max 500 entries. */
2884
3980
  event_slugs?: string[];
2885
- /** @description Filter by tags or category names (case-insensitive) — for market_created. Max 500 entries. */
3981
+ /**
3982
+ * @description Filter by tags or category names (case-insensitive). Matches a market's tags or its
3983
+ * category label — for market_created and all market-keyed events. Max 500 entries.
3984
+ */
2886
3985
  tags?: string[];
3986
+ /**
3987
+ * @description Filter by series slugs (case-insensitive). Matches a market's parent series — for all
3988
+ * market-keyed events. Max 500 entries.
3989
+ */
3990
+ series_slugs?: string[];
2887
3991
  /** @description Filter by outcomes (e.g. "Yes", "No") — for position metrics / close_to_bond. Max 500 entries. */
2888
3992
  outcomes?: string[];
2889
3993
  /** @description Filter by position outcome index — for close_to_bond. Position 0 = Yes/Up, 1 = No. Max 500 entries. */
@@ -3006,6 +4110,17 @@ export interface components {
3006
4110
  * Valid values: "BTC", "ETH", "SOL", "XRP", "DOGE", "BNB", "HYPE". Empty = all assets (send everything).
3007
4111
  */
3008
4112
  asset_symbols?: components["schemas"]["WebhookAssetSymbol"][];
4113
+ /**
4114
+ * @description Fire-and-delete: delete the subscription after its first successful
4115
+ * delivery. Works on any webhook event. (`price_threshold` additionally
4116
+ * requires `position_ids` or `condition_ids`.)
4117
+ */
4118
+ one_shot?: boolean;
4119
+ /**
4120
+ * @description For `price_threshold` — fire immediately if the first observed price is
4121
+ * already past the target. Default `false` (wait for an actual crossing).
4122
+ */
4123
+ fire_if_already_past?: boolean;
3009
4124
  };
3010
4125
  /** @description List webhooks response */
3011
4126
  WebhookListResponseBody: {
@@ -3189,6 +4304,7 @@ export interface components {
3189
4304
  /**
3190
4305
  * @description CLOB V2 builder code (lower-cased `0x...` bytes32 hex). Absent on V1
3191
4306
  * trades; may be `0x0000…` for V2 trades placed without a builder code.
4307
+ * CLOB builder code.
3192
4308
  */
3193
4309
  builder_code?: string | null;
3194
4310
  /**
@@ -3199,19 +4315,30 @@ export interface components {
3199
4315
  };
3200
4316
  /** @description Server acknowledgement for an oracle events stream subscription */
3201
4317
  OracleEventsStreamSubscribeResponse: {
4318
+ /** @description Accepted market condition IDs. */
3202
4319
  condition_ids?: string[];
4320
+ /** @description Accepted market slugs. */
3203
4321
  market_slugs?: string[];
4322
+ /** @description Accepted event slugs. */
3204
4323
  event_slugs?: string[];
4324
+ /** @description Accepted oracle event types. */
3205
4325
  oracle_event_types?: string[];
3206
- /** @enum {string} */
4326
+ /**
4327
+ * @description Trade status filter.
4328
+ * @enum {string}
4329
+ */
3207
4330
  status?: "confirmed" | "pending" | "all";
4331
+ /** @description Whether to subscribe to all matching events. */
3208
4332
  subscribe_all?: boolean;
3209
4333
  /** @description Filter values that were rejected (invalid format or unknown type) */
3210
4334
  rejected?: string[];
3211
4335
  };
3212
4336
  /** @description Subscribe to the oracle events stream. No filters = subscribe to all events. */
3213
4337
  OracleEventsStreamSubscribeMessage: {
3214
- /** @enum {string} */
4338
+ /**
4339
+ * @description Subscription action.
4340
+ * @enum {string}
4341
+ */
3215
4342
  action: "subscribe" | "unsubscribe_all";
3216
4343
  /** @description 64-char hex condition IDs (with or without 0x prefix) */
3217
4344
  condition_ids?: string[];
@@ -3233,23 +4360,38 @@ export interface components {
3233
4360
  MarketsStreamUpdateEvent: {
3234
4361
  /** @enum {string} */
3235
4362
  type: "markets_stream_update";
3236
- /** @enum {string} */
4363
+ /**
4364
+ * @description WebSocket room ID.
4365
+ * @enum {string}
4366
+ */
3237
4367
  room_id: "polymarket_markets_stream";
3238
- /** @enum {string} */
4368
+ /**
4369
+ * @description Subscription mode.
4370
+ * @enum {string}
4371
+ */
3239
4372
  mode: "filter" | "ids";
3240
- /** @enum {integer} */
4373
+ /**
4374
+ * @description Flush interval in milliseconds.
4375
+ * @enum {integer}
4376
+ */
3241
4377
  interval_ms: 500 | 1000 | 3000 | 10000;
3242
4378
  /** @description Full market rows (same shape as `GET /polymarket/market`). Not a delta — each element is a complete row replacement. */
3243
4379
  data: Record<string, never>[];
3244
4380
  };
3245
4381
  /** @description Server acknowledgement for a markets_stream subscribe/unsubscribe. Envelope type: "markets_stream_subscribe_response". */
3246
4382
  MarketsStreamSubscribeResponse: {
3247
- /** @enum {string} */
4383
+ /**
4384
+ * @description Subscription mode.
4385
+ * @enum {string}
4386
+ */
3248
4387
  mode?: "filter" | "ids" | "";
4388
+ /** @description Flush interval in milliseconds. */
3249
4389
  interval_ms?: number;
3250
4390
  /** @description Accepted condition_ids (ids mode). */
3251
4391
  condition_ids?: string[];
4392
+ /** @description Accepted market slugs. */
3252
4393
  market_slugs?: string[];
4394
+ /** @description Accepted event slugs. */
3253
4395
  event_slugs?: string[];
3254
4396
  /** @description Ids that failed normalization or exceeded the per-sub cap. */
3255
4397
  rejected?: string[];
@@ -3260,21 +4402,39 @@ export interface components {
3260
4402
  MarketsStreamFilter: {
3261
4403
  /** @description Case-insensitive substring match on `title`. 3–100 chars. */
3262
4404
  search?: string;
4405
+ /** @description Categories to include. */
3263
4406
  categories?: string[];
4407
+ /** @description Categories to exclude. */
3264
4408
  exclude_categories?: string[];
4409
+ /** @description Accepted tag slugs. */
3265
4410
  tags?: string[];
4411
+ /** @description Tags to exclude. */
3266
4412
  exclude_tags?: string[];
4413
+ /** @description Minimum volume. */
3267
4414
  min_volume?: number;
4415
+ /** @description Maximum volume. */
3268
4416
  max_volume?: number;
4417
+ /** @description Minimum transaction count. */
3269
4418
  min_txns?: number;
4419
+ /** @description Maximum transaction count. */
3270
4420
  max_txns?: number;
4421
+ /** @description Minimum unique trader count. */
3271
4422
  min_unique_traders?: number;
4423
+ /** @description Maximum unique trader count. */
3272
4424
  max_unique_traders?: number;
4425
+ /** @description Minimum liquidity. */
3273
4426
  min_liquidity?: number;
4427
+ /** @description Maximum liquidity. */
3274
4428
  max_liquidity?: number;
3275
- /** Format: int64 */
4429
+ /**
4430
+ * Format: int64
4431
+ * @description Minimum holder count.
4432
+ */
3276
4433
  min_holders?: number;
3277
- /** Format: int64 */
4434
+ /**
4435
+ * Format: int64
4436
+ * @description Maximum holder count.
4437
+ */
3278
4438
  max_holders?: number;
3279
4439
  /**
3280
4440
  * Format: int64
@@ -3296,7 +4456,10 @@ export interface components {
3296
4456
  };
3297
4457
  /** @description Subscribe to the trades stream. No filters = subscribe to all trades. */
3298
4458
  TradesStreamSubscribeMessage: {
3299
- /** @enum {string} */
4459
+ /**
4460
+ * @description Subscription action.
4461
+ * @enum {string}
4462
+ */
3300
4463
  action: "subscribe" | "unsubscribe_all";
3301
4464
  /** @description 64-char hex condition IDs (with or without 0x prefix) */
3302
4465
  condition_ids?: string[];
@@ -3320,14 +4483,24 @@ export interface components {
3320
4483
  };
3321
4484
  /** @description Server acknowledgement for a trades stream subscription */
3322
4485
  TradesStreamSubscribeResponse: {
4486
+ /** @description Accepted market condition IDs. */
3323
4487
  condition_ids?: string[];
4488
+ /** @description Accepted market slugs. */
3324
4489
  market_slugs?: string[];
4490
+ /** @description Accepted event slugs. */
3325
4491
  event_slugs?: string[];
4492
+ /** @description Accepted outcome token IDs. */
3326
4493
  position_ids?: string[];
4494
+ /** @description Accepted trader wallets. */
3327
4495
  traders?: string[];
4496
+ /** @description Accepted trade types. */
3328
4497
  trade_types?: string[];
3329
- /** @enum {string} */
4498
+ /**
4499
+ * @description Trade status filter.
4500
+ * @enum {string}
4501
+ */
3330
4502
  status?: "confirmed" | "pending" | "all";
4503
+ /** @description Whether to subscribe to all matching events. */
3331
4504
  subscribe_all?: boolean;
3332
4505
  /** @description Filter values that were rejected (invalid format or unknown type) */
3333
4506
  rejected?: string[];
@@ -3340,9 +4513,14 @@ export interface components {
3340
4513
  * **Pending trades:** `block`, `confirmed_at`, `log_index`, `block_index` are absent. `received_at` (milliseconds) is included instead. For OrderFilled/OrdersMatched, `order_hash`, `taker`, `fee`, `fee_shares`, `fee_pct` are also absent.
3341
4514
  */
3342
4515
  TradeStreamEvent: {
3343
- /** @enum {string} */
4516
+ /**
4517
+ * @description Trade type.
4518
+ * @enum {string}
4519
+ */
3344
4520
  trade_type: "OrderFilled" | "OrdersMatched";
4521
+ /** @description Event ID. */
3345
4522
  id: string;
4523
+ /** @description Transaction hash. */
3346
4524
  hash: string;
3347
4525
  /** @description Absent for pending trades */
3348
4526
  block?: number;
@@ -3357,28 +4535,49 @@ export interface components {
3357
4535
  /** @description Absent for pending trades */
3358
4536
  order_hash?: string;
3359
4537
  trader: {
4538
+ /** @description Wallet address. */
3360
4539
  address?: string;
4540
+ /** @description Display name. */
3361
4541
  name?: string | null;
4542
+ /** @description Pseudonym. */
3362
4543
  pseudonym?: string | null;
4544
+ /** @description Profile image URL. */
3363
4545
  profile_image?: string | null;
4546
+ /** @description X username. */
3364
4547
  x_username?: string | null;
4548
+ /** @description Whether the profile is verified. */
3365
4549
  verified_badge?: boolean;
3366
4550
  };
3367
4551
  /** @description Absent for pending trades */
3368
4552
  taker?: string;
3369
- /** @enum {string} */
4553
+ /**
4554
+ * @description Trade side.
4555
+ * @enum {string}
4556
+ */
3370
4557
  side?: "Buy" | "Sell";
4558
+ /** @description Market condition ID. */
3371
4559
  condition_id?: string | null;
4560
+ /** @description Outcome token ID. */
3372
4561
  position_id?: string;
4562
+ /** @description Outcome name. */
3373
4563
  outcome?: string | null;
4564
+ /** @description Outcome index. */
3374
4565
  outcome_index?: number | null;
4566
+ /** @description Market question. */
3375
4567
  question?: string | null;
4568
+ /** @description Image URL. */
3376
4569
  image_url?: string | null;
4570
+ /** @description Market slug. */
3377
4571
  slug?: string | null;
4572
+ /** @description Event slug. */
3378
4573
  event_slug?: string | null;
4574
+ /** @description Trade amount in USD. */
3379
4575
  usd_amount?: number;
4576
+ /** @description Trade size in shares. */
3380
4577
  shares_amount?: number;
4578
+ /** @description Outcome price. */
3381
4579
  price?: number;
4580
+ /** @description Implied probability. */
3382
4581
  probability?: number | null;
3383
4582
  /** @description Absent for pending trades */
3384
4583
  fee?: number;
@@ -3386,31 +4585,49 @@ export interface components {
3386
4585
  fee_shares?: number;
3387
4586
  /** @description Absent for pending trades */
3388
4587
  fee_pct?: number;
4588
+ /** @description Exchange identifier. */
3389
4589
  exchange: number;
3390
4590
  /** @description CLOB V2 builder code (lower-cased `0x...` bytes32 hex). Absent on V1 trades; may be `0x0000…` for V2 trades placed without a builder code. */
3391
4591
  builder_code?: string;
3392
4592
  /** @description Builder fee in USDC. Absent when no builder code is attached. */
3393
4593
  builder_fee?: number;
3394
4594
  } | {
3395
- /** @enum {string} */
4595
+ /**
4596
+ * @description Trade type.
4597
+ * @enum {string}
4598
+ */
3396
4599
  trade_type: "MakerRebate" | "Reward" | "Yield";
4600
+ /** @description Event ID. */
3397
4601
  id: string;
4602
+ /** @description Transaction hash. */
3398
4603
  hash: string;
4604
+ /** @description Block number. */
3399
4605
  block?: number;
4606
+ /** @description Confirmation timestamp. */
3400
4607
  confirmed_at?: number;
4608
+ /** @description Receive timestamp. */
3401
4609
  received_at?: number;
4610
+ /** @description Log index. */
3402
4611
  log_index?: number;
4612
+ /** @description Block index. */
3403
4613
  block_index?: number;
3404
4614
  trader: {
4615
+ /** @description Wallet address. */
3405
4616
  address?: string;
4617
+ /** @description Display name. */
3406
4618
  name?: string | null;
4619
+ /** @description Pseudonym. */
3407
4620
  pseudonym?: string | null;
4621
+ /** @description Profile image URL. */
3408
4622
  profile_image?: string | null;
4623
+ /** @description X username. */
3409
4624
  x_username?: string | null;
4625
+ /** @description Whether the profile is verified. */
3410
4626
  verified_badge?: boolean;
3411
4627
  };
3412
4628
  /** @description Payout distributor address */
3413
4629
  taker?: string;
4630
+ /** @description Trade amount in USD. */
3414
4631
  usd_amount?: number;
3415
4632
  /** @description Always 0 for payout credits */
3416
4633
  shares_amount?: number;
@@ -3425,195 +4642,370 @@ export interface components {
3425
4642
  /** @description Unknown/non-exchange credit source */
3426
4643
  exchange: number;
3427
4644
  } | {
3428
- /** @enum {string} */
4645
+ /**
4646
+ * @description Trade type.
4647
+ * @enum {string}
4648
+ */
3429
4649
  trade_type: "Redemption";
4650
+ /** @description Event ID. */
3430
4651
  id: string;
4652
+ /** @description Transaction hash. */
3431
4653
  hash: string;
4654
+ /** @description Block number. */
3432
4655
  block?: number;
4656
+ /** @description Confirmation timestamp. */
3433
4657
  confirmed_at?: number;
4658
+ /** @description Receive timestamp. */
3434
4659
  received_at?: number;
4660
+ /** @description Log index. */
3435
4661
  log_index?: number;
4662
+ /** @description Block index. */
3436
4663
  block_index?: number;
3437
4664
  trader: {
4665
+ /** @description Wallet address. */
3438
4666
  address?: string;
4667
+ /** @description Display name. */
3439
4668
  name?: string | null;
4669
+ /** @description Pseudonym. */
3440
4670
  pseudonym?: string | null;
4671
+ /** @description Profile image URL. */
3441
4672
  profile_image?: string | null;
4673
+ /** @description X username. */
3442
4674
  x_username?: string | null;
4675
+ /** @description Whether the profile is verified. */
3443
4676
  verified_badge?: boolean;
3444
4677
  };
4678
+ /** @description Market condition ID. */
3445
4679
  condition_id?: string | null;
4680
+ /** @description Outcome name. */
3446
4681
  outcome?: string | null;
4682
+ /** @description Outcome index. */
3447
4683
  outcome_index?: number | null;
4684
+ /** @description Market question. */
3448
4685
  question?: string | null;
4686
+ /** @description Image URL. */
3449
4687
  image_url?: string | null;
4688
+ /** @description Market slug. */
3450
4689
  slug?: string | null;
4690
+ /** @description Event slug. */
3451
4691
  event_slug?: string | null;
4692
+ /** @description Trade amount in USD. */
3452
4693
  usd_amount?: number;
4694
+ /** @description Winning outcome index. */
3453
4695
  winning_outcome_index?: number | null;
4696
+ /** @description Position details. */
3454
4697
  position_details?: {
4698
+ /** @description Outcome token ID. */
3455
4699
  position_id?: string;
4700
+ /** @description Outcome index. */
3456
4701
  outcome_index?: number;
4702
+ /** @description Amount as a decimal string. */
3457
4703
  amount?: string;
3458
4704
  }[];
4705
+ /** @description Exchange identifier. */
3459
4706
  exchange: number;
3460
4707
  } | {
3461
- /** @enum {string} */
4708
+ /**
4709
+ * @description Trade type.
4710
+ * @enum {string}
4711
+ */
3462
4712
  trade_type: "Merge";
4713
+ /** @description Event ID. */
3463
4714
  id: string;
4715
+ /** @description Transaction hash. */
3464
4716
  hash: string;
4717
+ /** @description Block number. */
3465
4718
  block?: number;
4719
+ /** @description Confirmation timestamp. */
3466
4720
  confirmed_at?: number;
4721
+ /** @description Receive timestamp. */
3467
4722
  received_at?: number;
4723
+ /** @description Log index. */
3468
4724
  log_index?: number;
4725
+ /** @description Block index. */
3469
4726
  block_index?: number;
3470
4727
  trader: {
4728
+ /** @description Wallet address. */
3471
4729
  address?: string;
4730
+ /** @description Display name. */
3472
4731
  name?: string | null;
4732
+ /** @description Pseudonym. */
3473
4733
  pseudonym?: string | null;
4734
+ /** @description Profile image URL. */
3474
4735
  profile_image?: string | null;
4736
+ /** @description X username. */
3475
4737
  x_username?: string | null;
4738
+ /** @description Whether the profile is verified. */
3476
4739
  verified_badge?: boolean;
3477
4740
  };
4741
+ /** @description Market condition ID. */
3478
4742
  condition_id?: string | null;
4743
+ /** @description Market question. */
3479
4744
  question?: string | null;
4745
+ /** @description Image URL. */
3480
4746
  image_url?: string | null;
4747
+ /** @description Market slug. */
3481
4748
  slug?: string | null;
4749
+ /** @description Event slug. */
3482
4750
  event_slug?: string | null;
4751
+ /** @description Trade amount in USD. */
3483
4752
  usd_amount?: number;
4753
+ /** @description Position details. */
3484
4754
  position_details?: {
4755
+ /** @description Outcome token ID. */
3485
4756
  position_id?: string;
4757
+ /** @description Outcome index. */
3486
4758
  outcome_index?: number;
4759
+ /** @description Amount as a decimal string. */
3487
4760
  amount?: string;
3488
4761
  }[];
4762
+ /** @description Exchange identifier. */
3489
4763
  exchange: number;
3490
4764
  } | {
3491
- /** @enum {string} */
4765
+ /**
4766
+ * @description Trade type.
4767
+ * @enum {string}
4768
+ */
3492
4769
  trade_type: "Split";
4770
+ /** @description Event ID. */
3493
4771
  id: string;
4772
+ /** @description Transaction hash. */
3494
4773
  hash: string;
4774
+ /** @description Block number. */
3495
4775
  block?: number;
4776
+ /** @description Confirmation timestamp. */
3496
4777
  confirmed_at?: number;
4778
+ /** @description Receive timestamp. */
3497
4779
  received_at?: number;
4780
+ /** @description Log index. */
3498
4781
  log_index?: number;
4782
+ /** @description Block index. */
3499
4783
  block_index?: number;
3500
4784
  trader: {
4785
+ /** @description Wallet address. */
3501
4786
  address?: string;
4787
+ /** @description Display name. */
3502
4788
  name?: string | null;
4789
+ /** @description Pseudonym. */
3503
4790
  pseudonym?: string | null;
4791
+ /** @description Profile image URL. */
3504
4792
  profile_image?: string | null;
4793
+ /** @description X username. */
3505
4794
  x_username?: string | null;
4795
+ /** @description Whether the profile is verified. */
3506
4796
  verified_badge?: boolean;
3507
4797
  };
4798
+ /** @description Market condition ID. */
3508
4799
  condition_id?: string | null;
4800
+ /** @description Market question. */
3509
4801
  question?: string | null;
4802
+ /** @description Image URL. */
3510
4803
  image_url?: string | null;
4804
+ /** @description Market slug. */
3511
4805
  slug?: string | null;
4806
+ /** @description Event slug. */
3512
4807
  event_slug?: string | null;
4808
+ /** @description Trade amount in USD. */
3513
4809
  usd_amount?: number;
4810
+ /** @description Position details. */
3514
4811
  position_details?: {
4812
+ /** @description Outcome token ID. */
3515
4813
  position_id?: string;
4814
+ /** @description Outcome index. */
3516
4815
  outcome_index?: number;
4816
+ /** @description Amount as a decimal string. */
3517
4817
  amount?: string;
3518
4818
  }[];
4819
+ /** @description Exchange identifier. */
3519
4820
  exchange: number;
3520
4821
  } | {
3521
- /** @enum {string} */
4822
+ /**
4823
+ * @description Trade type.
4824
+ * @enum {string}
4825
+ */
3522
4826
  trade_type: "PositionsConverted";
4827
+ /** @description Event ID. */
3523
4828
  id: string;
4829
+ /** @description Transaction hash. */
3524
4830
  hash: string;
4831
+ /** @description Block number. */
3525
4832
  block?: number;
4833
+ /** @description Confirmation timestamp. */
3526
4834
  confirmed_at?: number;
4835
+ /** @description Receive timestamp. */
3527
4836
  received_at?: number;
4837
+ /** @description Log index. */
3528
4838
  log_index?: number;
4839
+ /** @description Block index. */
3529
4840
  block_index?: number;
3530
4841
  trader: {
4842
+ /** @description Wallet address. */
3531
4843
  address?: string;
4844
+ /** @description Display name. */
3532
4845
  name?: string | null;
4846
+ /** @description Pseudonym. */
3533
4847
  pseudonym?: string | null;
4848
+ /** @description Profile image URL. */
3534
4849
  profile_image?: string | null;
4850
+ /** @description X username. */
3535
4851
  x_username?: string | null;
4852
+ /** @description Whether the profile is verified. */
3536
4853
  verified_badge?: boolean;
3537
4854
  };
4855
+ /** @description Market id. */
3538
4856
  market_id?: string;
4857
+ /** @description Index set. */
3539
4858
  index_set?: string;
4859
+ /** @description Trade size in shares. */
3540
4860
  shares_amount?: number;
4861
+ /** @description Fee. */
3541
4862
  fee?: number;
4863
+ /** @description Fee percent. */
3542
4864
  fee_pct?: number;
3543
4865
  /** @description Per-position conversion amounts */
3544
4866
  position_details?: {
4867
+ /** @description Outcome token ID. */
3545
4868
  position_id?: string;
4869
+ /** @description Outcome index. */
3546
4870
  outcome_index?: number;
4871
+ /** @description Amount as a decimal string. */
3547
4872
  amount?: string;
3548
4873
  }[];
4874
+ /** @description Exchange identifier. */
3549
4875
  exchange: number;
3550
4876
  } | {
3551
- /** @enum {string} */
4877
+ /**
4878
+ * @description Trade type.
4879
+ * @enum {string}
4880
+ */
3552
4881
  trade_type: "Cancelled";
4882
+ /** @description Event ID. */
3553
4883
  id: string;
4884
+ /** @description Transaction hash. */
3554
4885
  hash: string;
4886
+ /** @description Block number. */
3555
4887
  block?: number;
4888
+ /** @description Confirmation timestamp. */
3556
4889
  confirmed_at?: number;
4890
+ /** @description Receive timestamp. */
3557
4891
  received_at?: number;
4892
+ /** @description Log index. */
3558
4893
  log_index?: number;
4894
+ /** @description Block index. */
3559
4895
  block_index?: number;
4896
+ /** @description Order hash. */
3560
4897
  order_hash?: string;
4898
+ /** @description Market question. */
3561
4899
  question?: string | null;
4900
+ /** @description Image URL. */
3562
4901
  image_url?: string | null;
4902
+ /** @description Market slug. */
3563
4903
  slug?: string | null;
4904
+ /** @description Event slug. */
3564
4905
  event_slug?: string | null;
4906
+ /** @description Exchange identifier. */
3565
4907
  exchange: number;
3566
4908
  } | {
3567
- /** @enum {string} */
4909
+ /**
4910
+ * @description Oracle lifecycle event type.
4911
+ * @enum {string}
4912
+ */
3568
4913
  trade_type: "Initialization" | "Proposal" | "Dispute" | "Settled" | "Resolution" | "ConditionResolution" | "Reset" | "Flag" | "Unflag" | "Pause" | "Unpause" | "ManualResolution" | "NegRiskOutcomeReported";
4914
+ /** @description Event ID. */
3569
4915
  id: string;
4916
+ /** @description Transaction hash. */
3570
4917
  hash: string;
4918
+ /** @description Block number. */
3571
4919
  block?: number;
4920
+ /** @description Confirmation timestamp. */
3572
4921
  confirmed_at?: number;
4922
+ /** @description Receive timestamp. */
3573
4923
  received_at?: number;
4924
+ /** @description Log index. */
3574
4925
  log_index?: number;
4926
+ /** @description Block index. */
3575
4927
  block_index?: number;
4928
+ /** @description Oracle contract. */
3576
4929
  oracle_contract: string;
4930
+ /** @description Market condition ID. */
3577
4931
  condition_id: string;
4932
+ /** @description Market question. */
3578
4933
  question?: string | null;
4934
+ /** @description Image URL. */
3579
4935
  image_url?: string | null;
4936
+ /** @description Market slug. */
3580
4937
  slug?: string | null;
4938
+ /** @description Event slug. */
3581
4939
  event_slug?: string | null;
4940
+ /** @description Assertion id. */
3582
4941
  assertion_id?: string | null;
4942
+ /** @description Proposer. */
3583
4943
  proposer?: string | null;
4944
+ /** @description Disputer. */
3584
4945
  disputer?: string | null;
4946
+ /** @description Proposed outcome. */
3585
4947
  proposed_outcome?: string | null;
4948
+ /** @description Settled price. */
3586
4949
  settled_price?: number | null;
4950
+ /** @description Disputed. */
3587
4951
  disputed?: boolean | null;
4952
+ /** @description Settlement resolution. */
3588
4953
  settlement_resolution?: boolean | null;
4954
+ /** @description Bond. */
3589
4955
  bond?: string | null;
4956
+ /** @description Expiration time. */
3590
4957
  expiration_time?: number | null;
4958
+ /** @description Creator. */
3591
4959
  creator?: string | null;
4960
+ /** @description Reward token. */
3592
4961
  reward_token?: string | null;
4962
+ /** @description Reward details. */
3593
4963
  reward?: string | null;
4964
+ /** @description Proposal bond. */
3594
4965
  proposal_bond?: string | null;
3595
4966
  } | {
3596
- /** @enum {string} */
4967
+ /**
4968
+ * @description Trade type.
4969
+ * @enum {string}
4970
+ */
3597
4971
  trade_type: "RegisterToken";
4972
+ /** @description Event ID. */
3598
4973
  id: string;
4974
+ /** @description Transaction hash. */
3599
4975
  hash: string;
4976
+ /** @description Block number. */
3600
4977
  block?: number;
4978
+ /** @description Confirmation timestamp. */
3601
4979
  confirmed_at?: number;
4980
+ /** @description Receive timestamp. */
3602
4981
  received_at?: number;
4982
+ /** @description Log index. */
3603
4983
  log_index?: number;
4984
+ /** @description Block index. */
3604
4985
  block_index?: number;
4986
+ /** @description Market condition ID. */
3605
4987
  condition_id: string;
4988
+ /** @description Token0. */
3606
4989
  token0?: string;
4990
+ /** @description Token1. */
3607
4991
  token1?: string;
4992
+ /** @description Market question. */
3608
4993
  question?: string | null;
4994
+ /** @description Image URL. */
3609
4995
  image_url?: string | null;
4996
+ /** @description Market slug. */
3610
4997
  slug?: string | null;
4998
+ /** @description Event slug. */
3611
4999
  event_slug?: string | null;
5000
+ /** @description Exchange identifier. */
3612
5001
  exchange: number;
3613
5002
  };
3614
5003
  /** @description Subscribe to the asset prices stream. Empty asset_symbols = all assets. */
3615
5004
  AssetPricesSubscribeMessage: {
3616
- /** @enum {string} */
5005
+ /**
5006
+ * @description Subscription action.
5007
+ * @enum {string}
5008
+ */
3617
5009
  action: "subscribe" | "unsubscribe_all";
3618
5010
  /** @description Uppercase asset symbols (BTC, ETH, SOL, XRP, DOGE, BNB, HYPE). Empty = subscribe to all. */
3619
5011
  asset_symbols?: string[];
@@ -3674,7 +5066,10 @@ export interface components {
3674
5066
  };
3675
5067
  /** @description Subscribe to the asset window updates stream. At least one of asset_symbols or timeframes must be non-empty. */
3676
5068
  AssetWindowUpdatesSubscribeMessage: {
3677
- /** @enum {string} */
5069
+ /**
5070
+ * @description Subscription action.
5071
+ * @enum {string}
5072
+ */
3678
5073
  action: "subscribe" | "unsubscribe_all";
3679
5074
  /** @description Uppercase asset symbols (BTC, ETH, SOL, XRP, DOGE, BNB, HYPE) */
3680
5075
  asset_symbols?: string[];
@@ -3683,7 +5078,9 @@ export interface components {
3683
5078
  };
3684
5079
  /** @description Server acknowledgement for an asset window updates subscription */
3685
5080
  AssetWindowUpdatesSubscribeResponse: {
5081
+ /** @description Accepted asset symbols. */
3686
5082
  asset_symbols?: string[];
5083
+ /** @description Accepted metric timeframes. */
3687
5084
  timeframes?: string[];
3688
5085
  /** @description Set if the subscription was rejected (e.g. no filters provided) */
3689
5086
  error?: string | null;
@@ -3692,15 +5089,21 @@ export interface components {
3692
5089
  AssetWindowUpdateEvent: components["schemas"]["AssetPriceWindowUpdateEvent"];
3693
5090
  /** @description Subscribe to the market metrics stream. condition_ids is required and must be non-empty. */
3694
5091
  MarketMetricsSubscribeMessage: {
3695
- /** @enum {string} */
5092
+ /**
5093
+ * @description Subscription action.
5094
+ * @enum {string}
5095
+ */
3696
5096
  action: "subscribe" | "unsubscribe_all";
3697
5097
  /** @description 64-char hex condition IDs (with or without 0x prefix) */
3698
5098
  condition_ids: string[];
5099
+ /** @description Accepted metric timeframes. */
3699
5100
  timeframes?: ("1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime")[];
3700
5101
  };
3701
5102
  /** @description Server acknowledgement for a market metrics subscription */
3702
5103
  MarketMetricsSubscribeResponse: {
5104
+ /** @description Accepted market condition IDs. */
3703
5105
  condition_ids?: string[];
5106
+ /** @description Accepted metric timeframes. */
3704
5107
  timeframes?: string[];
3705
5108
  /** @description Condition IDs that were rejected (invalid format) */
3706
5109
  rejected?: string[];
@@ -3711,7 +5114,10 @@ export interface components {
3711
5114
  MarketMetricsEvent: {
3712
5115
  /** @description 64-char hex condition ID */
3713
5116
  condition_id: string;
3714
- /** @enum {string} */
5117
+ /**
5118
+ * @description Metric timeframe.
5119
+ * @enum {string}
5120
+ */
3715
5121
  timeframe: "1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime";
3716
5122
  /**
3717
5123
  * Format: int64
@@ -3740,34 +5146,58 @@ export interface components {
3740
5146
  * @description Builder-attributed transactions
3741
5147
  */
3742
5148
  builder_txns: number;
3743
- /** Format: int64 */
5149
+ /**
5150
+ * Format: int64
5151
+ * @description Unique trader count.
5152
+ */
3744
5153
  unique_traders: number;
3745
- /** Format: int64 */
5154
+ /**
5155
+ * Format: int64
5156
+ * @description Unique maker count.
5157
+ */
3746
5158
  unique_makers: number;
3747
- /** Format: int64 */
5159
+ /**
5160
+ * Format: int64
5161
+ * @description Unique taker count.
5162
+ */
3748
5163
  unique_takers: number;
3749
- /** Format: int64 */
5164
+ /**
5165
+ * Format: int64
5166
+ * @description Unique builder-attributed trader count.
5167
+ */
3750
5168
  unique_builder_traders: number;
3751
5169
  };
3752
5170
  /** @description Subscribe to the event metrics stream. event_slugs is required and must be non-empty. */
3753
5171
  EventMetricsSubscribeMessage: {
3754
- /** @enum {string} */
5172
+ /**
5173
+ * @description Subscription action.
5174
+ * @enum {string}
5175
+ */
3755
5176
  action: "subscribe" | "unsubscribe_all";
3756
5177
  /** @description Event slugs (lowercase) */
3757
5178
  event_slugs: string[];
5179
+ /** @description Accepted metric timeframes. */
3758
5180
  timeframes?: ("1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime")[];
3759
5181
  };
3760
5182
  /** @description Server acknowledgement for an event metrics subscription */
3761
5183
  EventMetricsSubscribeResponse: {
5184
+ /** @description Accepted event slugs. */
3762
5185
  event_slugs?: string[];
5186
+ /** @description Accepted metric timeframes. */
3763
5187
  timeframes?: string[];
5188
+ /** @description Rejected filter values. */
3764
5189
  rejected?: string[];
5190
+ /** @description Subscription error message. */
3765
5191
  error?: string | null;
3766
5192
  };
3767
5193
  /** @description Server-pushed event: aggregated metrics update for one timeframe of an event. Envelope type: "event_metrics_update". One event is emitted per timeframe window on each update. */
3768
5194
  EventMetricsEvent: {
5195
+ /** @description Event slug. */
3769
5196
  event_slug: string;
3770
- /** @enum {string} */
5197
+ /**
5198
+ * @description Metric timeframe.
5199
+ * @enum {string}
5200
+ */
3771
5201
  timeframe: "1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime";
3772
5202
  /**
3773
5203
  * Format: int64
@@ -3782,40 +5212,72 @@ export interface components {
3782
5212
  builder_usd_volume: string;
3783
5213
  /** @description Builder-attributed shares/contracts volume in this timeframe window (decimal string) */
3784
5214
  builder_shares_volume: string;
5215
+ /** @description Total fees. */
3785
5216
  fees: number;
5217
+ /** @description Builder-attributed fees. */
3786
5218
  builder_fees: number;
3787
- /** Format: int64 */
5219
+ /**
5220
+ * Format: int64
5221
+ * @description Transaction count.
5222
+ */
3788
5223
  txns: number;
3789
- /** Format: int64 */
5224
+ /**
5225
+ * Format: int64
5226
+ * @description Builder-attributed transaction count.
5227
+ */
3790
5228
  builder_txns: number;
3791
- /** Format: int64 */
5229
+ /**
5230
+ * Format: int64
5231
+ * @description Unique trader count.
5232
+ */
3792
5233
  unique_traders: number;
3793
- /** Format: int64 */
5234
+ /**
5235
+ * Format: int64
5236
+ * @description Unique maker count.
5237
+ */
3794
5238
  unique_makers: number;
3795
- /** Format: int64 */
5239
+ /**
5240
+ * Format: int64
5241
+ * @description Unique taker count.
5242
+ */
3796
5243
  unique_takers: number;
3797
- /** Format: int64 */
5244
+ /**
5245
+ * Format: int64
5246
+ * @description Unique builder-attributed trader count.
5247
+ */
3798
5248
  unique_builder_traders: number;
3799
5249
  };
3800
5250
  /** @description Subscribe to the tag metrics stream. tags is required and must be non-empty. */
3801
5251
  TagMetricsSubscribeMessage: {
3802
- /** @enum {string} */
5252
+ /**
5253
+ * @description Subscription action.
5254
+ * @enum {string}
5255
+ */
3803
5256
  action: "subscribe" | "unsubscribe_all";
3804
5257
  /** @description Tag labels or slugs, matched case-insensitively */
3805
5258
  tags: string[];
5259
+ /** @description Accepted metric timeframes. */
3806
5260
  timeframes?: ("1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime")[];
3807
5261
  };
3808
5262
  /** @description Server acknowledgement for a tag metrics subscription */
3809
5263
  TagMetricsSubscribeResponse: {
5264
+ /** @description Accepted tag slugs. */
3810
5265
  tags?: string[];
5266
+ /** @description Accepted metric timeframes. */
3811
5267
  timeframes?: string[];
5268
+ /** @description Rejected filter values. */
3812
5269
  rejected?: string[];
5270
+ /** @description Subscription error message. */
3813
5271
  error?: string | null;
3814
5272
  };
3815
5273
  /** @description Server-pushed event: aggregated metrics update for one timeframe of a tag. Envelope type: "tag_metrics_update". One event is emitted per timeframe window on each update. */
3816
5274
  TagMetricsEvent: {
5275
+ /** @description Tag slug. */
3817
5276
  tag: string;
3818
- /** @enum {string} */
5277
+ /**
5278
+ * @description Metric timeframe.
5279
+ * @enum {string}
5280
+ */
3819
5281
  timeframe: "1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime";
3820
5282
  /**
3821
5283
  * Format: int64
@@ -3830,34 +5292,62 @@ export interface components {
3830
5292
  builder_usd_volume: string;
3831
5293
  /** @description Builder-attributed shares/contracts volume in this timeframe window (decimal string) */
3832
5294
  builder_shares_volume: string;
5295
+ /** @description Total fees. */
3833
5296
  fees: number;
5297
+ /** @description Builder-attributed fees. */
3834
5298
  builder_fees: number;
3835
- /** Format: int64 */
5299
+ /**
5300
+ * Format: int64
5301
+ * @description Transaction count.
5302
+ */
3836
5303
  txns: number;
3837
- /** Format: int64 */
5304
+ /**
5305
+ * Format: int64
5306
+ * @description Builder-attributed transaction count.
5307
+ */
3838
5308
  builder_txns: number;
3839
- /** Format: int64 */
5309
+ /**
5310
+ * Format: int64
5311
+ * @description Unique trader count.
5312
+ */
3840
5313
  unique_traders: number;
3841
- /** Format: int64 */
5314
+ /**
5315
+ * Format: int64
5316
+ * @description Unique maker count.
5317
+ */
3842
5318
  unique_makers: number;
3843
- /** Format: int64 */
5319
+ /**
5320
+ * Format: int64
5321
+ * @description Unique taker count.
5322
+ */
3844
5323
  unique_takers: number;
3845
- /** Format: int64 */
5324
+ /**
5325
+ * Format: int64
5326
+ * @description Unique builder-attributed trader count.
5327
+ */
3846
5328
  unique_builder_traders: number;
3847
5329
  };
3848
5330
  /** @description Subscribe to the position metrics stream. position_ids is required and must be non-empty. */
3849
5331
  PositionMetricsSubscribeMessage: {
3850
- /** @enum {string} */
5332
+ /**
5333
+ * @description Subscription action.
5334
+ * @enum {string}
5335
+ */
3851
5336
  action: "subscribe" | "unsubscribe_all";
3852
5337
  /** @description ERC-1155 outcome token IDs (decimal or hex strings) */
3853
5338
  position_ids: string[];
5339
+ /** @description Accepted metric timeframes. */
3854
5340
  timeframes?: ("1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime")[];
3855
5341
  };
3856
5342
  /** @description Server acknowledgement for a position metrics subscription */
3857
5343
  PositionMetricsSubscribeResponse: {
5344
+ /** @description Accepted outcome token IDs. */
3858
5345
  position_ids?: string[];
5346
+ /** @description Accepted metric timeframes. */
3859
5347
  timeframes?: string[];
5348
+ /** @description Rejected filter values. */
3860
5349
  rejected?: string[];
5350
+ /** @description Subscription error message. */
3861
5351
  error?: string | null;
3862
5352
  };
3863
5353
  /** @description Server-pushed event: metrics update for one timeframe of an outcome token. Envelope type: "position_metrics_update". One event is emitted per timeframe window on each update. */
@@ -3868,8 +5358,12 @@ export interface components {
3868
5358
  position_id: string;
3869
5359
  /** @description Outcome name (e.g. "Yes") */
3870
5360
  outcome?: string | null;
5361
+ /** @description Outcome index. */
3871
5362
  outcome_index?: number | null;
3872
- /** @enum {string} */
5363
+ /**
5364
+ * @description Metric timeframe.
5365
+ * @enum {string}
5366
+ */
3873
5367
  timeframe: "1m" | "5m" | "30m" | "1h" | "6h" | "24h" | "7d" | "30d" | "lifetime";
3874
5368
  /**
3875
5369
  * Format: int64
@@ -3900,27 +5394,59 @@ export interface components {
3900
5394
  builder_shares_buy_volume: string;
3901
5395
  /** @description Builder-attributed sell shares/contracts volume (decimal string) */
3902
5396
  builder_shares_sell_volume: string;
5397
+ /** @description Total fees. */
3903
5398
  fees: number;
5399
+ /** @description Builder-attributed fees. */
3904
5400
  builder_fees: number;
3905
- /** Format: int64 */
5401
+ /**
5402
+ * Format: int64
5403
+ * @description Transaction count.
5404
+ */
3906
5405
  txns: number;
3907
- /** Format: int64 */
5406
+ /**
5407
+ * Format: int64
5408
+ * @description Buy count.
5409
+ */
3908
5410
  buys: number;
3909
- /** Format: int64 */
5411
+ /**
5412
+ * Format: int64
5413
+ * @description Sell count.
5414
+ */
3910
5415
  sells: number;
3911
- /** Format: int64 */
5416
+ /**
5417
+ * Format: int64
5418
+ * @description Builder-attributed transaction count.
5419
+ */
3912
5420
  builder_txns: number;
3913
- /** Format: int64 */
5421
+ /**
5422
+ * Format: int64
5423
+ * @description Builder-attributed buy count.
5424
+ */
3914
5425
  builder_buys: number;
3915
- /** Format: int64 */
5426
+ /**
5427
+ * Format: int64
5428
+ * @description Builder-attributed sell count.
5429
+ */
3916
5430
  builder_sells: number;
3917
- /** Format: int64 */
5431
+ /**
5432
+ * Format: int64
5433
+ * @description Unique trader count.
5434
+ */
3918
5435
  unique_traders: number;
3919
- /** Format: int64 */
5436
+ /**
5437
+ * Format: int64
5438
+ * @description Unique maker count.
5439
+ */
3920
5440
  unique_makers: number;
3921
- /** Format: int64 */
5441
+ /**
5442
+ * Format: int64
5443
+ * @description Unique taker count.
5444
+ */
3922
5445
  unique_takers: number;
3923
- /** Format: int64 */
5446
+ /**
5447
+ * Format: int64
5448
+ * @description Unique builder-attributed trader count.
5449
+ */
3924
5450
  unique_builder_traders: number;
3925
5451
  /** @description OHLC open price (0–1) */
3926
5452
  price_open: number;
@@ -3938,13 +5464,85 @@ export interface components {
3938
5464
  probability_high: number;
3939
5465
  /** @description Lowest implied probability in window (0–1) */
3940
5466
  probability_low: number;
5467
+ /** @description Average shares per trade. */
3941
5468
  avg_trade_shares: number;
5469
+ /** @description Average shares per buy. */
3942
5470
  avg_buy_shares: number;
5471
+ /** @description Average shares per sell. */
3943
5472
  avg_sell_shares: number;
3944
5473
  };
5474
+ /** @description Subscribe to the position liquidity stream. position_ids is optional — omit for firehose. */
5475
+ PositionLiquiditySubscribeMessage: {
5476
+ /**
5477
+ * @description Subscription action.
5478
+ * @enum {string}
5479
+ */
5480
+ action: "subscribe" | "unsubscribe_all";
5481
+ /** @description ERC-1155 outcome token IDs (decimal or hex). Empty/omitted = all positions. */
5482
+ position_ids?: string[];
5483
+ };
5484
+ /** @description Server-pushed event: latest USD liquidity for an outcome token. Envelope type: "position_liquidity_update". */
5485
+ PositionLiquidityEvent: {
5486
+ /** @description ERC-1155 token ID (decimal string) */
5487
+ position_id: string;
5488
+ /** @description Order-book liquidity in USD */
5489
+ liquidity_usd: number;
5490
+ /**
5491
+ * Format: int64
5492
+ * @description Update timestamp (Unix millis)
5493
+ */
5494
+ liquidity_updated_at: number;
5495
+ };
5496
+ /** @description Subscribe to the market liquidity stream. condition_ids is optional — omit for firehose. */
5497
+ MarketLiquiditySubscribeMessage: {
5498
+ /**
5499
+ * @description Subscription action.
5500
+ * @enum {string}
5501
+ */
5502
+ action: "subscribe" | "unsubscribe_all";
5503
+ /** @description 64-char hex market IDs. Empty/omitted = all markets. */
5504
+ condition_ids?: string[];
5505
+ };
5506
+ /** @description Server-pushed event: latest total USD liquidity for a market. Envelope type: "market_liquidity_update". */
5507
+ MarketLiquidityEvent: {
5508
+ /** @description 64-char hex condition ID */
5509
+ condition_id: string;
5510
+ /** @description Total order-book liquidity in USD */
5511
+ liquidity_usd: number;
5512
+ /**
5513
+ * Format: int64
5514
+ * @description Update timestamp (Unix millis)
5515
+ */
5516
+ liquidity_updated_at: number;
5517
+ };
5518
+ /** @description Subscribe to the event liquidity stream. event_slugs is optional — omit for firehose. */
5519
+ EventLiquiditySubscribeMessage: {
5520
+ /**
5521
+ * @description Subscription action.
5522
+ * @enum {string}
5523
+ */
5524
+ action: "subscribe" | "unsubscribe_all";
5525
+ /** @description Event slugs. Empty/omitted = all events. */
5526
+ event_slugs?: string[];
5527
+ };
5528
+ /** @description Server-pushed event: latest total USD liquidity for an event. Envelope type: "event_liquidity_update". */
5529
+ EventLiquidityEvent: {
5530
+ /** @description Event slug */
5531
+ event_slug: string;
5532
+ /** @description Total order-book liquidity in USD */
5533
+ liquidity_usd: number;
5534
+ /**
5535
+ * Format: int64
5536
+ * @description Update timestamp (Unix millis)
5537
+ */
5538
+ liquidity_updated_at: number;
5539
+ };
3945
5540
  /** @description Subscribe to the trader PnL stream. `traders` is required and must be non-empty. `update_types` and `timeframes` are optional narrowing filters — omit or leave empty to receive all update types / timeframes. */
3946
5541
  TraderPnlSubscribeMessage: {
3947
- /** @enum {string} */
5542
+ /**
5543
+ * @description Subscription action.
5544
+ * @enum {string}
5545
+ */
3948
5546
  action: "subscribe" | "unsubscribe_all";
3949
5547
  /** @description EVM wallet addresses */
3950
5548
  traders: string[];
@@ -3957,6 +5555,7 @@ export interface components {
3957
5555
  };
3958
5556
  /** @description Server acknowledgement for a trader PnL subscription. Echoes the accepted (normalized) filter sets so clients can confirm the active subscription. */
3959
5557
  TraderPnlSubscribeResponse: {
5558
+ /** @description Accepted trader wallets. */
3960
5559
  traders?: string[];
3961
5560
  /** @description Accepted update types. Empty = all. */
3962
5561
  update_types?: ("global" | "market" | "category")[];
@@ -3971,58 +5570,120 @@ export interface components {
3971
5570
  TraderGlobalPnlRow: {
3972
5571
  /** @description Trader EVM wallet address */
3973
5572
  trader: string;
5573
+ /** @description Dirty update kinds included in this event. */
3974
5574
  dirty_kinds?: ("trade" | "price" | "window" | "market_resolved")[];
3975
5575
  /** @description "1d", "7d", "30d", or "lifetime" */
3976
5576
  timeframe?: string | null;
3977
5577
  /** @description Realized PnL for the timeframe */
3978
5578
  realized_pnl_usd: number;
3979
- /** Format: int64 */
5579
+ /**
5580
+ * Format: int64
5581
+ * @description Events traded.
5582
+ */
3980
5583
  events_traded?: number;
3981
- /** Format: int64 */
5584
+ /**
5585
+ * Format: int64
5586
+ * @description Markets traded.
5587
+ */
3982
5588
  markets_traded?: number;
3983
- /** Format: int64 */
5589
+ /**
5590
+ * Format: int64
5591
+ * @description Total buy count.
5592
+ */
3984
5593
  total_buys?: number;
3985
- /** Format: int64 */
5594
+ /**
5595
+ * Format: int64
5596
+ * @description Total sell count.
5597
+ */
3986
5598
  total_sells?: number;
3987
- /** Format: int64 */
5599
+ /**
5600
+ * Format: int64
5601
+ * @description Total redemption count.
5602
+ */
3988
5603
  total_redemptions?: number;
3989
- /** Format: int64 */
5604
+ /**
5605
+ * Format: int64
5606
+ * @description Total merge count.
5607
+ */
3990
5608
  total_merges?: number;
3991
- /** Format: int64 */
5609
+ /**
5610
+ * Format: int64
5611
+ * @description Total split count.
5612
+ */
3992
5613
  total_splits?: number;
5614
+ /** @description Total volume in USD. */
3993
5615
  total_volume_usd?: number;
5616
+ /** @description Buy volume in USD. */
3994
5617
  buy_volume_usd?: number;
5618
+ /** @description Sell volume in USD. */
3995
5619
  sell_volume_usd?: number;
5620
+ /** @description Redemption volume in USD. */
3996
5621
  redemption_volume_usd?: number;
5622
+ /** @description Merge volume in USD. */
3997
5623
  merge_volume_usd?: number;
5624
+ /** @description Split volume in USD. */
3998
5625
  split_volume_usd?: number;
3999
- /** Format: int64 */
5626
+ /**
5627
+ * Format: int64
5628
+ * @description Maker rebate count.
5629
+ */
4000
5630
  maker_rebate_count?: number;
5631
+ /** @description Maker rebates in USD. */
4001
5632
  maker_rebate_usd?: number;
4002
- /** Format: int64 */
5633
+ /**
5634
+ * Format: int64
5635
+ * @description Reward count.
5636
+ */
4003
5637
  reward_count?: number;
5638
+ /** @description Rewards in USD. */
4004
5639
  reward_usd?: number;
4005
- /** Format: int64 */
5640
+ /**
5641
+ * Format: int64
5642
+ * @description Yield count.
5643
+ */
4006
5644
  yield_count?: number;
5645
+ /** @description Yield in USD. */
4007
5646
  yield_usd?: number;
4008
- /** Format: int64 */
5647
+ /**
5648
+ * Format: int64
5649
+ * @description Total credit count.
5650
+ */
4009
5651
  total_credit_count?: number;
5652
+ /** @description Total credits in USD. */
4010
5653
  total_credit_usd?: number;
4011
- /** Format: int64 */
5654
+ /**
5655
+ * Format: int64
5656
+ * @description Markets won.
5657
+ */
4012
5658
  markets_won?: number;
4013
- /** Format: int64 */
5659
+ /**
5660
+ * Format: int64
5661
+ * @description Markets lost.
5662
+ */
4014
5663
  markets_lost?: number;
5664
+ /** @description Market win rate percent. */
4015
5665
  market_win_rate_pct?: number;
5666
+ /** @description Total wins in USD. */
4016
5667
  total_wins_usd?: number;
5668
+ /** @description Total losses in USD. */
4017
5669
  total_losses_usd?: number;
5670
+ /** @description Average win in USD. */
4018
5671
  avg_win_usd?: number | null;
5672
+ /** @description Average loss in USD. */
4019
5673
  avg_loss_usd?: number | null;
5674
+ /** @description Profit factor. */
4020
5675
  profit_factor?: number | null;
5676
+ /** @description Average hold time in seconds. */
4021
5677
  avg_hold_time_seconds?: number;
5678
+ /** @description Total fees. */
4022
5679
  total_fees?: number;
5680
+ /** @description Best trade PnL in USD. */
4023
5681
  best_trade_pnl_usd?: number | null;
5682
+ /** @description Best trade condition ID. */
4024
5683
  best_trade_condition_id?: string | null;
5684
+ /** @description Worst trade PnL in USD. */
4025
5685
  worst_trade_pnl_usd?: number | null;
5686
+ /** @description Worst trade condition ID. */
4026
5687
  worst_trade_condition_id?: string | null;
4027
5688
  /**
4028
5689
  * Format: int64
@@ -4037,34 +5698,65 @@ export interface components {
4037
5698
  };
4038
5699
  /** @description One per-market PnL row inside a `trader_market_pnl_batch` envelope's `data` array. */
4039
5700
  TraderMarketPnlRow: {
5701
+ /** @description Trader wallet address. */
4040
5702
  trader: string;
5703
+ /** @description Dirty update kinds included in this event. */
4041
5704
  dirty_kinds?: ("trade" | "price" | "window" | "market_resolved")[];
4042
5705
  /** @description "1d", "7d", "30d", or "lifetime" */
4043
5706
  timeframe?: string | null;
4044
5707
  /** @description 64-char hex condition ID */
4045
5708
  condition_id: string;
5709
+ /** @description Realized PnL in USD. */
4046
5710
  realized_pnl_usd?: number;
5711
+ /** @description Current shares balance. */
4047
5712
  current_shares_balance?: number;
5713
+ /** @description Category label. */
4048
5714
  category?: string | null;
5715
+ /** @description Event slug. */
4049
5716
  event_slug?: string | null;
4050
- /** Format: int64 */
5717
+ /**
5718
+ * Format: int64
5719
+ * @description Outcomes traded.
5720
+ */
4051
5721
  outcomes_traded?: number;
4052
- /** Format: int64 */
5722
+ /**
5723
+ * Format: int64
5724
+ * @description Total buy count.
5725
+ */
4053
5726
  total_buys?: number;
4054
- /** Format: int64 */
5727
+ /**
5728
+ * Format: int64
5729
+ * @description Total sell count.
5730
+ */
4055
5731
  total_sells?: number;
4056
- /** Format: int64 */
5732
+ /**
5733
+ * Format: int64
5734
+ * @description Total redemption count.
5735
+ */
4057
5736
  total_redemptions?: number;
4058
- /** Format: int64 */
5737
+ /**
5738
+ * Format: int64
5739
+ * @description Total merge count.
5740
+ */
4059
5741
  total_merges?: number;
4060
- /** Format: int64 */
5742
+ /**
5743
+ * Format: int64
5744
+ * @description Total split count.
5745
+ */
4061
5746
  total_splits?: number;
5747
+ /** @description Buy volume in USD. */
4062
5748
  buy_usd?: number;
5749
+ /** @description Sell volume in USD. */
4063
5750
  sell_usd?: number;
5751
+ /** @description Redemption volume in USD. */
4064
5752
  redemption_usd?: number;
5753
+ /** @description Merge volume in USD. */
4065
5754
  merge_usd?: number;
5755
+ /** @description Split volume in USD. */
4066
5756
  split_volume_usd?: number;
5757
+ /** @description Total fees. */
4067
5758
  total_fees?: number;
5759
+ /** @description Total shares bought. */
4068
5760
  total_shares_bought?: number;
4069
5761
  /**
4070
5762
  * Format: int64
@@ -4079,50 +5771,103 @@ export interface components {
4079
5771
  };
4080
5772
  /** @description One per-category PnL row inside a `trader_category_pnl_batch` envelope's `data` array. */
4081
5773
  TraderCategoryPnlRow: {
5774
+ /** @description Trader wallet address. */
4082
5775
  trader: string;
5776
+ /** @description Dirty update kinds included in this event. */
4083
5777
  dirty_kinds?: ("trade" | "price" | "window" | "market_resolved")[];
4084
5778
  /** @description "1d", "7d", "30d", or "lifetime" */
4085
5779
  timeframe?: string | null;
5780
+ /** @description Category label. */
4086
5781
  category: string;
5782
+ /** @description Realized PnL in USD. */
4087
5783
  realized_pnl_usd?: number;
4088
- /** Format: int64 */
5784
+ /**
5785
+ * Format: int64
5786
+ * @description Markets in this category.
5787
+ */
4089
5788
  markets_in_category?: number;
4090
- /** Format: int64 */
5789
+ /**
5790
+ * Format: int64
5791
+ * @description Markets traded.
5792
+ */
4091
5793
  markets_traded?: number;
4092
- /** Format: int64 */
5794
+ /**
5795
+ * Format: int64
5796
+ * @description Outcomes traded.
5797
+ */
4093
5798
  outcomes_traded?: number;
4094
- /** Format: int64 */
5799
+ /**
5800
+ * Format: int64
5801
+ * @description Total buy count.
5802
+ */
4095
5803
  total_buys?: number;
4096
- /** Format: int64 */
5804
+ /**
5805
+ * Format: int64
5806
+ * @description Total sell count.
5807
+ */
4097
5808
  total_sells?: number;
4098
- /** Format: int64 */
5809
+ /**
5810
+ * Format: int64
5811
+ * @description Total redemption count.
5812
+ */
4099
5813
  total_redemptions?: number;
4100
- /** Format: int64 */
5814
+ /**
5815
+ * Format: int64
5816
+ * @description Total merge count.
5817
+ */
4101
5818
  total_merges?: number;
4102
- /** Format: int64 */
5819
+ /**
5820
+ * Format: int64
5821
+ * @description Total split count.
5822
+ */
4103
5823
  total_splits?: number;
5824
+ /** @description Total volume in USD. */
4104
5825
  total_volume_usd?: number;
5826
+ /** @description Buy volume in USD. */
4105
5827
  buy_usd?: number;
5828
+ /** @description Sell volume in USD. */
4106
5829
  sell_usd?: number;
5830
+ /** @description Redemption volume in USD. */
4107
5831
  redemption_usd?: number;
5832
+ /** @description Merge volume in USD. */
4108
5833
  merge_usd?: number;
5834
+ /** @description Split volume in USD. */
4109
5835
  split_volume_usd?: number;
5836
+ /** @description Total fees. */
4110
5837
  total_fees?: number;
5838
+ /** @description Total shares bought. */
4111
5839
  total_shares_bought?: number;
4112
- /** Format: int64 */
5840
+ /**
5841
+ * Format: int64
5842
+ * @description Markets won.
5843
+ */
4113
5844
  markets_won?: number;
4114
- /** Format: int64 */
5845
+ /**
5846
+ * Format: int64
5847
+ * @description Markets lost.
5848
+ */
4115
5849
  markets_lost?: number;
5850
+ /** @description Market win rate percent. */
4116
5851
  market_win_rate_pct?: number;
5852
+ /** @description Average hold time in seconds. */
4117
5853
  avg_hold_time_seconds?: number;
5854
+ /** @description Best trade PnL in USD. */
4118
5855
  best_trade_pnl_usd?: number | null;
5856
+ /** @description Best trade condition ID. */
4119
5857
  best_trade_condition_id?: string | null;
5858
+ /** @description Worst trade PnL in USD. */
4120
5859
  worst_trade_pnl_usd?: number | null;
5860
+ /** @description Worst trade condition ID. */
4121
5861
  worst_trade_condition_id?: string | null;
5862
+ /** @description Total wins in USD. */
4122
5863
  total_wins_usd?: number;
5864
+ /** @description Total losses in USD. */
4123
5865
  total_losses_usd?: number;
5866
+ /** @description Average win in USD. */
4124
5867
  avg_win_usd?: number | null;
5868
+ /** @description Average loss in USD. */
4125
5869
  avg_loss_usd?: number | null;
5870
+ /** @description Profit factor. */
4126
5871
  profit_factor?: number | null;
4127
5872
  /**
4128
5873
  * Format: int64
@@ -4137,10 +5882,16 @@ export interface components {
4137
5882
  };
4138
5883
  /** @description Row carried by `trader_global_tick_batch` (price-only trader aggregate). */
4139
5884
  TraderGlobalTickRow: {
5885
+ /** @description Trader wallet address. */
4140
5886
  trader: string;
5887
+ /** @description Realized PnL in USD. */
4141
5888
  realized_pnl_usd?: number;
5889
+ /** @description Open positions value. */
4142
5890
  open_positions_value?: number;
4143
- /** Format: int64 */
5891
+ /**
5892
+ * Format: int64
5893
+ * @description Last block number.
5894
+ */
4144
5895
  last_block?: number;
4145
5896
  /**
4146
5897
  * Format: int64
@@ -4151,10 +5902,16 @@ export interface components {
4151
5902
  };
4152
5903
  /** @description Row carried by `trader_market_tick_batch` (price-only per-market). */
4153
5904
  TraderMarketTickRow: {
5905
+ /** @description Trader wallet address. */
4154
5906
  trader: string;
5907
+ /** @description Market condition ID. */
4155
5908
  condition_id: string;
5909
+ /** @description Realized PnL in USD. */
4156
5910
  realized_pnl_usd?: number;
4157
- /** Format: int64 */
5911
+ /**
5912
+ * Format: int64
5913
+ * @description Last block number.
5914
+ */
4158
5915
  last_block?: number;
4159
5916
  /**
4160
5917
  * Format: int64
@@ -4165,10 +5922,16 @@ export interface components {
4165
5922
  };
4166
5923
  /** @description Row carried by `trader_category_tick_batch` (price-only per-category). */
4167
5924
  TraderCategoryTickRow: {
5925
+ /** @description Trader wallet address. */
4168
5926
  trader: string;
5927
+ /** @description Category label. */
4169
5928
  category: string;
5929
+ /** @description Realized PnL in USD. */
4170
5930
  realized_pnl_usd?: number;
4171
- /** Format: int64 */
5931
+ /**
5932
+ * Format: int64
5933
+ * @description Last block number.
5934
+ */
4172
5935
  last_block?: number;
4173
5936
  /**
4174
5937
  * Format: int64
@@ -4179,17 +5942,33 @@ export interface components {
4179
5942
  };
4180
5943
  /** @description Row carried by `trader_global_resolution_batch` (trader-aggregate resolution). */
4181
5944
  TraderGlobalResolutionRow: {
5945
+ /** @description Trader wallet address. */
4182
5946
  trader: string;
5947
+ /** @description Realized PnL in USD. */
4183
5948
  realized_pnl_usd?: number;
4184
- /** Format: int64 */
5949
+ /**
5950
+ * Format: int64
5951
+ * @description Markets won.
5952
+ */
4185
5953
  markets_won?: number;
4186
- /** Format: int64 */
5954
+ /**
5955
+ * Format: int64
5956
+ * @description Markets lost.
5957
+ */
4187
5958
  markets_lost?: number;
4188
- /** Format: int64 */
5959
+ /**
5960
+ * Format: int64
5961
+ * @description Markets resolved.
5962
+ */
4189
5963
  markets_resolved?: number;
5964
+ /** @description Total wins usd lifetime. */
4190
5965
  total_wins_usd_lifetime?: number;
5966
+ /** @description Total losses usd lifetime. */
4191
5967
  total_losses_usd_lifetime?: number;
4192
- /** Format: int64 */
5968
+ /**
5969
+ * Format: int64
5970
+ * @description Last block number.
5971
+ */
4193
5972
  last_block?: number;
4194
5973
  /**
4195
5974
  * Format: int64
@@ -4200,12 +5979,20 @@ export interface components {
4200
5979
  };
4201
5980
  /** @description Row carried by `trader_market_resolution_batch` (per-market resolution). */
4202
5981
  TraderMarketResolutionRow: {
5982
+ /** @description Trader wallet address. */
4203
5983
  trader: string;
5984
+ /** @description Market condition ID. */
4204
5985
  condition_id: string;
5986
+ /** @description Whether the market is resolved. */
4205
5987
  resolved?: boolean;
5988
+ /** @description Whether the position won. */
4206
5989
  won?: boolean | null;
5990
+ /** @description Realized PnL in USD. */
4207
5991
  realized_pnl_usd?: number;
4208
- /** Format: int64 */
5992
+ /**
5993
+ * Format: int64
5994
+ * @description Last block number.
5995
+ */
4209
5996
  last_block?: number;
4210
5997
  /**
4211
5998
  * Format: int64
@@ -4216,16 +6003,30 @@ export interface components {
4216
6003
  };
4217
6004
  /** @description Row carried by `trader_category_resolution_batch` (per-category resolution). */
4218
6005
  TraderCategoryResolutionRow: {
6006
+ /** @description Trader wallet address. */
4219
6007
  trader: string;
6008
+ /** @description Category label. */
4220
6009
  category: string;
6010
+ /** @description Realized PnL in USD. */
4221
6011
  realized_pnl_usd?: number;
4222
- /** Format: int64 */
6012
+ /**
6013
+ * Format: int64
6014
+ * @description Markets won.
6015
+ */
4223
6016
  markets_won?: number;
4224
- /** Format: int64 */
6017
+ /**
6018
+ * Format: int64
6019
+ * @description Markets lost.
6020
+ */
4225
6021
  markets_lost?: number;
6022
+ /** @description Total wins usd lifetime. */
4226
6023
  total_wins_usd_lifetime?: number;
6024
+ /** @description Total losses usd lifetime. */
4227
6025
  total_losses_usd_lifetime?: number;
4228
- /** Format: int64 */
6026
+ /**
6027
+ * Format: int64
6028
+ * @description Last block number.
6029
+ */
4229
6030
  last_block?: number;
4230
6031
  /**
4231
6032
  * Format: int64
@@ -4332,7 +6133,10 @@ export interface components {
4332
6133
  };
4333
6134
  /** @description Subscribe to the trader positions stream. `traders` is required and must be non-empty. `dirty_kinds` is an optional narrowing filter — empty/omitted or `["all"]` = receive every kind of update. */
4334
6135
  TraderPositionsSubscribeMessage: {
4335
- /** @enum {string} */
6136
+ /**
6137
+ * @description Subscription action.
6138
+ * @enum {string}
6139
+ */
4336
6140
  action: "subscribe" | "unsubscribe_all";
4337
6141
  /** @description EVM wallet addresses */
4338
6142
  traders: string[];
@@ -4341,49 +6145,80 @@ export interface components {
4341
6145
  };
4342
6146
  /** @description Server acknowledgement for a trader positions subscription. */
4343
6147
  TraderPositionsSubscribeResponse: {
6148
+ /** @description Accepted trader wallets. */
4344
6149
  traders?: string[];
4345
6150
  /** @description Echoed accepted dirty_kinds filter. Empty = all. */
4346
6151
  dirty_kinds?: ("trade" | "price" | "position_resolved")[];
6152
+ /** @description Rejected filter values. */
4347
6153
  rejected?: string[];
6154
+ /** @description Subscription error message. */
4348
6155
  error?: string | null;
4349
6156
  };
4350
6157
  /** @description One position-update row inside a `trader_position_batch` envelope's `data` array. */
4351
6158
  TraderPositionRow: {
4352
6159
  /** @description ERC-1155 token ID (decimal string) */
4353
6160
  position_id?: string | null;
6161
+ /** @description Market condition ID. */
4354
6162
  condition_id?: string | null;
6163
+ /** @description Market slug. */
4355
6164
  market_slug?: string | null;
6165
+ /** @description Event slug. */
4356
6166
  event_slug?: string | null;
4357
6167
  title?: string | null;
6168
+ /** @description Market question. */
4358
6169
  question?: string | null;
6170
+ /** @description Image URL. */
4359
6171
  image_url?: string | null;
4360
6172
  /** @description Outcome name (e.g. "Yes") */
4361
6173
  outcome?: string | null;
6174
+ /** @description Outcome index. */
4362
6175
  outcome_index?: number | null;
6176
+ /** @description Whether the position is open. */
4363
6177
  open?: boolean | null;
4364
6178
  /** @description Resolution outcome — present once the market resolved */
4365
6179
  won?: boolean | null;
4366
- /** Format: int64 */
6180
+ /**
6181
+ * Format: int64
6182
+ * @description Total buy count.
6183
+ */
4367
6184
  total_buys?: number | null;
4368
- /** Format: int64 */
6185
+ /**
6186
+ * Format: int64
6187
+ * @description Total sell count.
6188
+ */
4369
6189
  total_sells?: number | null;
4370
- /** Format: int64 */
6190
+ /**
6191
+ * Format: int64
6192
+ * @description Conversion count.
6193
+ */
4371
6194
  converted_count?: number | null;
6195
+ /** @description Converted shares gained. */
4372
6196
  converted_shares_gained?: number | null;
6197
+ /** @description Converted shares lost. */
4373
6198
  converted_shares_lost?: number | null;
6199
+ /** @description Total shares bought. */
4374
6200
  total_shares_bought?: number | null;
6201
+ /** @description Total shares sold. */
4375
6202
  total_shares_sold?: number | null;
6203
+ /** @description Total buys in USD. */
4376
6204
  total_buy_usd?: number | null;
6205
+ /** @description Total sells in USD. */
4377
6206
  total_sell_usd?: number | null;
6207
+ /** @description Redemption volume in USD. */
4378
6208
  redemption_usd?: number | null;
6209
+ /** @description Merge volume in USD. */
4379
6210
  merge_usd?: number | null;
4380
6211
  /** @description 0–1 */
4381
6212
  avg_entry_price?: number | null;
6213
+ /** @description Average exit price. */
4382
6214
  avg_exit_price?: number | null;
4383
6215
  /** @description Volume-weighted across buys + sells */
4384
6216
  avg_price?: number | null;
6217
+ /** @description Realized PnL in USD. */
4385
6218
  realized_pnl_usd?: number | null;
6219
+ /** @description Realized PnL percent. */
4386
6220
  realized_pnl_pct?: number | null;
6221
+ /** @description Total fees. */
4387
6222
  total_fees?: number | null;
4388
6223
  /**
4389
6224
  * Format: int64
@@ -4397,9 +6232,11 @@ export interface components {
4397
6232
  last_trade_at?: number | null;
4398
6233
  /** @description Latest on-chain mark for the outcome token */
4399
6234
  current_price?: number | null;
6235
+ /** @description Current shares balance. */
4400
6236
  current_shares_balance?: number | null;
4401
6237
  /** @description current_price × current_shares_balance */
4402
6238
  current_value?: number | null;
6239
+ /** @description Last traded price. */
4403
6240
  last_traded_price?: number | null;
4404
6241
  /**
4405
6242
  * Format: int64
@@ -4419,7 +6256,10 @@ export interface components {
4419
6256
  TraderPositionBatchEvent: {
4420
6257
  /** @enum {string} */
4421
6258
  type: "trader_position_batch";
4422
- /** @enum {string} */
6259
+ /**
6260
+ * @description WebSocket room ID.
6261
+ * @enum {string}
6262
+ */
4423
6263
  room_id: "polymarket_trader_positions";
4424
6264
  /**
4425
6265
  * Format: int64
@@ -4430,66 +6270,100 @@ export interface components {
4430
6270
  };
4431
6271
  /** @description One price-tick row inside a `trader_position_price_batch` envelope's `data` array. */
4432
6272
  TraderPositionPriceRow: {
6273
+ /** @description Trader wallet address. */
4433
6274
  trader?: string | null;
4434
6275
  /** @description ERC-1155 token ID (decimal string) */
4435
6276
  position_id?: string | null;
6277
+ /** @description Market condition ID. */
4436
6278
  condition_id?: string | null;
4437
6279
  /** @description Latest on-chain mark for the outcome token */
4438
6280
  current_price?: number | null;
6281
+ /** @description Current position value. */
4439
6282
  current_value?: number | null;
6283
+ /** @description Realized PnL in USD. */
4440
6284
  realized_pnl_usd?: number | null;
6285
+ /** @description Realized PnL percent. */
4441
6286
  realized_pnl_pct?: number | null;
4442
- /** Format: int64 */
6287
+ /**
6288
+ * Format: int64
6289
+ * @description Last block number.
6290
+ */
4443
6291
  last_block?: number | null;
4444
6292
  /**
4445
6293
  * Format: int64
4446
6294
  * @description Unix milliseconds
4447
6295
  */
4448
6296
  last_trade_at?: number | null;
6297
+ /** @description Dirty update kinds included in this event. */
4449
6298
  dirty_kinds?: "price"[];
4450
6299
  };
4451
6300
  /** @description Server-pushed per-block batch of position price ticks (mark-to-market refreshes). Envelope type: `trader_position_price_batch`. */
4452
6301
  TraderPositionPriceBatchEvent: {
4453
6302
  /** @enum {string} */
4454
6303
  type: "trader_position_price_batch";
4455
- /** @enum {string} */
6304
+ /**
6305
+ * @description WebSocket room ID.
6306
+ * @enum {string}
6307
+ */
4456
6308
  room_id: "polymarket_trader_positions";
4457
- /** Format: int64 */
6309
+ /**
6310
+ * Format: int64
6311
+ * @description Block number.
6312
+ */
4458
6313
  block: number;
4459
6314
  data: components["schemas"]["TraderPositionPriceRow"][];
4460
6315
  };
4461
6316
  /** @description One resolution row inside a `trader_position_resolution_batch` envelope's `data` array. */
4462
6317
  TraderPositionResolutionRow: {
6318
+ /** @description Trader wallet address. */
4463
6319
  trader?: string | null;
4464
6320
  /** @description ERC-1155 token ID (decimal string) */
4465
6321
  position_id?: string | null;
6322
+ /** @description Market condition ID. */
4466
6323
  condition_id?: string | null;
6324
+ /** @description Whether the market is resolved. */
4467
6325
  resolved?: boolean | null;
6326
+ /** @description Whether the position won. */
4468
6327
  won?: boolean | null;
6328
+ /** @description Realized PnL in USD. */
4469
6329
  realized_pnl_usd?: number | null;
6330
+ /** @description Realized PnL percent. */
4470
6331
  realized_pnl_pct?: number | null;
4471
- /** Format: int64 */
6332
+ /**
6333
+ * Format: int64
6334
+ * @description Last block number.
6335
+ */
4472
6336
  last_block?: number | null;
4473
6337
  /**
4474
6338
  * Format: int64
4475
6339
  * @description Unix milliseconds
4476
6340
  */
4477
6341
  last_trade_at?: number | null;
6342
+ /** @description Dirty update kinds included in this event. */
4478
6343
  dirty_kinds?: "position_resolved"[];
4479
6344
  };
4480
6345
  /** @description Server-pushed per-block batch of position resolutions. Envelope type: `trader_position_resolution_batch`. */
4481
6346
  TraderPositionResolutionBatchEvent: {
4482
6347
  /** @enum {string} */
4483
6348
  type: "trader_position_resolution_batch";
4484
- /** @enum {string} */
6349
+ /**
6350
+ * @description WebSocket room ID.
6351
+ * @enum {string}
6352
+ */
4485
6353
  room_id: "polymarket_trader_positions";
4486
- /** Format: int64 */
6354
+ /**
6355
+ * Format: int64
6356
+ * @description Block number.
6357
+ */
4487
6358
  block: number;
4488
6359
  data: components["schemas"]["TraderPositionResolutionRow"][];
4489
6360
  };
4490
6361
  /** @description Subscribe to the trader exit markers stream. `traders` is required and must be non-empty. `reasons` is an optional narrowing filter — empty/omitted or `["all"]` = receive every exit reason. */
4491
6362
  TraderExitMarkersSubscribeMessage: {
4492
- /** @enum {string} */
6363
+ /**
6364
+ * @description Subscription action.
6365
+ * @enum {string}
6366
+ */
4493
6367
  action: "subscribe" | "unsubscribe_all";
4494
6368
  /** @description EVM wallet addresses */
4495
6369
  traders: string[];
@@ -4498,10 +6372,13 @@ export interface components {
4498
6372
  };
4499
6373
  /** @description Server acknowledgement for a trader exit markers subscription. */
4500
6374
  TraderExitMarkersSubscribeResponse: {
6375
+ /** @description Accepted trader wallets. */
4501
6376
  traders?: string[];
4502
6377
  /** @description Echoed accepted reasons filter. Empty = all. */
4503
6378
  reasons?: ("resolved_win" | "resolved_loss" | "sold_win" | "sold_loss")[];
6379
+ /** @description Rejected filter values. */
4504
6380
  rejected?: string[];
6381
+ /** @description Subscription error message. */
4505
6382
  error?: string | null;
4506
6383
  };
4507
6384
  /** @description One exit row inside a `trader_exit_marker_batch` envelope's `data` array. */
@@ -4510,20 +6387,26 @@ export interface components {
4510
6387
  trader?: string;
4511
6388
  /** @description ERC-1155 token ID (decimal string) */
4512
6389
  position_id?: string;
6390
+ /** @description Market condition ID. */
4513
6391
  condition_id?: string;
6392
+ /** @description Event slug. */
4514
6393
  event_slug?: string;
6394
+ /** @description Market slug. */
4515
6395
  market_slug?: string;
4516
6396
  title?: string;
4517
6397
  /** @description Full market question text */
4518
6398
  question?: string;
6399
+ /** @description Image URL. */
4519
6400
  image_url?: string;
4520
6401
  /** @description Outcome name (e.g. "Yes") */
4521
6402
  outcome?: string;
6403
+ /** @description Outcome index. */
4522
6404
  outcome_index?: number | null;
4523
6405
  /** @description Realized PnL at exit, USD */
4524
6406
  pnl_usd?: number;
4525
6407
  /** @description Realized PnL at exit, percent */
4526
6408
  pnl_pct?: number;
6409
+ /** @description Cost basis in USD. */
4527
6410
  cost_basis_usd?: number;
4528
6411
  /**
4529
6412
  * @description Why the position closed: `resolved_*` held to market resolution (win/loss by verdict); `sold_*` closed before resolution (win/loss by realized PnL sign).
@@ -4545,7 +6428,10 @@ export interface components {
4545
6428
  TraderExitMarkerBatchEvent: {
4546
6429
  /** @enum {string} */
4547
6430
  type: "trader_exit_marker_batch";
4548
- /** @enum {string} */
6431
+ /**
6432
+ * @description WebSocket room ID.
6433
+ * @enum {string}
6434
+ */
4549
6435
  room_id: "polymarket_trader_pnl_exits";
4550
6436
  /**
4551
6437
  * Format: int64
@@ -4556,7 +6442,10 @@ export interface components {
4556
6442
  };
4557
6443
  /** @description Subscribe to holder metrics for explicit positions, conditions, or events. At least one identifier array must be non-empty. Omitted arrays receive no updates for that metric family. Up to 500 total identifiers are accepted. */
4558
6444
  HolderMetricsSubscribeMessage: {
4559
- /** @enum {string} */
6445
+ /**
6446
+ * @description Subscription action.
6447
+ * @enum {string}
6448
+ */
4560
6449
  action: "subscribe" | "unsubscribe_all";
4561
6450
  /** @description Position token IDs to receive position holder metrics for. */
4562
6451
  position_ids?: string[];
@@ -4566,54 +6455,85 @@ export interface components {
4566
6455
  event_slugs?: string[];
4567
6456
  };
4568
6457
  PositionHolderMetricsRow: {
6458
+ /** @description Unix timestamp in seconds. */
4569
6459
  ts?: number;
6460
+ /** @description Block number. */
4570
6461
  block?: number;
6462
+ /** @description Outcome token ID. */
4571
6463
  position_id?: string;
6464
+ /** @description Number of holders. */
4572
6465
  holder_count?: number;
6466
+ /** @description Total shares held. */
4573
6467
  total_balance?: number;
6468
+ /** @description Total holder cost basis in USD. */
4574
6469
  total_cost_basis?: number;
6470
+ /** @description Number of market-level holders. */
4575
6471
  condition_holder_count?: number | null;
6472
+ /** @description Number of event-level holders. */
4576
6473
  event_holder_count?: number | null;
4577
6474
  };
4578
6475
  ConditionHolderMetricsRow: {
6476
+ /** @description Unix timestamp in seconds. */
4579
6477
  ts?: number;
6478
+ /** @description Block number. */
4580
6479
  block?: number;
6480
+ /** @description Market condition ID. */
4581
6481
  condition_id?: string;
6482
+ /** @description Number of holders. */
4582
6483
  holder_count?: number;
4583
6484
  };
4584
6485
  EventHolderMetricsRow: {
6486
+ /** @description Unix timestamp in seconds. */
4585
6487
  ts?: number;
6488
+ /** @description Block number. */
4586
6489
  block?: number;
6490
+ /** @description Event slug. */
4587
6491
  event_slug?: string;
6492
+ /** @description Number of holders. */
4588
6493
  holder_count?: number;
4589
6494
  };
4590
6495
  HolderMetricsPositionBatchEvent: {
4591
6496
  /** @enum {string} */
4592
6497
  type: "holder_metrics_position_batch";
4593
- /** @enum {string} */
6498
+ /**
6499
+ * @description WebSocket room ID.
6500
+ * @enum {string}
6501
+ */
4594
6502
  room_id: "polymarket_holder_metrics";
6503
+ /** @description Block number. */
4595
6504
  block: number;
4596
6505
  data: components["schemas"]["PositionHolderMetricsRow"][];
4597
6506
  };
4598
6507
  HolderMetricsConditionBatchEvent: {
4599
6508
  /** @enum {string} */
4600
6509
  type: "holder_metrics_condition_batch";
4601
- /** @enum {string} */
6510
+ /**
6511
+ * @description WebSocket room ID.
6512
+ * @enum {string}
6513
+ */
4602
6514
  room_id: "polymarket_holder_metrics";
6515
+ /** @description Block number. */
4603
6516
  block: number;
4604
6517
  data: components["schemas"]["ConditionHolderMetricsRow"][];
4605
6518
  };
4606
6519
  HolderMetricsEventBatchEvent: {
4607
6520
  /** @enum {string} */
4608
6521
  type: "holder_metrics_event_batch";
4609
- /** @enum {string} */
6522
+ /**
6523
+ * @description WebSocket room ID.
6524
+ * @enum {string}
6525
+ */
4610
6526
  room_id: "polymarket_holder_metrics";
6527
+ /** @description Block number. */
4611
6528
  block: number;
4612
6529
  data: components["schemas"]["EventHolderMetricsRow"][];
4613
6530
  };
4614
6531
  /** @description Subscribe to the accounts stream. `wallets` is required. Share balance updates (`accounts_update`) are always delivered. Set `include_usdce`, `include_pusd`, or `include_matic` to also receive those balance streams. */
4615
6532
  AccountsSubscribeMessage: {
4616
- /** @enum {string} */
6533
+ /**
6534
+ * @description Subscription action.
6535
+ * @enum {string}
6536
+ */
4617
6537
  action: "subscribe" | "unsubscribe_all";
4618
6538
  /** @description EVM wallet addresses */
4619
6539
  wallets: string[];
@@ -4626,12 +6546,17 @@ export interface components {
4626
6546
  };
4627
6547
  /** @description Server acknowledgement for an accounts subscription */
4628
6548
  AccountsSubscribeResponse: {
6549
+ /** @description Accepted wallet addresses. */
4629
6550
  wallets?: string[];
4630
6551
  /** @description Addresses rejected (invalid format) */
4631
6552
  rejected?: string[];
6553
+ /** @description Whether to include USDC.e balances. */
4632
6554
  include_usdce?: boolean;
6555
+ /** @description Whether to include pUSD balances. */
4633
6556
  include_pusd?: boolean;
6557
+ /** @description Whether to include MATIC balances. */
4634
6558
  include_matic?: boolean;
6559
+ /** @description Subscription error message. */
4635
6560
  error?: string | null;
4636
6561
  };
4637
6562
  /** @description Server-pushed event: ERC-1155 outcome token balance change for a wallet. Envelope type: "accounts_update". */
@@ -4642,7 +6567,10 @@ export interface components {
4642
6567
  position_id: string;
4643
6568
  /** @description Current token balance (decimal string) */
4644
6569
  balance: string;
4645
- /** Format: int64 */
6570
+ /**
6571
+ * Format: int64
6572
+ * @description Block number.
6573
+ */
4646
6574
  block_number: number;
4647
6575
  /**
4648
6576
  * Format: int64
@@ -4662,7 +6590,10 @@ export interface components {
4662
6590
  token_address?: string;
4663
6591
  /** @description Current USDCe balance (decimal string) — omitted when not available */
4664
6592
  balance?: string;
4665
- /** Format: uint64 */
6593
+ /**
6594
+ * Format: uint64
6595
+ * @description Block number.
6596
+ */
4666
6597
  block_number: number;
4667
6598
  /**
4668
6599
  * Format: int64
@@ -4678,7 +6609,10 @@ export interface components {
4678
6609
  token_address?: string;
4679
6610
  /** @description Current pUSD balance (decimal string) — omitted when not available */
4680
6611
  balance?: string;
4681
- /** Format: uint64 */
6612
+ /**
6613
+ * Format: uint64
6614
+ * @description Block number.
6615
+ */
4682
6616
  block_number: number;
4683
6617
  /**
4684
6618
  * Format: int64
@@ -4694,7 +6628,10 @@ export interface components {
4694
6628
  token_address?: string;
4695
6629
  /** @description Current MATIC balance (decimal string) — omitted when not available */
4696
6630
  balance?: string;
4697
- /** Format: uint64 */
6631
+ /**
6632
+ * Format: uint64
6633
+ * @description Block number.
6634
+ */
4698
6635
  block_number: number;
4699
6636
  /**
4700
6637
  * Format: int64
@@ -4704,7 +6641,10 @@ export interface components {
4704
6641
  };
4705
6642
  /** @description Subscribe to the order book stream. At least one filter is required. Maximum 500 combined condition_ids + position_ids per client. No `type` field is needed — the server routes by room_id. */
4706
6643
  OrderBookSubscribeMessage: {
4707
- /** @enum {string} */
6644
+ /**
6645
+ * @description Subscription action.
6646
+ * @enum {string}
6647
+ */
4708
6648
  action: "subscribe" | "unsubscribe_all";
4709
6649
  /** @description Condition IDs (markets). All positions within each market are delivered. */
4710
6650
  condition_ids?: string[];
@@ -4758,7 +6698,10 @@ export interface components {
4758
6698
  };
4759
6699
  /** @description Subscribe to CLOB reward changes. Either provide specific condition_ids or set subscribe_all to true. */
4760
6700
  ClobRewardsSubscribeMessage: {
4761
- /** @enum {string} */
6701
+ /**
6702
+ * @description Subscription action.
6703
+ * @enum {string}
6704
+ */
4762
6705
  action: "subscribe" | "unsubscribe_all";
4763
6706
  /** @description Condition IDs to watch for reward changes. */
4764
6707
  condition_ids?: string[];
@@ -4785,14 +6728,22 @@ export interface components {
4785
6728
  condition_id?: string;
4786
6729
  /** @description Full reward state (null for 'removed' events) */
4787
6730
  reward?: {
6731
+ /** @description Market condition ID. */
4788
6732
  condition_id?: string;
4789
6733
  rewards_config?: {
6734
+ /** @description Event ID. */
4790
6735
  id?: number;
4791
6736
  /** @description Reward token address (e.g. USDC) */
4792
6737
  asset_address?: string;
4793
- /** Format: date */
6738
+ /**
6739
+ * Format: date
6740
+ * @description Reward start date.
6741
+ */
4794
6742
  start_date?: string;
4795
- /** Format: date */
6743
+ /**
6744
+ * Format: date
6745
+ * @description Reward end date.
6746
+ */
4796
6747
  end_date?: string;
4797
6748
  /** @description Daily reward rate in USDC */
4798
6749
  rate_per_day?: number;
@@ -4843,16 +6794,25 @@ export interface components {
4843
6794
  EventsStreamFilter: {
4844
6795
  /** @description Case-insensitive substring match on `title`. 3–100 chars. */
4845
6796
  search?: string;
6797
+ /** @description Categories to include. */
4846
6798
  categories?: string[];
6799
+ /** @description Categories to exclude. */
4847
6800
  exclude_categories?: string[];
4848
6801
  /** @description Match by tag slug OR label (case-insensitive). */
4849
6802
  tags?: string[];
6803
+ /** @description Tags to exclude. */
4850
6804
  exclude_tags?: string[];
6805
+ /** @description Minimum volume. */
4851
6806
  min_volume?: number;
6807
+ /** @description Maximum volume. */
4852
6808
  max_volume?: number;
6809
+ /** @description Minimum transaction count. */
4853
6810
  min_txns?: number;
6811
+ /** @description Maximum transaction count. */
4854
6812
  max_txns?: number;
6813
+ /** @description Minimum unique trader count. */
4855
6814
  min_unique_traders?: number;
6815
+ /** @description Maximum unique trader count. */
4856
6816
  max_unique_traders?: number;
4857
6817
  /**
4858
6818
  * @description Timeframe that `volume`/`txns`/`unique_traders` thresholds are evaluated against. Default `24h`.
@@ -4862,8 +6822,12 @@ export interface components {
4862
6822
  };
4863
6823
  /** @description Server acknowledgement for an events_stream subscribe/unsubscribe. Envelope type: "events_stream_subscribe_response". */
4864
6824
  EventsStreamSubscribeResponse: {
4865
- /** @enum {string} */
6825
+ /**
6826
+ * @description Subscription mode.
6827
+ * @enum {string}
6828
+ */
4866
6829
  mode?: "filter" | "ids" | "";
6830
+ /** @description Flush interval in milliseconds. */
4867
6831
  interval_ms?: number;
4868
6832
  /** @description Accepted ids (ids mode only). Empty in filter mode. */
4869
6833
  event_slugs?: string[];
@@ -4876,11 +6840,20 @@ export interface components {
4876
6840
  EventsStreamUpdateEvent: {
4877
6841
  /** @enum {string} */
4878
6842
  type: "events_stream_update";
4879
- /** @enum {string} */
6843
+ /**
6844
+ * @description WebSocket room ID.
6845
+ * @enum {string}
6846
+ */
4880
6847
  room_id: "polymarket_events_stream";
4881
- /** @enum {string} */
6848
+ /**
6849
+ * @description Subscription mode.
6850
+ * @enum {string}
6851
+ */
4882
6852
  mode: "filter" | "ids";
4883
- /** @enum {integer} */
6853
+ /**
6854
+ * @description Flush interval in milliseconds.
6855
+ * @enum {integer}
6856
+ */
4884
6857
  interval_ms: 500 | 1000 | 3000 | 10000;
4885
6858
  /** @description Full `PolymarketEvent` rows (same shape as `GET /polymarket/events`). Not a delta — each array element is a complete row replacement. */
4886
6859
  data: Record<string, never>[];
@@ -4916,9 +6889,14 @@ export interface components {
4916
6889
  * @description A buy/sell trade was matched on the exchange.
4917
6890
  */
4918
6891
  TradeOrderFilledEvent: {
4919
- /** @enum {string} */
6892
+ /**
6893
+ * @description Trade type.
6894
+ * @enum {string}
6895
+ */
4920
6896
  trade_type: "OrderFilled" | "OrdersMatched";
6897
+ /** @description Event ID. */
4921
6898
  id: string;
6899
+ /** @description Transaction hash. */
4922
6900
  hash: string;
4923
6901
  /** @description Absent for pending trades */
4924
6902
  block?: number;
@@ -4933,28 +6911,49 @@ export interface components {
4933
6911
  /** @description Absent for pending trades */
4934
6912
  order_hash?: string;
4935
6913
  trader: {
6914
+ /** @description Wallet address. */
4936
6915
  address?: string;
6916
+ /** @description Display name. */
4937
6917
  name?: string | null;
6918
+ /** @description Pseudonym. */
4938
6919
  pseudonym?: string | null;
6920
+ /** @description Profile image URL. */
4939
6921
  profile_image?: string | null;
6922
+ /** @description X username. */
4940
6923
  x_username?: string | null;
6924
+ /** @description Whether the profile is verified. */
4941
6925
  verified_badge?: boolean;
4942
6926
  };
4943
6927
  /** @description Absent for pending trades */
4944
6928
  taker?: string;
4945
- /** @enum {string} */
6929
+ /**
6930
+ * @description Trade side.
6931
+ * @enum {string}
6932
+ */
4946
6933
  side?: "Buy" | "Sell";
6934
+ /** @description Market condition ID. */
4947
6935
  condition_id?: string | null;
6936
+ /** @description Outcome token ID. */
4948
6937
  position_id?: string;
6938
+ /** @description Outcome name. */
4949
6939
  outcome?: string | null;
6940
+ /** @description Outcome index. */
4950
6941
  outcome_index?: number | null;
6942
+ /** @description Market question. */
4951
6943
  question?: string | null;
6944
+ /** @description Image URL. */
4952
6945
  image_url?: string | null;
6946
+ /** @description Market slug. */
4953
6947
  slug?: string | null;
6948
+ /** @description Event slug. */
4954
6949
  event_slug?: string | null;
6950
+ /** @description Trade amount in USD. */
4955
6951
  usd_amount?: number;
6952
+ /** @description Trade size in shares. */
4956
6953
  shares_amount?: number;
6954
+ /** @description Outcome price. */
4957
6955
  price?: number;
6956
+ /** @description Implied probability. */
4958
6957
  probability?: number | null;
4959
6958
  /** @description Absent for pending trades */
4960
6959
  fee?: number;
@@ -4962,6 +6961,7 @@ export interface components {
4962
6961
  fee_shares?: number;
4963
6962
  /** @description Absent for pending trades */
4964
6963
  fee_pct?: number;
6964
+ /** @description Exchange identifier. */
4965
6965
  exchange: number;
4966
6966
  /** @description CLOB V2 builder code (lower-cased `0x...` bytes32 hex). Absent on V1 trades; may be `0x0000…` for V2 trades placed without a builder code. */
4967
6967
  builder_code?: string;
@@ -4973,25 +6973,42 @@ export interface components {
4973
6973
  * @description pUSD credit paid directly to the trader wallet.
4974
6974
  */
4975
6975
  TradeRedemptionEvent: {
4976
- /** @enum {string} */
6976
+ /**
6977
+ * @description Trade type.
6978
+ * @enum {string}
6979
+ */
4977
6980
  trade_type: "MakerRebate" | "Reward" | "Yield";
6981
+ /** @description Event ID. */
4978
6982
  id: string;
6983
+ /** @description Transaction hash. */
4979
6984
  hash: string;
6985
+ /** @description Block number. */
4980
6986
  block?: number;
6987
+ /** @description Confirmation timestamp. */
4981
6988
  confirmed_at?: number;
6989
+ /** @description Receive timestamp. */
4982
6990
  received_at?: number;
6991
+ /** @description Log index. */
4983
6992
  log_index?: number;
6993
+ /** @description Block index. */
4984
6994
  block_index?: number;
4985
6995
  trader: {
6996
+ /** @description Wallet address. */
4986
6997
  address?: string;
6998
+ /** @description Display name. */
4987
6999
  name?: string | null;
7000
+ /** @description Pseudonym. */
4988
7001
  pseudonym?: string | null;
7002
+ /** @description Profile image URL. */
4989
7003
  profile_image?: string | null;
7004
+ /** @description X username. */
4990
7005
  x_username?: string | null;
7006
+ /** @description Whether the profile is verified. */
4991
7007
  verified_badge?: boolean;
4992
7008
  };
4993
7009
  /** @description Payout distributor address */
4994
7010
  taker?: string;
7011
+ /** @description Trade amount in USD. */
4995
7012
  usd_amount?: number;
4996
7013
  /** @description Always 0 for payout credits */
4997
7014
  shares_amount?: number;
@@ -5011,37 +7028,67 @@ export interface components {
5011
7028
  * @description Positions redeemed after market resolution.
5012
7029
  */
5013
7030
  TradeMergeEvent: {
5014
- /** @enum {string} */
7031
+ /**
7032
+ * @description Trade type.
7033
+ * @enum {string}
7034
+ */
5015
7035
  trade_type: "Redemption";
7036
+ /** @description Event ID. */
5016
7037
  id: string;
7038
+ /** @description Transaction hash. */
5017
7039
  hash: string;
7040
+ /** @description Block number. */
5018
7041
  block?: number;
7042
+ /** @description Confirmation timestamp. */
5019
7043
  confirmed_at?: number;
7044
+ /** @description Receive timestamp. */
5020
7045
  received_at?: number;
7046
+ /** @description Log index. */
5021
7047
  log_index?: number;
7048
+ /** @description Block index. */
5022
7049
  block_index?: number;
5023
7050
  trader: {
7051
+ /** @description Wallet address. */
5024
7052
  address?: string;
7053
+ /** @description Display name. */
5025
7054
  name?: string | null;
7055
+ /** @description Pseudonym. */
5026
7056
  pseudonym?: string | null;
7057
+ /** @description Profile image URL. */
5027
7058
  profile_image?: string | null;
7059
+ /** @description X username. */
5028
7060
  x_username?: string | null;
7061
+ /** @description Whether the profile is verified. */
5029
7062
  verified_badge?: boolean;
5030
7063
  };
7064
+ /** @description Market condition ID. */
5031
7065
  condition_id?: string | null;
7066
+ /** @description Outcome name. */
5032
7067
  outcome?: string | null;
7068
+ /** @description Outcome index. */
5033
7069
  outcome_index?: number | null;
7070
+ /** @description Market question. */
5034
7071
  question?: string | null;
7072
+ /** @description Image URL. */
5035
7073
  image_url?: string | null;
7074
+ /** @description Market slug. */
5036
7075
  slug?: string | null;
7076
+ /** @description Event slug. */
5037
7077
  event_slug?: string | null;
7078
+ /** @description Trade amount in USD. */
5038
7079
  usd_amount?: number;
7080
+ /** @description Winning outcome index. */
5039
7081
  winning_outcome_index?: number | null;
7082
+ /** @description Position details. */
5040
7083
  position_details?: {
7084
+ /** @description Outcome token ID. */
5041
7085
  position_id?: string;
7086
+ /** @description Outcome index. */
5042
7087
  outcome_index?: number;
7088
+ /** @description Amount as a decimal string. */
5043
7089
  amount?: string;
5044
7090
  }[];
7091
+ /** @description Exchange identifier. */
5045
7092
  exchange: number;
5046
7093
  };
5047
7094
  /**
@@ -5049,34 +7096,61 @@ export interface components {
5049
7096
  * @description Outcome tokens burned to receive collateral.
5050
7097
  */
5051
7098
  TradeSplitEvent: {
5052
- /** @enum {string} */
7099
+ /**
7100
+ * @description Trade type.
7101
+ * @enum {string}
7102
+ */
5053
7103
  trade_type: "Merge";
7104
+ /** @description Event ID. */
5054
7105
  id: string;
7106
+ /** @description Transaction hash. */
5055
7107
  hash: string;
7108
+ /** @description Block number. */
5056
7109
  block?: number;
7110
+ /** @description Confirmation timestamp. */
5057
7111
  confirmed_at?: number;
7112
+ /** @description Receive timestamp. */
5058
7113
  received_at?: number;
7114
+ /** @description Log index. */
5059
7115
  log_index?: number;
7116
+ /** @description Block index. */
5060
7117
  block_index?: number;
5061
7118
  trader: {
7119
+ /** @description Wallet address. */
5062
7120
  address?: string;
7121
+ /** @description Display name. */
5063
7122
  name?: string | null;
7123
+ /** @description Pseudonym. */
5064
7124
  pseudonym?: string | null;
7125
+ /** @description Profile image URL. */
5065
7126
  profile_image?: string | null;
7127
+ /** @description X username. */
5066
7128
  x_username?: string | null;
7129
+ /** @description Whether the profile is verified. */
5067
7130
  verified_badge?: boolean;
5068
7131
  };
7132
+ /** @description Market condition ID. */
5069
7133
  condition_id?: string | null;
7134
+ /** @description Market question. */
5070
7135
  question?: string | null;
7136
+ /** @description Image URL. */
5071
7137
  image_url?: string | null;
7138
+ /** @description Market slug. */
5072
7139
  slug?: string | null;
7140
+ /** @description Event slug. */
5073
7141
  event_slug?: string | null;
7142
+ /** @description Trade amount in USD. */
5074
7143
  usd_amount?: number;
7144
+ /** @description Position details. */
5075
7145
  position_details?: {
7146
+ /** @description Outcome token ID. */
5076
7147
  position_id?: string;
7148
+ /** @description Outcome index. */
5077
7149
  outcome_index?: number;
7150
+ /** @description Amount as a decimal string. */
5078
7151
  amount?: string;
5079
7152
  }[];
7153
+ /** @description Exchange identifier. */
5080
7154
  exchange: number;
5081
7155
  };
5082
7156
  /**
@@ -5084,34 +7158,61 @@ export interface components {
5084
7158
  * @description Collateral deposited to receive outcome tokens.
5085
7159
  */
5086
7160
  TradePositionsConvertedEvent: {
5087
- /** @enum {string} */
7161
+ /**
7162
+ * @description Trade type.
7163
+ * @enum {string}
7164
+ */
5088
7165
  trade_type: "Split";
7166
+ /** @description Event ID. */
5089
7167
  id: string;
7168
+ /** @description Transaction hash. */
5090
7169
  hash: string;
7170
+ /** @description Block number. */
5091
7171
  block?: number;
7172
+ /** @description Confirmation timestamp. */
5092
7173
  confirmed_at?: number;
7174
+ /** @description Receive timestamp. */
5093
7175
  received_at?: number;
7176
+ /** @description Log index. */
5094
7177
  log_index?: number;
7178
+ /** @description Block index. */
5095
7179
  block_index?: number;
5096
7180
  trader: {
7181
+ /** @description Wallet address. */
5097
7182
  address?: string;
7183
+ /** @description Display name. */
5098
7184
  name?: string | null;
7185
+ /** @description Pseudonym. */
5099
7186
  pseudonym?: string | null;
7187
+ /** @description Profile image URL. */
5100
7188
  profile_image?: string | null;
7189
+ /** @description X username. */
5101
7190
  x_username?: string | null;
7191
+ /** @description Whether the profile is verified. */
5102
7192
  verified_badge?: boolean;
5103
7193
  };
7194
+ /** @description Market condition ID. */
5104
7195
  condition_id?: string | null;
7196
+ /** @description Market question. */
5105
7197
  question?: string | null;
7198
+ /** @description Image URL. */
5106
7199
  image_url?: string | null;
7200
+ /** @description Market slug. */
5107
7201
  slug?: string | null;
7202
+ /** @description Event slug. */
5108
7203
  event_slug?: string | null;
7204
+ /** @description Trade amount in USD. */
5109
7205
  usd_amount?: number;
7206
+ /** @description Position details. */
5110
7207
  position_details?: {
7208
+ /** @description Outcome token ID. */
5111
7209
  position_id?: string;
7210
+ /** @description Outcome index. */
5112
7211
  outcome_index?: number;
7212
+ /** @description Amount as a decimal string. */
5113
7213
  amount?: string;
5114
7214
  }[];
7215
+ /** @description Exchange identifier. */
5115
7216
  exchange: number;
5116
7217
  };
5117
7218
  /**
@@ -5119,34 +7220,59 @@ export interface components {
5119
7220
  * @description NegRisk NO tokens converted to YES tokens + collateral.
5120
7221
  */
5121
7222
  TradeCancelledEvent: {
5122
- /** @enum {string} */
7223
+ /**
7224
+ * @description Trade type.
7225
+ * @enum {string}
7226
+ */
5123
7227
  trade_type: "PositionsConverted";
7228
+ /** @description Event ID. */
5124
7229
  id: string;
7230
+ /** @description Transaction hash. */
5125
7231
  hash: string;
7232
+ /** @description Block number. */
5126
7233
  block?: number;
7234
+ /** @description Confirmation timestamp. */
5127
7235
  confirmed_at?: number;
7236
+ /** @description Receive timestamp. */
5128
7237
  received_at?: number;
7238
+ /** @description Log index. */
5129
7239
  log_index?: number;
7240
+ /** @description Block index. */
5130
7241
  block_index?: number;
5131
7242
  trader: {
7243
+ /** @description Wallet address. */
5132
7244
  address?: string;
7245
+ /** @description Display name. */
5133
7246
  name?: string | null;
7247
+ /** @description Pseudonym. */
5134
7248
  pseudonym?: string | null;
7249
+ /** @description Profile image URL. */
5135
7250
  profile_image?: string | null;
7251
+ /** @description X username. */
5136
7252
  x_username?: string | null;
7253
+ /** @description Whether the profile is verified. */
5137
7254
  verified_badge?: boolean;
5138
7255
  };
7256
+ /** @description Market id. */
5139
7257
  market_id?: string;
7258
+ /** @description Index set. */
5140
7259
  index_set?: string;
7260
+ /** @description Trade size in shares. */
5141
7261
  shares_amount?: number;
7262
+ /** @description Fee. */
5142
7263
  fee?: number;
7264
+ /** @description Fee percent. */
5143
7265
  fee_pct?: number;
5144
7266
  /** @description Per-position conversion amounts */
5145
7267
  position_details?: {
7268
+ /** @description Outcome token ID. */
5146
7269
  position_id?: string;
7270
+ /** @description Outcome index. */
5147
7271
  outcome_index?: number;
7272
+ /** @description Amount as a decimal string. */
5148
7273
  amount?: string;
5149
7274
  }[];
7275
+ /** @description Exchange identifier. */
5150
7276
  exchange: number;
5151
7277
  };
5152
7278
  /**
@@ -5154,20 +7280,36 @@ export interface components {
5154
7280
  * @description Order cancelled on-chain.
5155
7281
  */
5156
7282
  TradeOracleLifecycleEvent: {
5157
- /** @enum {string} */
7283
+ /**
7284
+ * @description Trade type.
7285
+ * @enum {string}
7286
+ */
5158
7287
  trade_type: "Cancelled";
7288
+ /** @description Event ID. */
5159
7289
  id: string;
7290
+ /** @description Transaction hash. */
5160
7291
  hash: string;
7292
+ /** @description Block number. */
5161
7293
  block?: number;
7294
+ /** @description Confirmation timestamp. */
5162
7295
  confirmed_at?: number;
7296
+ /** @description Receive timestamp. */
5163
7297
  received_at?: number;
7298
+ /** @description Log index. */
5164
7299
  log_index?: number;
7300
+ /** @description Block index. */
5165
7301
  block_index?: number;
7302
+ /** @description Order hash. */
5166
7303
  order_hash?: string;
7304
+ /** @description Market question. */
5167
7305
  question?: string | null;
7306
+ /** @description Image URL. */
5168
7307
  image_url?: string | null;
7308
+ /** @description Market slug. */
5169
7309
  slug?: string | null;
7310
+ /** @description Event slug. */
5170
7311
  event_slug?: string | null;
7312
+ /** @description Exchange identifier. */
5171
7313
  exchange: number;
5172
7314
  };
5173
7315
  /**
@@ -5175,33 +7317,62 @@ export interface components {
5175
7317
  * @description Market lifecycle events: Initialization, Proposal, Dispute, Settled, Resolution, ConditionResolution, Reset, Flag, Unflag, Pause, Unpause, ManualResolution, NegRiskOutcomeReported.
5176
7318
  */
5177
7319
  TradeRegisterTokenEvent: {
5178
- /** @enum {string} */
7320
+ /**
7321
+ * @description Oracle lifecycle event type.
7322
+ * @enum {string}
7323
+ */
5179
7324
  trade_type: "Initialization" | "Proposal" | "Dispute" | "Settled" | "Resolution" | "ConditionResolution" | "Reset" | "Flag" | "Unflag" | "Pause" | "Unpause" | "ManualResolution" | "NegRiskOutcomeReported";
7325
+ /** @description Event ID. */
5180
7326
  id: string;
7327
+ /** @description Transaction hash. */
5181
7328
  hash: string;
7329
+ /** @description Block number. */
5182
7330
  block?: number;
7331
+ /** @description Confirmation timestamp. */
5183
7332
  confirmed_at?: number;
7333
+ /** @description Receive timestamp. */
5184
7334
  received_at?: number;
7335
+ /** @description Log index. */
5185
7336
  log_index?: number;
7337
+ /** @description Block index. */
5186
7338
  block_index?: number;
7339
+ /** @description Oracle contract. */
5187
7340
  oracle_contract: string;
7341
+ /** @description Market condition ID. */
5188
7342
  condition_id: string;
7343
+ /** @description Market question. */
5189
7344
  question?: string | null;
7345
+ /** @description Image URL. */
5190
7346
  image_url?: string | null;
7347
+ /** @description Market slug. */
5191
7348
  slug?: string | null;
7349
+ /** @description Event slug. */
5192
7350
  event_slug?: string | null;
7351
+ /** @description Assertion id. */
5193
7352
  assertion_id?: string | null;
7353
+ /** @description Proposer. */
5194
7354
  proposer?: string | null;
7355
+ /** @description Disputer. */
5195
7356
  disputer?: string | null;
7357
+ /** @description Proposed outcome. */
5196
7358
  proposed_outcome?: string | null;
7359
+ /** @description Settled price. */
5197
7360
  settled_price?: number | null;
7361
+ /** @description Disputed. */
5198
7362
  disputed?: boolean | null;
7363
+ /** @description Settlement resolution. */
5199
7364
  settlement_resolution?: boolean | null;
7365
+ /** @description Bond. */
5200
7366
  bond?: string | null;
7367
+ /** @description Expiration time. */
5201
7368
  expiration_time?: number | null;
7369
+ /** @description Creator. */
5202
7370
  creator?: string | null;
7371
+ /** @description Reward token. */
5203
7372
  reward_token?: string | null;
7373
+ /** @description Reward details. */
5204
7374
  reward?: string | null;
7375
+ /** @description Proposal bond. */
5205
7376
  proposal_bond?: string | null;
5206
7377
  };
5207
7378
  };