@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.
Files changed (90) hide show
  1. package/.DS_Store +0 -0
  2. package/.gitignore +18 -1
  3. package/README.md +33 -0
  4. package/dist/index.d.mts +1396 -1
  5. package/dist/index.d.ts +1396 -1
  6. package/dist/index.js +287 -3
  7. package/dist/index.js.map +1 -1
  8. package/dist/index.mjs +287 -3
  9. package/dist/index.mjs.map +1 -1
  10. package/docs/.nojekyll +1 -0
  11. package/docs/assets/hierarchy.js +1 -0
  12. package/docs/assets/highlight.css +92 -0
  13. package/docs/assets/icons.js +18 -0
  14. package/docs/assets/icons.svg +1 -0
  15. package/docs/assets/main.js +60 -0
  16. package/docs/assets/navigation.js +1 -0
  17. package/docs/assets/search.js +1 -0
  18. package/docs/assets/style.css +1633 -0
  19. package/docs/functions/borrowV1.html +1 -0
  20. package/docs/functions/borrowV2.html +1 -0
  21. package/docs/functions/closePositionEvm.html +9 -0
  22. package/docs/functions/closeTradeV1.html +17 -0
  23. package/docs/functions/closeTradeV2.html +18 -0
  24. package/docs/functions/createTpDelegate.html +17 -0
  25. package/docs/functions/getActiveLoanCountEvm.html +8 -0
  26. package/docs/functions/getActiveLoansBatchEvm.html +10 -0
  27. package/docs/functions/getAllPositions.html +17 -0
  28. package/docs/functions/getAvailableExposureEvm.html +9 -0
  29. package/docs/functions/getClosedPositions.html +7 -0
  30. package/docs/functions/getClosedPositionsEvm.html +9 -0
  31. package/docs/functions/getCollateralExposureEvm.html +9 -0
  32. package/docs/functions/getCollateralInfoEvm.html +9 -0
  33. package/docs/functions/getDelegateAccounts.html +13 -0
  34. package/docs/functions/getLiquidatedPositions.html +13 -0
  35. package/docs/functions/getLiquidatedPositionsEvm.html +9 -0
  36. package/docs/functions/getLoanEvm.html +9 -0
  37. package/docs/functions/getLoansByBorrowerEvm.html +9 -0
  38. package/docs/functions/getOffers.html +7 -0
  39. package/docs/functions/getOffersEvm.html +9 -0
  40. package/docs/functions/getOpenPositions.html +11 -0
  41. package/docs/functions/getOpeningFeeEvm.html +8 -0
  42. package/docs/functions/getPda.html +8 -0
  43. package/docs/functions/getPositionAccountPDA.html +9 -0
  44. package/docs/functions/getPositionsEvm.html +8 -0
  45. package/docs/functions/getProfitFeeEvm.html +8 -0
  46. package/docs/functions/getTokenBalanceEvm.html +8 -0
  47. package/docs/functions/getUserLoansEvm.html +9 -0
  48. package/docs/functions/lending.addToWithdrawalAccessList.html +1 -0
  49. package/docs/functions/lending.createOffer.html +15 -0
  50. package/docs/functions/lending.depositFunds.html +17 -0
  51. package/docs/functions/lending.getNodeWalletPDA.html +9 -0
  52. package/docs/functions/lending.getTradingPoolPDA.html +9 -0
  53. package/docs/functions/lending.getWithdrawalAccessList.html +1 -0
  54. package/docs/functions/lending.getWithdrawalAccessListPDA.html +1 -0
  55. package/docs/functions/lending.removeFromWithdrawalAccessList.html +1 -0
  56. package/docs/functions/lending.updateInterestRate.html +13 -0
  57. package/docs/functions/lending.updateMaxBorrow.html +13 -0
  58. package/docs/functions/lending.updateMaxExposure.html +13 -0
  59. package/docs/functions/lending.updateOffer.html +19 -0
  60. package/docs/functions/lending.withdrawFunds.html +20 -0
  61. package/docs/functions/lending.withdrawFundsV1.html +16 -0
  62. package/docs/functions/lending.withdrawFundsV2.html +19 -0
  63. package/docs/functions/liquidatePositionEvm.html +6 -0
  64. package/docs/functions/mergePositionV2.html +13 -0
  65. package/docs/functions/modifyTpDelegate.html +17 -0
  66. package/docs/functions/openPositionEvm.html +9 -0
  67. package/docs/functions/openTradeV1.html +26 -0
  68. package/docs/functions/openTradeV2.html +29 -0
  69. package/docs/functions/partialRepayV1.html +10 -0
  70. package/docs/functions/partialRepayV2.html +10 -0
  71. package/docs/functions/removeTpDelegate.html +13 -0
  72. package/docs/functions/splitPositionV2.html +13 -0
  73. package/docs/functions/updateMaxLendPerTokenBatchEvm.html +9 -0
  74. package/docs/hierarchy.html +1 -0
  75. package/docs/index.html +3 -0
  76. package/docs/modules/IDLV2.html +2 -0
  77. package/docs/modules/lending.html +1 -0
  78. package/docs/modules.html +4 -0
  79. package/docs/types/IDLV2.Lavarage.html +8 -0
  80. package/docs/types/Lavarage.html +8 -0
  81. package/docs/variables/IDL.html +1 -0
  82. package/docs/variables/IDLV2.IDL.html +1 -0
  83. package/docs-readme.md +5 -0
  84. package/evm.ts +308 -0
  85. package/idl/lavarage.ts +126 -0
  86. package/idl/lavaragev2.ts +166 -0
  87. package/index.ts +924 -113
  88. package/lending.ts +330 -1
  89. package/package.json +8 -5
  90. 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": [