@lavarage/sdk 7.5.6 → 7.5.8
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.
- package/.DS_Store +0 -0
- package/.gitignore +18 -1
- package/README.md +33 -0
- package/dist/index.d.mts +1396 -1
- package/dist/index.d.ts +1396 -1
- package/dist/index.js +287 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +287 -3
- package/dist/index.mjs.map +1 -1
- package/docs/.nojekyll +1 -0
- package/docs/assets/hierarchy.js +1 -0
- package/docs/assets/highlight.css +92 -0
- package/docs/assets/icons.js +18 -0
- package/docs/assets/icons.svg +1 -0
- package/docs/assets/main.js +60 -0
- package/docs/assets/navigation.js +1 -0
- package/docs/assets/search.js +1 -0
- package/docs/assets/style.css +1633 -0
- package/docs/functions/borrowV1.html +1 -0
- package/docs/functions/borrowV2.html +1 -0
- package/docs/functions/closePositionEvm.html +9 -0
- package/docs/functions/closeTradeV1.html +17 -0
- package/docs/functions/closeTradeV2.html +18 -0
- package/docs/functions/createTpDelegate.html +17 -0
- package/docs/functions/getActiveLoanCountEvm.html +8 -0
- package/docs/functions/getActiveLoansBatchEvm.html +10 -0
- package/docs/functions/getAllPositions.html +17 -0
- package/docs/functions/getAvailableExposureEvm.html +9 -0
- package/docs/functions/getClosedPositions.html +7 -0
- package/docs/functions/getClosedPositionsEvm.html +9 -0
- package/docs/functions/getCollateralExposureEvm.html +9 -0
- package/docs/functions/getCollateralInfoEvm.html +9 -0
- package/docs/functions/getDelegateAccounts.html +13 -0
- package/docs/functions/getLiquidatedPositions.html +13 -0
- package/docs/functions/getLiquidatedPositionsEvm.html +9 -0
- package/docs/functions/getLoanEvm.html +9 -0
- package/docs/functions/getLoansByBorrowerEvm.html +9 -0
- package/docs/functions/getOffers.html +7 -0
- package/docs/functions/getOffersEvm.html +9 -0
- package/docs/functions/getOpenPositions.html +11 -0
- package/docs/functions/getOpeningFeeEvm.html +8 -0
- package/docs/functions/getPda.html +8 -0
- package/docs/functions/getPositionAccountPDA.html +9 -0
- package/docs/functions/getPositionsEvm.html +8 -0
- package/docs/functions/getProfitFeeEvm.html +8 -0
- package/docs/functions/getTokenBalanceEvm.html +8 -0
- package/docs/functions/getUserLoansEvm.html +9 -0
- package/docs/functions/lending.addToWithdrawalAccessList.html +1 -0
- package/docs/functions/lending.createOffer.html +15 -0
- package/docs/functions/lending.depositFunds.html +17 -0
- package/docs/functions/lending.getNodeWalletPDA.html +9 -0
- package/docs/functions/lending.getTradingPoolPDA.html +9 -0
- package/docs/functions/lending.getWithdrawalAccessList.html +1 -0
- package/docs/functions/lending.getWithdrawalAccessListPDA.html +1 -0
- package/docs/functions/lending.removeFromWithdrawalAccessList.html +1 -0
- package/docs/functions/lending.updateInterestRate.html +13 -0
- package/docs/functions/lending.updateMaxBorrow.html +13 -0
- package/docs/functions/lending.updateMaxExposure.html +13 -0
- package/docs/functions/lending.updateOffer.html +19 -0
- package/docs/functions/lending.withdrawFunds.html +20 -0
- package/docs/functions/lending.withdrawFundsV1.html +16 -0
- package/docs/functions/lending.withdrawFundsV2.html +19 -0
- package/docs/functions/liquidatePositionEvm.html +6 -0
- package/docs/functions/mergePositionV2.html +13 -0
- package/docs/functions/modifyTpDelegate.html +17 -0
- package/docs/functions/openPositionEvm.html +9 -0
- package/docs/functions/openTradeV1.html +26 -0
- package/docs/functions/openTradeV2.html +29 -0
- package/docs/functions/partialRepayV1.html +10 -0
- package/docs/functions/partialRepayV2.html +10 -0
- package/docs/functions/removeTpDelegate.html +13 -0
- package/docs/functions/splitPositionV2.html +13 -0
- package/docs/functions/updateMaxLendPerTokenBatchEvm.html +9 -0
- package/docs/hierarchy.html +1 -0
- package/docs/index.html +3 -0
- package/docs/modules/IDLV2.html +2 -0
- package/docs/modules/lending.html +1 -0
- package/docs/modules.html +4 -0
- package/docs/types/IDLV2.Lavarage.html +8 -0
- package/docs/types/Lavarage.html +8 -0
- package/docs/variables/IDL.html +1 -0
- package/docs/variables/IDLV2.IDL.html +1 -0
- package/docs-readme.md +5 -0
- package/evm.ts +308 -0
- package/idl/lavarage.ts +126 -0
- package/idl/lavaragev2.ts +166 -0
- package/index.ts +924 -113
- package/lending.ts +330 -1
- package/package.json +8 -5
- package/typedoc.json +23 -0
package/idl/lavaragev2.ts
CHANGED
|
@@ -772,6 +772,89 @@ export type Lavarage = {
|
|
|
772
772
|
}
|
|
773
773
|
]
|
|
774
774
|
},
|
|
775
|
+
{
|
|
776
|
+
"name": "tradingCloseRepaySolWithReferral",
|
|
777
|
+
"accounts": [
|
|
778
|
+
{
|
|
779
|
+
"name": "positionAccount",
|
|
780
|
+
"isMut": true,
|
|
781
|
+
"isSigner": false
|
|
782
|
+
},
|
|
783
|
+
{
|
|
784
|
+
"name": "trader",
|
|
785
|
+
"isMut": true,
|
|
786
|
+
"isSigner": true
|
|
787
|
+
},
|
|
788
|
+
{
|
|
789
|
+
"name": "tradingPool",
|
|
790
|
+
"isMut": true,
|
|
791
|
+
"isSigner": false
|
|
792
|
+
},
|
|
793
|
+
{
|
|
794
|
+
"name": "nodeWallet",
|
|
795
|
+
"isMut": true,
|
|
796
|
+
"isSigner": false
|
|
797
|
+
},
|
|
798
|
+
{
|
|
799
|
+
"name": "systemProgram",
|
|
800
|
+
"isMut": false,
|
|
801
|
+
"isSigner": false
|
|
802
|
+
},
|
|
803
|
+
{
|
|
804
|
+
"name": "clock",
|
|
805
|
+
"isMut": false,
|
|
806
|
+
"isSigner": false
|
|
807
|
+
},
|
|
808
|
+
{
|
|
809
|
+
"name": "randomAccountAsId",
|
|
810
|
+
"isMut": false,
|
|
811
|
+
"isSigner": false
|
|
812
|
+
},
|
|
813
|
+
{
|
|
814
|
+
"name": "mint",
|
|
815
|
+
"isMut": false,
|
|
816
|
+
"isSigner": false
|
|
817
|
+
},
|
|
818
|
+
{
|
|
819
|
+
"name": "fromTokenAccount",
|
|
820
|
+
"isMut": true,
|
|
821
|
+
"isSigner": false
|
|
822
|
+
},
|
|
823
|
+
{
|
|
824
|
+
"name": "toTokenAccount",
|
|
825
|
+
"isMut": true,
|
|
826
|
+
"isSigner": false
|
|
827
|
+
},
|
|
828
|
+
{
|
|
829
|
+
"name": "feeTokenAccount",
|
|
830
|
+
"isMut": true,
|
|
831
|
+
"isSigner": false
|
|
832
|
+
},
|
|
833
|
+
{
|
|
834
|
+
"name": "tokenProgram",
|
|
835
|
+
"isMut": false,
|
|
836
|
+
"isSigner": false
|
|
837
|
+
}
|
|
838
|
+
],
|
|
839
|
+
"args": [
|
|
840
|
+
{
|
|
841
|
+
"name": "closingPositionSize",
|
|
842
|
+
"type": "u64"
|
|
843
|
+
},
|
|
844
|
+
{
|
|
845
|
+
"name": "closeType",
|
|
846
|
+
"type": "u64"
|
|
847
|
+
},
|
|
848
|
+
{
|
|
849
|
+
"name": "discountBps",
|
|
850
|
+
"type": "u64"
|
|
851
|
+
},
|
|
852
|
+
{
|
|
853
|
+
"name": "referralBps",
|
|
854
|
+
"type": "u64"
|
|
855
|
+
}
|
|
856
|
+
]
|
|
857
|
+
},
|
|
775
858
|
{
|
|
776
859
|
"name": "tradingPartialRepaySol",
|
|
777
860
|
"accounts": [
|
|
@@ -2459,6 +2542,89 @@ export const IDL: Lavarage = {
|
|
|
2459
2542
|
}
|
|
2460
2543
|
]
|
|
2461
2544
|
},
|
|
2545
|
+
{
|
|
2546
|
+
"name": "tradingCloseRepaySolWithReferral",
|
|
2547
|
+
"accounts": [
|
|
2548
|
+
{
|
|
2549
|
+
"name": "positionAccount",
|
|
2550
|
+
"isMut": true,
|
|
2551
|
+
"isSigner": false
|
|
2552
|
+
},
|
|
2553
|
+
{
|
|
2554
|
+
"name": "trader",
|
|
2555
|
+
"isMut": true,
|
|
2556
|
+
"isSigner": true
|
|
2557
|
+
},
|
|
2558
|
+
{
|
|
2559
|
+
"name": "tradingPool",
|
|
2560
|
+
"isMut": true,
|
|
2561
|
+
"isSigner": false
|
|
2562
|
+
},
|
|
2563
|
+
{
|
|
2564
|
+
"name": "nodeWallet",
|
|
2565
|
+
"isMut": true,
|
|
2566
|
+
"isSigner": false
|
|
2567
|
+
},
|
|
2568
|
+
{
|
|
2569
|
+
"name": "systemProgram",
|
|
2570
|
+
"isMut": false,
|
|
2571
|
+
"isSigner": false
|
|
2572
|
+
},
|
|
2573
|
+
{
|
|
2574
|
+
"name": "clock",
|
|
2575
|
+
"isMut": false,
|
|
2576
|
+
"isSigner": false
|
|
2577
|
+
},
|
|
2578
|
+
{
|
|
2579
|
+
"name": "randomAccountAsId",
|
|
2580
|
+
"isMut": false,
|
|
2581
|
+
"isSigner": false
|
|
2582
|
+
},
|
|
2583
|
+
{
|
|
2584
|
+
"name": "mint",
|
|
2585
|
+
"isMut": false,
|
|
2586
|
+
"isSigner": false
|
|
2587
|
+
},
|
|
2588
|
+
{
|
|
2589
|
+
"name": "fromTokenAccount",
|
|
2590
|
+
"isMut": true,
|
|
2591
|
+
"isSigner": false
|
|
2592
|
+
},
|
|
2593
|
+
{
|
|
2594
|
+
"name": "toTokenAccount",
|
|
2595
|
+
"isMut": true,
|
|
2596
|
+
"isSigner": false
|
|
2597
|
+
},
|
|
2598
|
+
{
|
|
2599
|
+
"name": "feeTokenAccount",
|
|
2600
|
+
"isMut": true,
|
|
2601
|
+
"isSigner": false
|
|
2602
|
+
},
|
|
2603
|
+
{
|
|
2604
|
+
"name": "tokenProgram",
|
|
2605
|
+
"isMut": false,
|
|
2606
|
+
"isSigner": false
|
|
2607
|
+
}
|
|
2608
|
+
],
|
|
2609
|
+
"args": [
|
|
2610
|
+
{
|
|
2611
|
+
"name": "closingPositionSize",
|
|
2612
|
+
"type": "u64"
|
|
2613
|
+
},
|
|
2614
|
+
{
|
|
2615
|
+
"name": "closeType",
|
|
2616
|
+
"type": "u64"
|
|
2617
|
+
},
|
|
2618
|
+
{
|
|
2619
|
+
"name": "discountBps",
|
|
2620
|
+
"type": "u64"
|
|
2621
|
+
},
|
|
2622
|
+
{
|
|
2623
|
+
"name": "referralBps",
|
|
2624
|
+
"type": "u64"
|
|
2625
|
+
}
|
|
2626
|
+
]
|
|
2627
|
+
},
|
|
2462
2628
|
{
|
|
2463
2629
|
"name": "tradingPartialRepaySol",
|
|
2464
2630
|
"accounts": [
|