@venusprotocol/venus-periphery 1.2.0-slim-dev.3 → 1.2.0-slim-dev.5

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 (28) hide show
  1. package/artifacts/contracts/DeviationSentinel/DeviationSentinel.sol/DeviationSentinel.json +2 -2
  2. package/artifacts/contracts/DeviationSentinel/Oracles/PancakeSwapOracle.sol/PancakeSwapOracle.json +2 -2
  3. package/artifacts/contracts/DeviationSentinel/Oracles/SentinelOracle.sol/SentinelOracle.json +2 -2
  4. package/artifacts/contracts/DeviationSentinel/Oracles/UniswapOracle.sol/UniswapOracle.json +2 -2
  5. package/artifacts/contracts/Interfaces/IComptroller.sol/IComptroller.json +37 -0
  6. package/artifacts/contracts/Interfaces/ICorePoolComptroller.sol/ICorePoolComptroller.json +37 -0
  7. package/artifacts/contracts/Interfaces/IVBNB.sol/IVBNB.json +37 -0
  8. package/artifacts/contracts/Interfaces/IVToken.sol/IVToken.json +37 -0
  9. package/artifacts/contracts/LeverageManager/LeverageStrategiesManager.sol/LeverageStrategiesManager.json +2 -2
  10. package/artifacts/contracts/Libraries/FixedPoint96.sol/FixedPoint96.json +2 -2
  11. package/artifacts/contracts/Libraries/FullMath.sol/FullMath.json +2 -2
  12. package/artifacts/contracts/PositionSwapper/PositionSwapper.sol/PositionSwapper.json +2 -2
  13. package/artifacts/contracts/RelativePositionManager/IPositionAccount.sol/IPositionAccount.json +250 -0
  14. package/artifacts/contracts/RelativePositionManager/IRelativePositionManager.sol/IRelativePositionManager.json +1580 -0
  15. package/artifacts/contracts/RelativePositionManager/PositionAccount.sol/PositionAccount.json +448 -0
  16. package/artifacts/contracts/RelativePositionManager/RelativePositionManager.sol/RelativePositionManager.json +2021 -0
  17. package/artifacts/contracts/SwapHelper/SwapHelper.sol/SwapHelper.json +2 -2
  18. package/artifacts/contracts/SwapRouter/SwapRouter.sol/SwapRouter.json +2 -2
  19. package/artifacts/contracts/pendle-pt-fixed-rate-vault/PendlePTVaultAdapter.sol/PendlePTVaultAdapter.json +1763 -0
  20. package/artifacts/contracts/pendle-pt-fixed-rate-vault/interfaces/IPendlePTVaultAdapter.sol/IPendlePTVaultAdapter.json +1463 -0
  21. package/artifacts/contracts/pendle-pt-fixed-rate-vault/interfaces/IVenusComptroller.sol/IVenusComptroller.json +54 -0
  22. package/artifacts/contracts/pendle-pt-fixed-rate-vault/interfaces/IVenusVToken.sol/IVenusVToken.json +104 -0
  23. package/artifacts/contracts/pendle-pt-fixed-rate-vault/test/AggregatorMock.sol/AggregatorMock.json +123 -0
  24. package/artifacts/contracts/pendle-pt-fixed-rate-vault/test/IPancakeRouterV2.sol/IPancakeRouterV2.json +89 -0
  25. package/artifacts/contracts/test/MockTarget.sol/MockTarget.json +2 -2
  26. package/deployments/bscmainnet_addresses.json +7 -0
  27. package/deployments/bsctestnet_addresses.json +8 -1
  28. package/package.json +1 -1
@@ -0,0 +1,1580 @@
1
+ {
2
+ "_format": "hh-sol-artifact-1",
3
+ "contractName": "IRelativePositionManager",
4
+ "sourceName": "contracts/RelativePositionManager/IRelativePositionManager.sol",
5
+ "abi": [
6
+ {
7
+ "inputs": [],
8
+ "name": "AssetNotListed",
9
+ "type": "error"
10
+ },
11
+ {
12
+ "inputs": [],
13
+ "name": "BorrowAmountExceedsMaximum",
14
+ "type": "error"
15
+ },
16
+ {
17
+ "inputs": [],
18
+ "name": "CompletelyPaused",
19
+ "type": "error"
20
+ },
21
+ {
22
+ "inputs": [],
23
+ "name": "DSAInactive",
24
+ "type": "error"
25
+ },
26
+ {
27
+ "inputs": [],
28
+ "name": "DSAVTokenAlreadyAdded",
29
+ "type": "error"
30
+ },
31
+ {
32
+ "inputs": [
33
+ {
34
+ "internalType": "uint256",
35
+ "name": "errorCode",
36
+ "type": "uint256"
37
+ }
38
+ ],
39
+ "name": "EnterMarketFailed",
40
+ "type": "error"
41
+ },
42
+ {
43
+ "inputs": [],
44
+ "name": "ExcessiveShortDust",
45
+ "type": "error"
46
+ },
47
+ {
48
+ "inputs": [],
49
+ "name": "InsufficientPrincipal",
50
+ "type": "error"
51
+ },
52
+ {
53
+ "inputs": [],
54
+ "name": "InsufficientWithdrawableAmount",
55
+ "type": "error"
56
+ },
57
+ {
58
+ "inputs": [],
59
+ "name": "InvalidCloseFractionBps",
60
+ "type": "error"
61
+ },
62
+ {
63
+ "inputs": [],
64
+ "name": "InvalidCollateralFactor",
65
+ "type": "error"
66
+ },
67
+ {
68
+ "inputs": [],
69
+ "name": "InvalidDSA",
70
+ "type": "error"
71
+ },
72
+ {
73
+ "inputs": [],
74
+ "name": "InvalidLeverage",
75
+ "type": "error"
76
+ },
77
+ {
78
+ "inputs": [],
79
+ "name": "InvalidLongAmountToRedeem",
80
+ "type": "error"
81
+ },
82
+ {
83
+ "inputs": [],
84
+ "name": "InvalidOraclePrice",
85
+ "type": "error"
86
+ },
87
+ {
88
+ "inputs": [],
89
+ "name": "InvalidProportionalCloseTolerance",
90
+ "type": "error"
91
+ },
92
+ {
93
+ "inputs": [],
94
+ "name": "MinAmountOutRepayBelowDebt",
95
+ "type": "error"
96
+ },
97
+ {
98
+ "inputs": [],
99
+ "name": "MinAmountOutSecondBelowDebt",
100
+ "type": "error"
101
+ },
102
+ {
103
+ "inputs": [
104
+ {
105
+ "internalType": "uint256",
106
+ "name": "errorCode",
107
+ "type": "uint256"
108
+ }
109
+ ],
110
+ "name": "MintBehalfFailed",
111
+ "type": "error"
112
+ },
113
+ {
114
+ "inputs": [],
115
+ "name": "PartiallyPaused",
116
+ "type": "error"
117
+ },
118
+ {
119
+ "inputs": [],
120
+ "name": "PositionAccountImplementationLocked",
121
+ "type": "error"
122
+ },
123
+ {
124
+ "inputs": [],
125
+ "name": "PositionAccountImplementationNotSet",
126
+ "type": "error"
127
+ },
128
+ {
129
+ "inputs": [],
130
+ "name": "PositionAlreadyExists",
131
+ "type": "error"
132
+ },
133
+ {
134
+ "inputs": [],
135
+ "name": "PositionNotActive",
136
+ "type": "error"
137
+ },
138
+ {
139
+ "inputs": [],
140
+ "name": "PositionNotFullyClosed",
141
+ "type": "error"
142
+ },
143
+ {
144
+ "inputs": [],
145
+ "name": "ProportionalCloseAmountOutOfTolerance",
146
+ "type": "error"
147
+ },
148
+ {
149
+ "inputs": [
150
+ {
151
+ "internalType": "uint256",
152
+ "name": "errorCode",
153
+ "type": "uint256"
154
+ }
155
+ ],
156
+ "name": "RedeemBehalfFailed",
157
+ "type": "error"
158
+ },
159
+ {
160
+ "inputs": [],
161
+ "name": "SameDSAActiveStatus",
162
+ "type": "error"
163
+ },
164
+ {
165
+ "inputs": [],
166
+ "name": "SameMarketNotAllowed",
167
+ "type": "error"
168
+ },
169
+ {
170
+ "inputs": [],
171
+ "name": "SameProportionalCloseTolerance",
172
+ "type": "error"
173
+ },
174
+ {
175
+ "inputs": [],
176
+ "name": "SlippageExceeded",
177
+ "type": "error"
178
+ },
179
+ {
180
+ "inputs": [],
181
+ "name": "TokenSwapCallFailed",
182
+ "type": "error"
183
+ },
184
+ {
185
+ "inputs": [],
186
+ "name": "VBNBNotSupported",
187
+ "type": "error"
188
+ },
189
+ {
190
+ "inputs": [],
191
+ "name": "ZeroAddress",
192
+ "type": "error"
193
+ },
194
+ {
195
+ "inputs": [],
196
+ "name": "ZeroAmount",
197
+ "type": "error"
198
+ },
199
+ {
200
+ "inputs": [],
201
+ "name": "ZeroDebt",
202
+ "type": "error"
203
+ },
204
+ {
205
+ "inputs": [],
206
+ "name": "ZeroShortAmount",
207
+ "type": "error"
208
+ },
209
+ {
210
+ "inputs": [],
211
+ "name": "ZeroVTokensMinted",
212
+ "type": "error"
213
+ },
214
+ {
215
+ "anonymous": false,
216
+ "inputs": [
217
+ {
218
+ "indexed": false,
219
+ "internalType": "bool",
220
+ "name": "paused",
221
+ "type": "bool"
222
+ }
223
+ ],
224
+ "name": "CompletePauseToggled",
225
+ "type": "event"
226
+ },
227
+ {
228
+ "anonymous": false,
229
+ "inputs": [
230
+ {
231
+ "indexed": true,
232
+ "internalType": "address",
233
+ "name": "dsaVToken",
234
+ "type": "address"
235
+ },
236
+ {
237
+ "indexed": false,
238
+ "internalType": "uint8",
239
+ "name": "index",
240
+ "type": "uint8"
241
+ },
242
+ {
243
+ "indexed": false,
244
+ "internalType": "bool",
245
+ "name": "active",
246
+ "type": "bool"
247
+ }
248
+ ],
249
+ "name": "DSAVTokenActiveUpdated",
250
+ "type": "event"
251
+ },
252
+ {
253
+ "anonymous": false,
254
+ "inputs": [
255
+ {
256
+ "indexed": true,
257
+ "internalType": "address",
258
+ "name": "dsaVToken",
259
+ "type": "address"
260
+ },
261
+ {
262
+ "indexed": false,
263
+ "internalType": "uint8",
264
+ "name": "index",
265
+ "type": "uint8"
266
+ }
267
+ ],
268
+ "name": "DSAVTokenAdded",
269
+ "type": "event"
270
+ },
271
+ {
272
+ "anonymous": false,
273
+ "inputs": [
274
+ {
275
+ "indexed": false,
276
+ "internalType": "bool",
277
+ "name": "paused",
278
+ "type": "bool"
279
+ }
280
+ ],
281
+ "name": "PartialPauseToggled",
282
+ "type": "event"
283
+ },
284
+ {
285
+ "anonymous": false,
286
+ "inputs": [
287
+ {
288
+ "indexed": true,
289
+ "internalType": "address",
290
+ "name": "user",
291
+ "type": "address"
292
+ },
293
+ {
294
+ "indexed": true,
295
+ "internalType": "address",
296
+ "name": "longAsset",
297
+ "type": "address"
298
+ },
299
+ {
300
+ "indexed": true,
301
+ "internalType": "address",
302
+ "name": "shortAsset",
303
+ "type": "address"
304
+ },
305
+ {
306
+ "indexed": false,
307
+ "internalType": "address",
308
+ "name": "positionAccount",
309
+ "type": "address"
310
+ }
311
+ ],
312
+ "name": "PositionAccountDeployed",
313
+ "type": "event"
314
+ },
315
+ {
316
+ "anonymous": false,
317
+ "inputs": [
318
+ {
319
+ "indexed": true,
320
+ "internalType": "address",
321
+ "name": "implementation",
322
+ "type": "address"
323
+ }
324
+ ],
325
+ "name": "PositionAccountImplementationSet",
326
+ "type": "event"
327
+ },
328
+ {
329
+ "anonymous": false,
330
+ "inputs": [
331
+ {
332
+ "indexed": true,
333
+ "internalType": "address",
334
+ "name": "user",
335
+ "type": "address"
336
+ },
337
+ {
338
+ "indexed": true,
339
+ "internalType": "address",
340
+ "name": "longAsset",
341
+ "type": "address"
342
+ },
343
+ {
344
+ "indexed": true,
345
+ "internalType": "address",
346
+ "name": "shortAsset",
347
+ "type": "address"
348
+ },
349
+ {
350
+ "indexed": false,
351
+ "internalType": "address",
352
+ "name": "dsaAsset",
353
+ "type": "address"
354
+ },
355
+ {
356
+ "indexed": false,
357
+ "internalType": "address",
358
+ "name": "positionAccount",
359
+ "type": "address"
360
+ },
361
+ {
362
+ "indexed": false,
363
+ "internalType": "uint256",
364
+ "name": "cycleId",
365
+ "type": "uint256"
366
+ },
367
+ {
368
+ "indexed": false,
369
+ "internalType": "uint256",
370
+ "name": "initialPrincipal",
371
+ "type": "uint256"
372
+ },
373
+ {
374
+ "indexed": false,
375
+ "internalType": "uint256",
376
+ "name": "effectiveLeverage",
377
+ "type": "uint256"
378
+ }
379
+ ],
380
+ "name": "PositionActivated",
381
+ "type": "event"
382
+ },
383
+ {
384
+ "anonymous": false,
385
+ "inputs": [
386
+ {
387
+ "indexed": true,
388
+ "internalType": "address",
389
+ "name": "user",
390
+ "type": "address"
391
+ },
392
+ {
393
+ "indexed": true,
394
+ "internalType": "address",
395
+ "name": "positionAccount",
396
+ "type": "address"
397
+ },
398
+ {
399
+ "indexed": false,
400
+ "internalType": "uint256",
401
+ "name": "cycleId",
402
+ "type": "uint256"
403
+ },
404
+ {
405
+ "indexed": false,
406
+ "internalType": "uint256",
407
+ "name": "closeFractionBps",
408
+ "type": "uint256"
409
+ },
410
+ {
411
+ "indexed": false,
412
+ "internalType": "uint256",
413
+ "name": "amountRepaid",
414
+ "type": "uint256"
415
+ },
416
+ {
417
+ "indexed": false,
418
+ "internalType": "uint256",
419
+ "name": "amountRedeemed",
420
+ "type": "uint256"
421
+ },
422
+ {
423
+ "indexed": false,
424
+ "internalType": "uint256",
425
+ "name": "amountRedeemedDsa",
426
+ "type": "uint256"
427
+ },
428
+ {
429
+ "indexed": false,
430
+ "internalType": "uint256",
431
+ "name": "longDustRedeemed",
432
+ "type": "uint256"
433
+ }
434
+ ],
435
+ "name": "PositionClosed",
436
+ "type": "event"
437
+ },
438
+ {
439
+ "anonymous": false,
440
+ "inputs": [
441
+ {
442
+ "indexed": true,
443
+ "internalType": "address",
444
+ "name": "user",
445
+ "type": "address"
446
+ },
447
+ {
448
+ "indexed": true,
449
+ "internalType": "address",
450
+ "name": "positionAccount",
451
+ "type": "address"
452
+ },
453
+ {
454
+ "indexed": false,
455
+ "internalType": "uint256",
456
+ "name": "cycleId",
457
+ "type": "uint256"
458
+ },
459
+ {
460
+ "indexed": false,
461
+ "internalType": "uint256",
462
+ "name": "longRedeemed",
463
+ "type": "uint256"
464
+ },
465
+ {
466
+ "indexed": false,
467
+ "internalType": "uint256",
468
+ "name": "dsaRedeemed",
469
+ "type": "uint256"
470
+ }
471
+ ],
472
+ "name": "PositionDeactivated",
473
+ "type": "event"
474
+ },
475
+ {
476
+ "anonymous": false,
477
+ "inputs": [
478
+ {
479
+ "indexed": true,
480
+ "internalType": "address",
481
+ "name": "user",
482
+ "type": "address"
483
+ },
484
+ {
485
+ "indexed": true,
486
+ "internalType": "address",
487
+ "name": "positionAccount",
488
+ "type": "address"
489
+ },
490
+ {
491
+ "indexed": false,
492
+ "internalType": "uint256",
493
+ "name": "cycleId",
494
+ "type": "uint256"
495
+ },
496
+ {
497
+ "indexed": false,
498
+ "internalType": "address",
499
+ "name": "longAsset",
500
+ "type": "address"
501
+ },
502
+ {
503
+ "indexed": false,
504
+ "internalType": "address",
505
+ "name": "shortAsset",
506
+ "type": "address"
507
+ },
508
+ {
509
+ "indexed": false,
510
+ "internalType": "address",
511
+ "name": "dsaAsset",
512
+ "type": "address"
513
+ },
514
+ {
515
+ "indexed": false,
516
+ "internalType": "uint256",
517
+ "name": "shortAmount",
518
+ "type": "uint256"
519
+ },
520
+ {
521
+ "indexed": false,
522
+ "internalType": "uint256",
523
+ "name": "initialPrincipal",
524
+ "type": "uint256"
525
+ }
526
+ ],
527
+ "name": "PositionOpened",
528
+ "type": "event"
529
+ },
530
+ {
531
+ "anonymous": false,
532
+ "inputs": [
533
+ {
534
+ "indexed": true,
535
+ "internalType": "address",
536
+ "name": "user",
537
+ "type": "address"
538
+ },
539
+ {
540
+ "indexed": true,
541
+ "internalType": "address",
542
+ "name": "positionAccount",
543
+ "type": "address"
544
+ },
545
+ {
546
+ "indexed": false,
547
+ "internalType": "uint256",
548
+ "name": "cycleId",
549
+ "type": "uint256"
550
+ },
551
+ {
552
+ "indexed": false,
553
+ "internalType": "address",
554
+ "name": "longAsset",
555
+ "type": "address"
556
+ },
557
+ {
558
+ "indexed": false,
559
+ "internalType": "address",
560
+ "name": "shortAsset",
561
+ "type": "address"
562
+ },
563
+ {
564
+ "indexed": false,
565
+ "internalType": "address",
566
+ "name": "dsaAsset",
567
+ "type": "address"
568
+ },
569
+ {
570
+ "indexed": false,
571
+ "internalType": "uint256",
572
+ "name": "shortAmount",
573
+ "type": "uint256"
574
+ },
575
+ {
576
+ "indexed": false,
577
+ "internalType": "uint256",
578
+ "name": "additionalPrincipal",
579
+ "type": "uint256"
580
+ }
581
+ ],
582
+ "name": "PositionScaled",
583
+ "type": "event"
584
+ },
585
+ {
586
+ "anonymous": false,
587
+ "inputs": [
588
+ {
589
+ "indexed": true,
590
+ "internalType": "address",
591
+ "name": "user",
592
+ "type": "address"
593
+ },
594
+ {
595
+ "indexed": true,
596
+ "internalType": "address",
597
+ "name": "positionAccount",
598
+ "type": "address"
599
+ },
600
+ {
601
+ "indexed": false,
602
+ "internalType": "uint256",
603
+ "name": "cycleId",
604
+ "type": "uint256"
605
+ },
606
+ {
607
+ "indexed": false,
608
+ "internalType": "address",
609
+ "name": "dsaAsset",
610
+ "type": "address"
611
+ },
612
+ {
613
+ "indexed": false,
614
+ "internalType": "uint256",
615
+ "name": "amount",
616
+ "type": "uint256"
617
+ },
618
+ {
619
+ "indexed": false,
620
+ "internalType": "uint256",
621
+ "name": "newTotalPrincipal",
622
+ "type": "uint256"
623
+ }
624
+ ],
625
+ "name": "PrincipalSupplied",
626
+ "type": "event"
627
+ },
628
+ {
629
+ "anonymous": false,
630
+ "inputs": [
631
+ {
632
+ "indexed": true,
633
+ "internalType": "address",
634
+ "name": "user",
635
+ "type": "address"
636
+ },
637
+ {
638
+ "indexed": true,
639
+ "internalType": "address",
640
+ "name": "positionAccount",
641
+ "type": "address"
642
+ },
643
+ {
644
+ "indexed": false,
645
+ "internalType": "uint256",
646
+ "name": "cycleId",
647
+ "type": "uint256"
648
+ },
649
+ {
650
+ "indexed": false,
651
+ "internalType": "address",
652
+ "name": "dsaAsset",
653
+ "type": "address"
654
+ },
655
+ {
656
+ "indexed": false,
657
+ "internalType": "uint256",
658
+ "name": "amount",
659
+ "type": "uint256"
660
+ },
661
+ {
662
+ "indexed": false,
663
+ "internalType": "uint256",
664
+ "name": "remainingPrincipal",
665
+ "type": "uint256"
666
+ }
667
+ ],
668
+ "name": "PrincipalWithdrawn",
669
+ "type": "event"
670
+ },
671
+ {
672
+ "anonymous": false,
673
+ "inputs": [
674
+ {
675
+ "indexed": true,
676
+ "internalType": "address",
677
+ "name": "user",
678
+ "type": "address"
679
+ },
680
+ {
681
+ "indexed": true,
682
+ "internalType": "address",
683
+ "name": "positionAccount",
684
+ "type": "address"
685
+ },
686
+ {
687
+ "indexed": false,
688
+ "internalType": "uint256",
689
+ "name": "amountConvertedToProfit",
690
+ "type": "uint256"
691
+ },
692
+ {
693
+ "indexed": false,
694
+ "internalType": "uint256",
695
+ "name": "newTotalPrincipal",
696
+ "type": "uint256"
697
+ }
698
+ ],
699
+ "name": "ProfitConverted",
700
+ "type": "event"
701
+ },
702
+ {
703
+ "anonymous": false,
704
+ "inputs": [
705
+ {
706
+ "indexed": true,
707
+ "internalType": "uint256",
708
+ "name": "oldTolerance",
709
+ "type": "uint256"
710
+ },
711
+ {
712
+ "indexed": true,
713
+ "internalType": "uint256",
714
+ "name": "newTolerance",
715
+ "type": "uint256"
716
+ }
717
+ ],
718
+ "name": "ProportionalCloseToleranceUpdated",
719
+ "type": "event"
720
+ },
721
+ {
722
+ "anonymous": false,
723
+ "inputs": [
724
+ {
725
+ "indexed": true,
726
+ "internalType": "address",
727
+ "name": "user",
728
+ "type": "address"
729
+ },
730
+ {
731
+ "indexed": true,
732
+ "internalType": "address",
733
+ "name": "positionAccount",
734
+ "type": "address"
735
+ },
736
+ {
737
+ "indexed": false,
738
+ "internalType": "uint256",
739
+ "name": "oldSuppliedPrincipal",
740
+ "type": "uint256"
741
+ },
742
+ {
743
+ "indexed": false,
744
+ "internalType": "uint256",
745
+ "name": "newSuppliedPrincipal",
746
+ "type": "uint256"
747
+ }
748
+ ],
749
+ "name": "RefreshedSuppliedPrincipal",
750
+ "type": "event"
751
+ },
752
+ {
753
+ "anonymous": false,
754
+ "inputs": [
755
+ {
756
+ "indexed": true,
757
+ "internalType": "address",
758
+ "name": "token",
759
+ "type": "address"
760
+ },
761
+ {
762
+ "indexed": true,
763
+ "internalType": "address",
764
+ "name": "from",
765
+ "type": "address"
766
+ },
767
+ {
768
+ "indexed": true,
769
+ "internalType": "address",
770
+ "name": "to",
771
+ "type": "address"
772
+ },
773
+ {
774
+ "indexed": false,
775
+ "internalType": "uint256",
776
+ "name": "amount",
777
+ "type": "uint256"
778
+ }
779
+ ],
780
+ "name": "UnderlyingTransferred",
781
+ "type": "event"
782
+ },
783
+ {
784
+ "inputs": [
785
+ {
786
+ "internalType": "address",
787
+ "name": "longVToken",
788
+ "type": "address"
789
+ },
790
+ {
791
+ "internalType": "address",
792
+ "name": "shortVToken",
793
+ "type": "address"
794
+ },
795
+ {
796
+ "internalType": "uint8",
797
+ "name": "dsaIndex",
798
+ "type": "uint8"
799
+ },
800
+ {
801
+ "internalType": "uint256",
802
+ "name": "initialPrincipal",
803
+ "type": "uint256"
804
+ },
805
+ {
806
+ "internalType": "uint256",
807
+ "name": "effectiveLeverage",
808
+ "type": "uint256"
809
+ },
810
+ {
811
+ "internalType": "uint256",
812
+ "name": "shortAmount",
813
+ "type": "uint256"
814
+ },
815
+ {
816
+ "internalType": "uint256",
817
+ "name": "minLongAmount",
818
+ "type": "uint256"
819
+ },
820
+ {
821
+ "internalType": "bytes",
822
+ "name": "swapData",
823
+ "type": "bytes"
824
+ }
825
+ ],
826
+ "name": "activateAndOpenPosition",
827
+ "outputs": [],
828
+ "stateMutability": "nonpayable",
829
+ "type": "function"
830
+ },
831
+ {
832
+ "inputs": [
833
+ {
834
+ "internalType": "address",
835
+ "name": "dsaVToken",
836
+ "type": "address"
837
+ }
838
+ ],
839
+ "name": "addDSAVToken",
840
+ "outputs": [],
841
+ "stateMutability": "nonpayable",
842
+ "type": "function"
843
+ },
844
+ {
845
+ "inputs": [
846
+ {
847
+ "internalType": "contract IVToken",
848
+ "name": "longVToken",
849
+ "type": "address"
850
+ },
851
+ {
852
+ "internalType": "contract IVToken",
853
+ "name": "shortVToken",
854
+ "type": "address"
855
+ },
856
+ {
857
+ "internalType": "uint256",
858
+ "name": "closeFractionBps",
859
+ "type": "uint256"
860
+ },
861
+ {
862
+ "internalType": "uint256",
863
+ "name": "longAmountToRedeemForFirstSwap",
864
+ "type": "uint256"
865
+ },
866
+ {
867
+ "internalType": "uint256",
868
+ "name": "shortAmountToRepayForFirstSwap",
869
+ "type": "uint256"
870
+ },
871
+ {
872
+ "internalType": "uint256",
873
+ "name": "minAmountOutFirst",
874
+ "type": "uint256"
875
+ },
876
+ {
877
+ "internalType": "bytes",
878
+ "name": "swapDataFirst",
879
+ "type": "bytes"
880
+ },
881
+ {
882
+ "internalType": "uint256",
883
+ "name": "dsaAmountToRedeemForSecondSwap",
884
+ "type": "uint256"
885
+ },
886
+ {
887
+ "internalType": "uint256",
888
+ "name": "minAmountOutSecond",
889
+ "type": "uint256"
890
+ },
891
+ {
892
+ "internalType": "bytes",
893
+ "name": "swapDataSecond",
894
+ "type": "bytes"
895
+ }
896
+ ],
897
+ "name": "closeWithLoss",
898
+ "outputs": [],
899
+ "stateMutability": "nonpayable",
900
+ "type": "function"
901
+ },
902
+ {
903
+ "inputs": [
904
+ {
905
+ "internalType": "contract IVToken",
906
+ "name": "longVToken",
907
+ "type": "address"
908
+ },
909
+ {
910
+ "internalType": "contract IVToken",
911
+ "name": "shortVToken",
912
+ "type": "address"
913
+ },
914
+ {
915
+ "components": [
916
+ {
917
+ "internalType": "uint256",
918
+ "name": "longAmountToRedeemForFirstSwap",
919
+ "type": "uint256"
920
+ },
921
+ {
922
+ "internalType": "uint256",
923
+ "name": "shortAmountToRepayForFirstSwap",
924
+ "type": "uint256"
925
+ },
926
+ {
927
+ "internalType": "uint256",
928
+ "name": "minAmountOutFirst",
929
+ "type": "uint256"
930
+ },
931
+ {
932
+ "internalType": "bytes",
933
+ "name": "swapDataFirst",
934
+ "type": "bytes"
935
+ },
936
+ {
937
+ "internalType": "uint256",
938
+ "name": "dsaAmountToRedeemForSecondSwap",
939
+ "type": "uint256"
940
+ },
941
+ {
942
+ "internalType": "uint256",
943
+ "name": "minAmountOutSecond",
944
+ "type": "uint256"
945
+ },
946
+ {
947
+ "internalType": "bytes",
948
+ "name": "swapDataSecond",
949
+ "type": "bytes"
950
+ }
951
+ ],
952
+ "internalType": "struct IRelativePositionManager.CloseWithLossParams",
953
+ "name": "lossSwapParams",
954
+ "type": "tuple"
955
+ }
956
+ ],
957
+ "name": "closeWithLossAndDeactivate",
958
+ "outputs": [],
959
+ "stateMutability": "nonpayable",
960
+ "type": "function"
961
+ },
962
+ {
963
+ "inputs": [
964
+ {
965
+ "internalType": "contract IVToken",
966
+ "name": "longVToken",
967
+ "type": "address"
968
+ },
969
+ {
970
+ "internalType": "contract IVToken",
971
+ "name": "shortVToken",
972
+ "type": "address"
973
+ },
974
+ {
975
+ "internalType": "uint256",
976
+ "name": "closeFractionBps",
977
+ "type": "uint256"
978
+ },
979
+ {
980
+ "internalType": "uint256",
981
+ "name": "longAmountToRedeemForRepay",
982
+ "type": "uint256"
983
+ },
984
+ {
985
+ "internalType": "uint256",
986
+ "name": "minAmountOutRepay",
987
+ "type": "uint256"
988
+ },
989
+ {
990
+ "internalType": "bytes",
991
+ "name": "swapDataRepay",
992
+ "type": "bytes"
993
+ },
994
+ {
995
+ "internalType": "uint256",
996
+ "name": "longAmountToRedeemForProfit",
997
+ "type": "uint256"
998
+ },
999
+ {
1000
+ "internalType": "uint256",
1001
+ "name": "minAmountOutProfit",
1002
+ "type": "uint256"
1003
+ },
1004
+ {
1005
+ "internalType": "bytes",
1006
+ "name": "swapDataProfit",
1007
+ "type": "bytes"
1008
+ }
1009
+ ],
1010
+ "name": "closeWithProfit",
1011
+ "outputs": [],
1012
+ "stateMutability": "nonpayable",
1013
+ "type": "function"
1014
+ },
1015
+ {
1016
+ "inputs": [
1017
+ {
1018
+ "internalType": "contract IVToken",
1019
+ "name": "longVToken",
1020
+ "type": "address"
1021
+ },
1022
+ {
1023
+ "internalType": "contract IVToken",
1024
+ "name": "shortVToken",
1025
+ "type": "address"
1026
+ },
1027
+ {
1028
+ "components": [
1029
+ {
1030
+ "internalType": "uint256",
1031
+ "name": "longAmountToRedeemForRepay",
1032
+ "type": "uint256"
1033
+ },
1034
+ {
1035
+ "internalType": "uint256",
1036
+ "name": "minAmountOutRepay",
1037
+ "type": "uint256"
1038
+ },
1039
+ {
1040
+ "internalType": "bytes",
1041
+ "name": "swapDataRepay",
1042
+ "type": "bytes"
1043
+ },
1044
+ {
1045
+ "internalType": "uint256",
1046
+ "name": "longAmountToRedeemForProfit",
1047
+ "type": "uint256"
1048
+ },
1049
+ {
1050
+ "internalType": "uint256",
1051
+ "name": "minAmountOutProfit",
1052
+ "type": "uint256"
1053
+ },
1054
+ {
1055
+ "internalType": "bytes",
1056
+ "name": "swapDataProfit",
1057
+ "type": "bytes"
1058
+ }
1059
+ ],
1060
+ "internalType": "struct IRelativePositionManager.CloseWithProfitParams",
1061
+ "name": "profitSwapParams",
1062
+ "type": "tuple"
1063
+ }
1064
+ ],
1065
+ "name": "closeWithProfitAndDeactivate",
1066
+ "outputs": [],
1067
+ "stateMutability": "nonpayable",
1068
+ "type": "function"
1069
+ },
1070
+ {
1071
+ "inputs": [],
1072
+ "name": "completePause",
1073
+ "outputs": [],
1074
+ "stateMutability": "nonpayable",
1075
+ "type": "function"
1076
+ },
1077
+ {
1078
+ "inputs": [],
1079
+ "name": "completeUnpause",
1080
+ "outputs": [],
1081
+ "stateMutability": "nonpayable",
1082
+ "type": "function"
1083
+ },
1084
+ {
1085
+ "inputs": [
1086
+ {
1087
+ "internalType": "contract IVToken",
1088
+ "name": "longVToken",
1089
+ "type": "address"
1090
+ },
1091
+ {
1092
+ "internalType": "contract IVToken",
1093
+ "name": "shortVToken",
1094
+ "type": "address"
1095
+ }
1096
+ ],
1097
+ "name": "deactivatePosition",
1098
+ "outputs": [],
1099
+ "stateMutability": "nonpayable",
1100
+ "type": "function"
1101
+ },
1102
+ {
1103
+ "inputs": [],
1104
+ "name": "dsaVTokenIndexCounter",
1105
+ "outputs": [
1106
+ {
1107
+ "internalType": "uint8",
1108
+ "name": "count",
1109
+ "type": "uint8"
1110
+ }
1111
+ ],
1112
+ "stateMutability": "view",
1113
+ "type": "function"
1114
+ },
1115
+ {
1116
+ "inputs": [
1117
+ {
1118
+ "internalType": "address",
1119
+ "name": "positionAccount",
1120
+ "type": "address"
1121
+ },
1122
+ {
1123
+ "internalType": "address[]",
1124
+ "name": "targets",
1125
+ "type": "address[]"
1126
+ },
1127
+ {
1128
+ "internalType": "bytes[]",
1129
+ "name": "data",
1130
+ "type": "bytes[]"
1131
+ }
1132
+ ],
1133
+ "name": "executePositionAccountCall",
1134
+ "outputs": [],
1135
+ "stateMutability": "nonpayable",
1136
+ "type": "function"
1137
+ },
1138
+ {
1139
+ "inputs": [
1140
+ {
1141
+ "internalType": "address",
1142
+ "name": "user",
1143
+ "type": "address"
1144
+ },
1145
+ {
1146
+ "internalType": "contract IVToken",
1147
+ "name": "longVToken",
1148
+ "type": "address"
1149
+ },
1150
+ {
1151
+ "internalType": "contract IVToken",
1152
+ "name": "shortVToken",
1153
+ "type": "address"
1154
+ }
1155
+ ],
1156
+ "name": "getAvailableShortCapacity",
1157
+ "outputs": [
1158
+ {
1159
+ "internalType": "uint256",
1160
+ "name": "availableCapacity",
1161
+ "type": "uint256"
1162
+ }
1163
+ ],
1164
+ "stateMutability": "nonpayable",
1165
+ "type": "function"
1166
+ },
1167
+ {
1168
+ "inputs": [],
1169
+ "name": "getDsaVTokens",
1170
+ "outputs": [
1171
+ {
1172
+ "internalType": "address[]",
1173
+ "name": "dsaVTokensList",
1174
+ "type": "address[]"
1175
+ }
1176
+ ],
1177
+ "stateMutability": "view",
1178
+ "type": "function"
1179
+ },
1180
+ {
1181
+ "inputs": [
1182
+ {
1183
+ "internalType": "address",
1184
+ "name": "user",
1185
+ "type": "address"
1186
+ },
1187
+ {
1188
+ "internalType": "contract IVToken",
1189
+ "name": "longVToken",
1190
+ "type": "address"
1191
+ },
1192
+ {
1193
+ "internalType": "contract IVToken",
1194
+ "name": "shortVToken",
1195
+ "type": "address"
1196
+ }
1197
+ ],
1198
+ "name": "getLongCollateralBalance",
1199
+ "outputs": [
1200
+ {
1201
+ "internalType": "uint256",
1202
+ "name": "longBalance",
1203
+ "type": "uint256"
1204
+ }
1205
+ ],
1206
+ "stateMutability": "nonpayable",
1207
+ "type": "function"
1208
+ },
1209
+ {
1210
+ "inputs": [
1211
+ {
1212
+ "internalType": "contract IVToken",
1213
+ "name": "dsaVToken",
1214
+ "type": "address"
1215
+ },
1216
+ {
1217
+ "internalType": "address",
1218
+ "name": "longVToken",
1219
+ "type": "address"
1220
+ }
1221
+ ],
1222
+ "name": "getMaxLeverageAllowed",
1223
+ "outputs": [
1224
+ {
1225
+ "internalType": "uint256",
1226
+ "name": "maxLeverage",
1227
+ "type": "uint256"
1228
+ }
1229
+ ],
1230
+ "stateMutability": "view",
1231
+ "type": "function"
1232
+ },
1233
+ {
1234
+ "inputs": [
1235
+ {
1236
+ "internalType": "address",
1237
+ "name": "user",
1238
+ "type": "address"
1239
+ },
1240
+ {
1241
+ "internalType": "contract IVToken",
1242
+ "name": "longVToken",
1243
+ "type": "address"
1244
+ },
1245
+ {
1246
+ "internalType": "contract IVToken",
1247
+ "name": "shortVToken",
1248
+ "type": "address"
1249
+ }
1250
+ ],
1251
+ "name": "getPosition",
1252
+ "outputs": [
1253
+ {
1254
+ "components": [
1255
+ {
1256
+ "internalType": "address",
1257
+ "name": "user",
1258
+ "type": "address"
1259
+ },
1260
+ {
1261
+ "internalType": "address",
1262
+ "name": "longVToken",
1263
+ "type": "address"
1264
+ },
1265
+ {
1266
+ "internalType": "address",
1267
+ "name": "shortVToken",
1268
+ "type": "address"
1269
+ },
1270
+ {
1271
+ "internalType": "address",
1272
+ "name": "positionAccount",
1273
+ "type": "address"
1274
+ },
1275
+ {
1276
+ "internalType": "bool",
1277
+ "name": "isActive",
1278
+ "type": "bool"
1279
+ },
1280
+ {
1281
+ "internalType": "uint8",
1282
+ "name": "dsaIndex",
1283
+ "type": "uint8"
1284
+ },
1285
+ {
1286
+ "internalType": "address",
1287
+ "name": "dsaVToken",
1288
+ "type": "address"
1289
+ },
1290
+ {
1291
+ "internalType": "uint256",
1292
+ "name": "suppliedPrincipalVTokens",
1293
+ "type": "uint256"
1294
+ },
1295
+ {
1296
+ "internalType": "uint256",
1297
+ "name": "effectiveLeverage",
1298
+ "type": "uint256"
1299
+ },
1300
+ {
1301
+ "internalType": "uint256",
1302
+ "name": "cycleId",
1303
+ "type": "uint256"
1304
+ }
1305
+ ],
1306
+ "internalType": "struct IRelativePositionManager.Position",
1307
+ "name": "position",
1308
+ "type": "tuple"
1309
+ }
1310
+ ],
1311
+ "stateMutability": "view",
1312
+ "type": "function"
1313
+ },
1314
+ {
1315
+ "inputs": [
1316
+ {
1317
+ "internalType": "address",
1318
+ "name": "user",
1319
+ "type": "address"
1320
+ },
1321
+ {
1322
+ "internalType": "contract IVToken",
1323
+ "name": "longVToken",
1324
+ "type": "address"
1325
+ },
1326
+ {
1327
+ "internalType": "contract IVToken",
1328
+ "name": "shortVToken",
1329
+ "type": "address"
1330
+ }
1331
+ ],
1332
+ "name": "getPositionAccountAddress",
1333
+ "outputs": [
1334
+ {
1335
+ "internalType": "address",
1336
+ "name": "predicted",
1337
+ "type": "address"
1338
+ }
1339
+ ],
1340
+ "stateMutability": "view",
1341
+ "type": "function"
1342
+ },
1343
+ {
1344
+ "inputs": [
1345
+ {
1346
+ "internalType": "address",
1347
+ "name": "user",
1348
+ "type": "address"
1349
+ },
1350
+ {
1351
+ "internalType": "contract IVToken",
1352
+ "name": "longVToken",
1353
+ "type": "address"
1354
+ },
1355
+ {
1356
+ "internalType": "contract IVToken",
1357
+ "name": "shortVToken",
1358
+ "type": "address"
1359
+ }
1360
+ ],
1361
+ "name": "getSuppliedPrincipalBalance",
1362
+ "outputs": [
1363
+ {
1364
+ "internalType": "uint256",
1365
+ "name": "balance",
1366
+ "type": "uint256"
1367
+ }
1368
+ ],
1369
+ "stateMutability": "nonpayable",
1370
+ "type": "function"
1371
+ },
1372
+ {
1373
+ "inputs": [
1374
+ {
1375
+ "internalType": "address",
1376
+ "name": "user",
1377
+ "type": "address"
1378
+ },
1379
+ {
1380
+ "internalType": "contract IVToken",
1381
+ "name": "longVToken",
1382
+ "type": "address"
1383
+ },
1384
+ {
1385
+ "internalType": "contract IVToken",
1386
+ "name": "shortVToken",
1387
+ "type": "address"
1388
+ }
1389
+ ],
1390
+ "name": "getUtilizationInfo",
1391
+ "outputs": [
1392
+ {
1393
+ "components": [
1394
+ {
1395
+ "internalType": "uint256",
1396
+ "name": "actualCapitalUtilized",
1397
+ "type": "uint256"
1398
+ },
1399
+ {
1400
+ "internalType": "uint256",
1401
+ "name": "nominalCapitalUtilized",
1402
+ "type": "uint256"
1403
+ },
1404
+ {
1405
+ "internalType": "uint256",
1406
+ "name": "finalCapitalUtilized",
1407
+ "type": "uint256"
1408
+ },
1409
+ {
1410
+ "internalType": "uint256",
1411
+ "name": "availableCapitalUSD",
1412
+ "type": "uint256"
1413
+ },
1414
+ {
1415
+ "internalType": "uint256",
1416
+ "name": "withdrawableAmount",
1417
+ "type": "uint256"
1418
+ },
1419
+ {
1420
+ "internalType": "uint256",
1421
+ "name": "clampedLeverage",
1422
+ "type": "uint256"
1423
+ }
1424
+ ],
1425
+ "internalType": "struct IRelativePositionManager.UtilizationInfo",
1426
+ "name": "utilization",
1427
+ "type": "tuple"
1428
+ }
1429
+ ],
1430
+ "stateMutability": "nonpayable",
1431
+ "type": "function"
1432
+ },
1433
+ {
1434
+ "inputs": [],
1435
+ "name": "partialPause",
1436
+ "outputs": [],
1437
+ "stateMutability": "nonpayable",
1438
+ "type": "function"
1439
+ },
1440
+ {
1441
+ "inputs": [],
1442
+ "name": "partialUnpause",
1443
+ "outputs": [],
1444
+ "stateMutability": "nonpayable",
1445
+ "type": "function"
1446
+ },
1447
+ {
1448
+ "inputs": [
1449
+ {
1450
+ "internalType": "contract IVToken",
1451
+ "name": "longVToken",
1452
+ "type": "address"
1453
+ },
1454
+ {
1455
+ "internalType": "contract IVToken",
1456
+ "name": "shortVToken",
1457
+ "type": "address"
1458
+ },
1459
+ {
1460
+ "internalType": "uint256",
1461
+ "name": "additionalPrincipal",
1462
+ "type": "uint256"
1463
+ },
1464
+ {
1465
+ "internalType": "uint256",
1466
+ "name": "shortAmount",
1467
+ "type": "uint256"
1468
+ },
1469
+ {
1470
+ "internalType": "uint256",
1471
+ "name": "minLongAmount",
1472
+ "type": "uint256"
1473
+ },
1474
+ {
1475
+ "internalType": "bytes",
1476
+ "name": "swapData",
1477
+ "type": "bytes"
1478
+ }
1479
+ ],
1480
+ "name": "scalePosition",
1481
+ "outputs": [],
1482
+ "stateMutability": "nonpayable",
1483
+ "type": "function"
1484
+ },
1485
+ {
1486
+ "inputs": [
1487
+ {
1488
+ "internalType": "uint8",
1489
+ "name": "dsaIndex",
1490
+ "type": "uint8"
1491
+ },
1492
+ {
1493
+ "internalType": "bool",
1494
+ "name": "active",
1495
+ "type": "bool"
1496
+ }
1497
+ ],
1498
+ "name": "setDSAVTokenActive",
1499
+ "outputs": [],
1500
+ "stateMutability": "nonpayable",
1501
+ "type": "function"
1502
+ },
1503
+ {
1504
+ "inputs": [
1505
+ {
1506
+ "internalType": "address",
1507
+ "name": "positionAccountImpl",
1508
+ "type": "address"
1509
+ }
1510
+ ],
1511
+ "name": "setPositionAccountImplementation",
1512
+ "outputs": [],
1513
+ "stateMutability": "nonpayable",
1514
+ "type": "function"
1515
+ },
1516
+ {
1517
+ "inputs": [
1518
+ {
1519
+ "internalType": "uint256",
1520
+ "name": "newTolerance",
1521
+ "type": "uint256"
1522
+ }
1523
+ ],
1524
+ "name": "setProportionalCloseTolerance",
1525
+ "outputs": [],
1526
+ "stateMutability": "nonpayable",
1527
+ "type": "function"
1528
+ },
1529
+ {
1530
+ "inputs": [
1531
+ {
1532
+ "internalType": "address",
1533
+ "name": "longVToken",
1534
+ "type": "address"
1535
+ },
1536
+ {
1537
+ "internalType": "address",
1538
+ "name": "shortVToken",
1539
+ "type": "address"
1540
+ },
1541
+ {
1542
+ "internalType": "uint256",
1543
+ "name": "amount",
1544
+ "type": "uint256"
1545
+ }
1546
+ ],
1547
+ "name": "supplyPrincipal",
1548
+ "outputs": [],
1549
+ "stateMutability": "nonpayable",
1550
+ "type": "function"
1551
+ },
1552
+ {
1553
+ "inputs": [
1554
+ {
1555
+ "internalType": "contract IVToken",
1556
+ "name": "longVToken",
1557
+ "type": "address"
1558
+ },
1559
+ {
1560
+ "internalType": "contract IVToken",
1561
+ "name": "shortVToken",
1562
+ "type": "address"
1563
+ },
1564
+ {
1565
+ "internalType": "uint256",
1566
+ "name": "amount",
1567
+ "type": "uint256"
1568
+ }
1569
+ ],
1570
+ "name": "withdrawPrincipal",
1571
+ "outputs": [],
1572
+ "stateMutability": "nonpayable",
1573
+ "type": "function"
1574
+ }
1575
+ ],
1576
+ "bytecode": "0x",
1577
+ "deployedBytecode": "0x",
1578
+ "linkReferences": {},
1579
+ "deployedLinkReferences": {}
1580
+ }