@pear-protocol/types 2.22.1 → 2.24.0

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.
Files changed (44) hide show
  1. package/dist/bundle.d.ts +1 -0
  2. package/dist/common/transaction-hash.d.ts +7 -0
  3. package/dist/copy/entities.d.ts +160 -10
  4. package/dist/copy/responses.d.ts +95 -11
  5. package/dist/execution/entities.d.ts +43 -43
  6. package/dist/execution/queries.d.ts +3 -2
  7. package/dist/execution/responses.d.ts +24 -24
  8. package/dist/fill/entities.d.ts +60 -1
  9. package/dist/fill/queries.d.ts +1 -0
  10. package/dist/fill/responses.d.ts +34 -4
  11. package/dist/index.js +668 -410
  12. package/dist/ladder/entities.d.ts +141 -24
  13. package/dist/ladder/payloads.d.ts +60 -24
  14. package/dist/ladder/queries.d.ts +2 -2
  15. package/dist/ladder/responses.d.ts +420 -69
  16. package/dist/notification/entities.d.ts +53 -6
  17. package/dist/notification/responses.d.ts +24 -2
  18. package/dist/order/entities.d.ts +3 -3
  19. package/dist/position/entities.d.ts +5 -5
  20. package/dist/position/responses.d.ts +4 -4
  21. package/dist/realtime/frames.d.ts +38 -6
  22. package/dist/realtime/public-events.d.ts +19 -3
  23. package/dist/rewards/entities.d.ts +18 -0
  24. package/dist/rewards/index.d.ts +1 -0
  25. package/dist/rewards/queries.d.ts +7 -0
  26. package/dist/rewards/responses.d.ts +54 -0
  27. package/dist/schedule/entities.d.ts +155 -19
  28. package/dist/schedule/index.d.ts +1 -0
  29. package/dist/schedule/queries.d.ts +3 -2
  30. package/dist/schedule/responses.d.ts +142 -19
  31. package/dist/sync/payloads.d.ts +56 -88
  32. package/dist/tca/responses.d.ts +12 -12
  33. package/dist/trade/payloads.d.ts +60 -24
  34. package/dist/trade/responses.d.ts +60 -60
  35. package/dist/traders/performance.d.ts +4 -0
  36. package/dist/traders/public.d.ts +537 -285
  37. package/dist/trigger/common/index.d.ts +8 -2
  38. package/dist/trigger/entities/conditions.d.ts +40 -0
  39. package/dist/trigger/entities/index.d.ts +339 -32
  40. package/dist/trigger/payloads/conditions.d.ts +70 -38
  41. package/dist/trigger/payloads/index.d.ts +408 -216
  42. package/dist/trigger/queries.d.ts +2 -2
  43. package/dist/trigger/responses.d.ts +218 -20
  44. package/package.json +1 -1
@@ -10,10 +10,10 @@ export declare const TriggerListParams: z.ZodObject<{
10
10
  lighter: "lighter";
11
11
  lighter_rhc: "lighter_rhc";
12
12
  }>>;
13
- status: z.ZodOptional<z.ZodPipe<z.ZodTransform<string[] | (("ACTIVE" | "CANCELLED" | "COMPLETED")[] & any[]) | undefined, ("ACTIVE" | "CANCELLED" | "COMPLETED")[]>, z.ZodArray<z.ZodEnum<{
13
+ status: z.ZodOptional<z.ZodPipe<z.ZodTransform<string[] | (("ACTIVE" | "COMPLETED" | "CANCELLED")[] & any[]) | undefined, ("ACTIVE" | "COMPLETED" | "CANCELLED")[]>, z.ZodArray<z.ZodEnum<{
14
14
  ACTIVE: "ACTIVE";
15
- CANCELLED: "CANCELLED";
16
15
  COMPLETED: "COMPLETED";
16
+ CANCELLED: "CANCELLED";
17
17
  }>>>>;
18
18
  }, z.core.$strip>;
19
19
  export type TriggerListParamsInput = z.input<typeof TriggerListParams>;
@@ -24,12 +24,13 @@ export declare const TriggerListResponse: z.ZodObject<{
24
24
  triggeredAt: z.ZodOptional<z.ZodString>;
25
25
  cancelledAt: z.ZodOptional<z.ZodString>;
26
26
  cancelledReason: z.ZodOptional<z.ZodEnum<{
27
- USER: "USER";
28
27
  POSITION_CLOSED: "POSITION_CLOSED";
28
+ USER: "USER";
29
29
  SYSTEM: "SYSTEM";
30
30
  POSITION_NETTED: "POSITION_NETTED";
31
31
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
32
32
  POSITION_REVERSED: "POSITION_REVERSED";
33
+ POSITION_RESIZED: "POSITION_RESIZED";
33
34
  }>>;
34
35
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
35
36
  id: z.ZodUUID;
@@ -42,7 +43,9 @@ export declare const TriggerListResponse: z.ZodObject<{
42
43
  }>;
43
44
  tradeAccountId: z.ZodUUID;
44
45
  symbol: z.ZodString;
45
- positionId: z.ZodUUID;
46
+ executionId: z.ZodOptional<z.ZodUUID>;
47
+ scheduleId: z.ZodOptional<z.ZodUUID>;
48
+ triggerId: z.ZodOptional<z.ZodUUID>;
46
49
  connector: z.ZodEnum<{
47
50
  hyperliquid: "hyperliquid";
48
51
  binance: "binance";
@@ -68,6 +71,13 @@ export declare const TriggerListResponse: z.ZodObject<{
68
71
  exchangeFillId: z.ZodString;
69
72
  quantity: z.ZodString;
70
73
  }, z.core.$strip>>;
74
+ assignments: z.ZodArray<z.ZodObject<{
75
+ positionId: z.ZodUUID;
76
+ quantity: z.ZodString;
77
+ usd: z.ZodString;
78
+ tradeFee: z.ZodOptional<z.ZodString>;
79
+ pearFee: z.ZodOptional<z.ZodString>;
80
+ }, z.core.$strip>>;
71
81
  }, z.core.$strip>>>;
72
82
  bracketType: z.ZodEnum<{
73
83
  NONE: "NONE";
@@ -236,12 +246,13 @@ export declare const TriggerListResponse: z.ZodObject<{
236
246
  triggeredAt: z.ZodOptional<z.ZodString>;
237
247
  cancelledAt: z.ZodOptional<z.ZodString>;
238
248
  cancelledReason: z.ZodOptional<z.ZodEnum<{
239
- USER: "USER";
240
249
  POSITION_CLOSED: "POSITION_CLOSED";
250
+ USER: "USER";
241
251
  SYSTEM: "SYSTEM";
242
252
  POSITION_NETTED: "POSITION_NETTED";
243
253
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
244
254
  POSITION_REVERSED: "POSITION_REVERSED";
255
+ POSITION_RESIZED: "POSITION_RESIZED";
245
256
  }>>;
246
257
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
247
258
  id: z.ZodUUID;
@@ -254,7 +265,9 @@ export declare const TriggerListResponse: z.ZodObject<{
254
265
  }>;
255
266
  tradeAccountId: z.ZodUUID;
256
267
  symbol: z.ZodString;
257
- positionId: z.ZodUUID;
268
+ executionId: z.ZodOptional<z.ZodUUID>;
269
+ scheduleId: z.ZodOptional<z.ZodUUID>;
270
+ triggerId: z.ZodOptional<z.ZodUUID>;
258
271
  connector: z.ZodEnum<{
259
272
  hyperliquid: "hyperliquid";
260
273
  binance: "binance";
@@ -280,6 +293,13 @@ export declare const TriggerListResponse: z.ZodObject<{
280
293
  exchangeFillId: z.ZodString;
281
294
  quantity: z.ZodString;
282
295
  }, z.core.$strip>>;
296
+ assignments: z.ZodArray<z.ZodObject<{
297
+ positionId: z.ZodUUID;
298
+ quantity: z.ZodString;
299
+ usd: z.ZodString;
300
+ tradeFee: z.ZodOptional<z.ZodString>;
301
+ pearFee: z.ZodOptional<z.ZodString>;
302
+ }, z.core.$strip>>;
283
303
  }, z.core.$strip>>>;
284
304
  bracketType: z.ZodEnum<{
285
305
  NONE: "NONE";
@@ -357,6 +377,10 @@ export declare const TriggerListResponse: z.ZodObject<{
357
377
  TROUGH: "TROUGH";
358
378
  }>;
359
379
  threshold: z.ZodNumber;
380
+ onPositionResize: z.ZodEnum<{
381
+ cancel: "cancel";
382
+ keep: "keep";
383
+ }>;
360
384
  }, z.core.$strip>;
361
385
  }, z.core.$strip>, z.ZodObject<{
362
386
  type: z.ZodLiteral<"upnl">;
@@ -370,6 +394,10 @@ export declare const TriggerListResponse: z.ZodObject<{
370
394
  TROUGH: "TROUGH";
371
395
  }>;
372
396
  threshold: z.ZodNumber;
397
+ onPositionResize: z.ZodEnum<{
398
+ cancel: "cancel";
399
+ keep: "keep";
400
+ }>;
373
401
  }, z.core.$strip>;
374
402
  }, z.core.$strip>, z.ZodObject<{
375
403
  type: z.ZodLiteral<"upnl_bps">;
@@ -494,12 +522,13 @@ export declare const TriggerListResponse: z.ZodObject<{
494
522
  triggeredAt: z.ZodOptional<z.ZodString>;
495
523
  cancelledAt: z.ZodOptional<z.ZodString>;
496
524
  cancelledReason: z.ZodOptional<z.ZodEnum<{
497
- USER: "USER";
498
525
  POSITION_CLOSED: "POSITION_CLOSED";
526
+ USER: "USER";
499
527
  SYSTEM: "SYSTEM";
500
528
  POSITION_NETTED: "POSITION_NETTED";
501
529
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
502
530
  POSITION_REVERSED: "POSITION_REVERSED";
531
+ POSITION_RESIZED: "POSITION_RESIZED";
503
532
  }>>;
504
533
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
505
534
  id: z.ZodUUID;
@@ -512,7 +541,9 @@ export declare const TriggerListResponse: z.ZodObject<{
512
541
  }>;
513
542
  tradeAccountId: z.ZodUUID;
514
543
  symbol: z.ZodString;
515
- positionId: z.ZodUUID;
544
+ executionId: z.ZodOptional<z.ZodUUID>;
545
+ scheduleId: z.ZodOptional<z.ZodUUID>;
546
+ triggerId: z.ZodOptional<z.ZodUUID>;
516
547
  connector: z.ZodEnum<{
517
548
  hyperliquid: "hyperliquid";
518
549
  binance: "binance";
@@ -538,6 +569,13 @@ export declare const TriggerListResponse: z.ZodObject<{
538
569
  exchangeFillId: z.ZodString;
539
570
  quantity: z.ZodString;
540
571
  }, z.core.$strip>>;
572
+ assignments: z.ZodArray<z.ZodObject<{
573
+ positionId: z.ZodUUID;
574
+ quantity: z.ZodString;
575
+ usd: z.ZodString;
576
+ tradeFee: z.ZodOptional<z.ZodString>;
577
+ pearFee: z.ZodOptional<z.ZodString>;
578
+ }, z.core.$strip>>;
541
579
  }, z.core.$strip>>>;
542
580
  bracketType: z.ZodEnum<{
543
581
  NONE: "NONE";
@@ -615,6 +653,10 @@ export declare const TriggerListResponse: z.ZodObject<{
615
653
  TROUGH: "TROUGH";
616
654
  }>;
617
655
  threshold: z.ZodNumber;
656
+ onPositionResize: z.ZodEnum<{
657
+ cancel: "cancel";
658
+ keep: "keep";
659
+ }>;
618
660
  }, z.core.$strip>;
619
661
  }, z.core.$strip>, z.ZodObject<{
620
662
  type: z.ZodLiteral<"upnl">;
@@ -628,6 +670,10 @@ export declare const TriggerListResponse: z.ZodObject<{
628
670
  TROUGH: "TROUGH";
629
671
  }>;
630
672
  threshold: z.ZodNumber;
673
+ onPositionResize: z.ZodEnum<{
674
+ cancel: "cancel";
675
+ keep: "keep";
676
+ }>;
631
677
  }, z.core.$strip>;
632
678
  }, z.core.$strip>, z.ZodObject<{
633
679
  type: z.ZodLiteral<"upnl_bps">;
@@ -684,6 +730,10 @@ export declare const TriggerListResponse: z.ZodObject<{
684
730
  mid: "mid";
685
731
  mark: "mark";
686
732
  }>;
733
+ onPositionResize: z.ZodEnum<{
734
+ cancel: "cancel";
735
+ keep: "keep";
736
+ }>;
687
737
  }, z.core.$strip>;
688
738
  }, z.core.$strip>, z.ZodObject<{
689
739
  type: z.ZodLiteral<"upnl_trailing">;
@@ -692,6 +742,10 @@ export declare const TriggerListResponse: z.ZodObject<{
692
742
  mid: "mid";
693
743
  mark: "mark";
694
744
  }>;
745
+ onPositionResize: z.ZodEnum<{
746
+ cancel: "cancel";
747
+ keep: "keep";
748
+ }>;
695
749
  }, z.core.$strip>;
696
750
  }, z.core.$strip>, z.ZodObject<{
697
751
  type: z.ZodLiteral<"upnl_bps_trailing">;
@@ -744,6 +798,7 @@ export declare const TriggerListResponse: z.ZodObject<{
744
798
  threshold: z.ZodNumber;
745
799
  }, z.core.$strip>;
746
800
  }, z.core.$strip>], "type">;
801
+ closePercent: z.ZodOptional<z.ZodNumber>;
747
802
  context: z.ZodObject<{
748
803
  type: z.ZodLiteral<"MARKET">;
749
804
  position: z.ZodObject<{
@@ -784,12 +839,13 @@ export declare const TriggerListResponse: z.ZodObject<{
784
839
  triggeredAt: z.ZodOptional<z.ZodString>;
785
840
  cancelledAt: z.ZodOptional<z.ZodString>;
786
841
  cancelledReason: z.ZodOptional<z.ZodEnum<{
787
- USER: "USER";
788
842
  POSITION_CLOSED: "POSITION_CLOSED";
843
+ USER: "USER";
789
844
  SYSTEM: "SYSTEM";
790
845
  POSITION_NETTED: "POSITION_NETTED";
791
846
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
792
847
  POSITION_REVERSED: "POSITION_REVERSED";
848
+ POSITION_RESIZED: "POSITION_RESIZED";
793
849
  }>>;
794
850
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
795
851
  id: z.ZodUUID;
@@ -802,7 +858,9 @@ export declare const TriggerListResponse: z.ZodObject<{
802
858
  }>;
803
859
  tradeAccountId: z.ZodUUID;
804
860
  symbol: z.ZodString;
805
- positionId: z.ZodUUID;
861
+ executionId: z.ZodOptional<z.ZodUUID>;
862
+ scheduleId: z.ZodOptional<z.ZodUUID>;
863
+ triggerId: z.ZodOptional<z.ZodUUID>;
806
864
  connector: z.ZodEnum<{
807
865
  hyperliquid: "hyperliquid";
808
866
  binance: "binance";
@@ -828,6 +886,13 @@ export declare const TriggerListResponse: z.ZodObject<{
828
886
  exchangeFillId: z.ZodString;
829
887
  quantity: z.ZodString;
830
888
  }, z.core.$strip>>;
889
+ assignments: z.ZodArray<z.ZodObject<{
890
+ positionId: z.ZodUUID;
891
+ quantity: z.ZodString;
892
+ usd: z.ZodString;
893
+ tradeFee: z.ZodOptional<z.ZodString>;
894
+ pearFee: z.ZodOptional<z.ZodString>;
895
+ }, z.core.$strip>>;
831
896
  }, z.core.$strip>>>;
832
897
  bracketType: z.ZodEnum<{
833
898
  NONE: "NONE";
@@ -906,6 +971,10 @@ export declare const TriggerListResponse: z.ZodObject<{
906
971
  TROUGH: "TROUGH";
907
972
  }>;
908
973
  threshold: z.ZodNumber;
974
+ onPositionResize: z.ZodEnum<{
975
+ cancel: "cancel";
976
+ keep: "keep";
977
+ }>;
909
978
  }, z.core.$strip>;
910
979
  }, z.core.$strip>, z.ZodObject<{
911
980
  type: z.ZodLiteral<"upnl">;
@@ -919,6 +988,10 @@ export declare const TriggerListResponse: z.ZodObject<{
919
988
  TROUGH: "TROUGH";
920
989
  }>;
921
990
  threshold: z.ZodNumber;
991
+ onPositionResize: z.ZodEnum<{
992
+ cancel: "cancel";
993
+ keep: "keep";
994
+ }>;
922
995
  }, z.core.$strip>;
923
996
  }, z.core.$strip>, z.ZodObject<{
924
997
  type: z.ZodLiteral<"upnl_bps">;
@@ -1040,12 +1113,13 @@ export declare const TriggerListResponse: z.ZodObject<{
1040
1113
  triggeredAt: z.ZodOptional<z.ZodString>;
1041
1114
  cancelledAt: z.ZodOptional<z.ZodString>;
1042
1115
  cancelledReason: z.ZodOptional<z.ZodEnum<{
1043
- USER: "USER";
1044
1116
  POSITION_CLOSED: "POSITION_CLOSED";
1117
+ USER: "USER";
1045
1118
  SYSTEM: "SYSTEM";
1046
1119
  POSITION_NETTED: "POSITION_NETTED";
1047
1120
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
1048
1121
  POSITION_REVERSED: "POSITION_REVERSED";
1122
+ POSITION_RESIZED: "POSITION_RESIZED";
1049
1123
  }>>;
1050
1124
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
1051
1125
  id: z.ZodUUID;
@@ -1058,7 +1132,9 @@ export declare const TriggerListResponse: z.ZodObject<{
1058
1132
  }>;
1059
1133
  tradeAccountId: z.ZodUUID;
1060
1134
  symbol: z.ZodString;
1061
- positionId: z.ZodUUID;
1135
+ executionId: z.ZodOptional<z.ZodUUID>;
1136
+ scheduleId: z.ZodOptional<z.ZodUUID>;
1137
+ triggerId: z.ZodOptional<z.ZodUUID>;
1062
1138
  connector: z.ZodEnum<{
1063
1139
  hyperliquid: "hyperliquid";
1064
1140
  binance: "binance";
@@ -1084,6 +1160,13 @@ export declare const TriggerListResponse: z.ZodObject<{
1084
1160
  exchangeFillId: z.ZodString;
1085
1161
  quantity: z.ZodString;
1086
1162
  }, z.core.$strip>>;
1163
+ assignments: z.ZodArray<z.ZodObject<{
1164
+ positionId: z.ZodUUID;
1165
+ quantity: z.ZodString;
1166
+ usd: z.ZodString;
1167
+ tradeFee: z.ZodOptional<z.ZodString>;
1168
+ pearFee: z.ZodOptional<z.ZodString>;
1169
+ }, z.core.$strip>>;
1087
1170
  }, z.core.$strip>>>;
1088
1171
  bracketType: z.ZodEnum<{
1089
1172
  NONE: "NONE";
@@ -1162,6 +1245,10 @@ export declare const TriggerListResponse: z.ZodObject<{
1162
1245
  TROUGH: "TROUGH";
1163
1246
  }>;
1164
1247
  threshold: z.ZodNumber;
1248
+ onPositionResize: z.ZodEnum<{
1249
+ cancel: "cancel";
1250
+ keep: "keep";
1251
+ }>;
1165
1252
  }, z.core.$strip>;
1166
1253
  }, z.core.$strip>, z.ZodObject<{
1167
1254
  type: z.ZodLiteral<"upnl">;
@@ -1175,6 +1262,10 @@ export declare const TriggerListResponse: z.ZodObject<{
1175
1262
  TROUGH: "TROUGH";
1176
1263
  }>;
1177
1264
  threshold: z.ZodNumber;
1265
+ onPositionResize: z.ZodEnum<{
1266
+ cancel: "cancel";
1267
+ keep: "keep";
1268
+ }>;
1178
1269
  }, z.core.$strip>;
1179
1270
  }, z.core.$strip>, z.ZodObject<{
1180
1271
  type: z.ZodLiteral<"upnl_bps">;
@@ -1231,6 +1322,10 @@ export declare const TriggerListResponse: z.ZodObject<{
1231
1322
  mid: "mid";
1232
1323
  mark: "mark";
1233
1324
  }>;
1325
+ onPositionResize: z.ZodEnum<{
1326
+ cancel: "cancel";
1327
+ keep: "keep";
1328
+ }>;
1234
1329
  }, z.core.$strip>;
1235
1330
  }, z.core.$strip>, z.ZodObject<{
1236
1331
  type: z.ZodLiteral<"upnl_trailing">;
@@ -1239,6 +1334,10 @@ export declare const TriggerListResponse: z.ZodObject<{
1239
1334
  mid: "mid";
1240
1335
  mark: "mark";
1241
1336
  }>;
1337
+ onPositionResize: z.ZodEnum<{
1338
+ cancel: "cancel";
1339
+ keep: "keep";
1340
+ }>;
1242
1341
  }, z.core.$strip>;
1243
1342
  }, z.core.$strip>, z.ZodObject<{
1244
1343
  type: z.ZodLiteral<"upnl_bps_trailing">;
@@ -1341,12 +1440,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1341
1440
  triggeredAt: z.ZodOptional<z.ZodString>;
1342
1441
  cancelledAt: z.ZodOptional<z.ZodString>;
1343
1442
  cancelledReason: z.ZodOptional<z.ZodEnum<{
1344
- USER: "USER";
1345
1443
  POSITION_CLOSED: "POSITION_CLOSED";
1444
+ USER: "USER";
1346
1445
  SYSTEM: "SYSTEM";
1347
1446
  POSITION_NETTED: "POSITION_NETTED";
1348
1447
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
1349
1448
  POSITION_REVERSED: "POSITION_REVERSED";
1449
+ POSITION_RESIZED: "POSITION_RESIZED";
1350
1450
  }>>;
1351
1451
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
1352
1452
  id: z.ZodUUID;
@@ -1359,7 +1459,9 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1359
1459
  }>;
1360
1460
  tradeAccountId: z.ZodUUID;
1361
1461
  symbol: z.ZodString;
1362
- positionId: z.ZodUUID;
1462
+ executionId: z.ZodOptional<z.ZodUUID>;
1463
+ scheduleId: z.ZodOptional<z.ZodUUID>;
1464
+ triggerId: z.ZodOptional<z.ZodUUID>;
1363
1465
  connector: z.ZodEnum<{
1364
1466
  hyperliquid: "hyperliquid";
1365
1467
  binance: "binance";
@@ -1385,6 +1487,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1385
1487
  exchangeFillId: z.ZodString;
1386
1488
  quantity: z.ZodString;
1387
1489
  }, z.core.$strip>>;
1490
+ assignments: z.ZodArray<z.ZodObject<{
1491
+ positionId: z.ZodUUID;
1492
+ quantity: z.ZodString;
1493
+ usd: z.ZodString;
1494
+ tradeFee: z.ZodOptional<z.ZodString>;
1495
+ pearFee: z.ZodOptional<z.ZodString>;
1496
+ }, z.core.$strip>>;
1388
1497
  }, z.core.$strip>>>;
1389
1498
  bracketType: z.ZodEnum<{
1390
1499
  NONE: "NONE";
@@ -1553,12 +1662,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1553
1662
  triggeredAt: z.ZodOptional<z.ZodString>;
1554
1663
  cancelledAt: z.ZodOptional<z.ZodString>;
1555
1664
  cancelledReason: z.ZodOptional<z.ZodEnum<{
1556
- USER: "USER";
1557
1665
  POSITION_CLOSED: "POSITION_CLOSED";
1666
+ USER: "USER";
1558
1667
  SYSTEM: "SYSTEM";
1559
1668
  POSITION_NETTED: "POSITION_NETTED";
1560
1669
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
1561
1670
  POSITION_REVERSED: "POSITION_REVERSED";
1671
+ POSITION_RESIZED: "POSITION_RESIZED";
1562
1672
  }>>;
1563
1673
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
1564
1674
  id: z.ZodUUID;
@@ -1571,7 +1681,9 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1571
1681
  }>;
1572
1682
  tradeAccountId: z.ZodUUID;
1573
1683
  symbol: z.ZodString;
1574
- positionId: z.ZodUUID;
1684
+ executionId: z.ZodOptional<z.ZodUUID>;
1685
+ scheduleId: z.ZodOptional<z.ZodUUID>;
1686
+ triggerId: z.ZodOptional<z.ZodUUID>;
1575
1687
  connector: z.ZodEnum<{
1576
1688
  hyperliquid: "hyperliquid";
1577
1689
  binance: "binance";
@@ -1597,6 +1709,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1597
1709
  exchangeFillId: z.ZodString;
1598
1710
  quantity: z.ZodString;
1599
1711
  }, z.core.$strip>>;
1712
+ assignments: z.ZodArray<z.ZodObject<{
1713
+ positionId: z.ZodUUID;
1714
+ quantity: z.ZodString;
1715
+ usd: z.ZodString;
1716
+ tradeFee: z.ZodOptional<z.ZodString>;
1717
+ pearFee: z.ZodOptional<z.ZodString>;
1718
+ }, z.core.$strip>>;
1600
1719
  }, z.core.$strip>>>;
1601
1720
  bracketType: z.ZodEnum<{
1602
1721
  NONE: "NONE";
@@ -1674,6 +1793,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1674
1793
  TROUGH: "TROUGH";
1675
1794
  }>;
1676
1795
  threshold: z.ZodNumber;
1796
+ onPositionResize: z.ZodEnum<{
1797
+ cancel: "cancel";
1798
+ keep: "keep";
1799
+ }>;
1677
1800
  }, z.core.$strip>;
1678
1801
  }, z.core.$strip>, z.ZodObject<{
1679
1802
  type: z.ZodLiteral<"upnl">;
@@ -1687,6 +1810,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1687
1810
  TROUGH: "TROUGH";
1688
1811
  }>;
1689
1812
  threshold: z.ZodNumber;
1813
+ onPositionResize: z.ZodEnum<{
1814
+ cancel: "cancel";
1815
+ keep: "keep";
1816
+ }>;
1690
1817
  }, z.core.$strip>;
1691
1818
  }, z.core.$strip>, z.ZodObject<{
1692
1819
  type: z.ZodLiteral<"upnl_bps">;
@@ -1811,12 +1938,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1811
1938
  triggeredAt: z.ZodOptional<z.ZodString>;
1812
1939
  cancelledAt: z.ZodOptional<z.ZodString>;
1813
1940
  cancelledReason: z.ZodOptional<z.ZodEnum<{
1814
- USER: "USER";
1815
1941
  POSITION_CLOSED: "POSITION_CLOSED";
1942
+ USER: "USER";
1816
1943
  SYSTEM: "SYSTEM";
1817
1944
  POSITION_NETTED: "POSITION_NETTED";
1818
1945
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
1819
1946
  POSITION_REVERSED: "POSITION_REVERSED";
1947
+ POSITION_RESIZED: "POSITION_RESIZED";
1820
1948
  }>>;
1821
1949
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
1822
1950
  id: z.ZodUUID;
@@ -1829,7 +1957,9 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1829
1957
  }>;
1830
1958
  tradeAccountId: z.ZodUUID;
1831
1959
  symbol: z.ZodString;
1832
- positionId: z.ZodUUID;
1960
+ executionId: z.ZodOptional<z.ZodUUID>;
1961
+ scheduleId: z.ZodOptional<z.ZodUUID>;
1962
+ triggerId: z.ZodOptional<z.ZodUUID>;
1833
1963
  connector: z.ZodEnum<{
1834
1964
  hyperliquid: "hyperliquid";
1835
1965
  binance: "binance";
@@ -1855,6 +1985,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1855
1985
  exchangeFillId: z.ZodString;
1856
1986
  quantity: z.ZodString;
1857
1987
  }, z.core.$strip>>;
1988
+ assignments: z.ZodArray<z.ZodObject<{
1989
+ positionId: z.ZodUUID;
1990
+ quantity: z.ZodString;
1991
+ usd: z.ZodString;
1992
+ tradeFee: z.ZodOptional<z.ZodString>;
1993
+ pearFee: z.ZodOptional<z.ZodString>;
1994
+ }, z.core.$strip>>;
1858
1995
  }, z.core.$strip>>>;
1859
1996
  bracketType: z.ZodEnum<{
1860
1997
  NONE: "NONE";
@@ -1932,6 +2069,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1932
2069
  TROUGH: "TROUGH";
1933
2070
  }>;
1934
2071
  threshold: z.ZodNumber;
2072
+ onPositionResize: z.ZodEnum<{
2073
+ cancel: "cancel";
2074
+ keep: "keep";
2075
+ }>;
1935
2076
  }, z.core.$strip>;
1936
2077
  }, z.core.$strip>, z.ZodObject<{
1937
2078
  type: z.ZodLiteral<"upnl">;
@@ -1945,6 +2086,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
1945
2086
  TROUGH: "TROUGH";
1946
2087
  }>;
1947
2088
  threshold: z.ZodNumber;
2089
+ onPositionResize: z.ZodEnum<{
2090
+ cancel: "cancel";
2091
+ keep: "keep";
2092
+ }>;
1948
2093
  }, z.core.$strip>;
1949
2094
  }, z.core.$strip>, z.ZodObject<{
1950
2095
  type: z.ZodLiteral<"upnl_bps">;
@@ -2001,6 +2146,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2001
2146
  mid: "mid";
2002
2147
  mark: "mark";
2003
2148
  }>;
2149
+ onPositionResize: z.ZodEnum<{
2150
+ cancel: "cancel";
2151
+ keep: "keep";
2152
+ }>;
2004
2153
  }, z.core.$strip>;
2005
2154
  }, z.core.$strip>, z.ZodObject<{
2006
2155
  type: z.ZodLiteral<"upnl_trailing">;
@@ -2009,6 +2158,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2009
2158
  mid: "mid";
2010
2159
  mark: "mark";
2011
2160
  }>;
2161
+ onPositionResize: z.ZodEnum<{
2162
+ cancel: "cancel";
2163
+ keep: "keep";
2164
+ }>;
2012
2165
  }, z.core.$strip>;
2013
2166
  }, z.core.$strip>, z.ZodObject<{
2014
2167
  type: z.ZodLiteral<"upnl_bps_trailing">;
@@ -2061,6 +2214,7 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2061
2214
  threshold: z.ZodNumber;
2062
2215
  }, z.core.$strip>;
2063
2216
  }, z.core.$strip>], "type">;
2217
+ closePercent: z.ZodOptional<z.ZodNumber>;
2064
2218
  context: z.ZodObject<{
2065
2219
  type: z.ZodLiteral<"MARKET">;
2066
2220
  position: z.ZodObject<{
@@ -2101,12 +2255,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2101
2255
  triggeredAt: z.ZodOptional<z.ZodString>;
2102
2256
  cancelledAt: z.ZodOptional<z.ZodString>;
2103
2257
  cancelledReason: z.ZodOptional<z.ZodEnum<{
2104
- USER: "USER";
2105
2258
  POSITION_CLOSED: "POSITION_CLOSED";
2259
+ USER: "USER";
2106
2260
  SYSTEM: "SYSTEM";
2107
2261
  POSITION_NETTED: "POSITION_NETTED";
2108
2262
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
2109
2263
  POSITION_REVERSED: "POSITION_REVERSED";
2264
+ POSITION_RESIZED: "POSITION_RESIZED";
2110
2265
  }>>;
2111
2266
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
2112
2267
  id: z.ZodUUID;
@@ -2119,7 +2274,9 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2119
2274
  }>;
2120
2275
  tradeAccountId: z.ZodUUID;
2121
2276
  symbol: z.ZodString;
2122
- positionId: z.ZodUUID;
2277
+ executionId: z.ZodOptional<z.ZodUUID>;
2278
+ scheduleId: z.ZodOptional<z.ZodUUID>;
2279
+ triggerId: z.ZodOptional<z.ZodUUID>;
2123
2280
  connector: z.ZodEnum<{
2124
2281
  hyperliquid: "hyperliquid";
2125
2282
  binance: "binance";
@@ -2145,6 +2302,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2145
2302
  exchangeFillId: z.ZodString;
2146
2303
  quantity: z.ZodString;
2147
2304
  }, z.core.$strip>>;
2305
+ assignments: z.ZodArray<z.ZodObject<{
2306
+ positionId: z.ZodUUID;
2307
+ quantity: z.ZodString;
2308
+ usd: z.ZodString;
2309
+ tradeFee: z.ZodOptional<z.ZodString>;
2310
+ pearFee: z.ZodOptional<z.ZodString>;
2311
+ }, z.core.$strip>>;
2148
2312
  }, z.core.$strip>>>;
2149
2313
  bracketType: z.ZodEnum<{
2150
2314
  NONE: "NONE";
@@ -2223,6 +2387,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2223
2387
  TROUGH: "TROUGH";
2224
2388
  }>;
2225
2389
  threshold: z.ZodNumber;
2390
+ onPositionResize: z.ZodEnum<{
2391
+ cancel: "cancel";
2392
+ keep: "keep";
2393
+ }>;
2226
2394
  }, z.core.$strip>;
2227
2395
  }, z.core.$strip>, z.ZodObject<{
2228
2396
  type: z.ZodLiteral<"upnl">;
@@ -2236,6 +2404,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2236
2404
  TROUGH: "TROUGH";
2237
2405
  }>;
2238
2406
  threshold: z.ZodNumber;
2407
+ onPositionResize: z.ZodEnum<{
2408
+ cancel: "cancel";
2409
+ keep: "keep";
2410
+ }>;
2239
2411
  }, z.core.$strip>;
2240
2412
  }, z.core.$strip>, z.ZodObject<{
2241
2413
  type: z.ZodLiteral<"upnl_bps">;
@@ -2357,12 +2529,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2357
2529
  triggeredAt: z.ZodOptional<z.ZodString>;
2358
2530
  cancelledAt: z.ZodOptional<z.ZodString>;
2359
2531
  cancelledReason: z.ZodOptional<z.ZodEnum<{
2360
- USER: "USER";
2361
2532
  POSITION_CLOSED: "POSITION_CLOSED";
2533
+ USER: "USER";
2362
2534
  SYSTEM: "SYSTEM";
2363
2535
  POSITION_NETTED: "POSITION_NETTED";
2364
2536
  POSITION_LIQUIDATED: "POSITION_LIQUIDATED";
2365
2537
  POSITION_REVERSED: "POSITION_REVERSED";
2538
+ POSITION_RESIZED: "POSITION_RESIZED";
2366
2539
  }>>;
2367
2540
  fills: z.ZodOptional<z.ZodArray<z.ZodObject<{
2368
2541
  id: z.ZodUUID;
@@ -2375,7 +2548,9 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2375
2548
  }>;
2376
2549
  tradeAccountId: z.ZodUUID;
2377
2550
  symbol: z.ZodString;
2378
- positionId: z.ZodUUID;
2551
+ executionId: z.ZodOptional<z.ZodUUID>;
2552
+ scheduleId: z.ZodOptional<z.ZodUUID>;
2553
+ triggerId: z.ZodOptional<z.ZodUUID>;
2379
2554
  connector: z.ZodEnum<{
2380
2555
  hyperliquid: "hyperliquid";
2381
2556
  binance: "binance";
@@ -2401,6 +2576,13 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2401
2576
  exchangeFillId: z.ZodString;
2402
2577
  quantity: z.ZodString;
2403
2578
  }, z.core.$strip>>;
2579
+ assignments: z.ZodArray<z.ZodObject<{
2580
+ positionId: z.ZodUUID;
2581
+ quantity: z.ZodString;
2582
+ usd: z.ZodString;
2583
+ tradeFee: z.ZodOptional<z.ZodString>;
2584
+ pearFee: z.ZodOptional<z.ZodString>;
2585
+ }, z.core.$strip>>;
2404
2586
  }, z.core.$strip>>>;
2405
2587
  bracketType: z.ZodEnum<{
2406
2588
  NONE: "NONE";
@@ -2479,6 +2661,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2479
2661
  TROUGH: "TROUGH";
2480
2662
  }>;
2481
2663
  threshold: z.ZodNumber;
2664
+ onPositionResize: z.ZodEnum<{
2665
+ cancel: "cancel";
2666
+ keep: "keep";
2667
+ }>;
2482
2668
  }, z.core.$strip>;
2483
2669
  }, z.core.$strip>, z.ZodObject<{
2484
2670
  type: z.ZodLiteral<"upnl">;
@@ -2492,6 +2678,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2492
2678
  TROUGH: "TROUGH";
2493
2679
  }>;
2494
2680
  threshold: z.ZodNumber;
2681
+ onPositionResize: z.ZodEnum<{
2682
+ cancel: "cancel";
2683
+ keep: "keep";
2684
+ }>;
2495
2685
  }, z.core.$strip>;
2496
2686
  }, z.core.$strip>, z.ZodObject<{
2497
2687
  type: z.ZodLiteral<"upnl_bps">;
@@ -2548,6 +2738,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2548
2738
  mid: "mid";
2549
2739
  mark: "mark";
2550
2740
  }>;
2741
+ onPositionResize: z.ZodEnum<{
2742
+ cancel: "cancel";
2743
+ keep: "keep";
2744
+ }>;
2551
2745
  }, z.core.$strip>;
2552
2746
  }, z.core.$strip>, z.ZodObject<{
2553
2747
  type: z.ZodLiteral<"upnl_trailing">;
@@ -2556,6 +2750,10 @@ export declare const CreateTriggerResponse: z.ZodObject<{
2556
2750
  mid: "mid";
2557
2751
  mark: "mark";
2558
2752
  }>;
2753
+ onPositionResize: z.ZodEnum<{
2754
+ cancel: "cancel";
2755
+ keep: "keep";
2756
+ }>;
2559
2757
  }, z.core.$strip>;
2560
2758
  }, z.core.$strip>, z.ZodObject<{
2561
2759
  type: z.ZodLiteral<"upnl_bps_trailing">;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pear-protocol/types",
3
- "version": "2.22.1",
3
+ "version": "2.24.0",
4
4
  "description": "Pear Protocol Types definitions",
5
5
  "private": false,
6
6
  "type": "module",