@kasufinance/kasu-sdk 1.0.1 → 1.0.2

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 (45) hide show
  1. package/.github/workflows/ci.yml +39 -0
  2. package/.github/workflows/main.yml +17 -13
  3. package/README.md +146 -0
  4. package/package.json +1 -1
  5. package/src/contracts/IClearingCoordinatorAbi.ts +0 -406
  6. package/src/contracts/IERC20MetadataAbi.ts +0 -364
  7. package/src/contracts/IFeeManagerAbi.ts +0 -182
  8. package/src/contracts/IKSULockingAbi.ts +0 -965
  9. package/src/contracts/IKasuAllowListAbi.ts +0 -605
  10. package/src/contracts/IKasuControllerAbi.ts +0 -703
  11. package/src/contracts/IKasuNFTsAbi.ts +0 -2744
  12. package/src/contracts/IKsuPriceAbi.ts +0 -87
  13. package/src/contracts/ILendingPoolAbi.ts +0 -2081
  14. package/src/contracts/ILendingPoolFactoryAbi.ts +0 -161
  15. package/src/contracts/ILendingPoolManagerAbi.ts +0 -1917
  16. package/src/contracts/ILendingPoolTrancheAbi.ts +0 -1911
  17. package/src/contracts/ISystemVariablesAbi.ts +0 -908
  18. package/src/contracts/IUserLoyaltyRewardsAbi.ts +0 -544
  19. package/src/contracts/IUserManagerAbi.ts +0 -612
  20. package/src/contracts/KSULockBonusAbi.ts +0 -124
  21. package/src/contracts/KasuPoolExternalTVLAbi.ts +0 -1071
  22. package/src/contracts/SwapperAbi.ts +0 -266
  23. package/src/contracts/common.ts +0 -44
  24. package/src/contracts/factories/IClearingCoordinatorAbi__factory.ts +0 -438
  25. package/src/contracts/factories/IERC20MetadataAbi__factory.ts +0 -248
  26. package/src/contracts/factories/IFeeManagerAbi__factory.ts +0 -90
  27. package/src/contracts/factories/IKSULockingAbi__factory.ts +0 -778
  28. package/src/contracts/factories/IKasuAllowListAbi__factory.ts +0 -479
  29. package/src/contracts/factories/IKasuControllerAbi__factory.ts +0 -447
  30. package/src/contracts/factories/IKasuNFTsAbi__factory.ts +0 -2116
  31. package/src/contracts/factories/IKsuPriceAbi__factory.ts +0 -36
  32. package/src/contracts/factories/ILendingPoolAbi__factory.ts +0 -1455
  33. package/src/contracts/factories/ILendingPoolFactoryAbi__factory.ts +0 -125
  34. package/src/contracts/factories/ILendingPoolManagerAbi__factory.ts +0 -1375
  35. package/src/contracts/factories/ILendingPoolTrancheAbi__factory.ts +0 -1345
  36. package/src/contracts/factories/ISystemVariablesAbi__factory.ts +0 -455
  37. package/src/contracts/factories/IUserLoyaltyRewardsAbi__factory.ts +0 -316
  38. package/src/contracts/factories/IUserManagerAbi__factory.ts +0 -345
  39. package/src/contracts/factories/KSULockBonusAbi__factory.ts +0 -115
  40. package/src/contracts/factories/KasuPoolExternalTVLAbi__factory.ts +0 -840
  41. package/src/contracts/factories/SwapperAbi__factory.ts +0 -167
  42. package/src/contracts/factories/index.ts +0 -21
  43. package/src/contracts/index.ts +0 -40
  44. package/tsconfig.tsbuildinfo +0 -1
  45. package/versioner.sh +0 -6
@@ -1,1455 +0,0 @@
1
- /* Autogenerated file. Do not edit manually. */
2
- /* tslint:disable */
3
- /* eslint-disable */
4
-
5
- import { Contract, Signer, utils } from "ethers";
6
- import type { Provider } from "@ethersproject/providers";
7
- import type {
8
- ILendingPoolAbi,
9
- ILendingPoolAbiInterface,
10
- } from "../ILendingPoolAbi";
11
-
12
- const _abi = [
13
- {
14
- inputs: [],
15
- name: "ClearingIsPending",
16
- type: "error",
17
- },
18
- {
19
- inputs: [
20
- {
21
- internalType: "uint256",
22
- name: "drawAmount",
23
- type: "uint256",
24
- },
25
- {
26
- internalType: "uint256",
27
- name: "availableAmount",
28
- type: "uint256",
29
- },
30
- ],
31
- name: "DrawAmountCantBeGreaterThanAvailableAmount",
32
- type: "error",
33
- },
34
- {
35
- inputs: [
36
- {
37
- internalType: "uint256",
38
- name: "feesOwedAmount",
39
- type: "uint256",
40
- },
41
- ],
42
- name: "FeesOwedAmountIsGreaterThanZero",
43
- type: "error",
44
- },
45
- {
46
- inputs: [],
47
- name: "LendingPoolIsNotStopped",
48
- type: "error",
49
- },
50
- {
51
- inputs: [],
52
- name: "LendingPoolIsStopped",
53
- type: "error",
54
- },
55
- {
56
- inputs: [
57
- {
58
- internalType: "uint256",
59
- name: "reportedLossAmount",
60
- type: "uint256",
61
- },
62
- {
63
- internalType: "uint256",
64
- name: "maxLossAmount",
65
- type: "uint256",
66
- },
67
- ],
68
- name: "LossAmountCantBeGreaterThanMaxLossAmount",
69
- type: "error",
70
- },
71
- {
72
- inputs: [
73
- {
74
- internalType: "uint256",
75
- name: "reportedLossAmount",
76
- type: "uint256",
77
- },
78
- ],
79
- name: "LossAmountShouldBeGreaterThanZero",
80
- type: "error",
81
- },
82
- {
83
- inputs: [
84
- {
85
- internalType: "uint256",
86
- name: "lossId",
87
- type: "uint256",
88
- },
89
- ],
90
- name: "LossIdNotValid",
91
- type: "error",
92
- },
93
- {
94
- inputs: [
95
- {
96
- internalType: "string",
97
- name: "reason",
98
- type: "string",
99
- },
100
- ],
101
- name: "PoolConfigurationIsIncorrect",
102
- type: "error",
103
- },
104
- {
105
- inputs: [
106
- {
107
- internalType: "uint256",
108
- name: "repayAmount",
109
- type: "uint256",
110
- },
111
- {
112
- internalType: "uint256",
113
- name: "owedAmount",
114
- type: "uint256",
115
- },
116
- ],
117
- name: "RepayAmountCantBeGreaterThanOwedAmount",
118
- type: "error",
119
- },
120
- {
121
- inputs: [
122
- {
123
- internalType: "uint256",
124
- name: "userOwedAmount",
125
- type: "uint256",
126
- },
127
- ],
128
- name: "UserOwedAmountIsGreaterThanZero",
129
- type: "error",
130
- },
131
- {
132
- inputs: [
133
- {
134
- internalType: "uint256",
135
- name: "withdrawAmount",
136
- type: "uint256",
137
- },
138
- {
139
- internalType: "uint256",
140
- name: "firstLostCapital",
141
- type: "uint256",
142
- },
143
- ],
144
- name: "WithdrawAmountCantBeGreaterThanFirstLostCapital",
145
- type: "error",
146
- },
147
- {
148
- anonymous: false,
149
- inputs: [
150
- {
151
- indexed: true,
152
- internalType: "address",
153
- name: "owner",
154
- type: "address",
155
- },
156
- {
157
- indexed: true,
158
- internalType: "address",
159
- name: "spender",
160
- type: "address",
161
- },
162
- {
163
- indexed: false,
164
- internalType: "uint256",
165
- name: "value",
166
- type: "uint256",
167
- },
168
- ],
169
- name: "Approval",
170
- type: "event",
171
- },
172
- {
173
- anonymous: false,
174
- inputs: [
175
- {
176
- indexed: true,
177
- internalType: "address",
178
- name: "user",
179
- type: "address",
180
- },
181
- {
182
- indexed: true,
183
- internalType: "address",
184
- name: "tranche",
185
- type: "address",
186
- },
187
- {
188
- indexed: false,
189
- internalType: "uint256",
190
- name: "amount",
191
- type: "uint256",
192
- },
193
- ],
194
- name: "DepositAccepted",
195
- type: "event",
196
- },
197
- {
198
- anonymous: false,
199
- inputs: [
200
- {
201
- indexed: true,
202
- internalType: "uint256",
203
- name: "epoch",
204
- type: "uint256",
205
- },
206
- {
207
- indexed: false,
208
- internalType: "uint256",
209
- name: "feesIncreasedAmount",
210
- type: "uint256",
211
- },
212
- ],
213
- name: "FeesOwedIncreased",
214
- type: "event",
215
- },
216
- {
217
- anonymous: false,
218
- inputs: [
219
- {
220
- indexed: false,
221
- internalType: "uint256",
222
- name: "amountAdded",
223
- type: "uint256",
224
- },
225
- ],
226
- name: "FirstLossCapitalAdded",
227
- type: "event",
228
- },
229
- {
230
- anonymous: false,
231
- inputs: [
232
- {
233
- indexed: true,
234
- internalType: "uint256",
235
- name: "lossId",
236
- type: "uint256",
237
- },
238
- {
239
- indexed: false,
240
- internalType: "uint256",
241
- name: "amount",
242
- type: "uint256",
243
- },
244
- ],
245
- name: "FirstLossCapitalLossReported",
246
- type: "event",
247
- },
248
- {
249
- anonymous: false,
250
- inputs: [
251
- {
252
- indexed: false,
253
- internalType: "uint256",
254
- name: "amountWithdrawn",
255
- type: "uint256",
256
- },
257
- ],
258
- name: "FirstLossCapitalWithdrawn",
259
- type: "event",
260
- },
261
- {
262
- anonymous: false,
263
- inputs: [
264
- {
265
- indexed: false,
266
- internalType: "uint256",
267
- name: "amount",
268
- type: "uint256",
269
- },
270
- ],
271
- name: "FundsDrawn",
272
- type: "event",
273
- },
274
- {
275
- anonymous: false,
276
- inputs: [
277
- {
278
- indexed: true,
279
- internalType: "address",
280
- name: "user",
281
- type: "address",
282
- },
283
- {
284
- indexed: true,
285
- internalType: "address",
286
- name: "tranche",
287
- type: "address",
288
- },
289
- {
290
- indexed: false,
291
- internalType: "uint256",
292
- name: "shares",
293
- type: "uint256",
294
- },
295
- {
296
- indexed: false,
297
- internalType: "uint256",
298
- name: "amount",
299
- type: "uint256",
300
- },
301
- ],
302
- name: "ImmediateWithdrawal",
303
- type: "event",
304
- },
305
- {
306
- anonymous: false,
307
- inputs: [
308
- {
309
- indexed: true,
310
- internalType: "address",
311
- name: "tranche",
312
- type: "address",
313
- },
314
- {
315
- indexed: true,
316
- internalType: "uint256",
317
- name: "epoch",
318
- type: "uint256",
319
- },
320
- {
321
- indexed: false,
322
- internalType: "uint256",
323
- name: "interestAmount",
324
- type: "uint256",
325
- },
326
- ],
327
- name: "InterestApplied",
328
- type: "event",
329
- },
330
- {
331
- anonymous: false,
332
- inputs: [],
333
- name: "LendingPoolStopped",
334
- type: "event",
335
- },
336
- {
337
- anonymous: false,
338
- inputs: [
339
- {
340
- indexed: false,
341
- internalType: "uint256",
342
- name: "amount",
343
- type: "uint256",
344
- },
345
- ],
346
- name: "LossReported",
347
- type: "event",
348
- },
349
- {
350
- anonymous: false,
351
- inputs: [
352
- {
353
- indexed: false,
354
- internalType: "uint256",
355
- name: "amountForUsers",
356
- type: "uint256",
357
- },
358
- {
359
- indexed: false,
360
- internalType: "uint256",
361
- name: "amountForFees",
362
- type: "uint256",
363
- },
364
- ],
365
- name: "OwedFundsRepaid",
366
- type: "event",
367
- },
368
- {
369
- anonymous: false,
370
- inputs: [
371
- {
372
- indexed: false,
373
- internalType: "uint256",
374
- name: "feesPaid",
375
- type: "uint256",
376
- },
377
- ],
378
- name: "PaidFees",
379
- type: "event",
380
- },
381
- {
382
- anonymous: false,
383
- inputs: [
384
- {
385
- indexed: true,
386
- internalType: "address",
387
- name: "tranche",
388
- type: "address",
389
- },
390
- {
391
- indexed: true,
392
- internalType: "uint256",
393
- name: "applicableEpoch",
394
- type: "uint256",
395
- },
396
- {
397
- indexed: false,
398
- internalType: "uint256",
399
- name: "arrayIndex",
400
- type: "uint256",
401
- },
402
- ],
403
- name: "RemovedTrancheInterestRateUpdate",
404
- type: "event",
405
- },
406
- {
407
- anonymous: false,
408
- inputs: [
409
- {
410
- indexed: true,
411
- internalType: "address",
412
- name: "from",
413
- type: "address",
414
- },
415
- {
416
- indexed: true,
417
- internalType: "address",
418
- name: "to",
419
- type: "address",
420
- },
421
- {
422
- indexed: false,
423
- internalType: "uint256",
424
- name: "value",
425
- type: "uint256",
426
- },
427
- ],
428
- name: "Transfer",
429
- type: "event",
430
- },
431
- {
432
- anonymous: false,
433
- inputs: [
434
- {
435
- indexed: false,
436
- internalType: "uint256",
437
- name: "desiredDrawAmount",
438
- type: "uint256",
439
- },
440
- ],
441
- name: "UpdatedDesiredDrawAmount",
442
- type: "event",
443
- },
444
- {
445
- anonymous: false,
446
- inputs: [
447
- {
448
- indexed: true,
449
- internalType: "address",
450
- name: "drawRecipient",
451
- type: "address",
452
- },
453
- ],
454
- name: "UpdatedDrawRecipient",
455
- type: "event",
456
- },
457
- {
458
- anonymous: false,
459
- inputs: [
460
- {
461
- indexed: true,
462
- internalType: "address",
463
- name: "tranche",
464
- type: "address",
465
- },
466
- {
467
- indexed: false,
468
- internalType: "uint256",
469
- name: "amount",
470
- type: "uint256",
471
- },
472
- ],
473
- name: "UpdatedMaximumDepositAmount",
474
- type: "event",
475
- },
476
- {
477
- anonymous: false,
478
- inputs: [
479
- {
480
- indexed: true,
481
- internalType: "address",
482
- name: "tranche",
483
- type: "address",
484
- },
485
- {
486
- indexed: false,
487
- internalType: "uint256",
488
- name: "amount",
489
- type: "uint256",
490
- },
491
- ],
492
- name: "UpdatedMinimumDepositAmount",
493
- type: "event",
494
- },
495
- {
496
- anonymous: false,
497
- inputs: [
498
- {
499
- indexed: false,
500
- internalType: "uint256",
501
- name: "percentage",
502
- type: "uint256",
503
- },
504
- ],
505
- name: "UpdatedMinimumExcessLiquidityPercentage",
506
- type: "event",
507
- },
508
- {
509
- anonymous: false,
510
- inputs: [
511
- {
512
- indexed: false,
513
- internalType: "uint256",
514
- name: "percentage",
515
- type: "uint256",
516
- },
517
- ],
518
- name: "UpdatedTargetExcessLiquidityPercentage",
519
- type: "event",
520
- },
521
- {
522
- anonymous: false,
523
- inputs: [
524
- {
525
- indexed: false,
526
- internalType: "uint256[]",
527
- name: "ratios",
528
- type: "uint256[]",
529
- },
530
- ],
531
- name: "UpdatedTrancheDesiredRatios",
532
- type: "event",
533
- },
534
- {
535
- anonymous: false,
536
- inputs: [
537
- {
538
- indexed: true,
539
- internalType: "address",
540
- name: "tranche",
541
- type: "address",
542
- },
543
- {
544
- indexed: true,
545
- internalType: "uint256",
546
- name: "applicableEpoch",
547
- type: "uint256",
548
- },
549
- {
550
- indexed: false,
551
- internalType: "uint256",
552
- name: "newInterestRate",
553
- type: "uint256",
554
- },
555
- ],
556
- name: "UpdatedTrancheInterestRate",
557
- type: "event",
558
- },
559
- {
560
- anonymous: false,
561
- inputs: [
562
- {
563
- indexed: false,
564
- internalType: "uint256",
565
- name: "epochDelay",
566
- type: "uint256",
567
- },
568
- ],
569
- name: "UpdatedTrancheInterestRateChangeEpochDelay",
570
- type: "event",
571
- },
572
- {
573
- anonymous: false,
574
- inputs: [
575
- {
576
- indexed: true,
577
- internalType: "address",
578
- name: "user",
579
- type: "address",
580
- },
581
- {
582
- indexed: true,
583
- internalType: "address",
584
- name: "tranche",
585
- type: "address",
586
- },
587
- {
588
- indexed: false,
589
- internalType: "uint256",
590
- name: "shares",
591
- type: "uint256",
592
- },
593
- {
594
- indexed: false,
595
- internalType: "uint256",
596
- name: "assetAmount",
597
- type: "uint256",
598
- },
599
- ],
600
- name: "WithdrawalAccepted",
601
- type: "event",
602
- },
603
- {
604
- inputs: [
605
- {
606
- internalType: "address",
607
- name: "tranche",
608
- type: "address",
609
- },
610
- {
611
- internalType: "address",
612
- name: "user",
613
- type: "address",
614
- },
615
- {
616
- internalType: "uint256",
617
- name: "acceptedAmount",
618
- type: "uint256",
619
- },
620
- ],
621
- name: "acceptDeposit",
622
- outputs: [
623
- {
624
- internalType: "uint256",
625
- name: "trancheShares",
626
- type: "uint256",
627
- },
628
- ],
629
- stateMutability: "nonpayable",
630
- type: "function",
631
- },
632
- {
633
- inputs: [
634
- {
635
- internalType: "address",
636
- name: "tranche",
637
- type: "address",
638
- },
639
- {
640
- internalType: "address",
641
- name: "user",
642
- type: "address",
643
- },
644
- {
645
- internalType: "uint256",
646
- name: "acceptedShares",
647
- type: "uint256",
648
- },
649
- ],
650
- name: "acceptWithdrawal",
651
- outputs: [
652
- {
653
- internalType: "uint256",
654
- name: "assetAmount",
655
- type: "uint256",
656
- },
657
- ],
658
- stateMutability: "nonpayable",
659
- type: "function",
660
- },
661
- {
662
- inputs: [
663
- {
664
- internalType: "address",
665
- name: "owner",
666
- type: "address",
667
- },
668
- {
669
- internalType: "address",
670
- name: "spender",
671
- type: "address",
672
- },
673
- ],
674
- name: "allowance",
675
- outputs: [
676
- {
677
- internalType: "uint256",
678
- name: "",
679
- type: "uint256",
680
- },
681
- ],
682
- stateMutability: "view",
683
- type: "function",
684
- },
685
- {
686
- inputs: [
687
- {
688
- internalType: "uint256",
689
- name: "epoch",
690
- type: "uint256",
691
- },
692
- ],
693
- name: "applyInterests",
694
- outputs: [],
695
- stateMutability: "nonpayable",
696
- type: "function",
697
- },
698
- {
699
- inputs: [
700
- {
701
- internalType: "address",
702
- name: "spender",
703
- type: "address",
704
- },
705
- {
706
- internalType: "uint256",
707
- name: "value",
708
- type: "uint256",
709
- },
710
- ],
711
- name: "approve",
712
- outputs: [
713
- {
714
- internalType: "bool",
715
- name: "",
716
- type: "bool",
717
- },
718
- ],
719
- stateMutability: "nonpayable",
720
- type: "function",
721
- },
722
- {
723
- inputs: [],
724
- name: "availableFunds",
725
- outputs: [
726
- {
727
- internalType: "uint256",
728
- name: "",
729
- type: "uint256",
730
- },
731
- ],
732
- stateMutability: "view",
733
- type: "function",
734
- },
735
- {
736
- inputs: [
737
- {
738
- internalType: "address",
739
- name: "account",
740
- type: "address",
741
- },
742
- ],
743
- name: "balanceOf",
744
- outputs: [
745
- {
746
- internalType: "uint256",
747
- name: "",
748
- type: "uint256",
749
- },
750
- ],
751
- stateMutability: "view",
752
- type: "function",
753
- },
754
- {
755
- inputs: [],
756
- name: "calculateMaximumLossAmount",
757
- outputs: [
758
- {
759
- internalType: "uint256",
760
- name: "maximumLossAmount",
761
- type: "uint256",
762
- },
763
- ],
764
- stateMutability: "view",
765
- type: "function",
766
- },
767
- {
768
- inputs: [
769
- {
770
- internalType: "address",
771
- name: "user",
772
- type: "address",
773
- },
774
- {
775
- internalType: "address",
776
- name: "tranche",
777
- type: "address",
778
- },
779
- {
780
- internalType: "uint256",
781
- name: "lossId",
782
- type: "uint256",
783
- },
784
- ],
785
- name: "claimRepaidLoss",
786
- outputs: [
787
- {
788
- internalType: "uint256",
789
- name: "claimedAmount",
790
- type: "uint256",
791
- },
792
- ],
793
- stateMutability: "nonpayable",
794
- type: "function",
795
- },
796
- {
797
- inputs: [
798
- {
799
- internalType: "uint256",
800
- name: "amount",
801
- type: "uint256",
802
- },
803
- ],
804
- name: "depositFirstLossCapital",
805
- outputs: [],
806
- stateMutability: "nonpayable",
807
- type: "function",
808
- },
809
- {
810
- inputs: [
811
- {
812
- internalType: "uint256",
813
- name: "amount",
814
- type: "uint256",
815
- },
816
- ],
817
- name: "drawFunds",
818
- outputs: [],
819
- stateMutability: "nonpayable",
820
- type: "function",
821
- },
822
- {
823
- inputs: [],
824
- name: "feesOwedAmount",
825
- outputs: [
826
- {
827
- internalType: "uint256",
828
- name: "",
829
- type: "uint256",
830
- },
831
- ],
832
- stateMutability: "view",
833
- type: "function",
834
- },
835
- {
836
- inputs: [
837
- {
838
- internalType: "address",
839
- name: "tranche",
840
- type: "address",
841
- },
842
- {
843
- internalType: "address",
844
- name: "user",
845
- type: "address",
846
- },
847
- {
848
- internalType: "uint256",
849
- name: "sharesToWithdraw",
850
- type: "uint256",
851
- },
852
- ],
853
- name: "forceImmediateWithdrawal",
854
- outputs: [
855
- {
856
- internalType: "uint256",
857
- name: "assetAmount",
858
- type: "uint256",
859
- },
860
- ],
861
- stateMutability: "nonpayable",
862
- type: "function",
863
- },
864
- {
865
- inputs: [],
866
- name: "getClearingConfig",
867
- outputs: [
868
- {
869
- components: [
870
- {
871
- internalType: "uint256",
872
- name: "drawAmount",
873
- type: "uint256",
874
- },
875
- {
876
- internalType: "uint256[]",
877
- name: "trancheDesiredRatios",
878
- type: "uint256[]",
879
- },
880
- {
881
- internalType: "uint256",
882
- name: "maxExcessPercentage",
883
- type: "uint256",
884
- },
885
- {
886
- internalType: "uint256",
887
- name: "minExcessPercentage",
888
- type: "uint256",
889
- },
890
- ],
891
- internalType: "struct ClearingConfiguration",
892
- name: "clearingConfig",
893
- type: "tuple",
894
- },
895
- ],
896
- stateMutability: "view",
897
- type: "function",
898
- },
899
- {
900
- inputs: [],
901
- name: "getLendingPoolInfo",
902
- outputs: [
903
- {
904
- components: [
905
- {
906
- internalType: "address[]",
907
- name: "trancheAddresses",
908
- type: "address[]",
909
- },
910
- {
911
- internalType: "address",
912
- name: "pendingPool",
913
- type: "address",
914
- },
915
- ],
916
- internalType: "struct LendingPoolInfo",
917
- name: "",
918
- type: "tuple",
919
- },
920
- ],
921
- stateMutability: "view",
922
- type: "function",
923
- },
924
- {
925
- inputs: [
926
- {
927
- internalType: "address",
928
- name: "tranche",
929
- type: "address",
930
- },
931
- ],
932
- name: "isLendingPoolTranche",
933
- outputs: [
934
- {
935
- internalType: "bool",
936
- name: "",
937
- type: "bool",
938
- },
939
- ],
940
- stateMutability: "view",
941
- type: "function",
942
- },
943
- {
944
- inputs: [],
945
- name: "lendingPoolTrancheCount",
946
- outputs: [
947
- {
948
- internalType: "uint256",
949
- name: "",
950
- type: "uint256",
951
- },
952
- ],
953
- stateMutability: "view",
954
- type: "function",
955
- },
956
- {
957
- inputs: [],
958
- name: "lendingPoolTranches",
959
- outputs: [
960
- {
961
- internalType: "address[]",
962
- name: "",
963
- type: "address[]",
964
- },
965
- ],
966
- stateMutability: "view",
967
- type: "function",
968
- },
969
- {
970
- inputs: [],
971
- name: "pendingPool",
972
- outputs: [
973
- {
974
- internalType: "address",
975
- name: "",
976
- type: "address",
977
- },
978
- ],
979
- stateMutability: "view",
980
- type: "function",
981
- },
982
- {
983
- inputs: [],
984
- name: "poolConfiguration",
985
- outputs: [
986
- {
987
- components: [
988
- {
989
- components: [
990
- {
991
- internalType: "uint256",
992
- name: "ratio",
993
- type: "uint256",
994
- },
995
- {
996
- internalType: "uint256",
997
- name: "interestRate",
998
- type: "uint256",
999
- },
1000
- {
1001
- internalType: "uint256",
1002
- name: "minDepositAmount",
1003
- type: "uint256",
1004
- },
1005
- {
1006
- internalType: "uint256",
1007
- name: "maxDepositAmount",
1008
- type: "uint256",
1009
- },
1010
- ],
1011
- internalType: "struct TrancheConfig[]",
1012
- name: "tranches",
1013
- type: "tuple[]",
1014
- },
1015
- {
1016
- internalType: "address",
1017
- name: "drawRecipient",
1018
- type: "address",
1019
- },
1020
- {
1021
- internalType: "uint256",
1022
- name: "desiredDrawAmount",
1023
- type: "uint256",
1024
- },
1025
- {
1026
- internalType: "uint256",
1027
- name: "trancheInterestChangeEpochDelay",
1028
- type: "uint256",
1029
- },
1030
- {
1031
- internalType: "uint256",
1032
- name: "targetExcessLiquidityPercentage",
1033
- type: "uint256",
1034
- },
1035
- {
1036
- internalType: "uint256",
1037
- name: "minimumExcessLiquidityPercentage",
1038
- type: "uint256",
1039
- },
1040
- ],
1041
- internalType: "struct PoolConfiguration",
1042
- name: "",
1043
- type: "tuple",
1044
- },
1045
- ],
1046
- stateMutability: "view",
1047
- type: "function",
1048
- },
1049
- {
1050
- inputs: [
1051
- {
1052
- internalType: "address",
1053
- name: "tranche",
1054
- type: "address",
1055
- },
1056
- {
1057
- internalType: "uint256",
1058
- name: "lossId",
1059
- type: "uint256",
1060
- },
1061
- {
1062
- internalType: "uint256",
1063
- name: "amount",
1064
- type: "uint256",
1065
- },
1066
- ],
1067
- name: "repayLoss",
1068
- outputs: [],
1069
- stateMutability: "nonpayable",
1070
- type: "function",
1071
- },
1072
- {
1073
- inputs: [
1074
- {
1075
- internalType: "uint256",
1076
- name: "amount",
1077
- type: "uint256",
1078
- },
1079
- ],
1080
- name: "repayOwedFunds",
1081
- outputs: [],
1082
- stateMutability: "nonpayable",
1083
- type: "function",
1084
- },
1085
- {
1086
- inputs: [
1087
- {
1088
- internalType: "uint256",
1089
- name: "lossAmount",
1090
- type: "uint256",
1091
- },
1092
- {
1093
- internalType: "bool",
1094
- name: "doMintLossTokens",
1095
- type: "bool",
1096
- },
1097
- ],
1098
- name: "reportLoss",
1099
- outputs: [
1100
- {
1101
- internalType: "uint256",
1102
- name: "appliedLoss",
1103
- type: "uint256",
1104
- },
1105
- ],
1106
- stateMutability: "nonpayable",
1107
- type: "function",
1108
- },
1109
- {
1110
- inputs: [],
1111
- name: "stop",
1112
- outputs: [],
1113
- stateMutability: "nonpayable",
1114
- type: "function",
1115
- },
1116
- {
1117
- inputs: [],
1118
- name: "totalSupply",
1119
- outputs: [
1120
- {
1121
- internalType: "uint256",
1122
- name: "",
1123
- type: "uint256",
1124
- },
1125
- ],
1126
- stateMutability: "view",
1127
- type: "function",
1128
- },
1129
- {
1130
- inputs: [
1131
- {
1132
- internalType: "address",
1133
- name: "tranche",
1134
- type: "address",
1135
- },
1136
- ],
1137
- name: "trancheConfigurationDepositLimits",
1138
- outputs: [
1139
- {
1140
- internalType: "uint256",
1141
- name: "minDepositAmount",
1142
- type: "uint256",
1143
- },
1144
- {
1145
- internalType: "uint256",
1146
- name: "maxDepositAmount",
1147
- type: "uint256",
1148
- },
1149
- ],
1150
- stateMutability: "view",
1151
- type: "function",
1152
- },
1153
- {
1154
- inputs: [
1155
- {
1156
- internalType: "address",
1157
- name: "tranche",
1158
- type: "address",
1159
- },
1160
- ],
1161
- name: "trancheIndex",
1162
- outputs: [
1163
- {
1164
- internalType: "uint256",
1165
- name: "",
1166
- type: "uint256",
1167
- },
1168
- ],
1169
- stateMutability: "view",
1170
- type: "function",
1171
- },
1172
- {
1173
- inputs: [
1174
- {
1175
- internalType: "address",
1176
- name: "to",
1177
- type: "address",
1178
- },
1179
- {
1180
- internalType: "uint256",
1181
- name: "value",
1182
- type: "uint256",
1183
- },
1184
- ],
1185
- name: "transfer",
1186
- outputs: [
1187
- {
1188
- internalType: "bool",
1189
- name: "",
1190
- type: "bool",
1191
- },
1192
- ],
1193
- stateMutability: "nonpayable",
1194
- type: "function",
1195
- },
1196
- {
1197
- inputs: [
1198
- {
1199
- internalType: "address",
1200
- name: "from",
1201
- type: "address",
1202
- },
1203
- {
1204
- internalType: "address",
1205
- name: "to",
1206
- type: "address",
1207
- },
1208
- {
1209
- internalType: "uint256",
1210
- name: "value",
1211
- type: "uint256",
1212
- },
1213
- ],
1214
- name: "transferFrom",
1215
- outputs: [
1216
- {
1217
- internalType: "bool",
1218
- name: "",
1219
- type: "bool",
1220
- },
1221
- ],
1222
- stateMutability: "nonpayable",
1223
- type: "function",
1224
- },
1225
- {
1226
- inputs: [
1227
- {
1228
- internalType: "uint256",
1229
- name: "desiredDrawAmount",
1230
- type: "uint256",
1231
- },
1232
- ],
1233
- name: "updateDesiredDrawAmount",
1234
- outputs: [],
1235
- stateMutability: "nonpayable",
1236
- type: "function",
1237
- },
1238
- {
1239
- inputs: [
1240
- {
1241
- internalType: "address",
1242
- name: "drawRecipient",
1243
- type: "address",
1244
- },
1245
- ],
1246
- name: "updateDrawRecipient",
1247
- outputs: [],
1248
- stateMutability: "nonpayable",
1249
- type: "function",
1250
- },
1251
- {
1252
- inputs: [
1253
- {
1254
- internalType: "address",
1255
- name: "tranche",
1256
- type: "address",
1257
- },
1258
- {
1259
- internalType: "uint256",
1260
- name: "maximumDepositAmount",
1261
- type: "uint256",
1262
- },
1263
- ],
1264
- name: "updateMaximumDepositAmount",
1265
- outputs: [],
1266
- stateMutability: "nonpayable",
1267
- type: "function",
1268
- },
1269
- {
1270
- inputs: [
1271
- {
1272
- internalType: "address",
1273
- name: "tranche",
1274
- type: "address",
1275
- },
1276
- {
1277
- internalType: "uint256",
1278
- name: "minimumDepositAmount",
1279
- type: "uint256",
1280
- },
1281
- ],
1282
- name: "updateMinimumDepositAmount",
1283
- outputs: [],
1284
- stateMutability: "nonpayable",
1285
- type: "function",
1286
- },
1287
- {
1288
- inputs: [
1289
- {
1290
- internalType: "uint256",
1291
- name: "minimumExcessLiquidityPercentage",
1292
- type: "uint256",
1293
- },
1294
- ],
1295
- name: "updateMinimumExcessLiquidityPercentage",
1296
- outputs: [],
1297
- stateMutability: "nonpayable",
1298
- type: "function",
1299
- },
1300
- {
1301
- inputs: [
1302
- {
1303
- internalType: "uint256",
1304
- name: "targetExcessLiquidityPercentage",
1305
- type: "uint256",
1306
- },
1307
- ],
1308
- name: "updateTargetExcessLiquidityPercentage",
1309
- outputs: [],
1310
- stateMutability: "nonpayable",
1311
- type: "function",
1312
- },
1313
- {
1314
- inputs: [
1315
- {
1316
- internalType: "uint256[]",
1317
- name: "ratios",
1318
- type: "uint256[]",
1319
- },
1320
- ],
1321
- name: "updateTrancheDesiredRatios",
1322
- outputs: [],
1323
- stateMutability: "nonpayable",
1324
- type: "function",
1325
- },
1326
- {
1327
- inputs: [
1328
- {
1329
- internalType: "address",
1330
- name: "tranche",
1331
- type: "address",
1332
- },
1333
- {
1334
- internalType: "uint256",
1335
- name: "interestRate",
1336
- type: "uint256",
1337
- },
1338
- ],
1339
- name: "updateTrancheInterestRate",
1340
- outputs: [],
1341
- stateMutability: "nonpayable",
1342
- type: "function",
1343
- },
1344
- {
1345
- inputs: [
1346
- {
1347
- internalType: "uint256",
1348
- name: "epochDelay",
1349
- type: "uint256",
1350
- },
1351
- ],
1352
- name: "updateTrancheInterestRateChangeEpochDelay",
1353
- outputs: [],
1354
- stateMutability: "nonpayable",
1355
- type: "function",
1356
- },
1357
- {
1358
- inputs: [
1359
- {
1360
- internalType: "address",
1361
- name: "user",
1362
- type: "address",
1363
- },
1364
- ],
1365
- name: "userBalance",
1366
- outputs: [
1367
- {
1368
- internalType: "uint256",
1369
- name: "",
1370
- type: "uint256",
1371
- },
1372
- ],
1373
- stateMutability: "view",
1374
- type: "function",
1375
- },
1376
- {
1377
- inputs: [],
1378
- name: "userOwedAmount",
1379
- outputs: [
1380
- {
1381
- internalType: "uint256",
1382
- name: "",
1383
- type: "uint256",
1384
- },
1385
- ],
1386
- stateMutability: "view",
1387
- type: "function",
1388
- },
1389
- {
1390
- inputs: [
1391
- {
1392
- components: [
1393
- {
1394
- internalType: "uint256",
1395
- name: "drawAmount",
1396
- type: "uint256",
1397
- },
1398
- {
1399
- internalType: "uint256[]",
1400
- name: "trancheDesiredRatios",
1401
- type: "uint256[]",
1402
- },
1403
- {
1404
- internalType: "uint256",
1405
- name: "maxExcessPercentage",
1406
- type: "uint256",
1407
- },
1408
- {
1409
- internalType: "uint256",
1410
- name: "minExcessPercentage",
1411
- type: "uint256",
1412
- },
1413
- ],
1414
- internalType: "struct ClearingConfiguration",
1415
- name: "clearingConfig",
1416
- type: "tuple",
1417
- },
1418
- ],
1419
- name: "verifyClearingConfig",
1420
- outputs: [],
1421
- stateMutability: "view",
1422
- type: "function",
1423
- },
1424
- {
1425
- inputs: [
1426
- {
1427
- internalType: "uint256",
1428
- name: "withdrawAmount",
1429
- type: "uint256",
1430
- },
1431
- {
1432
- internalType: "address",
1433
- name: "withdrawAddress",
1434
- type: "address",
1435
- },
1436
- ],
1437
- name: "withdrawFirstLossCapital",
1438
- outputs: [],
1439
- stateMutability: "nonpayable",
1440
- type: "function",
1441
- },
1442
- ] as const;
1443
-
1444
- export class ILendingPoolAbi__factory {
1445
- static readonly abi = _abi;
1446
- static createInterface(): ILendingPoolAbiInterface {
1447
- return new utils.Interface(_abi) as ILendingPoolAbiInterface;
1448
- }
1449
- static connect(
1450
- address: string,
1451
- signerOrProvider: Signer | Provider
1452
- ): ILendingPoolAbi {
1453
- return new Contract(address, _abi, signerOrProvider) as ILendingPoolAbi;
1454
- }
1455
- }