@exponent-labs/exponent-sdk 0.1.8 → 0.9.1
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/build/CodamaEventDecoder.d.ts +49 -0
- package/build/CodamaEventDecoder.js +113 -0
- package/build/CodamaEventDecoder.js.map +1 -0
- package/build/addressLookupTableUtil.d.ts +23 -18
- package/build/addressLookupTableUtil.js +31 -5
- package/build/addressLookupTableUtil.js.map +1 -1
- package/build/client/clmm/accounts/lpPosition.d.ts +29 -0
- package/build/client/clmm/accounts/lpPosition.js +82 -0
- package/build/client/clmm/accounts/lpPosition.js.map +1 -0
- package/build/client/clmm/accounts/marketThree.d.ts +47 -0
- package/build/client/clmm/accounts/marketThree.js +139 -0
- package/build/client/clmm/accounts/marketThree.js.map +1 -0
- package/build/client/clmm/accounts/vault.d.ts +48 -0
- package/build/client/clmm/accounts/vault.js +128 -0
- package/build/client/clmm/accounts/vault.js.map +1 -0
- package/build/client/clmm/eventRegistry.d.ts +59 -0
- package/build/client/clmm/eventRegistry.js +58 -0
- package/build/client/clmm/eventRegistry.js.map +1 -0
- package/build/client/clmm/index.d.ts +78 -0
- package/build/client/clmm/index.js +96 -0
- package/build/client/clmm/index.js.map +1 -0
- package/build/client/clmm/instructions/addFarm.d.ts +19 -0
- package/build/client/clmm/instructions/addFarm.js +31 -0
- package/build/client/clmm/instructions/addFarm.js.map +1 -0
- package/build/client/clmm/instructions/addLiquidity.d.ts +26 -0
- package/build/client/clmm/instructions/addLiquidity.js +38 -0
- package/build/client/clmm/instructions/addLiquidity.js.map +1 -0
- package/build/client/clmm/instructions/addMarketEmission.d.ts +15 -0
- package/build/client/clmm/instructions/addMarketEmission.js +27 -0
- package/build/client/clmm/instructions/addMarketEmission.js.map +1 -0
- package/build/client/clmm/instructions/buyPt.d.ts +24 -0
- package/build/client/clmm/instructions/buyPt.js +36 -0
- package/build/client/clmm/instructions/buyPt.js.map +1 -0
- package/build/client/clmm/instructions/buyYt.d.ts +26 -0
- package/build/client/clmm/instructions/buyYt.js +42 -0
- package/build/client/clmm/instructions/buyYt.js.map +1 -0
- package/build/client/clmm/instructions/claimFarmEmission.d.ts +18 -0
- package/build/client/clmm/instructions/claimFarmEmission.js +30 -0
- package/build/client/clmm/instructions/claimFarmEmission.js.map +1 -0
- package/build/client/clmm/instructions/closeMarket.d.ts +17 -0
- package/build/client/clmm/instructions/closeMarket.js +26 -0
- package/build/client/clmm/instructions/closeMarket.js.map +1 -0
- package/build/client/clmm/instructions/depositLiquidity.d.ts +25 -0
- package/build/client/clmm/instructions/depositLiquidity.js +37 -0
- package/build/client/clmm/instructions/depositLiquidity.js.map +1 -0
- package/build/client/clmm/instructions/initializeMarket.d.ts +47 -0
- package/build/client/clmm/instructions/initializeMarket.js +63 -0
- package/build/client/clmm/instructions/initializeMarket.js.map +1 -0
- package/build/client/clmm/instructions/marketAccrueEmission.d.ts +13 -0
- package/build/client/clmm/instructions/marketAccrueEmission.js +22 -0
- package/build/client/clmm/instructions/marketAccrueEmission.js.map +1 -0
- package/build/client/clmm/instructions/marketCollectEmission.d.ts +18 -0
- package/build/client/clmm/instructions/marketCollectEmission.js +30 -0
- package/build/client/clmm/instructions/marketCollectEmission.js.map +1 -0
- package/build/client/clmm/instructions/modifyFarm.d.ts +17 -0
- package/build/client/clmm/instructions/modifyFarm.js +29 -0
- package/build/client/clmm/instructions/modifyFarm.js.map +1 -0
- package/build/client/clmm/instructions/modifyMarketSetting.d.ts +11 -0
- package/build/client/clmm/instructions/modifyMarketSetting.js +23 -0
- package/build/client/clmm/instructions/modifyMarketSetting.js.map +1 -0
- package/build/client/clmm/instructions/sellPt.d.ts +24 -0
- package/build/client/clmm/instructions/sellPt.js +36 -0
- package/build/client/clmm/instructions/sellPt.js.map +1 -0
- package/build/client/clmm/instructions/sellYt.d.ts +26 -0
- package/build/client/clmm/instructions/sellYt.js +42 -0
- package/build/client/clmm/instructions/sellYt.js.map +1 -0
- package/build/client/clmm/instructions/tradePt.d.ts +25 -0
- package/build/client/clmm/instructions/tradePt.js +37 -0
- package/build/client/clmm/instructions/tradePt.js.map +1 -0
- package/build/client/clmm/instructions/tradePtExactOut.d.ts +25 -0
- package/build/client/clmm/instructions/tradePtExactOut.js +37 -0
- package/build/client/clmm/instructions/tradePtExactOut.js.map +1 -0
- package/build/client/clmm/instructions/withdrawLiquidity.d.ts +23 -0
- package/build/client/clmm/instructions/withdrawLiquidity.js +35 -0
- package/build/client/clmm/instructions/withdrawLiquidity.js.map +1 -0
- package/build/client/clmm/instructions/wrapperBuyYt.d.ts +28 -0
- package/build/client/clmm/instructions/wrapperBuyYt.js +48 -0
- package/build/client/clmm/instructions/wrapperBuyYt.js.map +1 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidity.d.ts +33 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidity.js +53 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidity.js.map +1 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidityBase.d.ts +32 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidityBase.js +52 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidityBase.js.map +1 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidityClassic.d.ts +28 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidityClassic.js +44 -0
- package/build/client/clmm/instructions/wrapperProvideLiquidityClassic.js.map +1 -0
- package/build/client/clmm/instructions/wrapperSellYt.d.ts +27 -0
- package/build/client/clmm/instructions/wrapperSellYt.js +47 -0
- package/build/client/clmm/instructions/wrapperSellYt.js.map +1 -0
- package/build/client/clmm/instructions/wrapperWithdrawLiquidity.d.ts +25 -0
- package/build/client/clmm/instructions/wrapperWithdrawLiquidity.js +41 -0
- package/build/client/clmm/instructions/wrapperWithdrawLiquidity.js.map +1 -0
- package/build/client/clmm/instructions/wrapperWithdrawLiquidityClassic.d.ts +22 -0
- package/build/client/clmm/instructions/wrapperWithdrawLiquidityClassic.js +38 -0
- package/build/client/clmm/instructions/wrapperWithdrawLiquidityClassic.js.map +1 -0
- package/build/client/clmm/types/addFarmEvent.d.ts +35 -0
- package/build/client/clmm/types/addFarmEvent.js +24 -0
- package/build/client/clmm/types/addFarmEvent.js.map +1 -0
- package/build/client/clmm/types/amount.d.ts +33 -0
- package/build/client/clmm/types/amount.js +20 -0
- package/build/client/clmm/types/amount.js.map +1 -0
- package/build/client/clmm/types/buyPtEvent.d.ts +23 -0
- package/build/client/clmm/types/buyPtEvent.js +18 -0
- package/build/client/clmm/types/buyPtEvent.js.map +1 -0
- package/build/client/clmm/types/buyYtEvent.d.ts +56 -0
- package/build/client/clmm/types/buyYtEvent.js +36 -0
- package/build/client/clmm/types/buyYtEvent.js.map +1 -0
- package/build/client/clmm/types/claimFarmEmissionsEvent.d.ts +171 -0
- package/build/client/clmm/types/claimFarmEmissionsEvent.js +42 -0
- package/build/client/clmm/types/claimFarmEmissionsEvent.js.map +1 -0
- package/build/client/clmm/types/claimLimits.d.ts +22 -0
- package/build/client/clmm/types/claimLimits.js +11 -0
- package/build/client/clmm/types/claimLimits.js.map +1 -0
- package/build/client/clmm/types/closeMarketEvent.d.ts +23 -0
- package/build/client/clmm/types/closeMarketEvent.js +18 -0
- package/build/client/clmm/types/closeMarketEvent.js.map +1 -0
- package/build/client/clmm/types/configurationOptions.d.ts +34 -0
- package/build/client/clmm/types/configurationOptions.js +14 -0
- package/build/client/clmm/types/configurationOptions.js.map +1 -0
- package/build/client/clmm/types/cpiAccounts.d.ts +107 -0
- package/build/client/clmm/types/cpiAccounts.js +13 -0
- package/build/client/clmm/types/cpiAccounts.js.map +1 -0
- package/build/client/clmm/types/cpiCoreAccounts.d.ts +47 -0
- package/build/client/clmm/types/cpiCoreAccounts.js +10 -0
- package/build/client/clmm/types/cpiCoreAccounts.js.map +1 -0
- package/build/client/clmm/types/cpiInterfaceContext.d.ts +18 -0
- package/build/client/clmm/types/cpiInterfaceContext.js +10 -0
- package/build/client/clmm/types/cpiInterfaceContext.js.map +1 -0
- package/build/client/clmm/types/crossingSplit.d.ts +124 -0
- package/build/client/clmm/types/crossingSplit.js +20 -0
- package/build/client/clmm/types/crossingSplit.js.map +1 -0
- package/build/client/clmm/types/depositLiquidityEvent.d.ts +171 -0
- package/build/client/clmm/types/depositLiquidityEvent.js +42 -0
- package/build/client/clmm/types/depositLiquidityEvent.js.map +1 -0
- package/build/client/clmm/types/depositLiquidityReturnData.d.ts +67 -0
- package/build/client/clmm/types/depositLiquidityReturnData.js +38 -0
- package/build/client/clmm/types/depositLiquidityReturnData.js.map +1 -0
- package/build/client/clmm/types/emissionInfo.d.ts +36 -0
- package/build/client/clmm/types/emissionInfo.js +22 -0
- package/build/client/clmm/types/emissionInfo.js.map +1 -0
- package/build/client/clmm/types/farmEmission.d.ts +24 -0
- package/build/client/clmm/types/farmEmission.js +16 -0
- package/build/client/clmm/types/farmEmission.js.map +1 -0
- package/build/client/clmm/types/index.d.ts +48 -0
- package/build/client/clmm/types/index.js +65 -0
- package/build/client/clmm/types/index.js.map +1 -0
- package/build/client/clmm/types/liquidityNetBalanceLimits.d.ts +26 -0
- package/build/client/clmm/types/liquidityNetBalanceLimits.js +12 -0
- package/build/client/clmm/types/liquidityNetBalanceLimits.js.map +1 -0
- package/build/client/clmm/types/lpFarm.d.ts +35 -0
- package/build/client/clmm/types/lpFarm.js +10 -0
- package/build/client/clmm/types/lpFarm.js.map +1 -0
- package/build/client/clmm/types/marketAccrueEmissionEvent.d.ts +151 -0
- package/build/client/clmm/types/marketAccrueEmissionEvent.js +31 -0
- package/build/client/clmm/types/marketAccrueEmissionEvent.js.map +1 -0
- package/build/client/clmm/types/marketAdminAction.d.ts +359 -0
- package/build/client/clmm/types/marketAdminAction.js +72 -0
- package/build/client/clmm/types/marketAdminAction.js.map +1 -0
- package/build/client/clmm/types/marketCollectEmissionEvent.d.ts +163 -0
- package/build/client/clmm/types/marketCollectEmissionEvent.js +37 -0
- package/build/client/clmm/types/marketCollectEmissionEvent.js.map +1 -0
- package/build/client/clmm/types/marketEmission.d.ts +20 -0
- package/build/client/clmm/types/marketEmission.js +15 -0
- package/build/client/clmm/types/marketEmission.js.map +1 -0
- package/build/client/clmm/types/marketEmissions.d.ts +27 -0
- package/build/client/clmm/types/marketEmissions.js +9 -0
- package/build/client/clmm/types/marketEmissions.js.map +1 -0
- package/build/client/clmm/types/marketFinancials.d.ts +26 -0
- package/build/client/clmm/types/marketFinancials.js +12 -0
- package/build/client/clmm/types/marketFinancials.js.map +1 -0
- package/build/client/clmm/types/marketThreeInitEvent.d.ts +71 -0
- package/build/client/clmm/types/marketThreeInitEvent.js +42 -0
- package/build/client/clmm/types/marketThreeInitEvent.js.map +1 -0
- package/build/client/clmm/types/mergeEvent.d.ts +84 -0
- package/build/client/clmm/types/mergeEvent.js +55 -0
- package/build/client/clmm/types/mergeEvent.js.map +1 -0
- package/build/client/clmm/types/modifiedTick.d.ts +18 -0
- package/build/client/clmm/types/modifiedTick.js +10 -0
- package/build/client/clmm/types/modifiedTick.js.map +1 -0
- package/build/client/clmm/types/modifiedTicks.d.ts +43 -0
- package/build/client/clmm/types/modifiedTicks.js +13 -0
- package/build/client/clmm/types/modifiedTicks.js.map +1 -0
- package/build/client/clmm/types/modifyFarmEvent.d.ts +43 -0
- package/build/client/clmm/types/modifyFarmEvent.js +26 -0
- package/build/client/clmm/types/modifyFarmEvent.js.map +1 -0
- package/build/client/clmm/types/number.d.ts +2 -0
- package/build/client/clmm/types/number.js +8 -0
- package/build/client/clmm/types/number.js.map +1 -0
- package/build/client/clmm/types/personalYieldTracker.d.ts +15 -0
- package/build/client/clmm/types/personalYieldTracker.js +10 -0
- package/build/client/clmm/types/personalYieldTracker.js.map +1 -0
- package/build/client/clmm/types/personalYieldTrackers.d.ts +23 -0
- package/build/client/clmm/types/personalYieldTrackers.js +9 -0
- package/build/client/clmm/types/personalYieldTrackers.js.map +1 -0
- package/build/client/clmm/types/principalShare.d.ts +51 -0
- package/build/client/clmm/types/principalShare.js +14 -0
- package/build/client/clmm/types/principalShare.js.map +1 -0
- package/build/client/clmm/types/principalShareTrackers.d.ts +63 -0
- package/build/client/clmm/types/principalShareTrackers.js +9 -0
- package/build/client/clmm/types/principalShareTrackers.js.map +1 -0
- package/build/client/clmm/types/sellPtEvent.d.ts +23 -0
- package/build/client/clmm/types/sellPtEvent.js +18 -0
- package/build/client/clmm/types/sellPtEvent.js.map +1 -0
- package/build/client/clmm/types/sellYtEvent.d.ts +47 -0
- package/build/client/clmm/types/sellYtEvent.js +33 -0
- package/build/client/clmm/types/sellYtEvent.js.map +1 -0
- package/build/client/clmm/types/stripEvent.d.ts +84 -0
- package/build/client/clmm/types/stripEvent.js +58 -0
- package/build/client/clmm/types/stripEvent.js.map +1 -0
- package/build/client/clmm/types/swapDirection.d.ts +5 -0
- package/build/client/clmm/types/swapDirection.js +11 -0
- package/build/client/clmm/types/swapDirection.js.map +1 -0
- package/build/client/clmm/types/tradePtEvent.d.ts +110 -0
- package/build/client/clmm/types/tradePtEvent.js +37 -0
- package/build/client/clmm/types/tradePtEvent.js.map +1 -0
- package/build/client/clmm/types/withdrawLiquidityEvent.d.ts +183 -0
- package/build/client/clmm/types/withdrawLiquidityEvent.js +45 -0
- package/build/client/clmm/types/withdrawLiquidityEvent.js.map +1 -0
- package/build/client/clmm/types/withdrawLiquidityReturnData.d.ts +46 -0
- package/build/client/clmm/types/withdrawLiquidityReturnData.js +17 -0
- package/build/client/clmm/types/withdrawLiquidityReturnData.js.map +1 -0
- package/build/client/clmm/types/wrapperBuyYtEvent.d.ts +23 -0
- package/build/client/clmm/types/wrapperBuyYtEvent.js +18 -0
- package/build/client/clmm/types/wrapperBuyYtEvent.js.map +1 -0
- package/build/client/clmm/types/wrapperProvideLiquidityBaseEvent.d.ts +56 -0
- package/build/client/clmm/types/wrapperProvideLiquidityBaseEvent.js +30 -0
- package/build/client/clmm/types/wrapperProvideLiquidityBaseEvent.js.map +1 -0
- package/build/client/clmm/types/wrapperProvideLiquidityClassicEvent.d.ts +52 -0
- package/build/client/clmm/types/wrapperProvideLiquidityClassicEvent.js +29 -0
- package/build/client/clmm/types/wrapperProvideLiquidityClassicEvent.js.map +1 -0
- package/build/client/clmm/types/wrapperProvideLiquidityEvent.d.ts +56 -0
- package/build/client/clmm/types/wrapperProvideLiquidityEvent.js +30 -0
- package/build/client/clmm/types/wrapperProvideLiquidityEvent.js.map +1 -0
- package/build/client/clmm/types/wrapperSellYtEvent.d.ts +23 -0
- package/build/client/clmm/types/wrapperSellYtEvent.js +18 -0
- package/build/client/clmm/types/wrapperSellYtEvent.js.map +1 -0
- package/build/client/clmm/types/wrapperWithdrawLiquidityClassicEvent.d.ts +60 -0
- package/build/client/clmm/types/wrapperWithdrawLiquidityClassicEvent.js +31 -0
- package/build/client/clmm/types/wrapperWithdrawLiquidityClassicEvent.js.map +1 -0
- package/build/client/clmm/types/wrapperWithdrawLiquidityEvent.d.ts +60 -0
- package/build/client/clmm/types/wrapperWithdrawLiquidityEvent.js +31 -0
- package/build/client/clmm/types/wrapperWithdrawLiquidityEvent.js.map +1 -0
- package/build/client/core/accounts/admin.d.ts +18 -0
- package/build/client/core/accounts/admin.js +71 -0
- package/build/client/core/accounts/admin.js.map +1 -0
- package/build/client/core/accounts/lpPosition.d.ts +20 -0
- package/build/client/core/accounts/lpPosition.js +73 -0
- package/build/client/core/accounts/lpPosition.js.map +1 -0
- package/build/client/core/accounts/marketTwo.d.ts +42 -0
- package/build/client/core/accounts/marketTwo.js +122 -0
- package/build/client/core/accounts/marketTwo.js.map +1 -0
- package/build/client/core/accounts/vault.d.ts +48 -0
- package/build/client/core/accounts/vault.js +128 -0
- package/build/client/core/accounts/vault.js.map +1 -0
- package/build/client/core/accounts/yieldTokenPosition.d.ts +20 -0
- package/build/client/core/accounts/yieldTokenPosition.js +74 -0
- package/build/client/core/accounts/yieldTokenPosition.js.map +1 -0
- package/build/client/core/eventRegistry.d.ts +87 -0
- package/build/client/core/eventRegistry.js +86 -0
- package/build/client/core/eventRegistry.js.map +1 -0
- package/build/client/core/index.d.ts +109 -0
- package/build/client/core/index.js +127 -0
- package/build/client/core/index.js.map +1 -0
- package/build/client/core/instructions/addEmission.d.ts +19 -0
- package/build/client/core/instructions/addEmission.js +35 -0
- package/build/client/core/instructions/addEmission.js.map +1 -0
- package/build/client/core/instructions/addFarm.d.ts +17 -0
- package/build/client/core/instructions/addFarm.js +29 -0
- package/build/client/core/instructions/addFarm.js.map +1 -0
- package/build/client/core/instructions/addLpTokensMetadata.d.ts +16 -0
- package/build/client/core/instructions/addLpTokensMetadata.js +32 -0
- package/build/client/core/instructions/addLpTokensMetadata.js.map +1 -0
- package/build/client/core/instructions/addMarketEmission.d.ts +16 -0
- package/build/client/core/instructions/addMarketEmission.js +28 -0
- package/build/client/core/instructions/addMarketEmission.js.map +1 -0
- package/build/client/core/instructions/buyYt.d.ts +28 -0
- package/build/client/core/instructions/buyYt.js +44 -0
- package/build/client/core/instructions/buyYt.js.map +1 -0
- package/build/client/core/instructions/claimFarmEmissions.d.ts +17 -0
- package/build/client/core/instructions/claimFarmEmissions.js +29 -0
- package/build/client/core/instructions/claimFarmEmissions.js.map +1 -0
- package/build/client/core/instructions/collectEmission.d.ts +21 -0
- package/build/client/core/instructions/collectEmission.js +37 -0
- package/build/client/core/instructions/collectEmission.js.map +1 -0
- package/build/client/core/instructions/collectInterest.d.ts +20 -0
- package/build/client/core/instructions/collectInterest.js +36 -0
- package/build/client/core/instructions/collectInterest.js.map +1 -0
- package/build/client/core/instructions/collectTreasuryEmission.d.ts +21 -0
- package/build/client/core/instructions/collectTreasuryEmission.js +33 -0
- package/build/client/core/instructions/collectTreasuryEmission.js.map +1 -0
- package/build/client/core/instructions/collectTreasuryInterest.d.ts +20 -0
- package/build/client/core/instructions/collectTreasuryInterest.js +32 -0
- package/build/client/core/instructions/collectTreasuryInterest.js.map +1 -0
- package/build/client/core/instructions/depositYt.d.ts +19 -0
- package/build/client/core/instructions/depositYt.js +31 -0
- package/build/client/core/instructions/depositYt.js.map +1 -0
- package/build/client/core/instructions/initLpPosition.d.ts +11 -0
- package/build/client/core/instructions/initLpPosition.js +20 -0
- package/build/client/core/instructions/initLpPosition.js.map +1 -0
- package/build/client/core/instructions/initMarketTwo.d.ts +37 -0
- package/build/client/core/instructions/initMarketTwo.js +53 -0
- package/build/client/core/instructions/initMarketTwo.js.map +1 -0
- package/build/client/core/instructions/initializeVault.d.ts +34 -0
- package/build/client/core/instructions/initializeVault.js +58 -0
- package/build/client/core/instructions/initializeVault.js.map +1 -0
- package/build/client/core/instructions/initializeYieldPosition.d.ts +10 -0
- package/build/client/core/instructions/initializeYieldPosition.js +19 -0
- package/build/client/core/instructions/initializeYieldPosition.js.map +1 -0
- package/build/client/core/instructions/marketCollectEmission.d.ts +17 -0
- package/build/client/core/instructions/marketCollectEmission.js +29 -0
- package/build/client/core/instructions/marketCollectEmission.js.map +1 -0
- package/build/client/core/instructions/marketDepositLp.d.ts +19 -0
- package/build/client/core/instructions/marketDepositLp.js +31 -0
- package/build/client/core/instructions/marketDepositLp.js.map +1 -0
- package/build/client/core/instructions/marketTwoDepositLiquidity.d.ts +22 -0
- package/build/client/core/instructions/marketTwoDepositLiquidity.js +34 -0
- package/build/client/core/instructions/marketTwoDepositLiquidity.js.map +1 -0
- package/build/client/core/instructions/marketTwoWithdrawLiquidity.d.ts +22 -0
- package/build/client/core/instructions/marketTwoWithdrawLiquidity.js +34 -0
- package/build/client/core/instructions/marketTwoWithdrawLiquidity.js.map +1 -0
- package/build/client/core/instructions/marketWithdrawLp.d.ts +19 -0
- package/build/client/core/instructions/marketWithdrawLp.js +31 -0
- package/build/client/core/instructions/marketWithdrawLp.js.map +1 -0
- package/build/client/core/instructions/merge.d.ts +22 -0
- package/build/client/core/instructions/merge.js +32 -0
- package/build/client/core/instructions/merge.js.map +1 -0
- package/build/client/core/instructions/modifyFarm.d.ts +15 -0
- package/build/client/core/instructions/modifyFarm.js +27 -0
- package/build/client/core/instructions/modifyFarm.js.map +1 -0
- package/build/client/core/instructions/modifyMarketSetting.d.ts +12 -0
- package/build/client/core/instructions/modifyMarketSetting.js +24 -0
- package/build/client/core/instructions/modifyMarketSetting.js.map +1 -0
- package/build/client/core/instructions/modifyVaultSetting.d.ts +12 -0
- package/build/client/core/instructions/modifyVaultSetting.js +24 -0
- package/build/client/core/instructions/modifyVaultSetting.js.map +1 -0
- package/build/client/core/instructions/reallocMarket.d.ts +12 -0
- package/build/client/core/instructions/reallocMarket.js +24 -0
- package/build/client/core/instructions/reallocMarket.js.map +1 -0
- package/build/client/core/instructions/sellYt.d.ts +28 -0
- package/build/client/core/instructions/sellYt.js +44 -0
- package/build/client/core/instructions/sellYt.js.map +1 -0
- package/build/client/core/instructions/stageYtYield.d.ts +13 -0
- package/build/client/core/instructions/stageYtYield.js +22 -0
- package/build/client/core/instructions/stageYtYield.js.map +1 -0
- package/build/client/core/instructions/strip.d.ts +22 -0
- package/build/client/core/instructions/strip.js +32 -0
- package/build/client/core/instructions/strip.js.map +1 -0
- package/build/client/core/instructions/tradePt.d.ts +20 -0
- package/build/client/core/instructions/tradePt.js +32 -0
- package/build/client/core/instructions/tradePt.js.map +1 -0
- package/build/client/core/instructions/withdrawYt.d.ts +20 -0
- package/build/client/core/instructions/withdrawYt.js +32 -0
- package/build/client/core/instructions/withdrawYt.js.map +1 -0
- package/build/client/core/instructions/wrapperBuyPt.d.ts +21 -0
- package/build/client/core/instructions/wrapperBuyPt.js +33 -0
- package/build/client/core/instructions/wrapperBuyPt.js.map +1 -0
- package/build/client/core/instructions/wrapperBuyYt.d.ts +32 -0
- package/build/client/core/instructions/wrapperBuyYt.js +52 -0
- package/build/client/core/instructions/wrapperBuyYt.js.map +1 -0
- package/build/client/core/instructions/wrapperCollectInterest.d.ts +19 -0
- package/build/client/core/instructions/wrapperCollectInterest.js +35 -0
- package/build/client/core/instructions/wrapperCollectInterest.js.map +1 -0
- package/build/client/core/instructions/wrapperMerge.d.ts +24 -0
- package/build/client/core/instructions/wrapperMerge.js +44 -0
- package/build/client/core/instructions/wrapperMerge.js.map +1 -0
- package/build/client/core/instructions/wrapperProvideLiquidity.d.ts +35 -0
- package/build/client/core/instructions/wrapperProvideLiquidity.js +59 -0
- package/build/client/core/instructions/wrapperProvideLiquidity.js.map +1 -0
- package/build/client/core/instructions/wrapperProvideLiquidityBase.d.ts +28 -0
- package/build/client/core/instructions/wrapperProvideLiquidityBase.js +44 -0
- package/build/client/core/instructions/wrapperProvideLiquidityBase.js.map +1 -0
- package/build/client/core/instructions/wrapperProvideLiquidityClassic.d.ts +26 -0
- package/build/client/core/instructions/wrapperProvideLiquidityClassic.js +42 -0
- package/build/client/core/instructions/wrapperProvideLiquidityClassic.js.map +1 -0
- package/build/client/core/instructions/wrapperSellPt.d.ts +21 -0
- package/build/client/core/instructions/wrapperSellPt.js +33 -0
- package/build/client/core/instructions/wrapperSellPt.js.map +1 -0
- package/build/client/core/instructions/wrapperSellYt.d.ts +29 -0
- package/build/client/core/instructions/wrapperSellYt.js +49 -0
- package/build/client/core/instructions/wrapperSellYt.js.map +1 -0
- package/build/client/core/instructions/wrapperStrip.d.ts +26 -0
- package/build/client/core/instructions/wrapperStrip.js +46 -0
- package/build/client/core/instructions/wrapperStrip.js.map +1 -0
- package/build/client/core/instructions/wrapperWithdrawLiquidity.d.ts +26 -0
- package/build/client/core/instructions/wrapperWithdrawLiquidity.js +42 -0
- package/build/client/core/instructions/wrapperWithdrawLiquidity.js.map +1 -0
- package/build/client/core/instructions/wrapperWithdrawLiquidityClassic.d.ts +24 -0
- package/build/client/core/instructions/wrapperWithdrawLiquidityClassic.js +40 -0
- package/build/client/core/instructions/wrapperWithdrawLiquidityClassic.js.map +1 -0
- package/build/client/core/types/adminAction.d.ts +326 -0
- package/build/client/core/types/adminAction.js +87 -0
- package/build/client/core/types/adminAction.js.map +1 -0
- package/build/client/core/types/amount.d.ts +33 -0
- package/build/client/core/types/amount.js +20 -0
- package/build/client/core/types/amount.js.map +1 -0
- package/build/client/core/types/buyPtEvent.d.ts +27 -0
- package/build/client/core/types/buyPtEvent.js +19 -0
- package/build/client/core/types/buyPtEvent.js.map +1 -0
- package/build/client/core/types/buyYtEvent.d.ts +68 -0
- package/build/client/core/types/buyYtEvent.js +45 -0
- package/build/client/core/types/buyYtEvent.js.map +1 -0
- package/build/client/core/types/claimFarmEmissionsEvent.d.ts +43 -0
- package/build/client/core/types/claimFarmEmissionsEvent.js +35 -0
- package/build/client/core/types/claimFarmEmissionsEvent.js.map +1 -0
- package/build/client/core/types/claimFarmEmissionsEventV2.d.ts +98 -0
- package/build/client/core/types/claimFarmEmissionsEventV2.js +38 -0
- package/build/client/core/types/claimFarmEmissionsEventV2.js.map +1 -0
- package/build/client/core/types/claimLimits.d.ts +22 -0
- package/build/client/core/types/claimLimits.js +11 -0
- package/build/client/core/types/claimLimits.js.map +1 -0
- package/build/client/core/types/collectEmissionEvent.d.ts +35 -0
- package/build/client/core/types/collectEmissionEvent.js +24 -0
- package/build/client/core/types/collectEmissionEvent.js.map +1 -0
- package/build/client/core/types/collectEmissionEventV2.d.ts +68 -0
- package/build/client/core/types/collectEmissionEventV2.js +27 -0
- package/build/client/core/types/collectEmissionEventV2.js.map +1 -0
- package/build/client/core/types/collectInterestEvent.d.ts +31 -0
- package/build/client/core/types/collectInterestEvent.js +23 -0
- package/build/client/core/types/collectInterestEvent.js.map +1 -0
- package/build/client/core/types/collectInterestEventV2.d.ts +64 -0
- package/build/client/core/types/collectInterestEventV2.js +26 -0
- package/build/client/core/types/collectInterestEventV2.js.map +1 -0
- package/build/client/core/types/collectTreasuryEmissionKind.d.ts +5 -0
- package/build/client/core/types/collectTreasuryEmissionKind.js +11 -0
- package/build/client/core/types/collectTreasuryEmissionKind.js.map +1 -0
- package/build/client/core/types/collectTreasuryInterestKind.d.ts +5 -0
- package/build/client/core/types/collectTreasuryInterestKind.js +11 -0
- package/build/client/core/types/collectTreasuryInterestKind.js.map +1 -0
- package/build/client/core/types/cpiAccounts.d.ts +107 -0
- package/build/client/core/types/cpiAccounts.js +13 -0
- package/build/client/core/types/cpiAccounts.js.map +1 -0
- package/build/client/core/types/cpiInterfaceContext.d.ts +18 -0
- package/build/client/core/types/cpiInterfaceContext.js +10 -0
- package/build/client/core/types/cpiInterfaceContext.js.map +1 -0
- package/build/client/core/types/depositLiquidityEvent.d.ts +67 -0
- package/build/client/core/types/depositLiquidityEvent.js +47 -0
- package/build/client/core/types/depositLiquidityEvent.js.map +1 -0
- package/build/client/core/types/depositLpEvent.d.ts +43 -0
- package/build/client/core/types/depositLpEvent.js +35 -0
- package/build/client/core/types/depositLpEvent.js.map +1 -0
- package/build/client/core/types/depositLpEventV2.d.ts +98 -0
- package/build/client/core/types/depositLpEventV2.js +38 -0
- package/build/client/core/types/depositLpEventV2.js.map +1 -0
- package/build/client/core/types/depositYtEvent.d.ts +56 -0
- package/build/client/core/types/depositYtEvent.js +39 -0
- package/build/client/core/types/depositYtEvent.js.map +1 -0
- package/build/client/core/types/depositYtEventV2.d.ts +89 -0
- package/build/client/core/types/depositYtEventV2.js +42 -0
- package/build/client/core/types/depositYtEventV2.js.map +1 -0
- package/build/client/core/types/emissionInfo.d.ts +36 -0
- package/build/client/core/types/emissionInfo.js +22 -0
- package/build/client/core/types/emissionInfo.js.map +1 -0
- package/build/client/core/types/farmEmission.d.ts +24 -0
- package/build/client/core/types/farmEmission.js +16 -0
- package/build/client/core/types/farmEmission.js.map +1 -0
- package/build/client/core/types/index.d.ts +60 -0
- package/build/client/core/types/index.js +77 -0
- package/build/client/core/types/index.js.map +1 -0
- package/build/client/core/types/initLpPositionEvent.d.ts +35 -0
- package/build/client/core/types/initLpPositionEvent.js +27 -0
- package/build/client/core/types/initLpPositionEvent.js.map +1 -0
- package/build/client/core/types/initializeYieldPositionEvent.d.ts +23 -0
- package/build/client/core/types/initializeYieldPositionEvent.js +21 -0
- package/build/client/core/types/initializeYieldPositionEvent.js.map +1 -0
- package/build/client/core/types/liquidityNetBalanceLimits.d.ts +26 -0
- package/build/client/core/types/liquidityNetBalanceLimits.js +12 -0
- package/build/client/core/types/liquidityNetBalanceLimits.js.map +1 -0
- package/build/client/core/types/lpFarm.d.ts +35 -0
- package/build/client/core/types/lpFarm.js +10 -0
- package/build/client/core/types/lpFarm.js.map +1 -0
- package/build/client/core/types/marketAdminAction.d.ts +286 -0
- package/build/client/core/types/marketAdminAction.js +61 -0
- package/build/client/core/types/marketAdminAction.js.map +1 -0
- package/build/client/core/types/marketCollectEmissionEvent.d.ts +39 -0
- package/build/client/core/types/marketCollectEmissionEvent.js +31 -0
- package/build/client/core/types/marketCollectEmissionEvent.js.map +1 -0
- package/build/client/core/types/marketCollectEmissionEventV2.d.ts +94 -0
- package/build/client/core/types/marketCollectEmissionEventV2.js +34 -0
- package/build/client/core/types/marketCollectEmissionEventV2.js.map +1 -0
- package/build/client/core/types/marketEmission.d.ts +20 -0
- package/build/client/core/types/marketEmission.js +15 -0
- package/build/client/core/types/marketEmission.js.map +1 -0
- package/build/client/core/types/marketEmissions.d.ts +27 -0
- package/build/client/core/types/marketEmissions.js +9 -0
- package/build/client/core/types/marketEmissions.js.map +1 -0
- package/build/client/core/types/marketFinancials.d.ts +30 -0
- package/build/client/core/types/marketFinancials.js +13 -0
- package/build/client/core/types/marketFinancials.js.map +1 -0
- package/build/client/core/types/mergeEvent.d.ts +84 -0
- package/build/client/core/types/mergeEvent.js +55 -0
- package/build/client/core/types/mergeEvent.js.map +1 -0
- package/build/client/core/types/number.d.ts +2 -0
- package/build/client/core/types/number.js +8 -0
- package/build/client/core/types/number.js.map +1 -0
- package/build/client/core/types/personalYieldTracker.d.ts +15 -0
- package/build/client/core/types/personalYieldTracker.js +10 -0
- package/build/client/core/types/personalYieldTracker.js.map +1 -0
- package/build/client/core/types/personalYieldTrackers.d.ts +23 -0
- package/build/client/core/types/personalYieldTrackers.js +9 -0
- package/build/client/core/types/personalYieldTrackers.js.map +1 -0
- package/build/client/core/types/principleDetails.d.ts +11 -0
- package/build/client/core/types/principleDetails.js +12 -0
- package/build/client/core/types/principleDetails.js.map +1 -0
- package/build/client/core/types/principles.d.ts +79 -0
- package/build/client/core/types/principles.js +14 -0
- package/build/client/core/types/principles.js.map +1 -0
- package/build/client/core/types/sellPtEvent.d.ts +27 -0
- package/build/client/core/types/sellPtEvent.js +19 -0
- package/build/client/core/types/sellPtEvent.js.map +1 -0
- package/build/client/core/types/sellYtEvent.d.ts +59 -0
- package/build/client/core/types/sellYtEvent.js +42 -0
- package/build/client/core/types/sellYtEvent.js.map +1 -0
- package/build/client/core/types/stageYieldEvent.d.ts +44 -0
- package/build/client/core/types/stageYieldEvent.js +30 -0
- package/build/client/core/types/stageYieldEvent.js.map +1 -0
- package/build/client/core/types/stageYieldEventV2.d.ts +73 -0
- package/build/client/core/types/stageYieldEventV2.js +32 -0
- package/build/client/core/types/stageYieldEventV2.js.map +1 -0
- package/build/client/core/types/stripEvent.d.ts +84 -0
- package/build/client/core/types/stripEvent.js +58 -0
- package/build/client/core/types/stripEvent.js.map +1 -0
- package/build/client/core/types/tradePtEvent.d.ts +52 -0
- package/build/client/core/types/tradePtEvent.js +38 -0
- package/build/client/core/types/tradePtEvent.js.map +1 -0
- package/build/client/core/types/withdrawLiquidityEvent.d.ts +59 -0
- package/build/client/core/types/withdrawLiquidityEvent.js +45 -0
- package/build/client/core/types/withdrawLiquidityEvent.js.map +1 -0
- package/build/client/core/types/withdrawLpEvent.d.ts +43 -0
- package/build/client/core/types/withdrawLpEvent.js +35 -0
- package/build/client/core/types/withdrawLpEvent.js.map +1 -0
- package/build/client/core/types/withdrawLpEventV2.d.ts +98 -0
- package/build/client/core/types/withdrawLpEventV2.js +38 -0
- package/build/client/core/types/withdrawLpEventV2.js.map +1 -0
- package/build/client/core/types/withdrawYtEvent.d.ts +56 -0
- package/build/client/core/types/withdrawYtEvent.js +39 -0
- package/build/client/core/types/withdrawYtEvent.js.map +1 -0
- package/build/client/core/types/withdrawYtEventV2.d.ts +89 -0
- package/build/client/core/types/withdrawYtEventV2.js +42 -0
- package/build/client/core/types/withdrawYtEventV2.js.map +1 -0
- package/build/client/core/types/wrapperBuyYtEvent.d.ts +27 -0
- package/build/client/core/types/wrapperBuyYtEvent.js +19 -0
- package/build/client/core/types/wrapperBuyYtEvent.js.map +1 -0
- package/build/client/core/types/wrapperCollectInterestEvent.d.ts +23 -0
- package/build/client/core/types/wrapperCollectInterestEvent.js +18 -0
- package/build/client/core/types/wrapperCollectInterestEvent.js.map +1 -0
- package/build/client/core/types/wrapperMergeEvent.d.ts +27 -0
- package/build/client/core/types/wrapperMergeEvent.js +19 -0
- package/build/client/core/types/wrapperMergeEvent.js.map +1 -0
- package/build/client/core/types/wrapperProvideLiquidityBaseEvent.d.ts +35 -0
- package/build/client/core/types/wrapperProvideLiquidityBaseEvent.js +21 -0
- package/build/client/core/types/wrapperProvideLiquidityBaseEvent.js.map +1 -0
- package/build/client/core/types/wrapperProvideLiquidityClassicEvent.d.ts +31 -0
- package/build/client/core/types/wrapperProvideLiquidityClassicEvent.js +20 -0
- package/build/client/core/types/wrapperProvideLiquidityClassicEvent.js.map +1 -0
- package/build/client/core/types/wrapperProvideLiquidityEvent.d.ts +31 -0
- package/build/client/core/types/wrapperProvideLiquidityEvent.js +20 -0
- package/build/client/core/types/wrapperProvideLiquidityEvent.js.map +1 -0
- package/build/client/core/types/wrapperSellYtEvent.d.ts +27 -0
- package/build/client/core/types/wrapperSellYtEvent.js +19 -0
- package/build/client/core/types/wrapperSellYtEvent.js.map +1 -0
- package/build/client/core/types/wrapperStripEvent.d.ts +27 -0
- package/build/client/core/types/wrapperStripEvent.js +19 -0
- package/build/client/core/types/wrapperStripEvent.js.map +1 -0
- package/build/client/core/types/wrapperWithdrawLiquidityClassicEvent.d.ts +31 -0
- package/build/client/core/types/wrapperWithdrawLiquidityClassicEvent.js +20 -0
- package/build/client/core/types/wrapperWithdrawLiquidityClassicEvent.js.map +1 -0
- package/build/client/core/types/wrapperWithdrawLiquidityEvent.d.ts +27 -0
- package/build/client/core/types/wrapperWithdrawLiquidityEvent.js +19 -0
- package/build/client/core/types/wrapperWithdrawLiquidityEvent.js.map +1 -0
- package/build/client/core/types/yieldTokenTracker.d.ts +15 -0
- package/build/client/core/types/yieldTokenTracker.js +10 -0
- package/build/client/core/types/yieldTokenTracker.js.map +1 -0
- package/build/client/orderbook/accounts/cpiAccountsOrderbook.d.ts +18 -0
- package/build/client/orderbook/accounts/cpiAccountsOrderbook.js +66 -0
- package/build/client/orderbook/accounts/cpiAccountsOrderbook.js.map +1 -0
- package/build/client/orderbook/accounts/vault.d.ts +48 -0
- package/build/client/orderbook/accounts/vault.js +128 -0
- package/build/client/orderbook/accounts/vault.js.map +1 -0
- package/build/client/orderbook/eventRegistry.d.ts +45 -0
- package/build/client/orderbook/eventRegistry.js +44 -0
- package/build/client/orderbook/eventRegistry.js.map +1 -0
- package/build/client/orderbook/index.d.ts +51 -0
- package/build/client/orderbook/index.js +69 -0
- package/build/client/orderbook/index.js.map +1 -0
- package/build/client/orderbook/instructions/collectAdminEmission.d.ts +14 -0
- package/build/client/orderbook/instructions/collectAdminEmission.js +26 -0
- package/build/client/orderbook/instructions/collectAdminEmission.js.map +1 -0
- package/build/client/orderbook/instructions/collectAdminFee.d.ts +21 -0
- package/build/client/orderbook/instructions/collectAdminFee.js +34 -0
- package/build/client/orderbook/instructions/collectAdminFee.js.map +1 -0
- package/build/client/orderbook/instructions/collectInterest.d.ts +21 -0
- package/build/client/orderbook/instructions/collectInterest.js +37 -0
- package/build/client/orderbook/instructions/collectInterest.js.map +1 -0
- package/build/client/orderbook/instructions/initializeOrderbook.d.ts +36 -0
- package/build/client/orderbook/instructions/initializeOrderbook.js +52 -0
- package/build/client/orderbook/instructions/initializeOrderbook.js.map +1 -0
- package/build/client/orderbook/instructions/marketOffer.d.ts +30 -0
- package/build/client/orderbook/instructions/marketOffer.js +46 -0
- package/build/client/orderbook/instructions/marketOffer.js.map +1 -0
- package/build/client/orderbook/instructions/postOffer.d.ts +33 -0
- package/build/client/orderbook/instructions/postOffer.js +49 -0
- package/build/client/orderbook/instructions/postOffer.js.map +1 -0
- package/build/client/orderbook/instructions/reallocOrderbookAccount.d.ts +12 -0
- package/build/client/orderbook/instructions/reallocOrderbookAccount.js +24 -0
- package/build/client/orderbook/instructions/reallocOrderbookAccount.js.map +1 -0
- package/build/client/orderbook/instructions/removeExpiredOffers.d.ts +12 -0
- package/build/client/orderbook/instructions/removeExpiredOffers.js +21 -0
- package/build/client/orderbook/instructions/removeExpiredOffers.js.map +1 -0
- package/build/client/orderbook/instructions/removeOffer.d.ts +24 -0
- package/build/client/orderbook/instructions/removeOffer.js +40 -0
- package/build/client/orderbook/instructions/removeOffer.js.map +1 -0
- package/build/client/orderbook/instructions/setConfigurationOptions.d.ts +10 -0
- package/build/client/orderbook/instructions/setConfigurationOptions.js +22 -0
- package/build/client/orderbook/instructions/setConfigurationOptions.js.map +1 -0
- package/build/client/orderbook/instructions/withdrawFunds.d.ts +27 -0
- package/build/client/orderbook/instructions/withdrawFunds.js +43 -0
- package/build/client/orderbook/instructions/withdrawFunds.js.map +1 -0
- package/build/client/orderbook/instructions/wrapperCollectAdminFee.d.ts +24 -0
- package/build/client/orderbook/instructions/wrapperCollectAdminFee.js +40 -0
- package/build/client/orderbook/instructions/wrapperCollectAdminFee.js.map +1 -0
- package/build/client/orderbook/instructions/wrapperCollectInterest.d.ts +20 -0
- package/build/client/orderbook/instructions/wrapperCollectInterest.js +36 -0
- package/build/client/orderbook/instructions/wrapperCollectInterest.js.map +1 -0
- package/build/client/orderbook/instructions/wrapperMarketOffer.d.ts +32 -0
- package/build/client/orderbook/instructions/wrapperMarketOffer.js +48 -0
- package/build/client/orderbook/instructions/wrapperMarketOffer.js.map +1 -0
- package/build/client/orderbook/instructions/wrapperPostOffer.d.ts +34 -0
- package/build/client/orderbook/instructions/wrapperPostOffer.js +50 -0
- package/build/client/orderbook/instructions/wrapperPostOffer.js.map +1 -0
- package/build/client/orderbook/instructions/wrapperRemoveOffer.d.ts +25 -0
- package/build/client/orderbook/instructions/wrapperRemoveOffer.js +41 -0
- package/build/client/orderbook/instructions/wrapperRemoveOffer.js.map +1 -0
- package/build/client/orderbook/instructions/wrapperWithdrawFunds.d.ts +28 -0
- package/build/client/orderbook/instructions/wrapperWithdrawFunds.js +44 -0
- package/build/client/orderbook/instructions/wrapperWithdrawFunds.js.map +1 -0
- package/build/client/orderbook/types/amount.d.ts +33 -0
- package/build/client/orderbook/types/amount.js +20 -0
- package/build/client/orderbook/types/amount.js.map +1 -0
- package/build/client/orderbook/types/claimLimits.d.ts +22 -0
- package/build/client/orderbook/types/claimLimits.js +11 -0
- package/build/client/orderbook/types/claimLimits.js.map +1 -0
- package/build/client/orderbook/types/collectAdminEmissionEvent.d.ts +27 -0
- package/build/client/orderbook/types/collectAdminEmissionEvent.js +19 -0
- package/build/client/orderbook/types/collectAdminEmissionEvent.js.map +1 -0
- package/build/client/orderbook/types/collectAdminFeeEvent.d.ts +26 -0
- package/build/client/orderbook/types/collectAdminFeeEvent.js +12 -0
- package/build/client/orderbook/types/collectAdminFeeEvent.js.map +1 -0
- package/build/client/orderbook/types/collectEmissionEventV2.d.ts +68 -0
- package/build/client/orderbook/types/collectEmissionEventV2.js +27 -0
- package/build/client/orderbook/types/collectEmissionEventV2.js.map +1 -0
- package/build/client/orderbook/types/collectInterestEventV2.d.ts +64 -0
- package/build/client/orderbook/types/collectInterestEventV2.js +26 -0
- package/build/client/orderbook/types/collectInterestEventV2.js.map +1 -0
- package/build/client/orderbook/types/collectUserInterestEvent.d.ts +23 -0
- package/build/client/orderbook/types/collectUserInterestEvent.js +18 -0
- package/build/client/orderbook/types/collectUserInterestEvent.js.map +1 -0
- package/build/client/orderbook/types/cpiAccounts.d.ts +107 -0
- package/build/client/orderbook/types/cpiAccounts.js +13 -0
- package/build/client/orderbook/types/cpiAccounts.js.map +1 -0
- package/build/client/orderbook/types/cpiInterfaceContext.d.ts +18 -0
- package/build/client/orderbook/types/cpiInterfaceContext.js +10 -0
- package/build/client/orderbook/types/cpiInterfaceContext.js.map +1 -0
- package/build/client/orderbook/types/emissionInfo.d.ts +36 -0
- package/build/client/orderbook/types/emissionInfo.js +22 -0
- package/build/client/orderbook/types/emissionInfo.js.map +1 -0
- package/build/client/orderbook/types/exponentCoreCpiAccounts.d.ts +107 -0
- package/build/client/orderbook/types/exponentCoreCpiAccounts.js +13 -0
- package/build/client/orderbook/types/exponentCoreCpiAccounts.js.map +1 -0
- package/build/client/orderbook/types/filledOffersEvent.d.ts +30 -0
- package/build/client/orderbook/types/filledOffersEvent.js +13 -0
- package/build/client/orderbook/types/filledOffersEvent.js.map +1 -0
- package/build/client/orderbook/types/index.d.ts +30 -0
- package/build/client/orderbook/types/index.js +47 -0
- package/build/client/orderbook/types/index.js.map +1 -0
- package/build/client/orderbook/types/marketOfferEvent.d.ts +93 -0
- package/build/client/orderbook/types/marketOfferEvent.js +33 -0
- package/build/client/orderbook/types/marketOfferEvent.js.map +1 -0
- package/build/client/orderbook/types/mergeEvent.d.ts +84 -0
- package/build/client/orderbook/types/mergeEvent.js +55 -0
- package/build/client/orderbook/types/mergeEvent.js.map +1 -0
- package/build/client/orderbook/types/number.d.ts +2 -0
- package/build/client/orderbook/types/number.js +8 -0
- package/build/client/orderbook/types/number.js.map +1 -0
- package/build/client/orderbook/types/offerOptions.d.ts +24 -0
- package/build/client/orderbook/types/offerOptions.js +22 -0
- package/build/client/orderbook/types/offerOptions.js.map +1 -0
- package/build/client/orderbook/types/offerType.d.ts +5 -0
- package/build/client/orderbook/types/offerType.js +11 -0
- package/build/client/orderbook/types/offerType.js.map +1 -0
- package/build/client/orderbook/types/orderbookInitEvent.d.ts +39 -0
- package/build/client/orderbook/types/orderbookInitEvent.js +25 -0
- package/build/client/orderbook/types/orderbookInitEvent.js.map +1 -0
- package/build/client/orderbook/types/postOfferEvent.d.ts +118 -0
- package/build/client/orderbook/types/postOfferEvent.js +36 -0
- package/build/client/orderbook/types/postOfferEvent.js.map +1 -0
- package/build/client/orderbook/types/removeOfferEvent.d.ts +39 -0
- package/build/client/orderbook/types/removeOfferEvent.js +31 -0
- package/build/client/orderbook/types/removeOfferEvent.js.map +1 -0
- package/build/client/orderbook/types/setConfigurationOptionsEnum.d.ts +72 -0
- package/build/client/orderbook/types/setConfigurationOptionsEnum.js +34 -0
- package/build/client/orderbook/types/setConfigurationOptionsEnum.js.map +1 -0
- package/build/client/orderbook/types/stripEvent.d.ts +84 -0
- package/build/client/orderbook/types/stripEvent.js +58 -0
- package/build/client/orderbook/types/stripEvent.js.map +1 -0
- package/build/client/orderbook/types/withdrawFundsEvent.d.ts +39 -0
- package/build/client/orderbook/types/withdrawFundsEvent.js +31 -0
- package/build/client/orderbook/types/withdrawFundsEvent.js.map +1 -0
- package/build/client/orderbook/types/wrapperCollectAdminFeeEvent.d.ts +18 -0
- package/build/client/orderbook/types/wrapperCollectAdminFeeEvent.js +10 -0
- package/build/client/orderbook/types/wrapperCollectAdminFeeEvent.js.map +1 -0
- package/build/client/orderbook/types/wrapperCollectInterestEvent.d.ts +15 -0
- package/build/client/orderbook/types/wrapperCollectInterestEvent.js +13 -0
- package/build/client/orderbook/types/wrapperCollectInterestEvent.js.map +1 -0
- package/build/client/orderbook/types/wrapperMarketOfferEvent.d.ts +19 -0
- package/build/client/orderbook/types/wrapperMarketOfferEvent.js +14 -0
- package/build/client/orderbook/types/wrapperMarketOfferEvent.js.map +1 -0
- package/build/client/orderbook/types/wrapperPostOfferEvent.d.ts +39 -0
- package/build/client/orderbook/types/wrapperPostOfferEvent.js +34 -0
- package/build/client/orderbook/types/wrapperPostOfferEvent.js.map +1 -0
- package/build/client/orderbook/types/wrapperRemoveOfferEvent.d.ts +15 -0
- package/build/client/orderbook/types/wrapperRemoveOfferEvent.js +13 -0
- package/build/client/orderbook/types/wrapperRemoveOfferEvent.js.map +1 -0
- package/build/client/orderbook/types/wrapperWithdrawFundsEvent.d.ts +27 -0
- package/build/client/orderbook/types/wrapperWithdrawFundsEvent.js +19 -0
- package/build/client/orderbook/types/wrapperWithdrawFundsEvent.js.map +1 -0
- package/build/client/orderbook/types/yieldTokenTracker.d.ts +15 -0
- package/build/client/orderbook/types/yieldTokenTracker.js +10 -0
- package/build/client/orderbook/types/yieldTokenTracker.js.map +1 -0
- package/build/client/vaults/accounts/actionProposal.d.ts +30 -0
- package/build/client/vaults/accounts/actionProposal.js +84 -0
- package/build/client/vaults/accounts/actionProposal.js.map +1 -0
- package/build/client/vaults/accounts/exponentStrategyVault.d.ts +39 -0
- package/build/client/vaults/accounts/exponentStrategyVault.js +113 -0
- package/build/client/vaults/accounts/exponentStrategyVault.js.map +1 -0
- package/build/client/vaults/accounts/programConfig.d.ts +19 -0
- package/build/client/vaults/accounts/programConfig.js +76 -0
- package/build/client/vaults/accounts/programConfig.js.map +1 -0
- package/build/client/vaults/accounts/voteAccount.d.ts +23 -0
- package/build/client/vaults/accounts/voteAccount.js +80 -0
- package/build/client/vaults/accounts/voteAccount.js.map +1 -0
- package/build/client/vaults/accounts/withdrawalAccount.d.ts +23 -0
- package/build/client/vaults/accounts/withdrawalAccount.js +78 -0
- package/build/client/vaults/accounts/withdrawalAccount.js.map +1 -0
- package/build/client/vaults/eventRegistry.d.ts +27 -0
- package/build/client/vaults/eventRegistry.js +27 -0
- package/build/client/vaults/eventRegistry.js.map +1 -0
- package/build/client/vaults/index.d.ts +108 -0
- package/build/client/vaults/index.js +127 -0
- package/build/client/vaults/index.js.map +1 -0
- package/build/client/vaults/instructions/activateProposal.d.ts +12 -0
- package/build/client/vaults/instructions/activateProposal.js +25 -0
- package/build/client/vaults/instructions/activateProposal.js.map +1 -0
- package/build/client/vaults/instructions/addPolicy.d.ts +16 -0
- package/build/client/vaults/instructions/addPolicy.js +33 -0
- package/build/client/vaults/instructions/addPolicy.js.map +1 -0
- package/build/client/vaults/instructions/appendProposalActions.d.ts +13 -0
- package/build/client/vaults/instructions/appendProposalActions.js +26 -0
- package/build/client/vaults/instructions/appendProposalActions.js.map +1 -0
- package/build/client/vaults/instructions/cancelProposal.d.ts +7 -0
- package/build/client/vaults/instructions/cancelProposal.js +17 -0
- package/build/client/vaults/instructions/cancelProposal.js.map +1 -0
- package/build/client/vaults/instructions/cancelWithdrawal.d.ts +10 -0
- package/build/client/vaults/instructions/cancelWithdrawal.js +20 -0
- package/build/client/vaults/instructions/cancelWithdrawal.js.map +1 -0
- package/build/client/vaults/instructions/collectManagementFee.d.ts +9 -0
- package/build/client/vaults/instructions/collectManagementFee.js +19 -0
- package/build/client/vaults/instructions/collectManagementFee.js.map +1 -0
- package/build/client/vaults/instructions/depositLiquidity.d.ts +20 -0
- package/build/client/vaults/instructions/depositLiquidity.js +33 -0
- package/build/client/vaults/instructions/depositLiquidity.js.map +1 -0
- package/build/client/vaults/instructions/executeProposal.d.ts +11 -0
- package/build/client/vaults/instructions/executeProposal.js +21 -0
- package/build/client/vaults/instructions/executeProposal.js.map +1 -0
- package/build/client/vaults/instructions/executeWithdrawal.d.ts +18 -0
- package/build/client/vaults/instructions/executeWithdrawal.js +31 -0
- package/build/client/vaults/instructions/executeWithdrawal.js.map +1 -0
- package/build/client/vaults/instructions/executeWithdrawalFromReserves.d.ts +22 -0
- package/build/client/vaults/instructions/executeWithdrawalFromReserves.js +35 -0
- package/build/client/vaults/instructions/executeWithdrawalFromReserves.js.map +1 -0
- package/build/client/vaults/instructions/fillWithdrawal.d.ts +17 -0
- package/build/client/vaults/instructions/fillWithdrawal.js +34 -0
- package/build/client/vaults/instructions/fillWithdrawal.js.map +1 -0
- package/build/client/vaults/instructions/finalizeProposal.d.ts +7 -0
- package/build/client/vaults/instructions/finalizeProposal.js +17 -0
- package/build/client/vaults/instructions/finalizeProposal.js.map +1 -0
- package/build/client/vaults/instructions/initProposal.d.ts +12 -0
- package/build/client/vaults/instructions/initProposal.js +25 -0
- package/build/client/vaults/instructions/initProposal.js.map +1 -0
- package/build/client/vaults/instructions/initializePrices.d.ts +7 -0
- package/build/client/vaults/instructions/initializePrices.js +17 -0
- package/build/client/vaults/instructions/initializePrices.js.map +1 -0
- package/build/client/vaults/instructions/initializeVault.d.ts +44 -0
- package/build/client/vaults/instructions/initializeVault.js +80 -0
- package/build/client/vaults/instructions/initializeVault.js.map +1 -0
- package/build/client/vaults/instructions/makeSentienelManager.d.ts +7 -0
- package/build/client/vaults/instructions/makeSentienelManager.js +17 -0
- package/build/client/vaults/instructions/makeSentienelManager.js.map +1 -0
- package/build/client/vaults/instructions/managePrices.d.ts +11 -0
- package/build/client/vaults/instructions/managePrices.js +24 -0
- package/build/client/vaults/instructions/managePrices.js.map +1 -0
- package/build/client/vaults/instructions/manageVaultSettings.d.ts +12 -0
- package/build/client/vaults/instructions/manageVaultSettings.js +25 -0
- package/build/client/vaults/instructions/manageVaultSettings.js.map +1 -0
- package/build/client/vaults/instructions/managerUpdatePosition.d.ts +12 -0
- package/build/client/vaults/instructions/managerUpdatePosition.js +25 -0
- package/build/client/vaults/instructions/managerUpdatePosition.js.map +1 -0
- package/build/client/vaults/instructions/proposeAction.d.ts +16 -0
- package/build/client/vaults/instructions/proposeAction.js +29 -0
- package/build/client/vaults/instructions/proposeAction.js.map +1 -0
- package/build/client/vaults/instructions/queueWithdrawal.d.ts +14 -0
- package/build/client/vaults/instructions/queueWithdrawal.js +27 -0
- package/build/client/vaults/instructions/queueWithdrawal.js.map +1 -0
- package/build/client/vaults/instructions/removePolicy.d.ts +13 -0
- package/build/client/vaults/instructions/removePolicy.js +27 -0
- package/build/client/vaults/instructions/removePolicy.js.map +1 -0
- package/build/client/vaults/instructions/sentinelSetVaultFlags.d.ts +10 -0
- package/build/client/vaults/instructions/sentinelSetVaultFlags.js +23 -0
- package/build/client/vaults/instructions/sentinelSetVaultFlags.js.map +1 -0
- package/build/client/vaults/instructions/stakeVote.d.ts +18 -0
- package/build/client/vaults/instructions/stakeVote.js +31 -0
- package/build/client/vaults/instructions/stakeVote.js.map +1 -0
- package/build/client/vaults/instructions/unstakeVote.d.ts +14 -0
- package/build/client/vaults/instructions/unstakeVote.js +24 -0
- package/build/client/vaults/instructions/unstakeVote.js.map +1 -0
- package/build/client/vaults/instructions/updatePolicy.d.ts +17 -0
- package/build/client/vaults/instructions/updatePolicy.js +34 -0
- package/build/client/vaults/instructions/updatePolicy.js.map +1 -0
- package/build/client/vaults/instructions/updatePolicyManager.d.ts +13 -0
- package/build/client/vaults/instructions/updatePolicyManager.js +27 -0
- package/build/client/vaults/instructions/updatePolicyManager.js.map +1 -0
- package/build/client/vaults/instructions/updatePrice.d.ts +9 -0
- package/build/client/vaults/instructions/updatePrice.js +22 -0
- package/build/client/vaults/instructions/updatePrice.js.map +1 -0
- package/build/client/vaults/instructions/validateInteractionHook.d.ts +16 -0
- package/build/client/vaults/instructions/validateInteractionHook.js +33 -0
- package/build/client/vaults/instructions/validateInteractionHook.js.map +1 -0
- package/build/client/vaults/instructions/wrapperAddPolicy.d.ts +16 -0
- package/build/client/vaults/instructions/wrapperAddPolicy.js +33 -0
- package/build/client/vaults/instructions/wrapperAddPolicy.js.map +1 -0
- package/build/client/vaults/instructions/wrapperExecuteWithdrawal.d.ts +27 -0
- package/build/client/vaults/instructions/wrapperExecuteWithdrawal.js +40 -0
- package/build/client/vaults/instructions/wrapperExecuteWithdrawal.js.map +1 -0
- package/build/client/vaults/instructions/wrapperManageVaultSettings.d.ts +12 -0
- package/build/client/vaults/instructions/wrapperManageVaultSettings.js +25 -0
- package/build/client/vaults/instructions/wrapperManageVaultSettings.js.map +1 -0
- package/build/client/vaults/instructions/wrapperManagerUpdatePosition.d.ts +12 -0
- package/build/client/vaults/instructions/wrapperManagerUpdatePosition.js +25 -0
- package/build/client/vaults/instructions/wrapperManagerUpdatePosition.js.map +1 -0
- package/build/client/vaults/instructions/wrapperRemovePolicy.d.ts +13 -0
- package/build/client/vaults/instructions/wrapperRemovePolicy.js +27 -0
- package/build/client/vaults/instructions/wrapperRemovePolicy.js.map +1 -0
- package/build/client/vaults/instructions/wrapperUpdatePolicy.d.ts +17 -0
- package/build/client/vaults/instructions/wrapperUpdatePolicy.js +34 -0
- package/build/client/vaults/instructions/wrapperUpdatePolicy.js.map +1 -0
- package/build/client/vaults/types/accountConstraint.d.ts +20 -0
- package/build/client/vaults/types/accountConstraint.js +16 -0
- package/build/client/vaults/types/accountConstraint.js.map +1 -0
- package/build/client/vaults/types/accountConstraintType.d.ts +18 -0
- package/build/client/vaults/types/accountConstraintType.js +38 -0
- package/build/client/vaults/types/accountConstraintType.js.map +1 -0
- package/build/client/vaults/types/allowedSettingsChange.d.ts +79 -0
- package/build/client/vaults/types/allowedSettingsChange.js +45 -0
- package/build/client/vaults/types/allowedSettingsChange.js.map +1 -0
- package/build/client/vaults/types/cancelProposalEvent.d.ts +27 -0
- package/build/client/vaults/types/cancelProposalEvent.js +23 -0
- package/build/client/vaults/types/cancelProposalEvent.js.map +1 -0
- package/build/client/vaults/types/clmmPositionEntry.d.ts +88 -0
- package/build/client/vaults/types/clmmPositionEntry.js +20 -0
- package/build/client/vaults/types/clmmPositionEntry.js.map +1 -0
- package/build/client/vaults/types/dataConstraint.d.ts +116 -0
- package/build/client/vaults/types/dataConstraint.js +13 -0
- package/build/client/vaults/types/dataConstraint.js.map +1 -0
- package/build/client/vaults/types/dataOperator.d.ts +9 -0
- package/build/client/vaults/types/dataOperator.js +16 -0
- package/build/client/vaults/types/dataOperator.js.map +1 -0
- package/build/client/vaults/types/dataValue.d.ts +104 -0
- package/build/client/vaults/types/dataValue.js +33 -0
- package/build/client/vaults/types/dataValue.js.map +1 -0
- package/build/client/vaults/types/depositLiquidityEvent.d.ts +55 -0
- package/build/client/vaults/types/depositLiquidityEvent.js +42 -0
- package/build/client/vaults/types/depositLiquidityEvent.js.map +1 -0
- package/build/client/vaults/types/executeProposalEvent.d.ts +27 -0
- package/build/client/vaults/types/executeProposalEvent.js +23 -0
- package/build/client/vaults/types/executeProposalEvent.js.map +1 -0
- package/build/client/vaults/types/executeWithdrawalEvent.d.ts +14 -0
- package/build/client/vaults/types/executeWithdrawalEvent.js +10 -0
- package/build/client/vaults/types/executeWithdrawalEvent.js.map +1 -0
- package/build/client/vaults/types/fillParam.d.ts +14 -0
- package/build/client/vaults/types/fillParam.js +10 -0
- package/build/client/vaults/types/fillParam.js.map +1 -0
- package/build/client/vaults/types/finalizeProposalEvent.d.ts +48 -0
- package/build/client/vaults/types/finalizeProposalEvent.js +26 -0
- package/build/client/vaults/types/finalizeProposalEvent.js.map +1 -0
- package/build/client/vaults/types/hook.d.ts +44 -0
- package/build/client/vaults/types/hook.js +18 -0
- package/build/client/vaults/types/hook.js.map +1 -0
- package/build/client/vaults/types/hookCompiledInstruction.d.ts +18 -0
- package/build/client/vaults/types/hookCompiledInstruction.js +11 -0
- package/build/client/vaults/types/hookCompiledInstruction.js.map +1 -0
- package/build/client/vaults/types/index.d.ts +67 -0
- package/build/client/vaults/types/index.js +85 -0
- package/build/client/vaults/types/index.js.map +1 -0
- package/build/client/vaults/types/instructionConstraint.d.ts +173 -0
- package/build/client/vaults/types/instructionConstraint.js +17 -0
- package/build/client/vaults/types/instructionConstraint.js.map +1 -0
- package/build/client/vaults/types/internalFundTransferPolicyCreationPayload.d.ts +19 -0
- package/build/client/vaults/types/internalFundTransferPolicyCreationPayload.js +18 -0
- package/build/client/vaults/types/internalFundTransferPolicyCreationPayload.js.map +1 -0
- package/build/client/vaults/types/kaminoFarmEntry.d.ts +15 -0
- package/build/client/vaults/types/kaminoFarmEntry.js +17 -0
- package/build/client/vaults/types/kaminoFarmEntry.js.map +1 -0
- package/build/client/vaults/types/kaminoObligationEntry.d.ts +134 -0
- package/build/client/vaults/types/kaminoObligationEntry.js +24 -0
- package/build/client/vaults/types/kaminoObligationEntry.js.map +1 -0
- package/build/client/vaults/types/limitedQuantityConstraints.d.ts +10 -0
- package/build/client/vaults/types/limitedQuantityConstraints.js +9 -0
- package/build/client/vaults/types/limitedQuantityConstraints.js.map +1 -0
- package/build/client/vaults/types/limitedSpendingLimit.d.ts +105 -0
- package/build/client/vaults/types/limitedSpendingLimit.js +17 -0
- package/build/client/vaults/types/limitedSpendingLimit.js.map +1 -0
- package/build/client/vaults/types/limitedTimeConstraints.d.ts +67 -0
- package/build/client/vaults/types/limitedTimeConstraints.js +12 -0
- package/build/client/vaults/types/limitedTimeConstraints.js.map +1 -0
- package/build/client/vaults/types/loopscaleLoanEntry.d.ts +11 -0
- package/build/client/vaults/types/loopscaleLoanEntry.js +13 -0
- package/build/client/vaults/types/loopscaleLoanEntry.js.map +1 -0
- package/build/client/vaults/types/loopscaleStrategyEntry.d.ts +11 -0
- package/build/client/vaults/types/loopscaleStrategyEntry.js +13 -0
- package/build/client/vaults/types/loopscaleStrategyEntry.js.map +1 -0
- package/build/client/vaults/types/number.d.ts +2 -0
- package/build/client/vaults/types/number.js +9 -0
- package/build/client/vaults/types/number.js.map +1 -0
- package/build/client/vaults/types/obligationType.d.ts +13 -0
- package/build/client/vaults/types/obligationType.js +24 -0
- package/build/client/vaults/types/obligationType.js.map +1 -0
- package/build/client/vaults/types/orderbookEntry.d.ts +64 -0
- package/build/client/vaults/types/orderbookEntry.js +25 -0
- package/build/client/vaults/types/orderbookEntry.js.map +1 -0
- package/build/client/vaults/types/periodV2.d.ts +60 -0
- package/build/client/vaults/types/periodV2.js +24 -0
- package/build/client/vaults/types/periodV2.js.map +1 -0
- package/build/client/vaults/types/permissions.d.ts +10 -0
- package/build/client/vaults/types/permissions.js +7 -0
- package/build/client/vaults/types/permissions.js.map +1 -0
- package/build/client/vaults/types/policyAction.d.ts +61 -0
- package/build/client/vaults/types/policyAction.js +29 -0
- package/build/client/vaults/types/policyAction.js.map +1 -0
- package/build/client/vaults/types/policyConfig.d.ts +10 -0
- package/build/client/vaults/types/policyConfig.js +15 -0
- package/build/client/vaults/types/policyConfig.js.map +1 -0
- package/build/client/vaults/types/policyCreationPayload.d.ts +287 -0
- package/build/client/vaults/types/policyCreationPayload.js +50 -0
- package/build/client/vaults/types/policyCreationPayload.js.map +1 -0
- package/build/client/vaults/types/policyExpirationArgs.d.ts +33 -0
- package/build/client/vaults/types/policyExpirationArgs.js +21 -0
- package/build/client/vaults/types/policyExpirationArgs.js.map +1 -0
- package/build/client/vaults/types/positionUpdate.d.ts +54 -0
- package/build/client/vaults/types/positionUpdate.js +112 -0
- package/build/client/vaults/types/positionUpdate.js.map +1 -0
- package/build/client/vaults/types/priceId.d.ts +40 -0
- package/build/client/vaults/types/priceId.js +21 -0
- package/build/client/vaults/types/priceId.js.map +1 -0
- package/build/client/vaults/types/priceType.d.ts +19 -0
- package/build/client/vaults/types/priceType.js +26 -0
- package/build/client/vaults/types/priceType.js.map +1 -0
- package/build/client/vaults/types/programInteractionPolicyCreationPayload.d.ts +11 -0
- package/build/client/vaults/types/programInteractionPolicyCreationPayload.js +16 -0
- package/build/client/vaults/types/programInteractionPolicyCreationPayload.js.map +1 -0
- package/build/client/vaults/types/proposalAction.d.ts +226 -0
- package/build/client/vaults/types/proposalAction.js +37 -0
- package/build/client/vaults/types/proposalAction.js.map +1 -0
- package/build/client/vaults/types/proposalActionKind.d.ts +7 -0
- package/build/client/vaults/types/proposalActionKind.js +14 -0
- package/build/client/vaults/types/proposalActionKind.js.map +1 -0
- package/build/client/vaults/types/proposalStatus.d.ts +9 -0
- package/build/client/vaults/types/proposalStatus.js +16 -0
- package/build/client/vaults/types/proposalStatus.js.map +1 -0
- package/build/client/vaults/types/proposalVoteConfig.d.ts +46 -0
- package/build/client/vaults/types/proposalVoteConfig.js +18 -0
- package/build/client/vaults/types/proposalVoteConfig.js.map +1 -0
- package/build/client/vaults/types/proposeActionEvent.d.ts +48 -0
- package/build/client/vaults/types/proposeActionEvent.js +29 -0
- package/build/client/vaults/types/proposeActionEvent.js.map +1 -0
- package/build/client/vaults/types/quantityConstraints.d.ts +18 -0
- package/build/client/vaults/types/quantityConstraints.js +11 -0
- package/build/client/vaults/types/quantityConstraints.js.map +1 -0
- package/build/client/vaults/types/reserveFarmMapping.d.ts +19 -0
- package/build/client/vaults/types/reserveFarmMapping.js +18 -0
- package/build/client/vaults/types/reserveFarmMapping.js.map +1 -0
- package/build/client/vaults/types/reservePriceMapping.d.ts +48 -0
- package/build/client/vaults/types/reservePriceMapping.js +15 -0
- package/build/client/vaults/types/reservePriceMapping.js.map +1 -0
- package/build/client/vaults/types/settingsChangePolicyCreationPayload.d.ts +81 -0
- package/build/client/vaults/types/settingsChangePolicyCreationPayload.js +10 -0
- package/build/client/vaults/types/settingsChangePolicyCreationPayload.js.map +1 -0
- package/build/client/vaults/types/spendingLimitPolicyCreationPayload.d.ts +142 -0
- package/build/client/vaults/types/spendingLimitPolicyCreationPayload.js +24 -0
- package/build/client/vaults/types/spendingLimitPolicyCreationPayload.js.map +1 -0
- package/build/client/vaults/types/stakeVoteEvent.d.ts +40 -0
- package/build/client/vaults/types/stakeVoteEvent.js +27 -0
- package/build/client/vaults/types/stakeVoteEvent.js.map +1 -0
- package/build/client/vaults/types/strategyPosition.d.ts +48 -0
- package/build/client/vaults/types/strategyPosition.js +59 -0
- package/build/client/vaults/types/strategyPosition.js.map +1 -0
- package/build/client/vaults/types/timeConstraints.d.ts +71 -0
- package/build/client/vaults/types/timeConstraints.js +13 -0
- package/build/client/vaults/types/timeConstraints.js.map +1 -0
- package/build/client/vaults/types/tokenAccountBalance.d.ts +52 -0
- package/build/client/vaults/types/tokenAccountBalance.js +19 -0
- package/build/client/vaults/types/tokenAccountBalance.js.map +1 -0
- package/build/client/vaults/types/tokenAccountEntry.d.ts +72 -0
- package/build/client/vaults/types/tokenAccountEntry.js +15 -0
- package/build/client/vaults/types/tokenAccountEntry.js.map +1 -0
- package/build/client/vaults/types/tokenEntry.d.ts +60 -0
- package/build/client/vaults/types/tokenEntry.js +24 -0
- package/build/client/vaults/types/tokenEntry.js.map +1 -0
- package/build/client/vaults/types/unstakeVoteEvent.d.ts +36 -0
- package/build/client/vaults/types/unstakeVoteEvent.js +26 -0
- package/build/client/vaults/types/unstakeVoteEvent.js.map +1 -0
- package/build/client/vaults/types/updatePriceAction.d.ts +174 -0
- package/build/client/vaults/types/updatePriceAction.js +104 -0
- package/build/client/vaults/types/updatePriceAction.js.map +1 -0
- package/build/client/vaults/types/updatePriceInput.d.ts +14 -0
- package/build/client/vaults/types/updatePriceInput.js +10 -0
- package/build/client/vaults/types/updatePriceInput.js.map +1 -0
- package/build/client/vaults/types/usageState.d.ts +14 -0
- package/build/client/vaults/types/usageState.js +10 -0
- package/build/client/vaults/types/usageState.js.map +1 -0
- package/build/client/vaults/types/vaultConfig.d.ts +87 -0
- package/build/client/vaults/types/vaultConfig.js +19 -0
- package/build/client/vaults/types/vaultConfig.js.map +1 -0
- package/build/client/vaults/types/vaultFinancials.d.ts +58 -0
- package/build/client/vaults/types/vaultFinancials.js +21 -0
- package/build/client/vaults/types/vaultFinancials.js.map +1 -0
- package/build/client/vaults/types/vaultFlagAction.d.ts +56 -0
- package/build/client/vaults/types/vaultFlagAction.js +22 -0
- package/build/client/vaults/types/vaultFlagAction.js.map +1 -0
- package/build/client/vaults/types/vaultFlagsUpdatedEvent.d.ts +23 -0
- package/build/client/vaults/types/vaultFlagsUpdatedEvent.js +19 -0
- package/build/client/vaults/types/vaultFlagsUpdatedEvent.js.map +1 -0
- package/build/client/vaults/types/vaultRoleKind.d.ts +7 -0
- package/build/client/vaults/types/vaultRoleKind.js +14 -0
- package/build/client/vaults/types/vaultRoleKind.js.map +1 -0
- package/build/client/vaults/types/vaultRoles.d.ts +23 -0
- package/build/client/vaults/types/vaultRoles.js +25 -0
- package/build/client/vaults/types/vaultRoles.js.map +1 -0
- package/build/client/vaults/types/vaultSettingsAction.d.ts +109 -0
- package/build/client/vaults/types/vaultSettingsAction.js +161 -0
- package/build/client/vaults/types/vaultSettingsAction.js.map +1 -0
- package/build/client/vaults/types/voteChoice.d.ts +5 -0
- package/build/client/vaults/types/voteChoice.js +12 -0
- package/build/client/vaults/types/voteChoice.js.map +1 -0
- package/build/client/vaults/types/withdrawalPeriodSettings.d.ts +48 -0
- package/build/client/vaults/types/withdrawalPeriodSettings.js +28 -0
- package/build/client/vaults/types/withdrawalPeriodSettings.js.map +1 -0
- package/build/client/vaults/types/withdrawalTokenFill.d.ts +19 -0
- package/build/client/vaults/types/withdrawalTokenFill.js +18 -0
- package/build/client/vaults/types/withdrawalTokenFill.js.map +1 -0
- package/build/client/vaults/types/yieldPositionEntry.d.ts +52 -0
- package/build/client/vaults/types/yieldPositionEntry.js +19 -0
- package/build/client/vaults/types/yieldPositionEntry.js.map +1 -0
- package/build/clmm/codamaEvents.d.ts +23 -0
- package/build/clmm/codamaEvents.js +24 -0
- package/build/clmm/codamaEvents.js.map +1 -0
- package/build/clmm/index.d.ts +1 -1
- package/build/clmm/index.js +1 -1
- package/build/clmm/index.js.map +1 -1
- package/build/codamaEvents.d.ts +18 -0
- package/build/codamaEvents.js +21 -0
- package/build/codamaEvents.js.map +1 -0
- package/build/environment.d.ts +8 -7
- package/build/environment.js +8 -7
- package/build/environment.js.map +1 -1
- package/build/exponentVaults/aumCalculator.d.ts +203 -0
- package/build/exponentVaults/aumCalculator.js +999 -0
- package/build/exponentVaults/aumCalculator.js.map +1 -0
- package/build/exponentVaults/events.d.ts +8 -0
- package/build/exponentVaults/events.js +12 -0
- package/build/exponentVaults/events.js.map +1 -0
- package/build/exponentVaults/fetcher.d.ts +52 -0
- package/build/exponentVaults/fetcher.js +199 -0
- package/build/exponentVaults/fetcher.js.map +1 -0
- package/build/exponentVaults/index.d.ts +31 -0
- package/build/exponentVaults/index.js +193 -0
- package/build/exponentVaults/index.js.map +1 -0
- package/build/exponentVaults/kamino-farms.d.ts +144 -0
- package/build/exponentVaults/kamino-farms.js +396 -0
- package/build/exponentVaults/kamino-farms.js.map +1 -0
- package/build/exponentVaults/kamino-markets.d.ts +887 -0
- package/build/exponentVaults/kamino-markets.js +345 -0
- package/build/exponentVaults/kamino-markets.js.map +1 -0
- package/build/exponentVaults/loopscale/client.d.ts +240 -0
- package/build/exponentVaults/loopscale/client.js +590 -0
- package/build/exponentVaults/loopscale/client.js.map +1 -0
- package/build/exponentVaults/loopscale/client.test.d.ts +1 -0
- package/build/exponentVaults/loopscale/client.test.js +183 -0
- package/build/exponentVaults/loopscale/client.test.js.map +1 -0
- package/build/exponentVaults/loopscale/helpers.d.ts +29 -0
- package/build/exponentVaults/loopscale/helpers.js +119 -0
- package/build/exponentVaults/loopscale/helpers.js.map +1 -0
- package/build/exponentVaults/loopscale/index.d.ts +3 -0
- package/build/exponentVaults/loopscale/index.js +12 -0
- package/build/exponentVaults/loopscale/index.js.map +1 -0
- package/build/exponentVaults/loopscale/prepared-transactions.d.ts +13 -0
- package/build/exponentVaults/loopscale/prepared-transactions.js +271 -0
- package/build/exponentVaults/loopscale/prepared-transactions.js.map +1 -0
- package/build/exponentVaults/loopscale/prepared-transactions.test.d.ts +1 -0
- package/build/exponentVaults/loopscale/prepared-transactions.test.js +400 -0
- package/build/exponentVaults/loopscale/prepared-transactions.test.js.map +1 -0
- package/build/exponentVaults/loopscale/prepared-types.d.ts +62 -0
- package/build/exponentVaults/loopscale/prepared-types.js +3 -0
- package/build/exponentVaults/loopscale/prepared-types.js.map +1 -0
- package/build/exponentVaults/loopscale/response-plan.d.ts +69 -0
- package/build/exponentVaults/loopscale/response-plan.js +141 -0
- package/build/exponentVaults/loopscale/response-plan.js.map +1 -0
- package/build/exponentVaults/loopscale/response-plan.test.d.ts +1 -0
- package/build/exponentVaults/loopscale/response-plan.test.js +139 -0
- package/build/exponentVaults/loopscale/response-plan.test.js.map +1 -0
- package/build/exponentVaults/loopscale/send-plan.d.ts +75 -0
- package/build/exponentVaults/loopscale/send-plan.js +235 -0
- package/build/exponentVaults/loopscale/send-plan.js.map +1 -0
- package/build/exponentVaults/loopscale/types.d.ts +443 -0
- package/build/exponentVaults/loopscale/types.js +3 -0
- package/build/exponentVaults/loopscale/types.js.map +1 -0
- package/build/exponentVaults/loopscale-client.d.ts +130 -0
- package/build/exponentVaults/loopscale-client.js +489 -0
- package/build/exponentVaults/loopscale-client.js.map +1 -0
- package/build/exponentVaults/loopscale-client.test.d.ts +1 -0
- package/build/exponentVaults/loopscale-client.test.js +162 -0
- package/build/exponentVaults/loopscale-client.test.js.map +1 -0
- package/build/exponentVaults/loopscale-client.types.d.ts +425 -0
- package/build/exponentVaults/loopscale-client.types.js +3 -0
- package/build/exponentVaults/loopscale-client.types.js.map +1 -0
- package/build/exponentVaults/loopscale-execution.d.ts +125 -0
- package/build/exponentVaults/loopscale-execution.js +341 -0
- package/build/exponentVaults/loopscale-execution.js.map +1 -0
- package/build/exponentVaults/loopscale-execution.test.d.ts +1 -0
- package/build/exponentVaults/loopscale-execution.test.js +139 -0
- package/build/exponentVaults/loopscale-execution.test.js.map +1 -0
- package/build/exponentVaults/loopscale-vault.d.ts +115 -0
- package/build/exponentVaults/loopscale-vault.js +275 -0
- package/build/exponentVaults/loopscale-vault.js.map +1 -0
- package/build/exponentVaults/loopscale-vault.test.d.ts +1 -0
- package/build/exponentVaults/loopscale-vault.test.js +102 -0
- package/build/exponentVaults/loopscale-vault.test.js.map +1 -0
- package/build/exponentVaults/policyBuilders.d.ts +756 -0
- package/build/exponentVaults/policyBuilders.js +1248 -0
- package/build/exponentVaults/policyBuilders.js.map +1 -0
- package/build/exponentVaults/policyMatcher.d.ts +82 -0
- package/build/exponentVaults/policyMatcher.js +730 -0
- package/build/exponentVaults/policyMatcher.js.map +1 -0
- package/build/exponentVaults/pricePathResolver.d.ts +45 -0
- package/build/exponentVaults/pricePathResolver.js +198 -0
- package/build/exponentVaults/pricePathResolver.js.map +1 -0
- package/build/exponentVaults/pricePathResolver.test.d.ts +1 -0
- package/build/exponentVaults/pricePathResolver.test.js +369 -0
- package/build/exponentVaults/pricePathResolver.test.js.map +1 -0
- package/build/exponentVaults/scope-refresh.d.ts +10 -0
- package/build/exponentVaults/scope-refresh.js +140 -0
- package/build/exponentVaults/scope-refresh.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/constants.d.ts +2 -0
- package/build/exponentVaults/squadsVaultTxnResolver/constants.js +61 -0
- package/build/exponentVaults/squadsVaultTxnResolver/constants.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/helpers.d.ts +26 -0
- package/build/exponentVaults/squadsVaultTxnResolver/helpers.js +268 -0
- package/build/exponentVaults/squadsVaultTxnResolver/helpers.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/index.d.ts +5 -0
- package/build/exponentVaults/squadsVaultTxnResolver/index.js +15 -0
- package/build/exponentVaults/squadsVaultTxnResolver/index.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/exponent.d.ts +6 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/exponent.js +361 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/exponent.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/helpers.d.ts +2 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/helpers.js +28 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/helpers.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/index.d.ts +2 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/index.js +25 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/index.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/kamino.d.ts +2 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/kamino.js +67 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/kamino.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/loopscale.d.ts +2 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/loopscale.js +73 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/loopscale.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/titan.d.ts +2 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/titan.js +35 -0
- package/build/exponentVaults/squadsVaultTxnResolver/resolvers/titan.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/squadsVaultTxnResolver.d.ts +21 -0
- package/build/exponentVaults/squadsVaultTxnResolver/squadsVaultTxnResolver.js +64 -0
- package/build/exponentVaults/squadsVaultTxnResolver/squadsVaultTxnResolver.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/types.d.ts +111 -0
- package/build/exponentVaults/squadsVaultTxnResolver/types.js +92 -0
- package/build/exponentVaults/squadsVaultTxnResolver/types.js.map +1 -0
- package/build/exponentVaults/squadsVaultTxnResolver/utils.d.ts +3 -0
- package/build/exponentVaults/squadsVaultTxnResolver/utils.js +8 -0
- package/build/exponentVaults/squadsVaultTxnResolver/utils.js.map +1 -0
- package/build/exponentVaults/syncTransaction.d.ts +84 -0
- package/build/exponentVaults/syncTransaction.js +344 -0
- package/build/exponentVaults/syncTransaction.js.map +1 -0
- package/build/exponentVaults/titan-quote.d.ts +22 -0
- package/build/exponentVaults/titan-quote.js +301 -0
- package/build/exponentVaults/titan-quote.js.map +1 -0
- package/build/exponentVaults/vault-instruction-types.d.ts +363 -0
- package/build/exponentVaults/vault-instruction-types.js +128 -0
- package/build/exponentVaults/vault-instruction-types.js.map +1 -0
- package/build/exponentVaults/vault-interaction.d.ts +3318 -0
- package/build/exponentVaults/vault-interaction.js +3479 -0
- package/build/exponentVaults/vault-interaction.js.map +1 -0
- package/build/exponentVaults/vault.d.ts +662 -0
- package/build/exponentVaults/vault.js +1713 -0
- package/build/exponentVaults/vault.js.map +1 -0
- package/build/exponentVaults/vaultTransactionBuilder.d.ts +285 -0
- package/build/exponentVaults/vaultTransactionBuilder.js +563 -0
- package/build/exponentVaults/vaultTransactionBuilder.js.map +1 -0
- package/build/exponentVaults/vaultTransactionBuilder.test.d.ts +1 -0
- package/build/exponentVaults/vaultTransactionBuilder.test.js +214 -0
- package/build/exponentVaults/vaultTransactionBuilder.test.js.map +1 -0
- package/build/flavors.d.ts +3 -3
- package/build/flavors.js +115 -111
- package/build/flavors.js.map +1 -1
- package/build/index.d.ts +15 -8
- package/build/index.js +23 -7
- package/build/index.js.map +1 -1
- package/build/lpPosition.d.ts +13 -15
- package/build/lpPosition.js +2 -6
- package/build/lpPosition.js.map +1 -1
- package/build/market.d.ts +203 -230
- package/build/market.js +277 -371
- package/build/market.js.map +1 -1
- package/build/marketThree.d.ts +407 -269
- package/build/marketThree.js +621 -285
- package/build/marketThree.js.map +1 -1
- package/build/marketThree.test.js +12 -12
- package/build/marketThree.test.js.map +1 -1
- package/build/orderbook/codamaEvents.d.ts +19 -0
- package/build/orderbook/codamaEvents.js +22 -0
- package/build/orderbook/codamaEvents.js.map +1 -0
- package/build/orderbook/index.d.ts +6 -3
- package/build/orderbook/index.js +8 -4
- package/build/orderbook/index.js.map +1 -1
- package/build/orderbook/math.d.ts +4 -2
- package/build/orderbook/math.js +23 -11
- package/build/orderbook/math.js.map +1 -1
- package/build/orderbook/orderbook.d.ts +182 -104
- package/build/orderbook/orderbook.js +375 -208
- package/build/orderbook/orderbook.js.map +1 -1
- package/build/orderbook/types.d.ts +6 -20
- package/build/orderbook/types.js +25 -5
- package/build/orderbook/types.js.map +1 -1
- package/build/orderbook/utils.d.ts +1 -3
- package/build/orderbook/utils.js +4 -12
- package/build/orderbook/utils.js.map +1 -1
- package/build/router.d.ts +72 -12
- package/build/router.js +333 -3
- package/build/router.js.map +1 -1
- package/build/syPosition.d.ts +2 -2
- package/build/syPosition.js +7 -7
- package/build/syPosition.js.map +1 -1
- package/build/tokenUtil.d.ts +3 -3
- package/build/tokenUtil.js.map +1 -1
- package/build/utils/index.d.ts +4 -5
- package/build/utils/index.js +3 -24
- package/build/utils/index.js.map +1 -1
- package/build/utils/ix.d.ts +2 -2
- package/build/vault.d.ts +108 -221
- package/build/vault.js +141 -98
- package/build/vault.js.map +1 -1
- package/build/ytPosition.d.ts +28 -36
- package/build/ytPosition.js +71 -62
- package/build/ytPosition.js.map +1 -1
- package/package.json +58 -28
- package/src/CodamaEventDecoder.ts +151 -0
- package/src/addressLookupTableUtil.ts +48 -14
- package/src/client/clmm/accounts/lpPosition.ts +143 -0
- package/src/client/clmm/accounts/marketThree.ts +274 -0
- package/src/client/clmm/accounts/vault.ts +234 -0
- package/src/client/clmm/eventRegistry.ts +92 -0
- package/src/client/clmm/index.ts +82 -0
- package/src/client/clmm/instructions/addFarm.ts +57 -0
- package/src/client/clmm/instructions/addLiquidity.ts +78 -0
- package/src/client/clmm/instructions/addMarketEmission.ts +50 -0
- package/src/client/clmm/instructions/buyPt.ts +73 -0
- package/src/client/clmm/instructions/buyYt.ts +80 -0
- package/src/client/clmm/instructions/claimFarmEmission.ts +56 -0
- package/src/client/clmm/instructions/closeMarket.ts +47 -0
- package/src/client/clmm/instructions/depositLiquidity.ts +71 -0
- package/src/client/clmm/instructions/initializeMarket.ts +127 -0
- package/src/client/clmm/instructions/marketAccrueEmission.ts +39 -0
- package/src/client/clmm/instructions/marketCollectEmission.ts +57 -0
- package/src/client/clmm/instructions/modifyFarm.ts +55 -0
- package/src/client/clmm/instructions/modifyMarketSetting.ts +45 -0
- package/src/client/clmm/instructions/sellPt.ts +73 -0
- package/src/client/clmm/instructions/sellYt.ts +80 -0
- package/src/client/clmm/instructions/tradePt.ts +73 -0
- package/src/client/clmm/instructions/tradePtExactOut.ts +75 -0
- package/src/client/clmm/instructions/withdrawLiquidity.ts +67 -0
- package/src/client/clmm/instructions/wrapperBuyYt.ts +85 -0
- package/src/client/clmm/instructions/wrapperProvideLiquidity.ts +100 -0
- package/src/client/clmm/instructions/wrapperProvideLiquidityBase.ts +98 -0
- package/src/client/clmm/instructions/wrapperProvideLiquidityClassic.ts +86 -0
- package/src/client/clmm/instructions/wrapperSellYt.ts +83 -0
- package/src/client/clmm/instructions/wrapperWithdrawLiquidity.ts +75 -0
- package/src/client/clmm/instructions/wrapperWithdrawLiquidityClassic.ts +69 -0
- package/src/client/clmm/types/addFarmEvent.ts +51 -0
- package/src/client/clmm/types/amount.ts +51 -0
- package/src/client/clmm/types/buyPtEvent.ts +36 -0
- package/src/client/clmm/types/buyYtEvent.ts +74 -0
- package/src/client/clmm/types/claimFarmEmissionsEvent.ts +94 -0
- package/src/client/clmm/types/claimLimits.ts +15 -0
- package/src/client/clmm/types/closeMarketEvent.ts +36 -0
- package/src/client/clmm/types/configurationOptions.ts +29 -0
- package/src/client/clmm/types/cpiAccounts.ts +21 -0
- package/src/client/clmm/types/cpiCoreAccounts.ts +15 -0
- package/src/client/clmm/types/cpiInterfaceContext.ts +13 -0
- package/src/client/clmm/types/crossingSplit.ts +40 -0
- package/src/client/clmm/types/depositLiquidityEvent.ts +93 -0
- package/src/client/clmm/types/depositLiquidityReturnData.ts +81 -0
- package/src/client/clmm/types/emissionInfo.ts +44 -0
- package/src/client/clmm/types/farmEmission.ts +31 -0
- package/src/client/clmm/types/index.ts +48 -0
- package/src/client/clmm/types/liquidityNetBalanceLimits.ts +22 -0
- package/src/client/clmm/types/lpFarm.ts +12 -0
- package/src/client/clmm/types/marketAccrueEmissionEvent.ts +69 -0
- package/src/client/clmm/types/marketAdminAction.ts +239 -0
- package/src/client/clmm/types/marketCollectEmissionEvent.ts +83 -0
- package/src/client/clmm/types/marketEmission.ts +28 -0
- package/src/client/clmm/types/marketEmissions.ts +10 -0
- package/src/client/clmm/types/marketFinancials.ts +17 -0
- package/src/client/clmm/types/marketThreeInitEvent.ts +92 -0
- package/src/client/clmm/types/mergeEvent.ts +118 -0
- package/src/client/clmm/types/modifiedTick.ts +13 -0
- package/src/client/clmm/types/modifiedTicks.ts +18 -0
- package/src/client/clmm/types/modifyFarmEvent.ts +56 -0
- package/src/client/clmm/types/number.ts +7 -0
- package/src/client/clmm/types/personalYieldTracker.ts +12 -0
- package/src/client/clmm/types/personalYieldTrackers.ts +13 -0
- package/src/client/clmm/types/principalShare.ts +22 -0
- package/src/client/clmm/types/principalShareTrackers.ts +10 -0
- package/src/client/clmm/types/sellPtEvent.ts +36 -0
- package/src/client/clmm/types/sellYtEvent.ts +69 -0
- package/src/client/clmm/types/stripEvent.ts +124 -0
- package/src/client/clmm/types/swapDirection.ts +8 -0
- package/src/client/clmm/types/tradePtEvent.ts +76 -0
- package/src/client/clmm/types/withdrawLiquidityEvent.ts +99 -0
- package/src/client/clmm/types/withdrawLiquidityReturnData.ts +27 -0
- package/src/client/clmm/types/wrapperBuyYtEvent.ts +36 -0
- package/src/client/clmm/types/wrapperProvideLiquidityBaseEvent.ts +60 -0
- package/src/client/clmm/types/wrapperProvideLiquidityClassicEvent.ts +58 -0
- package/src/client/clmm/types/wrapperProvideLiquidityEvent.ts +60 -0
- package/src/client/clmm/types/wrapperSellYtEvent.ts +36 -0
- package/src/client/clmm/types/wrapperWithdrawLiquidityClassicEvent.ts +62 -0
- package/src/client/clmm/types/wrapperWithdrawLiquidityEvent.ts +62 -0
- package/src/client/core/accounts/admin.ts +112 -0
- package/src/client/core/accounts/lpPosition.ts +122 -0
- package/src/client/core/accounts/marketTwo.ts +234 -0
- package/src/client/core/accounts/vault.ts +234 -0
- package/src/client/core/accounts/yieldTokenPosition.ts +126 -0
- package/src/client/core/eventRegistry.ts +134 -0
- package/src/client/core/index.ts +113 -0
- package/src/client/core/instructions/addEmission.ts +62 -0
- package/src/client/core/instructions/addFarm.ts +53 -0
- package/src/client/core/instructions/addLpTokensMetadata.ts +62 -0
- package/src/client/core/instructions/addMarketEmission.ts +52 -0
- package/src/client/core/instructions/buyYt.ts +79 -0
- package/src/client/core/instructions/claimFarmEmissions.ts +54 -0
- package/src/client/core/instructions/collectEmission.ts +66 -0
- package/src/client/core/instructions/collectInterest.ts +64 -0
- package/src/client/core/instructions/collectTreasuryEmission.ts +64 -0
- package/src/client/core/instructions/collectTreasuryInterest.ts +62 -0
- package/src/client/core/instructions/depositYt.ts +59 -0
- package/src/client/core/instructions/initLpPosition.ts +35 -0
- package/src/client/core/instructions/initMarketTwo.ts +103 -0
- package/src/client/core/instructions/initializeVault.ts +107 -0
- package/src/client/core/instructions/initializeYieldPosition.ts +33 -0
- package/src/client/core/instructions/marketCollectEmission.ts +55 -0
- package/src/client/core/instructions/marketDepositLp.ts +59 -0
- package/src/client/core/instructions/marketTwoDepositLiquidity.ts +65 -0
- package/src/client/core/instructions/marketTwoWithdrawLiquidity.ts +65 -0
- package/src/client/core/instructions/marketWithdrawLp.ts +59 -0
- package/src/client/core/instructions/merge.ts +61 -0
- package/src/client/core/instructions/modifyFarm.ts +51 -0
- package/src/client/core/instructions/modifyMarketSetting.ts +47 -0
- package/src/client/core/instructions/modifyVaultSetting.ts +44 -0
- package/src/client/core/instructions/reallocMarket.ts +45 -0
- package/src/client/core/instructions/sellYt.ts +79 -0
- package/src/client/core/instructions/stageYtYield.ts +39 -0
- package/src/client/core/instructions/strip.ts +61 -0
- package/src/client/core/instructions/tradePt.ts +59 -0
- package/src/client/core/instructions/withdrawYt.ts +61 -0
- package/src/client/core/instructions/wrapperBuyPt.ts +63 -0
- package/src/client/core/instructions/wrapperBuyYt.ts +93 -0
- package/src/client/core/instructions/wrapperCollectInterest.ts +63 -0
- package/src/client/core/instructions/wrapperMerge.ts +77 -0
- package/src/client/core/instructions/wrapperProvideLiquidity.ts +103 -0
- package/src/client/core/instructions/wrapperProvideLiquidityBase.ts +81 -0
- package/src/client/core/instructions/wrapperProvideLiquidityClassic.ts +77 -0
- package/src/client/core/instructions/wrapperSellPt.ts +63 -0
- package/src/client/core/instructions/wrapperSellYt.ts +87 -0
- package/src/client/core/instructions/wrapperStrip.ts +81 -0
- package/src/client/core/instructions/wrapperWithdrawLiquidity.ts +77 -0
- package/src/client/core/instructions/wrapperWithdrawLiquidityClassic.ts +73 -0
- package/src/client/core/types/adminAction.ts +255 -0
- package/src/client/core/types/amount.ts +51 -0
- package/src/client/core/types/buyPtEvent.ts +39 -0
- package/src/client/core/types/buyYtEvent.ts +95 -0
- package/src/client/core/types/claimFarmEmissionsEvent.ts +75 -0
- package/src/client/core/types/claimFarmEmissionsEventV2.ts +83 -0
- package/src/client/core/types/claimLimits.ts +15 -0
- package/src/client/core/types/collectEmissionEvent.ts +51 -0
- package/src/client/core/types/collectEmissionEventV2.ts +60 -0
- package/src/client/core/types/collectInterestEvent.ts +48 -0
- package/src/client/core/types/collectInterestEventV2.ts +57 -0
- package/src/client/core/types/collectTreasuryEmissionKind.ts +8 -0
- package/src/client/core/types/collectTreasuryInterestKind.ts +8 -0
- package/src/client/core/types/cpiAccounts.ts +21 -0
- package/src/client/core/types/cpiInterfaceContext.ts +13 -0
- package/src/client/core/types/depositLiquidityEvent.ts +101 -0
- package/src/client/core/types/depositLpEvent.ts +75 -0
- package/src/client/core/types/depositLpEventV2.ts +83 -0
- package/src/client/core/types/depositYtEvent.ts +82 -0
- package/src/client/core/types/depositYtEventV2.ts +91 -0
- package/src/client/core/types/emissionInfo.ts +44 -0
- package/src/client/core/types/farmEmission.ts +31 -0
- package/src/client/core/types/index.ts +60 -0
- package/src/client/core/types/initLpPositionEvent.ts +57 -0
- package/src/client/core/types/initializeYieldPositionEvent.ts +43 -0
- package/src/client/core/types/liquidityNetBalanceLimits.ts +22 -0
- package/src/client/core/types/lpFarm.ts +12 -0
- package/src/client/core/types/marketAdminAction.ts +212 -0
- package/src/client/core/types/marketCollectEmissionEvent.ts +67 -0
- package/src/client/core/types/marketCollectEmissionEventV2.ts +75 -0
- package/src/client/core/types/marketEmission.ts +28 -0
- package/src/client/core/types/marketEmissions.ts +10 -0
- package/src/client/core/types/marketFinancials.ts +19 -0
- package/src/client/core/types/mergeEvent.ts +118 -0
- package/src/client/core/types/number.ts +7 -0
- package/src/client/core/types/personalYieldTracker.ts +12 -0
- package/src/client/core/types/personalYieldTrackers.ts +13 -0
- package/src/client/core/types/principleDetails.ts +25 -0
- package/src/client/core/types/principles.ts +23 -0
- package/src/client/core/types/sellPtEvent.ts +39 -0
- package/src/client/core/types/sellYtEvent.ts +90 -0
- package/src/client/core/types/stageYieldEvent.ts +63 -0
- package/src/client/core/types/stageYieldEventV2.ts +69 -0
- package/src/client/core/types/stripEvent.ts +124 -0
- package/src/client/core/types/tradePtEvent.ts +80 -0
- package/src/client/core/types/withdrawLiquidityEvent.ts +97 -0
- package/src/client/core/types/withdrawLpEvent.ts +75 -0
- package/src/client/core/types/withdrawLpEventV2.ts +83 -0
- package/src/client/core/types/withdrawYtEvent.ts +82 -0
- package/src/client/core/types/withdrawYtEventV2.ts +91 -0
- package/src/client/core/types/wrapperBuyYtEvent.ts +39 -0
- package/src/client/core/types/wrapperCollectInterestEvent.ts +37 -0
- package/src/client/core/types/wrapperMergeEvent.ts +38 -0
- package/src/client/core/types/wrapperProvideLiquidityBaseEvent.ts +43 -0
- package/src/client/core/types/wrapperProvideLiquidityClassicEvent.ts +41 -0
- package/src/client/core/types/wrapperProvideLiquidityEvent.ts +41 -0
- package/src/client/core/types/wrapperSellYtEvent.ts +39 -0
- package/src/client/core/types/wrapperStripEvent.ts +38 -0
- package/src/client/core/types/wrapperWithdrawLiquidityClassicEvent.ts +41 -0
- package/src/client/core/types/wrapperWithdrawLiquidityEvent.ts +39 -0
- package/src/client/core/types/yieldTokenTracker.ts +12 -0
- package/src/client/orderbook/accounts/cpiAccountsOrderbook.ts +101 -0
- package/src/client/orderbook/accounts/vault.ts +234 -0
- package/src/client/orderbook/eventRegistry.ts +71 -0
- package/src/client/orderbook/index.ts +55 -0
- package/src/client/orderbook/instructions/collectAdminEmission.ts +48 -0
- package/src/client/orderbook/instructions/collectAdminFee.ts +59 -0
- package/src/client/orderbook/instructions/collectInterest.ts +66 -0
- package/src/client/orderbook/instructions/initializeOrderbook.ts +104 -0
- package/src/client/orderbook/instructions/marketOffer.ts +89 -0
- package/src/client/orderbook/instructions/postOffer.ts +96 -0
- package/src/client/orderbook/instructions/reallocOrderbookAccount.ts +45 -0
- package/src/client/orderbook/instructions/removeExpiredOffers.ts +37 -0
- package/src/client/orderbook/instructions/removeOffer.ts +73 -0
- package/src/client/orderbook/instructions/setConfigurationOptions.ts +43 -0
- package/src/client/orderbook/instructions/withdrawFunds.ts +78 -0
- package/src/client/orderbook/instructions/wrapperCollectAdminFee.ts +73 -0
- package/src/client/orderbook/instructions/wrapperCollectInterest.ts +65 -0
- package/src/client/orderbook/instructions/wrapperMarketOffer.ts +94 -0
- package/src/client/orderbook/instructions/wrapperPostOffer.ts +99 -0
- package/src/client/orderbook/instructions/wrapperRemoveOffer.ts +75 -0
- package/src/client/orderbook/instructions/wrapperWithdrawFunds.ts +80 -0
- package/src/client/orderbook/types/amount.ts +51 -0
- package/src/client/orderbook/types/claimLimits.ts +15 -0
- package/src/client/orderbook/types/collectAdminEmissionEvent.ts +39 -0
- package/src/client/orderbook/types/collectAdminFeeEvent.ts +17 -0
- package/src/client/orderbook/types/collectEmissionEventV2.ts +60 -0
- package/src/client/orderbook/types/collectInterestEventV2.ts +57 -0
- package/src/client/orderbook/types/collectUserInterestEvent.ts +36 -0
- package/src/client/orderbook/types/cpiAccounts.ts +21 -0
- package/src/client/orderbook/types/cpiInterfaceContext.ts +13 -0
- package/src/client/orderbook/types/emissionInfo.ts +44 -0
- package/src/client/orderbook/types/exponentCoreCpiAccounts.ts +21 -0
- package/src/client/orderbook/types/filledOffersEvent.ts +19 -0
- package/src/client/orderbook/types/index.ts +30 -0
- package/src/client/orderbook/types/marketOfferEvent.ts +72 -0
- package/src/client/orderbook/types/mergeEvent.ts +118 -0
- package/src/client/orderbook/types/number.ts +7 -0
- package/src/client/orderbook/types/offerOptions.ts +56 -0
- package/src/client/orderbook/types/offerType.ts +8 -0
- package/src/client/orderbook/types/orderbookInitEvent.ts +54 -0
- package/src/client/orderbook/types/postOfferEvent.ts +78 -0
- package/src/client/orderbook/types/removeOfferEvent.ts +67 -0
- package/src/client/orderbook/types/setConfigurationOptionsEnum.ts +116 -0
- package/src/client/orderbook/types/stripEvent.ts +124 -0
- package/src/client/orderbook/types/withdrawFundsEvent.ts +65 -0
- package/src/client/orderbook/types/wrapperCollectAdminFeeEvent.ts +13 -0
- package/src/client/orderbook/types/wrapperCollectInterestEvent.ts +25 -0
- package/src/client/orderbook/types/wrapperMarketOfferEvent.ts +27 -0
- package/src/client/orderbook/types/wrapperPostOfferEvent.ts +72 -0
- package/src/client/orderbook/types/wrapperRemoveOfferEvent.ts +25 -0
- package/src/client/orderbook/types/wrapperWithdrawFundsEvent.ts +38 -0
- package/src/client/orderbook/types/yieldTokenTracker.ts +12 -0
- package/src/client/vaults/accounts/actionProposal.ts +144 -0
- package/src/client/vaults/accounts/exponentStrategyVault.ts +211 -0
- package/src/client/vaults/accounts/programConfig.ts +123 -0
- package/src/client/vaults/accounts/voteAccount.ts +132 -0
- package/src/client/vaults/accounts/withdrawalAccount.ts +132 -0
- package/src/client/vaults/eventRegistry.ts +45 -0
- package/src/client/vaults/index.ts +113 -0
- package/src/client/vaults/instructions/activateProposal.ts +46 -0
- package/src/client/vaults/instructions/addPolicy.ts +57 -0
- package/src/client/vaults/instructions/appendProposalActions.ts +47 -0
- package/src/client/vaults/instructions/cancelProposal.ts +28 -0
- package/src/client/vaults/instructions/cancelWithdrawal.ts +34 -0
- package/src/client/vaults/instructions/collectManagementFee.ts +32 -0
- package/src/client/vaults/instructions/depositLiquidity.ts +62 -0
- package/src/client/vaults/instructions/executeProposal.ts +36 -0
- package/src/client/vaults/instructions/executeWithdrawal.ts +58 -0
- package/src/client/vaults/instructions/executeWithdrawalFromReserves.ts +66 -0
- package/src/client/vaults/instructions/fillWithdrawal.ts +59 -0
- package/src/client/vaults/instructions/finalizeProposal.ts +28 -0
- package/src/client/vaults/instructions/initProposal.ts +46 -0
- package/src/client/vaults/instructions/initializePrices.ts +28 -0
- package/src/client/vaults/instructions/initializeVault.ts +148 -0
- package/src/client/vaults/instructions/makeSentienelManager.ts +28 -0
- package/src/client/vaults/instructions/managePrices.ts +46 -0
- package/src/client/vaults/instructions/manageVaultSettings.ts +48 -0
- package/src/client/vaults/instructions/managerUpdatePosition.ts +45 -0
- package/src/client/vaults/instructions/queueWithdrawal.ts +50 -0
- package/src/client/vaults/instructions/removePolicy.ts +44 -0
- package/src/client/vaults/instructions/sentinelSetVaultFlags.ts +44 -0
- package/src/client/vaults/instructions/stakeVote.ts +57 -0
- package/src/client/vaults/instructions/unstakeVote.ts +42 -0
- package/src/client/vaults/instructions/updatePolicy.ts +59 -0
- package/src/client/vaults/instructions/updatePolicyManager.ts +44 -0
- package/src/client/vaults/instructions/updatePrice.ts +42 -0
- package/src/client/vaults/instructions/validateInteractionHook.ts +60 -0
- package/src/client/vaults/instructions/wrapperAddPolicy.ts +57 -0
- package/src/client/vaults/instructions/wrapperExecuteWithdrawal.ts +76 -0
- package/src/client/vaults/instructions/wrapperManageVaultSettings.ts +48 -0
- package/src/client/vaults/instructions/wrapperManagerUpdatePosition.ts +45 -0
- package/src/client/vaults/instructions/wrapperRemovePolicy.ts +44 -0
- package/src/client/vaults/instructions/wrapperUpdatePolicy.ts +59 -0
- package/src/client/vaults/types/accountConstraint.ts +35 -0
- package/src/client/vaults/types/accountConstraintType.ts +93 -0
- package/src/client/vaults/types/allowedSettingsChange.ts +136 -0
- package/src/client/vaults/types/cancelProposalEvent.ts +47 -0
- package/src/client/vaults/types/clmmPositionEntry.ts +37 -0
- package/src/client/vaults/types/dataConstraint.ts +16 -0
- package/src/client/vaults/types/dataOperator.ts +13 -0
- package/src/client/vaults/types/dataValue.ts +119 -0
- package/src/client/vaults/types/depositLiquidityEvent.ts +89 -0
- package/src/client/vaults/types/executeProposalEvent.ts +47 -0
- package/src/client/vaults/types/executeWithdrawalEvent.ts +12 -0
- package/src/client/vaults/types/fillParam.ts +12 -0
- package/src/client/vaults/types/finalizeProposalEvent.ts +51 -0
- package/src/client/vaults/types/hook.ts +40 -0
- package/src/client/vaults/types/hookCompiledInstruction.ts +20 -0
- package/src/client/vaults/types/index.ts +68 -0
- package/src/client/vaults/types/instructionConstraint.ts +33 -0
- package/src/client/vaults/types/internalFundTransferPolicyCreationPayload.ts +35 -0
- package/src/client/vaults/types/kaminoFarmEntry.ts +32 -0
- package/src/client/vaults/types/kaminoObligationEntry.ts +51 -0
- package/src/client/vaults/types/limitedQuantityConstraints.ts +10 -0
- package/src/client/vaults/types/limitedSpendingLimit.ts +35 -0
- package/src/client/vaults/types/limitedTimeConstraints.ts +15 -0
- package/src/client/vaults/types/loopscaleLoanEntry.ts +23 -0
- package/src/client/vaults/types/loopscaleStrategyEntry.ts +23 -0
- package/src/client/vaults/types/number.ts +8 -0
- package/src/client/vaults/types/obligationType.ts +63 -0
- package/src/client/vaults/types/orderbookEntry.ts +50 -0
- package/src/client/vaults/types/periodV2.ts +76 -0
- package/src/client/vaults/types/permissions.ts +8 -0
- package/src/client/vaults/types/policyAction.ts +74 -0
- package/src/client/vaults/types/policyConfig.ts +32 -0
- package/src/client/vaults/types/policyCreationPayload.ts +147 -0
- package/src/client/vaults/types/policyExpirationArgs.ts +67 -0
- package/src/client/vaults/types/positionUpdate.ts +313 -0
- package/src/client/vaults/types/priceId.ts +57 -0
- package/src/client/vaults/types/priceType.ts +23 -0
- package/src/client/vaults/types/programInteractionPolicyCreationPayload.ts +32 -0
- package/src/client/vaults/types/proposalAction.ts +97 -0
- package/src/client/vaults/types/proposalActionKind.ts +11 -0
- package/src/client/vaults/types/proposalStatus.ts +13 -0
- package/src/client/vaults/types/proposalVoteConfig.ts +36 -0
- package/src/client/vaults/types/proposeActionEvent.ts +62 -0
- package/src/client/vaults/types/quantityConstraints.ts +14 -0
- package/src/client/vaults/types/reserveFarmMapping.ts +35 -0
- package/src/client/vaults/types/reservePriceMapping.ts +26 -0
- package/src/client/vaults/types/settingsChangePolicyCreationPayload.ts +14 -0
- package/src/client/vaults/types/spendingLimitPolicyCreationPayload.ts +54 -0
- package/src/client/vaults/types/stakeVoteEvent.ts +54 -0
- package/src/client/vaults/types/strategyPosition.ts +178 -0
- package/src/client/vaults/types/timeConstraints.ts +22 -0
- package/src/client/vaults/types/tokenAccountBalance.ts +35 -0
- package/src/client/vaults/types/tokenAccountEntry.ts +30 -0
- package/src/client/vaults/types/tokenEntry.ts +48 -0
- package/src/client/vaults/types/unstakeVoteEvent.ts +53 -0
- package/src/client/vaults/types/updatePriceAction.ts +268 -0
- package/src/client/vaults/types/updatePriceInput.ts +12 -0
- package/src/client/vaults/types/usageState.ts +12 -0
- package/src/client/vaults/types/vaultConfig.ts +38 -0
- package/src/client/vaults/types/vaultFinancials.ts +40 -0
- package/src/client/vaults/types/vaultFlagAction.ts +75 -0
- package/src/client/vaults/types/vaultFlagsUpdatedEvent.ts +37 -0
- package/src/client/vaults/types/vaultRoleKind.ts +11 -0
- package/src/client/vaults/types/vaultRoles.ts +59 -0
- package/src/client/vaults/types/vaultSettingsAction.ts +533 -0
- package/src/client/vaults/types/voteChoice.ts +9 -0
- package/src/client/vaults/types/withdrawalPeriodSettings.ts +83 -0
- package/src/client/vaults/types/withdrawalTokenFill.ts +35 -0
- package/src/client/vaults/types/yieldPositionEntry.ts +35 -0
- package/src/clmm/codamaEvents.ts +34 -0
- package/src/clmm/index.ts +1 -1
- package/src/codamaEvents.ts +27 -0
- package/src/environment.ts +15 -13
- package/src/exponentVaults/aumCalculator.ts +1350 -0
- package/src/exponentVaults/events.ts +15 -0
- package/src/exponentVaults/fetcher.ts +257 -0
- package/src/exponentVaults/index.ts +322 -0
- package/src/exponentVaults/kamino-farms.ts +538 -0
- package/src/exponentVaults/kamino-markets.ts +363 -0
- package/src/exponentVaults/loopscale/client.ts +808 -0
- package/src/exponentVaults/loopscale/helpers.ts +172 -0
- package/src/exponentVaults/loopscale/index.ts +57 -0
- package/src/exponentVaults/loopscale/prepared-transactions.ts +435 -0
- package/src/exponentVaults/loopscale/prepared-types.ts +73 -0
- package/src/exponentVaults/loopscale/types.ts +466 -0
- package/src/exponentVaults/policyBuilders.ts +1729 -0
- package/src/exponentVaults/policyMatcher.ts +895 -0
- package/src/exponentVaults/pricePathResolver.test.ts +466 -0
- package/src/exponentVaults/pricePathResolver.ts +273 -0
- package/src/exponentVaults/scope-refresh.ts +169 -0
- package/src/exponentVaults/squadsVaultTxnResolver/constants.ts +59 -0
- package/src/exponentVaults/squadsVaultTxnResolver/helpers.ts +355 -0
- package/src/exponentVaults/squadsVaultTxnResolver/index.ts +16 -0
- package/src/exponentVaults/squadsVaultTxnResolver/resolvers/exponent.ts +472 -0
- package/src/exponentVaults/squadsVaultTxnResolver/resolvers/helpers.ts +33 -0
- package/src/exponentVaults/squadsVaultTxnResolver/resolvers/index.ts +38 -0
- package/src/exponentVaults/squadsVaultTxnResolver/resolvers/kamino.ts +83 -0
- package/src/exponentVaults/squadsVaultTxnResolver/resolvers/loopscale.ts +94 -0
- package/src/exponentVaults/squadsVaultTxnResolver/resolvers/titan.ts +41 -0
- package/src/exponentVaults/squadsVaultTxnResolver/squadsVaultTxnResolver.ts +91 -0
- package/src/exponentVaults/squadsVaultTxnResolver/types.ts +171 -0
- package/src/exponentVaults/squadsVaultTxnResolver/utils.ts +3 -0
- package/src/exponentVaults/syncTransaction.ts +500 -0
- package/src/exponentVaults/titan-quote.ts +446 -0
- package/src/exponentVaults/vault-instruction-types.ts +493 -0
- package/src/exponentVaults/vault-interaction.ts +5070 -0
- package/src/exponentVaults/vault.ts +2667 -0
- package/src/exponentVaults/vaultTransactionBuilder.test.ts +256 -0
- package/src/exponentVaults/vaultTransactionBuilder.ts +927 -0
- package/src/flavors.ts +100 -99
- package/src/index.ts +17 -8
- package/src/lpPosition.ts +13 -18
- package/src/market.ts +461 -544
- package/src/marketThree.test.ts +16 -14
- package/src/marketThree.ts +920 -489
- package/src/orderbook/codamaEvents.ts +28 -0
- package/src/orderbook/index.ts +5 -4
- package/src/orderbook/math.ts +25 -9
- package/src/orderbook/orderbook.ts +531 -330
- package/src/orderbook/types.ts +6 -11
- package/src/orderbook/utils.ts +4 -12
- package/src/router.ts +469 -19
- package/src/syPosition.ts +15 -16
- package/src/tokenUtil.ts +4 -4
- package/src/utils/index.ts +5 -31
- package/src/utils/ix.ts +2 -2
- package/src/vault.ts +282 -327
- package/src/ytPosition.ts +75 -118
- package/tsconfig.json +6 -1
- package/build/EventDecoderV2.d.ts +0 -31
- package/build/EventDecoderV2.js +0 -76
- package/build/EventDecoderV2.js.map +0 -1
- package/build/clmm/events.d.ts +0 -10
- package/build/clmm/events.js +0 -10
- package/build/clmm/events.js.map +0 -1
- package/build/events.d.ts +0 -563
- package/build/events.js +0 -301
- package/build/events.js.map +0 -1
- package/build/eventsV2.d.ts +0 -7
- package/build/eventsV2.js +0 -10
- package/build/eventsV2.js.map +0 -1
- package/build/orderbook/events.d.ts +0 -7
- package/build/orderbook/events.js +0 -10
- package/build/orderbook/events.js.map +0 -1
- package/src/EventDecoderV2.ts +0 -96
- package/src/clmm/events.ts +0 -17
- package/src/events.ts +0 -921
- package/src/eventsV2.ts +0 -13
- package/src/orderbook/events.ts +0 -13
|
@@ -0,0 +1,369 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const globals_1 = require("@jest/globals");
|
|
4
|
+
const web3_js_1 = require("@solana/web3.js");
|
|
5
|
+
const pricePathResolver_1 = require("./pricePathResolver");
|
|
6
|
+
// ============================================================================
|
|
7
|
+
// Test helpers
|
|
8
|
+
// ============================================================================
|
|
9
|
+
/** Create a deterministic PublicKey from a seed byte. */
|
|
10
|
+
function pk(seed) {
|
|
11
|
+
return new web3_js_1.PublicKey(Uint8Array.from({ length: 32 }, () => seed));
|
|
12
|
+
}
|
|
13
|
+
/** Named mints for readability. */
|
|
14
|
+
const USDC = pk(1);
|
|
15
|
+
const SOL = pk(2);
|
|
16
|
+
const PT_SOL = pk(3);
|
|
17
|
+
const USDT = pk(6);
|
|
18
|
+
const BSOL = pk(8);
|
|
19
|
+
const PT_BSOL = pk(9);
|
|
20
|
+
function makePriceEntry(params) {
|
|
21
|
+
return {
|
|
22
|
+
priceId: params.priceId,
|
|
23
|
+
priceMint: params.priceMint,
|
|
24
|
+
underlyingMint: params.underlyingMint,
|
|
25
|
+
price: [[0n, 0n, 0n, 0n]],
|
|
26
|
+
positionsAmount: 0n,
|
|
27
|
+
lastUpdatedAt: 0n,
|
|
28
|
+
lastUpdatedSlot: 0n,
|
|
29
|
+
priceType: 0,
|
|
30
|
+
impliedApyBps: null,
|
|
31
|
+
impliedApy: null,
|
|
32
|
+
priceInterfaceAccounts: web3_js_1.PublicKey.default,
|
|
33
|
+
interfaceAccounts: [],
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
function makePrices(entries) {
|
|
37
|
+
return {
|
|
38
|
+
managers: [],
|
|
39
|
+
prices: entries,
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
// ============================================================================
|
|
43
|
+
// resolveExponentPricePath — BFS core
|
|
44
|
+
// ============================================================================
|
|
45
|
+
(0, globals_1.describe)("resolveExponentPricePath", () => {
|
|
46
|
+
(0, globals_1.it)("resolves a direct 1-hop path (PT_SOL → SOL)", () => {
|
|
47
|
+
const prices = makePrices([
|
|
48
|
+
makePriceEntry({ priceId: 1n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
49
|
+
]);
|
|
50
|
+
const path = (0, pricePathResolver_1.resolveExponentPricePath)(prices, PT_SOL, SOL);
|
|
51
|
+
(0, globals_1.expect)(path).not.toBeNull();
|
|
52
|
+
(0, globals_1.expect)(path.sourceMint.equals(PT_SOL)).toBe(true);
|
|
53
|
+
(0, globals_1.expect)(path.targetMint.equals(SOL)).toBe(true);
|
|
54
|
+
(0, globals_1.expect)(path.edges).toHaveLength(1);
|
|
55
|
+
(0, globals_1.expect)(path.edges[0].priceId).toBe(1n);
|
|
56
|
+
(0, globals_1.expect)(path.mints).toHaveLength(2);
|
|
57
|
+
});
|
|
58
|
+
(0, globals_1.it)("resolves a 2-hop path (PT_SOL → SOL → USDC)", () => {
|
|
59
|
+
const prices = makePrices([
|
|
60
|
+
makePriceEntry({ priceId: 1n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
61
|
+
makePriceEntry({ priceId: 2n, priceMint: SOL, underlyingMint: USDC }),
|
|
62
|
+
]);
|
|
63
|
+
const path = (0, pricePathResolver_1.resolveExponentPricePath)(prices, PT_SOL, USDC);
|
|
64
|
+
(0, globals_1.expect)(path).not.toBeNull();
|
|
65
|
+
(0, globals_1.expect)(path.edges).toHaveLength(2);
|
|
66
|
+
(0, globals_1.expect)(path.mints).toHaveLength(3);
|
|
67
|
+
(0, globals_1.expect)(path.mints[0].equals(PT_SOL)).toBe(true);
|
|
68
|
+
(0, globals_1.expect)(path.mints[1].equals(SOL)).toBe(true);
|
|
69
|
+
(0, globals_1.expect)(path.mints[2].equals(USDC)).toBe(true);
|
|
70
|
+
});
|
|
71
|
+
(0, globals_1.it)("resolves a 3-hop path (PT_BSOL → BSOL → SOL → USDC)", () => {
|
|
72
|
+
const prices = makePrices([
|
|
73
|
+
makePriceEntry({ priceId: 1n, priceMint: PT_BSOL, underlyingMint: BSOL }),
|
|
74
|
+
makePriceEntry({ priceId: 2n, priceMint: BSOL, underlyingMint: SOL }),
|
|
75
|
+
makePriceEntry({ priceId: 3n, priceMint: SOL, underlyingMint: USDC }),
|
|
76
|
+
]);
|
|
77
|
+
const path = (0, pricePathResolver_1.resolveExponentPricePath)(prices, PT_BSOL, USDC);
|
|
78
|
+
(0, globals_1.expect)(path).not.toBeNull();
|
|
79
|
+
(0, globals_1.expect)(path.edges).toHaveLength(3);
|
|
80
|
+
(0, globals_1.expect)(path.mints[0].equals(PT_BSOL)).toBe(true);
|
|
81
|
+
(0, globals_1.expect)(path.mints[1].equals(BSOL)).toBe(true);
|
|
82
|
+
(0, globals_1.expect)(path.mints[2].equals(SOL)).toBe(true);
|
|
83
|
+
(0, globals_1.expect)(path.mints[3].equals(USDC)).toBe(true);
|
|
84
|
+
});
|
|
85
|
+
(0, globals_1.it)("returns null when no path exists", () => {
|
|
86
|
+
const prices = makePrices([
|
|
87
|
+
makePriceEntry({ priceId: 1n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
88
|
+
// No edge from SOL to USDC — disconnected
|
|
89
|
+
]);
|
|
90
|
+
const path = (0, pricePathResolver_1.resolveExponentPricePath)(prices, PT_SOL, USDC);
|
|
91
|
+
(0, globals_1.expect)(path).toBeNull();
|
|
92
|
+
});
|
|
93
|
+
(0, globals_1.it)("returns null for empty price graph", () => {
|
|
94
|
+
const prices = makePrices([]);
|
|
95
|
+
(0, globals_1.expect)((0, pricePathResolver_1.resolveExponentPricePath)(prices, PT_SOL, SOL)).toBeNull();
|
|
96
|
+
});
|
|
97
|
+
(0, globals_1.it)("finds the shortest path when multiple paths exist", () => {
|
|
98
|
+
const prices = makePrices([
|
|
99
|
+
// Direct: PT_SOL → USDC (1 hop)
|
|
100
|
+
makePriceEntry({ priceId: 10n, priceMint: PT_SOL, underlyingMint: USDC }),
|
|
101
|
+
// Indirect: PT_SOL → SOL → USDC (2 hops)
|
|
102
|
+
makePriceEntry({ priceId: 1n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
103
|
+
makePriceEntry({ priceId: 2n, priceMint: SOL, underlyingMint: USDC }),
|
|
104
|
+
]);
|
|
105
|
+
const path = (0, pricePathResolver_1.resolveExponentPricePath)(prices, PT_SOL, USDC);
|
|
106
|
+
// BFS finds shortest first
|
|
107
|
+
(0, globals_1.expect)(path).not.toBeNull();
|
|
108
|
+
(0, globals_1.expect)(path.edges).toHaveLength(1);
|
|
109
|
+
(0, globals_1.expect)(path.edges[0].priceId).toBe(10n);
|
|
110
|
+
});
|
|
111
|
+
(0, globals_1.it)("handles cycles in the graph without infinite loop", () => {
|
|
112
|
+
const prices = makePrices([
|
|
113
|
+
makePriceEntry({ priceId: 1n, priceMint: SOL, underlyingMint: USDC }),
|
|
114
|
+
makePriceEntry({ priceId: 2n, priceMint: USDC, underlyingMint: SOL }), // Cycle
|
|
115
|
+
makePriceEntry({ priceId: 3n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
116
|
+
]);
|
|
117
|
+
const path = (0, pricePathResolver_1.resolveExponentPricePath)(prices, PT_SOL, USDC);
|
|
118
|
+
(0, globals_1.expect)(path).not.toBeNull();
|
|
119
|
+
(0, globals_1.expect)(path.edges).toHaveLength(2);
|
|
120
|
+
});
|
|
121
|
+
});
|
|
122
|
+
// ============================================================================
|
|
123
|
+
// resolvePriceIdFromMintToUnderlying — PriceId construction
|
|
124
|
+
// ============================================================================
|
|
125
|
+
(0, globals_1.describe)("resolvePriceIdFromMintToUnderlying", () => {
|
|
126
|
+
(0, globals_1.it)("returns Simple PriceId for a 1-hop path", () => {
|
|
127
|
+
const prices = makePrices([
|
|
128
|
+
makePriceEntry({ priceId: 7n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
129
|
+
]);
|
|
130
|
+
const resolved = (0, pricePathResolver_1.resolvePriceIdFromMintToUnderlyingOrThrow)({
|
|
131
|
+
prices,
|
|
132
|
+
sourceMint: PT_SOL,
|
|
133
|
+
targetMint: SOL,
|
|
134
|
+
label: "test",
|
|
135
|
+
});
|
|
136
|
+
(0, globals_1.expect)(resolved.__kind).toBe("Simple");
|
|
137
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(resolved)).toEqual([7n]);
|
|
138
|
+
});
|
|
139
|
+
(0, globals_1.it)("returns Multiply PriceId for a 2-hop path in underlying-to-input order", () => {
|
|
140
|
+
// Path: PT_SOL → SOL → USDC
|
|
141
|
+
// Edges: [edge(12n, PT_SOL→SOL), edge(11n, SOL→USDC)]
|
|
142
|
+
// On-chain expects: multiply prices from underlying→input, so reversed: [11n, 12n]
|
|
143
|
+
const prices = makePrices([
|
|
144
|
+
makePriceEntry({ priceId: 11n, priceMint: SOL, underlyingMint: USDC }),
|
|
145
|
+
makePriceEntry({ priceId: 12n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
146
|
+
]);
|
|
147
|
+
const resolved = (0, pricePathResolver_1.resolvePriceIdFromMintToUnderlyingOrThrow)({
|
|
148
|
+
prices,
|
|
149
|
+
sourceMint: PT_SOL,
|
|
150
|
+
targetMint: USDC,
|
|
151
|
+
label: "test",
|
|
152
|
+
});
|
|
153
|
+
(0, globals_1.expect)(resolved.__kind).toBe("Multiply");
|
|
154
|
+
// On-chain validates: first entry's underlying_mint = vault underlying (USDC)
|
|
155
|
+
// Then chains: USDC ← SOL ← PT_SOL
|
|
156
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(resolved)).toEqual([11n, 12n]);
|
|
157
|
+
});
|
|
158
|
+
(0, globals_1.it)("returns Multiply PriceId for a 3-hop path", () => {
|
|
159
|
+
const prices = makePrices([
|
|
160
|
+
makePriceEntry({ priceId: 1n, priceMint: PT_BSOL, underlyingMint: BSOL }),
|
|
161
|
+
makePriceEntry({ priceId: 2n, priceMint: BSOL, underlyingMint: SOL }),
|
|
162
|
+
makePriceEntry({ priceId: 3n, priceMint: SOL, underlyingMint: USDC }),
|
|
163
|
+
]);
|
|
164
|
+
const resolved = (0, pricePathResolver_1.resolvePriceIdFromMintToUnderlyingOrThrow)({
|
|
165
|
+
prices,
|
|
166
|
+
sourceMint: PT_BSOL,
|
|
167
|
+
targetMint: USDC,
|
|
168
|
+
label: "test",
|
|
169
|
+
});
|
|
170
|
+
(0, globals_1.expect)(resolved.__kind).toBe("Multiply");
|
|
171
|
+
// Reversed edge order: [3n (SOL→USDC), 2n (BSOL→SOL), 1n (PT_BSOL→BSOL)]
|
|
172
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(resolved)).toEqual([3n, 2n, 1n]);
|
|
173
|
+
});
|
|
174
|
+
(0, globals_1.it)("returns null when no path exists", () => {
|
|
175
|
+
const prices = makePrices([]);
|
|
176
|
+
const resolved = (0, pricePathResolver_1.resolvePriceIdFromMintToUnderlying)(prices, PT_SOL, SOL);
|
|
177
|
+
(0, globals_1.expect)(resolved).toBeNull();
|
|
178
|
+
});
|
|
179
|
+
(0, globals_1.it)("throws with descriptive error when path is missing (OrThrow variant)", () => {
|
|
180
|
+
const prices = makePrices([]);
|
|
181
|
+
(0, globals_1.expect)(() => (0, pricePathResolver_1.resolvePriceIdFromMintToUnderlyingOrThrow)({
|
|
182
|
+
prices,
|
|
183
|
+
sourceMint: PT_SOL,
|
|
184
|
+
targetMint: SOL,
|
|
185
|
+
label: "test label",
|
|
186
|
+
})).toThrow(`Missing Exponent price path for test label: ${PT_SOL.toBase58()} -> ${SOL.toBase58()}`);
|
|
187
|
+
});
|
|
188
|
+
});
|
|
189
|
+
// ============================================================================
|
|
190
|
+
// resolveBestKaminoQuotePath — Kamino quote mint selection
|
|
191
|
+
// ============================================================================
|
|
192
|
+
(0, globals_1.describe)("resolveBestKaminoQuotePath", () => {
|
|
193
|
+
(0, globals_1.it)("always uses vault underlying as the quote mint", () => {
|
|
194
|
+
// USDC vault — quote should be USDC itself via the One price entry
|
|
195
|
+
const prices = makePrices([
|
|
196
|
+
makePriceEntry({ priceId: 1n, priceMint: USDC, underlyingMint: USDC }),
|
|
197
|
+
makePriceEntry({ priceId: 2n, priceMint: SOL, underlyingMint: USDC }),
|
|
198
|
+
]);
|
|
199
|
+
const result = (0, pricePathResolver_1.resolveBestKaminoQuotePath)({
|
|
200
|
+
prices,
|
|
201
|
+
vaultUnderlyingMint: USDC,
|
|
202
|
+
});
|
|
203
|
+
(0, globals_1.expect)(result.quoteInputMint.equals(USDC)).toBe(true);
|
|
204
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(result.quotePriceId)).toEqual([1n]);
|
|
205
|
+
});
|
|
206
|
+
(0, globals_1.it)("works for a SOL vault with a SOL→SOL identity entry", () => {
|
|
207
|
+
const prices = makePrices([
|
|
208
|
+
makePriceEntry({ priceId: 3n, priceMint: SOL, underlyingMint: SOL }),
|
|
209
|
+
]);
|
|
210
|
+
const result = (0, pricePathResolver_1.resolveBestKaminoQuotePath)({
|
|
211
|
+
prices,
|
|
212
|
+
vaultUnderlyingMint: SOL,
|
|
213
|
+
});
|
|
214
|
+
(0, globals_1.expect)(result.quoteInputMint.equals(SOL)).toBe(true);
|
|
215
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(result.quotePriceId)).toEqual([3n]);
|
|
216
|
+
});
|
|
217
|
+
(0, globals_1.it)("throws when no identity price exists for vault underlying", () => {
|
|
218
|
+
const prices = makePrices([]);
|
|
219
|
+
(0, globals_1.expect)(() => (0, pricePathResolver_1.resolveBestKaminoQuotePath)({
|
|
220
|
+
prices,
|
|
221
|
+
vaultUnderlyingMint: USDC,
|
|
222
|
+
})).toThrow("Missing Exponent price path for Kamino quote resolution");
|
|
223
|
+
});
|
|
224
|
+
});
|
|
225
|
+
// ============================================================================
|
|
226
|
+
// resolveKaminoReservePriceIdOrThrow — reserve-to-quote mapping
|
|
227
|
+
// ============================================================================
|
|
228
|
+
(0, globals_1.describe)("resolveKaminoReservePriceIdOrThrow", () => {
|
|
229
|
+
(0, globals_1.it)("returns identity (Simple 0) when reserve mint equals quote mint", () => {
|
|
230
|
+
const prices = makePrices([]);
|
|
231
|
+
const result = (0, pricePathResolver_1.resolveKaminoReservePriceIdOrThrow)({
|
|
232
|
+
prices,
|
|
233
|
+
reserveMint: USDC,
|
|
234
|
+
quoteInputMint: USDC,
|
|
235
|
+
});
|
|
236
|
+
(0, globals_1.expect)(result.__kind).toBe("Simple");
|
|
237
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(result)).toEqual([0n]);
|
|
238
|
+
});
|
|
239
|
+
(0, globals_1.it)("resolves reserve → quote when they differ", () => {
|
|
240
|
+
const prices = makePrices([
|
|
241
|
+
makePriceEntry({ priceId: 5n, priceMint: SOL, underlyingMint: USDC }),
|
|
242
|
+
]);
|
|
243
|
+
const result = (0, pricePathResolver_1.resolveKaminoReservePriceIdOrThrow)({
|
|
244
|
+
prices,
|
|
245
|
+
reserveMint: SOL,
|
|
246
|
+
quoteInputMint: USDC,
|
|
247
|
+
});
|
|
248
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(result)).toEqual([5n]);
|
|
249
|
+
});
|
|
250
|
+
(0, globals_1.it)("throws when reserve cannot reach quote", () => {
|
|
251
|
+
const prices = makePrices([]);
|
|
252
|
+
(0, globals_1.expect)(() => (0, pricePathResolver_1.resolveKaminoReservePriceIdOrThrow)({
|
|
253
|
+
prices,
|
|
254
|
+
reserveMint: SOL,
|
|
255
|
+
quoteInputMint: USDC,
|
|
256
|
+
})).toThrow("Missing Exponent price path for Kamino reserve mapping");
|
|
257
|
+
});
|
|
258
|
+
});
|
|
259
|
+
// ============================================================================
|
|
260
|
+
// Kamino end-to-end: quote selection + reserve mapping
|
|
261
|
+
// ============================================================================
|
|
262
|
+
(0, globals_1.describe)("Kamino end-to-end price resolution", () => {
|
|
263
|
+
(0, globals_1.it)("resolves a SOL vault with SOL and USDC reserves", () => {
|
|
264
|
+
// SOL vault: underlying = SOL
|
|
265
|
+
// Reserves: SOL (passthrough), USDC (needs USDC→SOL price)
|
|
266
|
+
const prices = makePrices([
|
|
267
|
+
makePriceEntry({ priceId: 1n, priceMint: SOL, underlyingMint: SOL }),
|
|
268
|
+
makePriceEntry({ priceId: 2n, priceMint: USDC, underlyingMint: SOL }),
|
|
269
|
+
]);
|
|
270
|
+
// Quote is always vault underlying
|
|
271
|
+
const quotePath = (0, pricePathResolver_1.resolveBestKaminoQuotePath)({
|
|
272
|
+
prices,
|
|
273
|
+
vaultUnderlyingMint: SOL,
|
|
274
|
+
});
|
|
275
|
+
(0, globals_1.expect)(quotePath.quoteInputMint.equals(SOL)).toBe(true);
|
|
276
|
+
// SOL reserve → SOL quote: passthrough
|
|
277
|
+
const solReservePrice = (0, pricePathResolver_1.resolveKaminoReservePriceIdOrThrow)({
|
|
278
|
+
prices,
|
|
279
|
+
reserveMint: SOL,
|
|
280
|
+
quoteInputMint: quotePath.quoteInputMint,
|
|
281
|
+
});
|
|
282
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(solReservePrice)).toEqual([0n]);
|
|
283
|
+
// USDC reserve → SOL quote: needs the USDC→SOL price
|
|
284
|
+
const usdcReservePrice = (0, pricePathResolver_1.resolveKaminoReservePriceIdOrThrow)({
|
|
285
|
+
prices,
|
|
286
|
+
reserveMint: USDC,
|
|
287
|
+
quoteInputMint: quotePath.quoteInputMint,
|
|
288
|
+
});
|
|
289
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(usdcReservePrice)).toEqual([2n]);
|
|
290
|
+
});
|
|
291
|
+
(0, globals_1.it)("resolves a USDC vault with BSOL needing a Multiply chain", () => {
|
|
292
|
+
// USDC vault: underlying = USDC
|
|
293
|
+
// BSOL reserve needs BSOL → SOL → USDC (two hops)
|
|
294
|
+
const prices = makePrices([
|
|
295
|
+
makePriceEntry({ priceId: 1n, priceMint: USDC, underlyingMint: USDC }),
|
|
296
|
+
makePriceEntry({ priceId: 2n, priceMint: SOL, underlyingMint: USDC }),
|
|
297
|
+
makePriceEntry({ priceId: 3n, priceMint: BSOL, underlyingMint: SOL }),
|
|
298
|
+
]);
|
|
299
|
+
const quotePath = (0, pricePathResolver_1.resolveBestKaminoQuotePath)({
|
|
300
|
+
prices,
|
|
301
|
+
vaultUnderlyingMint: USDC,
|
|
302
|
+
});
|
|
303
|
+
(0, globals_1.expect)(quotePath.quoteInputMint.equals(USDC)).toBe(true);
|
|
304
|
+
// BSOL → USDC requires chaining: Multiply [SOL→USDC, BSOL→SOL]
|
|
305
|
+
const bsolReservePrice = (0, pricePathResolver_1.resolveKaminoReservePriceIdOrThrow)({
|
|
306
|
+
prices,
|
|
307
|
+
reserveMint: BSOL,
|
|
308
|
+
quoteInputMint: quotePath.quoteInputMint,
|
|
309
|
+
});
|
|
310
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(bsolReservePrice)).toEqual([2n, 3n]);
|
|
311
|
+
// USDC → USDC: passthrough
|
|
312
|
+
const usdcReservePrice = (0, pricePathResolver_1.resolveKaminoReservePriceIdOrThrow)({
|
|
313
|
+
prices,
|
|
314
|
+
reserveMint: USDC,
|
|
315
|
+
quoteInputMint: quotePath.quoteInputMint,
|
|
316
|
+
});
|
|
317
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)(usdcReservePrice)).toEqual([0n]);
|
|
318
|
+
});
|
|
319
|
+
});
|
|
320
|
+
// ============================================================================
|
|
321
|
+
// extractPriceIds — parsing
|
|
322
|
+
// ============================================================================
|
|
323
|
+
(0, globals_1.describe)("extractPriceIds", () => {
|
|
324
|
+
(0, globals_1.it)("extracts from Simple (__kind format)", () => {
|
|
325
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)({ __kind: "Simple", priceId: 42n })).toEqual([42n]);
|
|
326
|
+
});
|
|
327
|
+
(0, globals_1.it)("extracts from Multiply (__kind format)", () => {
|
|
328
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)({ __kind: "Multiply", priceIds: [1n, 2n, 3n] })).toEqual([1n, 2n, 3n]);
|
|
329
|
+
});
|
|
330
|
+
(0, globals_1.it)("extracts from Simple (nested format)", () => {
|
|
331
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)({ simple: { priceId: 42n } })).toEqual([42n]);
|
|
332
|
+
});
|
|
333
|
+
(0, globals_1.it)("extracts from Multiply (nested format)", () => {
|
|
334
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)({ multiply: { priceIds: [1n, 2n, 3n] } })).toEqual([1n, 2n, 3n]);
|
|
335
|
+
});
|
|
336
|
+
(0, globals_1.it)("handles number priceIds in nested format", () => {
|
|
337
|
+
(0, globals_1.expect)((0, pricePathResolver_1.extractPriceIds)({ simple: { priceId: 42 } })).toEqual([42n]);
|
|
338
|
+
});
|
|
339
|
+
(0, globals_1.it)("throws for invalid shapes", () => {
|
|
340
|
+
(0, globals_1.expect)(() => (0, pricePathResolver_1.extractPriceIds)(null)).toThrow("Invalid PriceId");
|
|
341
|
+
(0, globals_1.expect)(() => (0, pricePathResolver_1.extractPriceIds)({})).toThrow("Unsupported PriceId shape");
|
|
342
|
+
});
|
|
343
|
+
});
|
|
344
|
+
// ============================================================================
|
|
345
|
+
// getPriceInputMintFromPriceId — reverse lookup
|
|
346
|
+
// ============================================================================
|
|
347
|
+
(0, globals_1.describe)("getPriceInputMintFromPriceId", () => {
|
|
348
|
+
(0, globals_1.it)("returns the priceMint of the last price in a Simple PriceId", () => {
|
|
349
|
+
const prices = makePrices([
|
|
350
|
+
makePriceEntry({ priceId: 5n, priceMint: SOL, underlyingMint: USDC }),
|
|
351
|
+
]);
|
|
352
|
+
const mint = (0, pricePathResolver_1.getPriceInputMintFromPriceId)(prices, { __kind: "Simple", priceId: 5n });
|
|
353
|
+
(0, globals_1.expect)(mint.equals(SOL)).toBe(true);
|
|
354
|
+
});
|
|
355
|
+
(0, globals_1.it)("returns the priceMint of the last price in a Multiply PriceId", () => {
|
|
356
|
+
const prices = makePrices([
|
|
357
|
+
makePriceEntry({ priceId: 1n, priceMint: SOL, underlyingMint: USDC }),
|
|
358
|
+
makePriceEntry({ priceId: 2n, priceMint: PT_SOL, underlyingMint: SOL }),
|
|
359
|
+
]);
|
|
360
|
+
// Multiply [1n, 2n] — last entry is priceId 2n, which has priceMint PT_SOL
|
|
361
|
+
const mint = (0, pricePathResolver_1.getPriceInputMintFromPriceId)(prices, { __kind: "Multiply", priceIds: [1n, 2n] });
|
|
362
|
+
(0, globals_1.expect)(mint.equals(PT_SOL)).toBe(true);
|
|
363
|
+
});
|
|
364
|
+
(0, globals_1.it)("throws when price entry not found", () => {
|
|
365
|
+
const prices = makePrices([]);
|
|
366
|
+
(0, globals_1.expect)(() => (0, pricePathResolver_1.getPriceInputMintFromPriceId)(prices, { __kind: "Simple", priceId: 999n })).toThrow("Price entry not found for id 999");
|
|
367
|
+
});
|
|
368
|
+
});
|
|
369
|
+
//# sourceMappingURL=pricePathResolver.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pricePathResolver.test.js","sourceRoot":"","sources":["../../src/exponentVaults/pricePathResolver.test.ts"],"names":[],"mappings":";;AAAA,2CAAoD;AACpD,6CAA2C;AAE3C,2DAQ4B;AAE5B,+EAA+E;AAC/E,eAAe;AACf,+EAA+E;AAE/E,yDAAyD;AACzD,SAAS,EAAE,CAAC,IAAY;IACtB,OAAO,IAAI,mBAAS,CAAC,UAAU,CAAC,IAAI,CAAC,EAAE,MA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AA;IAEF,IAAA,YAAE,EAAC,+DAA+D,EAAE,GAAG,EAAE;QACvE,MAAM,MAAM,GAAG,UAAU,CAAC;YACxB,cAAc,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,SAAS,EAAE,GAAG,EAAE,cAAc,EAAE,IAAI,EAAE,CAAC;YACrE,cAAc,CAAC,EAAE,OAAO,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,cAAc,EAAE,GAAG,EAAE,CAAC;SACxE,CAAC,CAAA;QAEF,2EAA2E;QAC3E,MAAM,IAAI,GAAG,IAAA,gDAA4B,EAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,QAAQ,EAAE,CAAC,EAAE,EAAE,EAAE,CAAC,EAAE,CAAC,CAAA;QAC7F,IAAA,gBAAM,EAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IACxC,CAAC,CAAC,CAAA;IAEF,IAAA,YAAE,EAAC,mCAAmC,EAAE,GAAG,EAAE;QAC3C,MAAM,MAAM,GAAG,UAAU,CAAC,EAAE,CAAC,CAAA;QAE7B,IAAA,gBAAM,EAAC,GAAG,EAAE,CACV,IAAA,gDAA4B,EAAC,MAAM,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,CAC1E,CAAC,OAAO,CAAC,kCAAkC,CAAC,CAAA;IAC/C,CAAC,CAAC,CAAA;AACJ,CAAC,CAAC,CAAA"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Reserve } from "@exponent-labs/kamino-reserve-deserializer";
|
|
2
|
+
import { Connection, TransactionInstruction } from "@solana/web3.js";
|
|
3
|
+
/**
|
|
4
|
+
* Build Scope refreshPriceList instructions for all reserves that use Scope oracles.
|
|
5
|
+
* Should be prepended before refreshReserve instructions so that Scope oracle data
|
|
6
|
+
* has fresh timestamps when reserves are refreshed.
|
|
7
|
+
*/
|
|
8
|
+
export declare function buildScopeRefreshInstructions(connection: Connection, reserves: {
|
|
9
|
+
account: Reserve;
|
|
10
|
+
}[]): Promise<TransactionInstruction[]>;
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.buildScopeRefreshInstructions = void 0;
|
|
4
|
+
const web3_js_1 = require("@solana/web3.js");
|
|
5
|
+
const SCOPE_PROGRAM_ID = new web3_js_1.PublicKey("HFn8GnPADiny6XqUoWE8uRPPxb29ikn4yTuPa9MF2fWJ");
|
|
6
|
+
const U16_MAX = 65535;
|
|
7
|
+
// Known Scope feed Configuration PDAs keyed by oraclePrices address.
|
|
8
|
+
// Source: @kamino-finance/scope-sdk constants/index.ts
|
|
9
|
+
const SCOPE_CONFIGURATIONS = {
|
|
10
|
+
"3t4JZcueEzTbVP6kLxXrL3VpWx45jDer4eqysweBchNH": "6cMwdbrJ95D7v5655Zsoe7oXmjQJMnagWK8EcdG6qmGM", // klend
|
|
11
|
+
"3NJYftD5sjVfxSnUdZ1wVML8f3aC6mp1CXCL6L7TnU8C": "AdTiP7QyjUyv6crF4H8z7fxJKU7Z5eCAGvJN1Y55cXxb", // hubble
|
|
12
|
+
};
|
|
13
|
+
// Oracle types that cannot be refreshed by the Scope program
|
|
14
|
+
const NON_REFRESHABLE_ORACLE_TYPES = new Set([5, 20]); // Chainlink, PythLazer
|
|
15
|
+
// Scope Configuration account layout (after 8-byte discriminator):
|
|
16
|
+
// offset 8: admin (32 bytes)
|
|
17
|
+
// offset 40: oracleMappings (32 bytes)
|
|
18
|
+
// offset 72: oraclePrices (32 bytes)
|
|
19
|
+
// offset 104: tokensMetadata (32 bytes)
|
|
20
|
+
// offset 136: oracleTwaps (32 bytes)
|
|
21
|
+
function decodeScopeConfig(data) {
|
|
22
|
+
return {
|
|
23
|
+
oracleMappings: new web3_js_1.PublicKey(data.subarray(40, 72)),
|
|
24
|
+
oraclePrices: new web3_js_1.PublicKey(data.subarray(72, 104)),
|
|
25
|
+
oracleTwaps: new web3_js_1.PublicKey(data.subarray(136, 168)),
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
// Scope OracleMappings account layout (after 8-byte discriminator):
|
|
29
|
+
// offset 8: priceInfoAccounts[512] (512 * 32 = 16384 bytes)
|
|
30
|
+
// offset 16392: priceTypes[512] (512 bytes)
|
|
31
|
+
function decodeScopeOracleMappings(data) {
|
|
32
|
+
const priceInfoAccounts = [];
|
|
33
|
+
for (let i = 0; i < 512; i++) {
|
|
34
|
+
const start = 8 + i * 32;
|
|
35
|
+
priceInfoAccounts.push(new web3_js_1.PublicKey(data.subarray(start, start + 32)));
|
|
36
|
+
}
|
|
37
|
+
const priceTypes = [];
|
|
38
|
+
for (let i = 0; i < 512; i++) {
|
|
39
|
+
priceTypes.push(data[16392 + i]);
|
|
40
|
+
}
|
|
41
|
+
return { priceInfoAccounts, priceTypes };
|
|
42
|
+
}
|
|
43
|
+
// refreshPriceList discriminator: [83, 186, 207, 131, 203, 254, 198, 130]
|
|
44
|
+
const REFRESH_PRICE_LIST_DISCRIMINATOR = Buffer.from([83, 186, 207, 131, 203, 254, 198, 130]);
|
|
45
|
+
function buildRefreshPriceListIx(oraclePrices, oracleMappings, oracleTwaps, tokens, oracleAccounts) {
|
|
46
|
+
// Data: 8-byte discriminator + borsh Vec<u16> (4-byte length + N * 2-byte values)
|
|
47
|
+
const data = Buffer.alloc(8 + 4 + tokens.length * 2);
|
|
48
|
+
REFRESH_PRICE_LIST_DISCRIMINATOR.copy(data, 0);
|
|
49
|
+
data.writeUInt32LE(tokens.length, 8);
|
|
50
|
+
for (let i = 0; i < tokens.length; i++) {
|
|
51
|
+
data.writeUInt16LE(tokens[i], 12 + i * 2);
|
|
52
|
+
}
|
|
53
|
+
const keys = [
|
|
54
|
+
{ pubkey: oraclePrices, isSigner: false, isWritable: true },
|
|
55
|
+
{ pubkey: oracleMappings, isSigner: false, isWritable: false },
|
|
56
|
+
{ pubkey: oracleTwaps, isSigner: false, isWritable: true },
|
|
57
|
+
{ pubkey: web3_js_1.SYSVAR_INSTRUCTIONS_PUBKEY, isSigner: false, isWritable: false },
|
|
58
|
+
...oracleAccounts,
|
|
59
|
+
];
|
|
60
|
+
return new web3_js_1.TransactionInstruction({
|
|
61
|
+
programId: SCOPE_PROGRAM_ID,
|
|
62
|
+
keys,
|
|
63
|
+
data,
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
/**
|
|
67
|
+
* Build Scope refreshPriceList instructions for all reserves that use Scope oracles.
|
|
68
|
+
* Should be prepended before refreshReserve instructions so that Scope oracle data
|
|
69
|
+
* has fresh timestamps when reserves are refreshed.
|
|
70
|
+
*/
|
|
71
|
+
async function buildScopeRefreshInstructions(connection, reserves) {
|
|
72
|
+
const defaultKey = web3_js_1.PublicKey.default;
|
|
73
|
+
// 1. Group token IDs by Scope feed (oraclePrices address)
|
|
74
|
+
const feedTokens = new Map();
|
|
75
|
+
for (const { account } of reserves) {
|
|
76
|
+
const scopeConfig = account.config.tokenInfo.scopeConfiguration;
|
|
77
|
+
if (scopeConfig.priceFeed.equals(defaultKey))
|
|
78
|
+
continue;
|
|
79
|
+
const feedKey = scopeConfig.priceFeed.toBase58();
|
|
80
|
+
if (!feedTokens.has(feedKey))
|
|
81
|
+
feedTokens.set(feedKey, new Set());
|
|
82
|
+
const tokens = feedTokens.get(feedKey);
|
|
83
|
+
for (const tokenId of scopeConfig.priceChain) {
|
|
84
|
+
if (tokenId !== U16_MAX)
|
|
85
|
+
tokens.add(tokenId);
|
|
86
|
+
}
|
|
87
|
+
for (const tokenId of scopeConfig.twapChain) {
|
|
88
|
+
if (tokenId !== U16_MAX)
|
|
89
|
+
tokens.add(tokenId);
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
if (feedTokens.size === 0)
|
|
93
|
+
return [];
|
|
94
|
+
// 2. For each feed, fetch Scope accounts and build the instruction
|
|
95
|
+
const instructions = [];
|
|
96
|
+
for (const [oraclePricesKey, tokenIds] of feedTokens) {
|
|
97
|
+
const oraclePrices = new web3_js_1.PublicKey(oraclePricesKey);
|
|
98
|
+
// Look up the Scope Configuration PDA for this feed
|
|
99
|
+
const configPdaStr = SCOPE_CONFIGURATIONS[oraclePricesKey];
|
|
100
|
+
if (!configPdaStr) {
|
|
101
|
+
console.warn(`Unknown Scope feed: ${oraclePricesKey}, skipping refresh`);
|
|
102
|
+
continue;
|
|
103
|
+
}
|
|
104
|
+
const configPda = new web3_js_1.PublicKey(configPdaStr);
|
|
105
|
+
// Fetch Configuration account to get oracleMappings and oracleTwaps
|
|
106
|
+
const configInfo = await connection.getAccountInfo(configPda);
|
|
107
|
+
if (!configInfo) {
|
|
108
|
+
console.warn(`Scope Configuration not found: ${configPdaStr}`);
|
|
109
|
+
continue;
|
|
110
|
+
}
|
|
111
|
+
const config = decodeScopeConfig(configInfo.data);
|
|
112
|
+
// Fetch OracleMappings to get per-token oracle accounts
|
|
113
|
+
const mappingsInfo = await connection.getAccountInfo(config.oracleMappings);
|
|
114
|
+
if (!mappingsInfo) {
|
|
115
|
+
console.warn(`Scope OracleMappings not found: ${config.oracleMappings.toBase58()}`);
|
|
116
|
+
continue;
|
|
117
|
+
}
|
|
118
|
+
const mappings = decodeScopeOracleMappings(mappingsInfo.data);
|
|
119
|
+
// Filter out non-refreshable oracle types and build remaining accounts
|
|
120
|
+
const sortedTokens = [...tokenIds].sort((a, b) => a - b);
|
|
121
|
+
const refreshableTokens = [];
|
|
122
|
+
const oracleAccounts = [];
|
|
123
|
+
for (const tokenId of sortedTokens) {
|
|
124
|
+
if (NON_REFRESHABLE_ORACLE_TYPES.has(mappings.priceTypes[tokenId]))
|
|
125
|
+
continue;
|
|
126
|
+
refreshableTokens.push(tokenId);
|
|
127
|
+
oracleAccounts.push({
|
|
128
|
+
pubkey: mappings.priceInfoAccounts[tokenId],
|
|
129
|
+
isSigner: false,
|
|
130
|
+
isWritable: false,
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
if (refreshableTokens.length === 0)
|
|
134
|
+
continue;
|
|
135
|
+
instructions.push(buildRefreshPriceListIx(oraclePrices, config.oracleMappings, config.oracleTwaps, refreshableTokens, oracleAccounts));
|
|
136
|
+
}
|
|
137
|
+
return instructions;
|
|
138
|
+
}
|
|
139
|
+
exports.buildScopeRefreshInstructions = buildScopeRefreshInstructions;
|
|
140
|
+
//# sourceMappingURL=scope-refresh.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scope-refresh.js","sourceRoot":"","sources":["../../src/exponentVaults/scope-refresh.ts"],"names":[],"mappings":";;;AACA,6CAAwH;AAExH,MAAM,gBAAgB,GAAG,IAAI,mBAAS,CAAC,8CAA8C,CAAC,CAAA;AACtF,MAAM,OAAO,GAAG,KAAK,CAAA;AAErB,qEAAqE;AACrE,uDAAuD;AACvD,MAAM,oBAAoB,GAA2B;IACnD,8CAA8C,EAAE,8CAA8C,EAAE,QAAQ;IACxG,8CAA8C,EAAE,8CAA8C,EAAE,SAAS;CAC1G,CAAA;AAED,6DAA6D;AAC7D,MAAM,4BAA4B,GAAG,IAAI,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAA,CAAC,uBAAuB;AAE7E,mEAAmE;AACnE,iCAAiC;AACjC,0CAA0C;AAC1C,wCAAwC;AACxC,0CAA0C;AAC1C,uCAAuC;AACvC,SAAS,iBAAiB,CAAC,IAAY;IACrC,OAAO;QACL,cAAc,EAAE,IAAI,mBAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;QACpD,YAAY,EAAE,IAAI,mBAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,GAAG,CAAC,CAAC;QACnD,WAAW,EAAE,IAAI,mBAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;KACpD,CAAA;AACH,CAAC;AAED,oEAAoE;AACpE,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use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ACTION_DISPLAY_NAMES = void 0;
|
|
4
|
+
/* eslint-disable camelcase */
|
|
5
|
+
exports.ACTION_DISPLAY_NAMES = {
|
|
6
|
+
swap_exact_sy_for_pt: "Buy PT",
|
|
7
|
+
swap_exact_pt_for_sy: "Sell PT",
|
|
8
|
+
swap_exact_sy_for_yt: "Buy YT",
|
|
9
|
+
swap_exact_yt_for_sy: "Sell YT",
|
|
10
|
+
wrapper_post_offer: "Post Limit Order",
|
|
11
|
+
raw_post_offer: "Post Offer",
|
|
12
|
+
raw_market_offer: "Market Offer",
|
|
13
|
+
wrapper_remove_offer: "Remove Offer",
|
|
14
|
+
wrapper_withdraw_funds: "Withdraw Filled Orders",
|
|
15
|
+
initialize_yield_position: "Initialize Yield Position",
|
|
16
|
+
wrapper_strip: "Strip",
|
|
17
|
+
wrapper_merge: "Merge",
|
|
18
|
+
mint_sy: "Mint SY",
|
|
19
|
+
redeem_sy: "Redeem SY",
|
|
20
|
+
lending_account_deposit: "Deposit",
|
|
21
|
+
lending_account_withdraw: "Withdraw",
|
|
22
|
+
lending_account_borrow: "Borrow",
|
|
23
|
+
lending_account_repay: "Repay",
|
|
24
|
+
init_user_metadata: "Init User Metadata",
|
|
25
|
+
deposit_reserve_liquidity: "Deposit Reserve Liquidity",
|
|
26
|
+
init_obligation: "Init Obligation",
|
|
27
|
+
init_obligation_farms_for_reserve: "Init Obligation Farms",
|
|
28
|
+
refresh_reserve: "Refresh Reserve",
|
|
29
|
+
refresh_obligation: "Refresh Obligation",
|
|
30
|
+
swap_route_v2: "Swap",
|
|
31
|
+
collect_interest: "Collect Interest",
|
|
32
|
+
wrapper_collect_interest: "Collect Interest",
|
|
33
|
+
deposit_yt: "Deposit YT",
|
|
34
|
+
withdraw_yt: "Withdraw YT",
|
|
35
|
+
// CLMM
|
|
36
|
+
deposit_liquidity: "Deposit Liquidity",
|
|
37
|
+
add_liquidity: "Add Liquidity",
|
|
38
|
+
withdraw_liquidity: "Withdraw Liquidity",
|
|
39
|
+
trade_pt: "Trade PT",
|
|
40
|
+
trade_pt_exact_out: "Trade PT (Exact Out)",
|
|
41
|
+
buy_yt: "Buy YT",
|
|
42
|
+
sell_yt: "Sell YT",
|
|
43
|
+
claim_farm_emission: "Claim Rewards",
|
|
44
|
+
// Loopscale
|
|
45
|
+
create_loan: "Create Loan",
|
|
46
|
+
deposit_collateral: "Deposit Collateral",
|
|
47
|
+
borrow_principal: "Borrow",
|
|
48
|
+
repay_principal: "Repay",
|
|
49
|
+
withdraw_collateral: "Withdraw Collateral",
|
|
50
|
+
close_loan: "Close Loan",
|
|
51
|
+
create_strategy: "Create Strategy",
|
|
52
|
+
deposit_strategy: "Deposit",
|
|
53
|
+
withdraw_strategy: "Withdraw",
|
|
54
|
+
close_strategy: "Close Strategy",
|
|
55
|
+
update_weight_matrix: "Update Weight Matrix",
|
|
56
|
+
lock_loan: "Lock Loan",
|
|
57
|
+
unlock_loan: "Unlock Loan",
|
|
58
|
+
update_strategy: "Update Strategy",
|
|
59
|
+
refinance_ledger: "Refinance",
|
|
60
|
+
};
|
|
61
|
+
//# sourceMappingURL=constants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/exponentVaults/squadsVaultTxnResolver/constants.ts"],"names":[],"mappings":";;;AAEA,8BAA8B;AACjB,QAAA,oBAAoB,GAAoC;IACnE,oBAAoB,EAAE,QAAQ;IAC9B,oBAAoB,EAAE,SAAS;IAC/B,oBAAoB,EAAE,QAAQ;IAC9B,oBAAoB,EAAE,SAAS;IAC/B,kBAAkB,EAAE,kBAAkB;IACtC,cAAc,EAAE,YAAY;IAC5B,gBAAgB,EAAE,cAAc;IAChC,oBAAoB,EAAE,cAAc;IACpC,sBAAsB,EAAE,wBAAwB;IAChD,yBAAyB,EAAE,2BAA2B;IACtD,aAAa,EAAE,OAAO;IACtB,aAAa,E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