@kamino-finance/klend-sdk 2.10.6
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/README.md +85 -0
- package/dist/classes/action.d.ts +154 -0
- package/dist/classes/action.js +1505 -0
- package/dist/classes/action.js.map +1 -0
- package/dist/classes/curve.d.ts +15 -0
- package/dist/classes/curve.js +32 -0
- package/dist/classes/curve.js.map +1 -0
- package/dist/classes/fraction.d.ts +23 -0
- package/dist/classes/fraction.js +60 -0
- package/dist/classes/fraction.js.map +1 -0
- package/dist/classes/index.d.ts +8 -0
- package/dist/classes/index.js +25 -0
- package/dist/classes/index.js.map +1 -0
- package/dist/classes/jupiterPerps.d.ts +2 -0
- package/dist/classes/jupiterPerps.js +25 -0
- package/dist/classes/jupiterPerps.js.map +1 -0
- package/dist/classes/market.d.ts +140 -0
- package/dist/classes/market.js +901 -0
- package/dist/classes/market.js.map +1 -0
- package/dist/classes/obligation.d.ts +170 -0
- package/dist/classes/obligation.js +610 -0
- package/dist/classes/obligation.js.map +1 -0
- package/dist/classes/reserve.d.ts +161 -0
- package/dist/classes/reserve.js +474 -0
- package/dist/classes/reserve.js.map +1 -0
- package/dist/classes/shared.d.ts +41 -0
- package/dist/classes/shared.js +10 -0
- package/dist/classes/shared.js.map +1 -0
- package/dist/classes/utils.d.ts +40 -0
- package/dist/classes/utils.js +129 -0
- package/dist/classes/utils.js.map +1 -0
- package/dist/idl.json +4102 -0
- package/dist/idl_codegen/accounts/LendingMarket.d.ts +153 -0
- package/dist/idl_codegen/accounts/LendingMarket.js +204 -0
- package/dist/idl_codegen/accounts/LendingMarket.js.map +1 -0
- package/dist/idl_codegen/accounts/Obligation.d.ts +139 -0
- package/dist/idl_codegen/accounts/Obligation.js +193 -0
- package/dist/idl_codegen/accounts/Obligation.js.map +1 -0
- package/dist/idl_codegen/accounts/ReferrerState.d.ts +22 -0
- package/dist/idl_codegen/accounts/ReferrerState.js +101 -0
- package/dist/idl_codegen/accounts/ReferrerState.js.map +1 -0
- package/dist/idl_codegen/accounts/ReferrerTokenState.d.ts +51 -0
- package/dist/idl_codegen/accounts/ReferrerTokenState.js +126 -0
- package/dist/idl_codegen/accounts/ReferrerTokenState.js.map +1 -0
- package/dist/idl_codegen/accounts/Reserve.d.ts +72 -0
- package/dist/idl_codegen/accounts/Reserve.js +156 -0
- package/dist/idl_codegen/accounts/Reserve.js.map +1 -0
- package/dist/idl_codegen/accounts/ShortUrl.d.ts +22 -0
- package/dist/idl_codegen/accounts/ShortUrl.js +101 -0
- package/dist/idl_codegen/accounts/ShortUrl.js.map +1 -0
- package/dist/idl_codegen/accounts/UserMetadata.d.ts +48 -0
- package/dist/idl_codegen/accounts/UserMetadata.js +126 -0
- package/dist/idl_codegen/accounts/UserMetadata.js.map +1 -0
- package/dist/idl_codegen/accounts/UserState.d.ts +143 -0
- package/dist/idl_codegen/accounts/UserState.js +180 -0
- package/dist/idl_codegen/accounts/UserState.js.map +1 -0
- package/dist/idl_codegen/accounts/index.d.ts +16 -0
- package/dist/idl_codegen/accounts/index.js +20 -0
- package/dist/idl_codegen/accounts/index.js.map +1 -0
- package/dist/idl_codegen/errors/anchor.d.ts +434 -0
- package/dist/idl_codegen/errors/anchor.js +713 -0
- package/dist/idl_codegen/errors/anchor.js.map +1 -0
- package/dist/idl_codegen/errors/custom.d.ts +730 -0
- package/dist/idl_codegen/errors/custom.js +1194 -0
- package/dist/idl_codegen/errors/custom.js.map +1 -0
- package/dist/idl_codegen/errors/index.d.ts +5 -0
- package/dist/idl_codegen/errors/index.js +71 -0
- package/dist/idl_codegen/errors/index.js.map +1 -0
- package/dist/idl_codegen/instructions/borrowObligationLiquidity.d.ts +20 -0
- package/dist/idl_codegen/instructions/borrowObligationLiquidity.js +75 -0
- package/dist/idl_codegen/instructions/borrowObligationLiquidity.js.map +1 -0
- package/dist/idl_codegen/instructions/deleteReferrerStateAndShortUrl.d.ts +9 -0
- package/dist/idl_codegen/instructions/deleteReferrerStateAndShortUrl.js +20 -0
- package/dist/idl_codegen/instructions/deleteReferrerStateAndShortUrl.js.map +1 -0
- package/dist/idl_codegen/instructions/depositObligationCollateral.d.ts +17 -0
- package/dist/idl_codegen/instructions/depositObligationCollateral.js +64 -0
- package/dist/idl_codegen/instructions/depositObligationCollateral.js.map +1 -0
- package/dist/idl_codegen/instructions/depositReserveLiquidity.d.ts +19 -0
- package/dist/idl_codegen/instructions/depositReserveLiquidity.js +74 -0
- package/dist/idl_codegen/instructions/depositReserveLiquidity.js.map +1 -0
- package/dist/idl_codegen/instructions/depositReserveLiquidityAndObligationCollateral.d.ts +21 -0
- package/dist/idl_codegen/instructions/depositReserveLiquidityAndObligationCollateral.js +80 -0
- package/dist/idl_codegen/instructions/depositReserveLiquidityAndObligationCollateral.js.map +1 -0
- package/dist/idl_codegen/instructions/flashBorrowReserveLiquidity.d.ts +20 -0
- package/dist/idl_codegen/instructions/flashBorrowReserveLiquidity.js +75 -0
- package/dist/idl_codegen/instructions/flashBorrowReserveLiquidity.js.map +1 -0
- package/dist/idl_codegen/instructions/flashRepayReserveLiquidity.d.ts +21 -0
- package/dist/idl_codegen/instructions/flashRepayReserveLiquidity.js +75 -0
- package/dist/idl_codegen/instructions/flashRepayReserveLiquidity.js.map +1 -0
- package/dist/idl_codegen/instructions/idlMissingTypes.d.ts +18 -0
- package/dist/idl_codegen/instructions/idlMissingTypes.js +62 -0
- package/dist/idl_codegen/instructions/idlMissingTypes.js.map +1 -0
- package/dist/idl_codegen/instructions/index.d.ts +66 -0
- package/dist/idl_codegen/instructions/index.js +70 -0
- package/dist/idl_codegen/instructions/index.js.map +1 -0
- package/dist/idl_codegen/instructions/initFarmsForReserve.d.ts +19 -0
- package/dist/idl_codegen/instructions/initFarmsForReserve.js +63 -0
- package/dist/idl_codegen/instructions/initFarmsForReserve.js.map +1 -0
- package/dist/idl_codegen/instructions/initLendingMarket.d.ts +13 -0
- package/dist/idl_codegen/instructions/initLendingMarket.js +55 -0
- package/dist/idl_codegen/instructions/initLendingMarket.js.map +1 -0
- package/dist/idl_codegen/instructions/initObligation.d.ts +19 -0
- package/dist/idl_codegen/instructions/initObligation.js +55 -0
- package/dist/idl_codegen/instructions/initObligation.js.map +1 -0
- package/dist/idl_codegen/instructions/initObligationFarmsForReserve.d.ts +20 -0
- package/dist/idl_codegen/instructions/initObligationFarmsForReserve.js +60 -0
- package/dist/idl_codegen/instructions/initObligationFarmsForReserve.js.map +1 -0
- package/dist/idl_codegen/instructions/initReferrerStateAndShortUrl.d.ts +14 -0
- package/dist/idl_codegen/instructions/initReferrerStateAndShortUrl.js +54 -0
- package/dist/idl_codegen/instructions/initReferrerStateAndShortUrl.js.map +1 -0
- package/dist/idl_codegen/instructions/initReferrerTokenState.d.ts +14 -0
- package/dist/idl_codegen/instructions/initReferrerTokenState.js +50 -0
- package/dist/idl_codegen/instructions/initReferrerTokenState.js.map +1 -0
- package/dist/idl_codegen/instructions/initReserve.d.ts +16 -0
- package/dist/idl_codegen/instructions/initReserve.js +47 -0
- package/dist/idl_codegen/instructions/initReserve.js.map +1 -0
- package/dist/idl_codegen/instructions/initUserMetadata.d.ts +14 -0
- package/dist/idl_codegen/instructions/initUserMetadata.js +54 -0
- package/dist/idl_codegen/instructions/initUserMetadata.js.map +1 -0
- package/dist/idl_codegen/instructions/liquidateObligationAndRedeemReserveCollateral.d.ts +27 -0
- package/dist/idl_codegen/instructions/liquidateObligationAndRedeemReserveCollateral.js +102 -0
- package/dist/idl_codegen/instructions/liquidateObligationAndRedeemReserveCollateral.js.map +1 -0
- package/dist/idl_codegen/instructions/redeemFees.d.ts +10 -0
- package/dist/idl_codegen/instructions/redeemFees.js +33 -0
- package/dist/idl_codegen/instructions/redeemFees.js.map +1 -0
- package/dist/idl_codegen/instructions/redeemReserveCollateral.d.ts +19 -0
- package/dist/idl_codegen/instructions/redeemReserveCollateral.js +78 -0
- package/dist/idl_codegen/instructions/redeemReserveCollateral.js.map +1 -0
- package/dist/idl_codegen/instructions/refreshObligation.d.ts +6 -0
- package/dist/idl_codegen/instructions/refreshObligation.js +17 -0
- package/dist/idl_codegen/instructions/refreshObligation.js.map +1 -0
- package/dist/idl_codegen/instructions/refreshObligationFarmsForReserve.d.ts +19 -0
- package/dist/idl_codegen/instructions/refreshObligationFarmsForReserve.js +63 -0
- package/dist/idl_codegen/instructions/refreshObligationFarmsForReserve.js.map +1 -0
- package/dist/idl_codegen/instructions/refreshReserve.d.ts +10 -0
- package/dist/idl_codegen/instructions/refreshReserve.js +29 -0
- package/dist/idl_codegen/instructions/refreshReserve.js.map +1 -0
- package/dist/idl_codegen/instructions/repayObligationLiquidity.d.ts +17 -0
- package/dist/idl_codegen/instructions/repayObligationLiquidity.js +60 -0
- package/dist/idl_codegen/instructions/repayObligationLiquidity.js.map +1 -0
- package/dist/idl_codegen/instructions/requestElevationGroup.d.ts +11 -0
- package/dist/idl_codegen/instructions/requestElevationGroup.js +47 -0
- package/dist/idl_codegen/instructions/requestElevationGroup.js.map +1 -0
- package/dist/idl_codegen/instructions/socializeLoss.d.ts +14 -0
- package/dist/idl_codegen/instructions/socializeLoss.js +53 -0
- package/dist/idl_codegen/instructions/socializeLoss.js.map +1 -0
- package/dist/idl_codegen/instructions/updateEntireReserveConfig.d.ts +13 -0
- package/dist/idl_codegen/instructions/updateEntireReserveConfig.js +51 -0
- package/dist/idl_codegen/instructions/updateEntireReserveConfig.js.map +1 -0
- package/dist/idl_codegen/instructions/updateLendingMarket.d.ts +12 -0
- package/dist/idl_codegen/instructions/updateLendingMarket.js +50 -0
- package/dist/idl_codegen/instructions/updateLendingMarket.js.map +1 -0
- package/dist/idl_codegen/instructions/updateLendingMarketOwner.d.ts +6 -0
- package/dist/idl_codegen/instructions/updateLendingMarketOwner.js +21 -0
- package/dist/idl_codegen/instructions/updateLendingMarketOwner.js.map +1 -0
- package/dist/idl_codegen/instructions/updateReserveConfig.d.ts +13 -0
- package/dist/idl_codegen/instructions/updateReserveConfig.js +51 -0
- package/dist/idl_codegen/instructions/updateReserveConfig.js.map +1 -0
- package/dist/idl_codegen/instructions/updateSingleReserveConfig.d.ts +13 -0
- package/dist/idl_codegen/instructions/updateSingleReserveConfig.js +51 -0
- package/dist/idl_codegen/instructions/updateSingleReserveConfig.js.map +1 -0
- package/dist/idl_codegen/instructions/withdrawObligationCollateral.d.ts +18 -0
- package/dist/idl_codegen/instructions/withdrawObligationCollateral.js +69 -0
- package/dist/idl_codegen/instructions/withdrawObligationCollateral.js.map +1 -0
- package/dist/idl_codegen/instructions/withdrawObligationCollateralAndRedeemReserveCollateral.d.ts +21 -0
- package/dist/idl_codegen/instructions/withdrawObligationCollateralAndRedeemReserveCollateral.js +84 -0
- package/dist/idl_codegen/instructions/withdrawObligationCollateralAndRedeemReserveCollateral.js.map +1 -0
- package/dist/idl_codegen/instructions/withdrawProtocolFee.d.ts +16 -0
- package/dist/idl_codegen/instructions/withdrawProtocolFee.js +59 -0
- package/dist/idl_codegen/instructions/withdrawProtocolFee.js.map +1 -0
- package/dist/idl_codegen/instructions/withdrawReferrerFees.d.ts +12 -0
- package/dist/idl_codegen/instructions/withdrawReferrerFees.js +35 -0
- package/dist/idl_codegen/instructions/withdrawReferrerFees.js.map +1 -0
- package/dist/idl_codegen/programId.d.ts +4 -0
- package/dist/idl_codegen/programId.js +13 -0
- package/dist/idl_codegen/programId.js.map +1 -0
- package/dist/idl_codegen/types/AssetTier.d.ts +44 -0
- package/dist/idl_codegen/types/AssetTier.js +128 -0
- package/dist/idl_codegen/types/AssetTier.js.map +1 -0
- package/dist/idl_codegen/types/BigFractionBytes.d.ts +27 -0
- package/dist/idl_codegen/types/BigFractionBytes.js +73 -0
- package/dist/idl_codegen/types/BigFractionBytes.js.map +1 -0
- package/dist/idl_codegen/types/BorrowRateCurve.d.ts +27 -0
- package/dist/idl_codegen/types/BorrowRateCurve.js +62 -0
- package/dist/idl_codegen/types/BorrowRateCurve.js.map +1 -0
- package/dist/idl_codegen/types/CurvePoint.d.ts +26 -0
- package/dist/idl_codegen/types/CurvePoint.js +66 -0
- package/dist/idl_codegen/types/CurvePoint.js.map +1 -0
- package/dist/idl_codegen/types/ElevationGroup.d.ts +52 -0
- package/dist/idl_codegen/types/ElevationGroup.js +103 -0
- package/dist/idl_codegen/types/ElevationGroup.js.map +1 -0
- package/dist/idl_codegen/types/FeeCalculation.d.ts +31 -0
- package/dist/idl_codegen/types/FeeCalculation.js +102 -0
- package/dist/idl_codegen/types/FeeCalculation.js.map +1 -0
- package/dist/idl_codegen/types/InitObligationArgs.d.ts +26 -0
- package/dist/idl_codegen/types/InitObligationArgs.js +66 -0
- package/dist/idl_codegen/types/InitObligationArgs.js.map +1 -0
- package/dist/idl_codegen/types/LastUpdate.d.ts +47 -0
- package/dist/idl_codegen/types/LastUpdate.js +86 -0
- package/dist/idl_codegen/types/LastUpdate.js.map +1 -0
- package/dist/idl_codegen/types/ObligationCollateral.d.ts +48 -0
- package/dist/idl_codegen/types/ObligationCollateral.js +87 -0
- package/dist/idl_codegen/types/ObligationCollateral.js.map +1 -0
- package/dist/idl_codegen/types/ObligationLiquidity.d.ts +75 -0
- package/dist/idl_codegen/types/ObligationLiquidity.js +107 -0
- package/dist/idl_codegen/types/ObligationLiquidity.js.map +1 -0
- package/dist/idl_codegen/types/PriceHeuristic.d.ts +41 -0
- package/dist/idl_codegen/types/PriceHeuristic.js +75 -0
- package/dist/idl_codegen/types/PriceHeuristic.js.map +1 -0
- package/dist/idl_codegen/types/PythConfiguration.d.ts +25 -0
- package/dist/idl_codegen/types/PythConfiguration.js +62 -0
- package/dist/idl_codegen/types/PythConfiguration.js.map +1 -0
- package/dist/idl_codegen/types/ReserveCollateral.d.ts +53 -0
- package/dist/idl_codegen/types/ReserveCollateral.js +93 -0
- package/dist/idl_codegen/types/ReserveCollateral.js.map +1 -0
- package/dist/idl_codegen/types/ReserveConfig.d.ts +304 -0
- package/dist/idl_codegen/types/ReserveConfig.js +209 -0
- package/dist/idl_codegen/types/ReserveConfig.js.map +1 -0
- package/dist/idl_codegen/types/ReserveFarmKind.d.ts +31 -0
- package/dist/idl_codegen/types/ReserveFarmKind.js +102 -0
- package/dist/idl_codegen/types/ReserveFarmKind.js.map +1 -0
- package/dist/idl_codegen/types/ReserveFees.d.ts +78 -0
- package/dist/idl_codegen/types/ReserveFees.js +86 -0
- package/dist/idl_codegen/types/ReserveFees.js.map +1 -0
- package/dist/idl_codegen/types/ReserveLiquidity.d.ts +173 -0
- package/dist/idl_codegen/types/ReserveLiquidity.js +166 -0
- package/dist/idl_codegen/types/ReserveLiquidity.js.map +1 -0
- package/dist/idl_codegen/types/ReserveStatus.d.ts +44 -0
- package/dist/idl_codegen/types/ReserveStatus.js +128 -0
- package/dist/idl_codegen/types/ReserveStatus.js.map +1 -0
- package/dist/idl_codegen/types/ScopeConfiguration.d.ts +41 -0
- package/dist/idl_codegen/types/ScopeConfiguration.js +76 -0
- package/dist/idl_codegen/types/ScopeConfiguration.js.map +1 -0
- package/dist/idl_codegen/types/SwitchboardConfiguration.d.ts +30 -0
- package/dist/idl_codegen/types/SwitchboardConfiguration.js +67 -0
- package/dist/idl_codegen/types/SwitchboardConfiguration.js.map +1 -0
- package/dist/idl_codegen/types/TokenInfo.d.ts +109 -0
- package/dist/idl_codegen/types/TokenInfo.js +116 -0
- package/dist/idl_codegen/types/TokenInfo.js.map +1 -0
- package/dist/idl_codegen/types/UpdateConfigMode.d.ts +538 -0
- package/dist/idl_codegen/types/UpdateConfigMode.js +1116 -0
- package/dist/idl_codegen/types/UpdateConfigMode.js.map +1 -0
- package/dist/idl_codegen/types/UpdateLendingMarketConfigValue.d.ts +155 -0
- package/dist/idl_codegen/types/UpdateLendingMarketConfigValue.js +273 -0
- package/dist/idl_codegen/types/UpdateLendingMarketConfigValue.js.map +1 -0
- package/dist/idl_codegen/types/UpdateLendingMarketMode.d.ts +200 -0
- package/dist/idl_codegen/types/UpdateLendingMarketMode.js +440 -0
- package/dist/idl_codegen/types/UpdateLendingMarketMode.js.map +1 -0
- package/dist/idl_codegen/types/WithdrawalCaps.d.ts +38 -0
- package/dist/idl_codegen/types/WithdrawalCaps.js +86 -0
- package/dist/idl_codegen/types/WithdrawalCaps.js.map +1 -0
- package/dist/idl_codegen/types/index.d.ts +65 -0
- package/dist/idl_codegen/types/index.js +77 -0
- package/dist/idl_codegen/types/index.js.map +1 -0
- package/dist/idl_codegen/zero_padding/ObligationZP.d.ts +53 -0
- package/dist/idl_codegen/zero_padding/ObligationZP.js +140 -0
- package/dist/idl_codegen/zero_padding/ObligationZP.js.map +1 -0
- package/dist/idl_codegen/zero_padding/index.d.ts +1 -0
- package/dist/idl_codegen/zero_padding/index.js +6 -0
- package/dist/idl_codegen/zero_padding/index.js.map +1 -0
- package/dist/idl_codegen_jupiter_perps/accounts/Pool.d.ts +48 -0
- package/dist/idl_codegen_jupiter_perps/accounts/Pool.js +144 -0
- package/dist/idl_codegen_jupiter_perps/accounts/Pool.js.map +1 -0
- package/dist/idl_codegen_jupiter_perps/accounts/index.d.ts +2 -0
- package/dist/idl_codegen_jupiter_perps/accounts/index.js +6 -0
- package/dist/idl_codegen_jupiter_perps/accounts/index.js.map +1 -0
- package/dist/idl_codegen_jupiter_perps/programId.d.ts +3 -0
- package/dist/idl_codegen_jupiter_perps/programId.js +9 -0
- package/dist/idl_codegen_jupiter_perps/programId.js.map +1 -0
- package/dist/idl_codegen_jupiter_perps/types/Fees.d.ts +62 -0
- package/dist/idl_codegen_jupiter_perps/types/Fees.js +115 -0
- package/dist/idl_codegen_jupiter_perps/types/Fees.js.map +1 -0
- package/dist/idl_codegen_jupiter_perps/types/Limit.d.ts +32 -0
- package/dist/idl_codegen_jupiter_perps/types/Limit.js +75 -0
- package/dist/idl_codegen_jupiter_perps/types/Limit.js.map +1 -0
- package/dist/idl_codegen_jupiter_perps/types/PoolApr.d.ts +32 -0
- package/dist/idl_codegen_jupiter_perps/types/PoolApr.js +75 -0
- package/dist/idl_codegen_jupiter_perps/types/PoolApr.js.map +1 -0
- package/dist/idl_codegen_jupiter_perps/types/index.d.ts +6 -0
- package/dist/idl_codegen_jupiter_perps/types/index.js +10 -0
- package/dist/idl_codegen_jupiter_perps/types/index.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +18 -0
- package/dist/index.js.map +1 -0
- package/dist/lending_operations/index.d.ts +2 -0
- package/dist/lending_operations/index.js +19 -0
- package/dist/lending_operations/index.js.map +1 -0
- package/dist/lending_operations/repay_with_collateral_calcs.d.ts +5 -0
- package/dist/lending_operations/repay_with_collateral_calcs.js +26 -0
- package/dist/lending_operations/repay_with_collateral_calcs.js.map +1 -0
- package/dist/lending_operations/repay_with_collateral_operations.d.ts +47 -0
- package/dist/lending_operations/repay_with_collateral_operations.js +163 -0
- package/dist/lending_operations/repay_with_collateral_operations.js.map +1 -0
- package/dist/leverage/calcs.d.ts +132 -0
- package/dist/leverage/calcs.js +291 -0
- package/dist/leverage/calcs.js.map +1 -0
- package/dist/leverage/index.d.ts +4 -0
- package/dist/leverage/index.js +21 -0
- package/dist/leverage/index.js.map +1 -0
- package/dist/leverage/instructions.d.ts +43 -0
- package/dist/leverage/instructions.js +103 -0
- package/dist/leverage/instructions.js.map +1 -0
- package/dist/leverage/operations.d.ts +231 -0
- package/dist/leverage/operations.js +1058 -0
- package/dist/leverage/operations.js.map +1 -0
- package/dist/leverage/utils.d.ts +22 -0
- package/dist/leverage/utils.js +144 -0
- package/dist/leverage/utils.js.map +1 -0
- package/dist/lib.d.ts +9 -0
- package/dist/lib.js +26 -0
- package/dist/lib.js.map +1 -0
- package/dist/referrals/index.d.ts +2 -0
- package/dist/referrals/index.js +19 -0
- package/dist/referrals/index.js.map +1 -0
- package/dist/referrals/instructions.d.ts +16 -0
- package/dist/referrals/instructions.js +76 -0
- package/dist/referrals/instructions.js.map +1 -0
- package/dist/referrals/operations.d.ts +97 -0
- package/dist/referrals/operations.js +258 -0
- package/dist/referrals/operations.js.map +1 -0
- package/dist/utils/ObligationType.d.ts +49 -0
- package/dist/utils/ObligationType.js +129 -0
- package/dist/utils/ObligationType.js.map +1 -0
- package/dist/utils/api.d.ts +6 -0
- package/dist/utils/api.js +61 -0
- package/dist/utils/api.js.map +1 -0
- package/dist/utils/ata.d.ts +25 -0
- package/dist/utils/ata.js +155 -0
- package/dist/utils/ata.js.map +1 -0
- package/dist/utils/constants.d.ts +48 -0
- package/dist/utils/constants.js +75 -0
- package/dist/utils/constants.js.map +1 -0
- package/dist/utils/idl.d.ts +2 -0
- package/dist/utils/idl.js +9 -0
- package/dist/utils/idl.js.map +1 -0
- package/dist/utils/index.d.ts +14 -0
- package/dist/utils/index.js +31 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/instruction.d.ts +22 -0
- package/dist/utils/instruction.js +202 -0
- package/dist/utils/instruction.js.map +1 -0
- package/dist/utils/kamino.d.ts +3 -0
- package/dist/utils/kamino.js +45 -0
- package/dist/utils/kamino.js.map +1 -0
- package/dist/utils/layout.d.ts +13 -0
- package/dist/utils/layout.js +123 -0
- package/dist/utils/layout.js.map +1 -0
- package/dist/utils/lookupTable.d.ts +5 -0
- package/dist/utils/lookupTable.js +57 -0
- package/dist/utils/lookupTable.js.map +1 -0
- package/dist/utils/oracle.d.ts +51 -0
- package/dist/utils/oracle.js +295 -0
- package/dist/utils/oracle.js.map +1 -0
- package/dist/utils/pubkey.d.ts +74 -0
- package/dist/utils/pubkey.js +229 -0
- package/dist/utils/pubkey.js.map +1 -0
- package/dist/utils/seeds.d.ts +122 -0
- package/dist/utils/seeds.js +153 -0
- package/dist/utils/seeds.js.map +1 -0
- package/dist/utils/slots.d.ts +18 -0
- package/dist/utils/slots.js +32 -0
- package/dist/utils/slots.js.map +1 -0
- package/dist/utils/syncNative.d.ts +10 -0
- package/dist/utils/syncNative.js +46 -0
- package/dist/utils/syncNative.js.map +1 -0
- package/dist/utils/userMetadata.d.ts +15 -0
- package/dist/utils/userMetadata.js +259 -0
- package/dist/utils/userMetadata.js.map +1 -0
- package/package.json +94 -0
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.depositReserveLiquidityAndObligationCollateral = exports.layout = void 0;
|
|
27
|
+
const web3_js_1 = require("@solana/web3.js"); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
28
|
+
const borsh = __importStar(require("@coral-xyz/borsh")); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
29
|
+
const programId_1 = require("../programId");
|
|
30
|
+
exports.layout = borsh.struct([borsh.u64("liquidityAmount")]);
|
|
31
|
+
function depositReserveLiquidityAndObligationCollateral(args, accounts, programId = programId_1.PROGRAM_ID) {
|
|
32
|
+
const keys = [
|
|
33
|
+
{ pubkey: accounts.owner, isSigner: true, isWritable: true },
|
|
34
|
+
{ pubkey: accounts.obligation, isSigner: false, isWritable: true },
|
|
35
|
+
{ pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },
|
|
36
|
+
{
|
|
37
|
+
pubkey: accounts.lendingMarketAuthority,
|
|
38
|
+
isSigner: false,
|
|
39
|
+
isWritable: false,
|
|
40
|
+
},
|
|
41
|
+
{ pubkey: accounts.reserve, isSigner: false, isWritable: true },
|
|
42
|
+
{
|
|
43
|
+
pubkey: accounts.reserveLiquiditySupply,
|
|
44
|
+
isSigner: false,
|
|
45
|
+
isWritable: true,
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
pubkey: accounts.reserveCollateralMint,
|
|
49
|
+
isSigner: false,
|
|
50
|
+
isWritable: true,
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
pubkey: accounts.reserveDestinationDepositCollateral,
|
|
54
|
+
isSigner: false,
|
|
55
|
+
isWritable: true,
|
|
56
|
+
},
|
|
57
|
+
{ pubkey: accounts.userSourceLiquidity, isSigner: false, isWritable: true },
|
|
58
|
+
{
|
|
59
|
+
pubkey: accounts.placeholderUserDestinationCollateral,
|
|
60
|
+
isSigner: false,
|
|
61
|
+
isWritable: false,
|
|
62
|
+
},
|
|
63
|
+
{ pubkey: accounts.tokenProgram, isSigner: false, isWritable: false },
|
|
64
|
+
{
|
|
65
|
+
pubkey: accounts.instructionSysvarAccount,
|
|
66
|
+
isSigner: false,
|
|
67
|
+
isWritable: false,
|
|
68
|
+
},
|
|
69
|
+
];
|
|
70
|
+
const identifier = Buffer.from([129, 199, 4, 2, 222, 39, 26, 46]);
|
|
71
|
+
const buffer = Buffer.alloc(1000);
|
|
72
|
+
const len = exports.layout.encode({
|
|
73
|
+
liquidityAmount: args.liquidityAmount,
|
|
74
|
+
}, buffer);
|
|
75
|
+
const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len);
|
|
76
|
+
const ix = new web3_js_1.TransactionInstruction({ keys, programId, data });
|
|
77
|
+
return ix;
|
|
78
|
+
}
|
|
79
|
+
exports.depositReserveLiquidityAndObligationCollateral = depositReserveLiquidityAndObligationCollateral;
|
|
80
|
+
//# sourceMappingURL=depositReserveLiquidityAndObligationCollateral.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"depositReserveLiquidityAndObligationCollateral.js","sourceRoot":"","sources":["../../../src/idl_codegen/instructions/depositReserveLiquidityAndObligationCollateral.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6CAAgF,CAAC,wDAAwD;AAEzI,wDAAyC,CAAC,wDAAwD;AAElG,4CAAyC;AAqB5B,QAAA,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAA;AAElE,SAAgB,8CAA8C,CAC5D,IAAwD,EACxD,QAAgE,EAChE,YAAuB,sBAAU;IAEjC,MAAM,IAAI,GAAuB;QAC/B,EAAE,MAAM,EAAE,QAAQ,CAAC,KAAK,EAAE,QAAQ,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE;QAC5D,EAAE,MAAM,EAAE,QAAQ,CAAC,UAAU,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAClE,EAAE,MAAM,EAAE,QAAQ,CAAC,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;QACtE;YACE,MAAM,EAAE,QAAQ,CAAC,sBAAsB;YACvC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,KAAK;SAClB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAC/D;YACE,MAAM,EAAE,QAAQ,CAAC,sBAAsB;YACvC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD;YACE,MAAM,EAAE,QAAQ,CAAC,qBAAqB;YACtC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD;YACE,MAAM,EAAE,QAAQ,CAAC,mCAAmC;YACpD,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,mBAAmB,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAC3E;YACE,MAAM,EAAE,QAAQ,CAAC,oCAAoC;YACrD,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,KAAK;SAClB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,YAAY,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;QACrE;YACE,MAAM,EAAE,QAAQ,CAAC,wBAAwB;YACzC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,KAAK;SAClB;KACF,CAAA;IACD,MAAM,UAAU,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC,EAAE,GAAG,EAAE,EAAE,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC,CAAA;IACjE,MAAM,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;IACjC,MAAM,GAAG,GAAG,cAAM,CAAC,MAAM,CACvB;QACE,eAAe,EAAE,IAAI,CAAC,eAAe;KACtC,EACD,MAAM,CACP,CAAA;IACD,MAAM,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,CAAA;IAClE,MAAM,EAAE,GAAG,IAAI,gCAAsB,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAA;IAChE,OAAO,EAAE,CAAA;AACX,CAAC;AAtDD,wGAsDC","sourcesContent":["import { TransactionInstruction, PublicKey, AccountMeta } from \"@solana/web3.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport BN from \"bn.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as borsh from \"@coral-xyz/borsh\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as types from \"../types\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport { PROGRAM_ID } from \"../programId\"\n\nexport interface DepositReserveLiquidityAndObligationCollateralArgs {\n liquidityAmount: BN\n}\n\nexport interface DepositReserveLiquidityAndObligationCollateralAccounts {\n owner: PublicKey\n obligation: PublicKey\n lendingMarket: PublicKey\n lendingMarketAuthority: PublicKey\n reserve: PublicKey\n reserveLiquiditySupply: PublicKey\n reserveCollateralMint: PublicKey\n reserveDestinationDepositCollateral: PublicKey\n userSourceLiquidity: PublicKey\n placeholderUserDestinationCollateral: PublicKey\n tokenProgram: PublicKey\n instructionSysvarAccount: PublicKey\n}\n\nexport const layout = borsh.struct([borsh.u64(\"liquidityAmount\")])\n\nexport function depositReserveLiquidityAndObligationCollateral(\n args: DepositReserveLiquidityAndObligationCollateralArgs,\n accounts: DepositReserveLiquidityAndObligationCollateralAccounts,\n programId: PublicKey = PROGRAM_ID\n) {\n const keys: Array<AccountMeta> = [\n { pubkey: accounts.owner, isSigner: true, isWritable: true },\n { pubkey: accounts.obligation, isSigner: false, isWritable: true },\n { pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },\n {\n pubkey: accounts.lendingMarketAuthority,\n isSigner: false,\n isWritable: false,\n },\n { pubkey: accounts.reserve, isSigner: false, isWritable: true },\n {\n pubkey: accounts.reserveLiquiditySupply,\n isSigner: false,\n isWritable: true,\n },\n {\n pubkey: accounts.reserveCollateralMint,\n isSigner: false,\n isWritable: true,\n },\n {\n pubkey: accounts.reserveDestinationDepositCollateral,\n isSigner: false,\n isWritable: true,\n },\n { pubkey: accounts.userSourceLiquidity, isSigner: false, isWritable: true },\n {\n pubkey: accounts.placeholderUserDestinationCollateral,\n isSigner: false,\n isWritable: false,\n },\n { pubkey: accounts.tokenProgram, isSigner: false, isWritable: false },\n {\n pubkey: accounts.instructionSysvarAccount,\n isSigner: false,\n isWritable: false,\n },\n ]\n const identifier = Buffer.from([129, 199, 4, 2, 222, 39, 26, 46])\n const buffer = Buffer.alloc(1000)\n const len = layout.encode(\n {\n liquidityAmount: args.liquidityAmount,\n },\n buffer\n )\n const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len)\n const ix = new TransactionInstruction({ keys, programId, data })\n return ix\n}\n"]}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { TransactionInstruction, PublicKey } from "@solana/web3.js";
|
|
2
|
+
import BN from "bn.js";
|
|
3
|
+
export interface FlashBorrowReserveLiquidityArgs {
|
|
4
|
+
liquidityAmount: BN;
|
|
5
|
+
}
|
|
6
|
+
export interface FlashBorrowReserveLiquidityAccounts {
|
|
7
|
+
userTransferAuthority: PublicKey;
|
|
8
|
+
lendingMarketAuthority: PublicKey;
|
|
9
|
+
lendingMarket: PublicKey;
|
|
10
|
+
reserve: PublicKey;
|
|
11
|
+
reserveSourceLiquidity: PublicKey;
|
|
12
|
+
userDestinationLiquidity: PublicKey;
|
|
13
|
+
reserveLiquidityFeeReceiver: PublicKey;
|
|
14
|
+
referrerTokenState: PublicKey;
|
|
15
|
+
referrerAccount: PublicKey;
|
|
16
|
+
sysvarInfo: PublicKey;
|
|
17
|
+
tokenProgram: PublicKey;
|
|
18
|
+
}
|
|
19
|
+
export declare const layout: any;
|
|
20
|
+
export declare function flashBorrowReserveLiquidity(args: FlashBorrowReserveLiquidityArgs, accounts: FlashBorrowReserveLiquidityAccounts, programId?: PublicKey): TransactionInstruction;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.flashBorrowReserveLiquidity = exports.layout = void 0;
|
|
27
|
+
const web3_js_1 = require("@solana/web3.js"); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
28
|
+
const borsh = __importStar(require("@coral-xyz/borsh")); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
29
|
+
const programId_1 = require("../programId");
|
|
30
|
+
exports.layout = borsh.struct([borsh.u64("liquidityAmount")]);
|
|
31
|
+
function flashBorrowReserveLiquidity(args, accounts, programId = programId_1.PROGRAM_ID) {
|
|
32
|
+
const keys = [
|
|
33
|
+
{
|
|
34
|
+
pubkey: accounts.userTransferAuthority,
|
|
35
|
+
isSigner: true,
|
|
36
|
+
isWritable: false,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
pubkey: accounts.lendingMarketAuthority,
|
|
40
|
+
isSigner: false,
|
|
41
|
+
isWritable: false,
|
|
42
|
+
},
|
|
43
|
+
{ pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },
|
|
44
|
+
{ pubkey: accounts.reserve, isSigner: false, isWritable: true },
|
|
45
|
+
{
|
|
46
|
+
pubkey: accounts.reserveSourceLiquidity,
|
|
47
|
+
isSigner: false,
|
|
48
|
+
isWritable: true,
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
pubkey: accounts.userDestinationLiquidity,
|
|
52
|
+
isSigner: false,
|
|
53
|
+
isWritable: true,
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
pubkey: accounts.reserveLiquidityFeeReceiver,
|
|
57
|
+
isSigner: false,
|
|
58
|
+
isWritable: true,
|
|
59
|
+
},
|
|
60
|
+
{ pubkey: accounts.referrerTokenState, isSigner: false, isWritable: true },
|
|
61
|
+
{ pubkey: accounts.referrerAccount, isSigner: false, isWritable: true },
|
|
62
|
+
{ pubkey: accounts.sysvarInfo, isSigner: false, isWritable: false },
|
|
63
|
+
{ pubkey: accounts.tokenProgram, isSigner: false, isWritable: false },
|
|
64
|
+
];
|
|
65
|
+
const identifier = Buffer.from([135, 231, 52, 167, 7, 52, 212, 193]);
|
|
66
|
+
const buffer = Buffer.alloc(1000);
|
|
67
|
+
const len = exports.layout.encode({
|
|
68
|
+
liquidityAmount: args.liquidityAmount,
|
|
69
|
+
}, buffer);
|
|
70
|
+
const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len);
|
|
71
|
+
const ix = new web3_js_1.TransactionInstruction({ keys, programId, data });
|
|
72
|
+
return ix;
|
|
73
|
+
}
|
|
74
|
+
exports.flashBorrowReserveLiquidity = flashBorrowReserveLiquidity;
|
|
75
|
+
//# sourceMappingURL=flashBorrowReserveLiquidity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flashBorrowReserveLiquidity.js","sourceRoot":"","sources":["../../../src/idl_codegen/instructions/flashBorrowReserveLiquidity.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6CAAgF,CAAC,wDAAwD;AAEzI,wDAAyC,CAAC,wDAAwD;AAElG,4CAAyC;AAoB5B,QAAA,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC,CAAC,CAAA;AAElE,SAAgB,2BAA2B,CACzC,IAAqC,EACrC,QAA6C,EAC7C,YAAuB,sBAAU;IAEjC,MAAM,IAAI,GAAuB;QAC/B;YACE,MAAM,EAAE,QAAQ,CAAC,qBAAqB;YACtC,QAAQ,EAAE,IAAI;YACd,UAAU,EAAE,KAAK;SAClB;QACD;YACE,MAAM,EAAE,QAAQ,CAAC,sBAAsB;YACvC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,KAAK;SAClB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;QACtE,EAAE,MAAM,EAAE,QAAQ,CAAC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAC/D;YACE,MAAM,EAAE,QAAQ,CAAC,sBAAsB;YACvC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD;YACE,MAAM,EAAE,QAAQ,CAAC,wBAAwB;YACzC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD;YACE,MAAM,EAAE,QAAQ,CAAC,2BAA2B;YAC5C,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,kBAAkB,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAC1E,EAAE,MAAM,EAAE,QAAQ,CAAC,eAAe,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QACvE,EAAE,MAAM,EAAE,QAAQ,CAAC,UAAU,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;QACnE,EAAE,MAAM,EAAE,QAAQ,CAAC,YAAY,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;KACtE,CAAA;IACD,MAAM,UAAU,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC,CAAA;IACpE,MAAM,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;IACjC,MAAM,GAAG,GAAG,cAAM,CAAC,MAAM,CACvB;QACE,eAAe,EAAE,IAAI,CAAC,eAAe;KACtC,EACD,MAAM,CACP,CAAA;IACD,MAAM,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,CAAA;IAClE,MAAM,EAAE,GAAG,IAAI,gCAAsB,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAA;IAChE,OAAO,EAAE,CAAA;AACX,CAAC;AAjDD,kEAiDC","sourcesContent":["import { TransactionInstruction, PublicKey, AccountMeta } from \"@solana/web3.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport BN from \"bn.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as borsh from \"@coral-xyz/borsh\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as types from \"../types\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport { PROGRAM_ID } from \"../programId\"\n\nexport interface FlashBorrowReserveLiquidityArgs {\n liquidityAmount: BN\n}\n\nexport interface FlashBorrowReserveLiquidityAccounts {\n userTransferAuthority: PublicKey\n lendingMarketAuthority: PublicKey\n lendingMarket: PublicKey\n reserve: PublicKey\n reserveSourceLiquidity: PublicKey\n userDestinationLiquidity: PublicKey\n reserveLiquidityFeeReceiver: PublicKey\n referrerTokenState: PublicKey\n referrerAccount: PublicKey\n sysvarInfo: PublicKey\n tokenProgram: PublicKey\n}\n\nexport const layout = borsh.struct([borsh.u64(\"liquidityAmount\")])\n\nexport function flashBorrowReserveLiquidity(\n args: FlashBorrowReserveLiquidityArgs,\n accounts: FlashBorrowReserveLiquidityAccounts,\n programId: PublicKey = PROGRAM_ID\n) {\n const keys: Array<AccountMeta> = [\n {\n pubkey: accounts.userTransferAuthority,\n isSigner: true,\n isWritable: false,\n },\n {\n pubkey: accounts.lendingMarketAuthority,\n isSigner: false,\n isWritable: false,\n },\n { pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },\n { pubkey: accounts.reserve, isSigner: false, isWritable: true },\n {\n pubkey: accounts.reserveSourceLiquidity,\n isSigner: false,\n isWritable: true,\n },\n {\n pubkey: accounts.userDestinationLiquidity,\n isSigner: false,\n isWritable: true,\n },\n {\n pubkey: accounts.reserveLiquidityFeeReceiver,\n isSigner: false,\n isWritable: true,\n },\n { pubkey: accounts.referrerTokenState, isSigner: false, isWritable: true },\n { pubkey: accounts.referrerAccount, isSigner: false, isWritable: true },\n { pubkey: accounts.sysvarInfo, isSigner: false, isWritable: false },\n { pubkey: accounts.tokenProgram, isSigner: false, isWritable: false },\n ]\n const identifier = Buffer.from([135, 231, 52, 167, 7, 52, 212, 193])\n const buffer = Buffer.alloc(1000)\n const len = layout.encode(\n {\n liquidityAmount: args.liquidityAmount,\n },\n buffer\n )\n const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len)\n const ix = new TransactionInstruction({ keys, programId, data })\n return ix\n}\n"]}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { TransactionInstruction, PublicKey } from "@solana/web3.js";
|
|
2
|
+
import BN from "bn.js";
|
|
3
|
+
export interface FlashRepayReserveLiquidityArgs {
|
|
4
|
+
liquidityAmount: BN;
|
|
5
|
+
borrowInstructionIndex: number;
|
|
6
|
+
}
|
|
7
|
+
export interface FlashRepayReserveLiquidityAccounts {
|
|
8
|
+
userTransferAuthority: PublicKey;
|
|
9
|
+
lendingMarketAuthority: PublicKey;
|
|
10
|
+
lendingMarket: PublicKey;
|
|
11
|
+
reserve: PublicKey;
|
|
12
|
+
reserveDestinationLiquidity: PublicKey;
|
|
13
|
+
userSourceLiquidity: PublicKey;
|
|
14
|
+
reserveLiquidityFeeReceiver: PublicKey;
|
|
15
|
+
referrerTokenState: PublicKey;
|
|
16
|
+
referrerAccount: PublicKey;
|
|
17
|
+
sysvarInfo: PublicKey;
|
|
18
|
+
tokenProgram: PublicKey;
|
|
19
|
+
}
|
|
20
|
+
export declare const layout: any;
|
|
21
|
+
export declare function flashRepayReserveLiquidity(args: FlashRepayReserveLiquidityArgs, accounts: FlashRepayReserveLiquidityAccounts, programId?: PublicKey): TransactionInstruction;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.flashRepayReserveLiquidity = exports.layout = void 0;
|
|
27
|
+
const web3_js_1 = require("@solana/web3.js"); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
28
|
+
const borsh = __importStar(require("@coral-xyz/borsh")); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
29
|
+
const programId_1 = require("../programId");
|
|
30
|
+
exports.layout = borsh.struct([
|
|
31
|
+
borsh.u64("liquidityAmount"),
|
|
32
|
+
borsh.u8("borrowInstructionIndex"),
|
|
33
|
+
]);
|
|
34
|
+
function flashRepayReserveLiquidity(args, accounts, programId = programId_1.PROGRAM_ID) {
|
|
35
|
+
const keys = [
|
|
36
|
+
{
|
|
37
|
+
pubkey: accounts.userTransferAuthority,
|
|
38
|
+
isSigner: true,
|
|
39
|
+
isWritable: false,
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
pubkey: accounts.lendingMarketAuthority,
|
|
43
|
+
isSigner: false,
|
|
44
|
+
isWritable: false,
|
|
45
|
+
},
|
|
46
|
+
{ pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },
|
|
47
|
+
{ pubkey: accounts.reserve, isSigner: false, isWritable: true },
|
|
48
|
+
{
|
|
49
|
+
pubkey: accounts.reserveDestinationLiquidity,
|
|
50
|
+
isSigner: false,
|
|
51
|
+
isWritable: true,
|
|
52
|
+
},
|
|
53
|
+
{ pubkey: accounts.userSourceLiquidity, isSigner: false, isWritable: true },
|
|
54
|
+
{
|
|
55
|
+
pubkey: accounts.reserveLiquidityFeeReceiver,
|
|
56
|
+
isSigner: false,
|
|
57
|
+
isWritable: true,
|
|
58
|
+
},
|
|
59
|
+
{ pubkey: accounts.referrerTokenState, isSigner: false, isWritable: true },
|
|
60
|
+
{ pubkey: accounts.referrerAccount, isSigner: false, isWritable: true },
|
|
61
|
+
{ pubkey: accounts.sysvarInfo, isSigner: false, isWritable: false },
|
|
62
|
+
{ pubkey: accounts.tokenProgram, isSigner: false, isWritable: false },
|
|
63
|
+
];
|
|
64
|
+
const identifier = Buffer.from([185, 117, 0, 203, 96, 245, 180, 186]);
|
|
65
|
+
const buffer = Buffer.alloc(1000);
|
|
66
|
+
const len = exports.layout.encode({
|
|
67
|
+
liquidityAmount: args.liquidityAmount,
|
|
68
|
+
borrowInstructionIndex: args.borrowInstructionIndex,
|
|
69
|
+
}, buffer);
|
|
70
|
+
const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len);
|
|
71
|
+
const ix = new web3_js_1.TransactionInstruction({ keys, programId, data });
|
|
72
|
+
return ix;
|
|
73
|
+
}
|
|
74
|
+
exports.flashRepayReserveLiquidity = flashRepayReserveLiquidity;
|
|
75
|
+
//# sourceMappingURL=flashRepayReserveLiquidity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"flashRepayReserveLiquidity.js","sourceRoot":"","sources":["../../../src/idl_codegen/instructions/flashRepayReserveLiquidity.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6CAAgF,CAAC,wDAAwD;AAEzI,wDAAyC,CAAC,wDAAwD;AAElG,4CAAyC;AAqB5B,QAAA,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC;IACjC,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC;IAC5B,KAAK,CAAC,EAAE,CAAC,wBAAwB,CAAC;CACnC,CAAC,CAAA;AAEF,SAAgB,0BAA0B,CACxC,IAAoC,EACpC,QAA4C,EAC5C,YAAuB,sBAAU;IAEjC,MAAM,IAAI,GAAuB;QAC/B;YACE,MAAM,EAAE,QAAQ,CAAC,qBAAqB;YACtC,QAAQ,EAAE,IAAI;YACd,UAAU,EAAE,KAAK;SAClB;QACD;YACE,MAAM,EAAE,QAAQ,CAAC,sBAAsB;YACvC,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,KAAK;SAClB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;QACtE,EAAE,MAAM,EAAE,QAAQ,CAAC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAC/D;YACE,MAAM,EAAE,QAAQ,CAAC,2BAA2B;YAC5C,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,mBAAmB,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAC3E;YACE,MAAM,EAAE,QAAQ,CAAC,2BAA2B;YAC5C,QAAQ,EAAE,KAAK;YACf,UAAU,EAAE,IAAI;SACjB;QACD,EAAE,MAAM,EAAE,QAAQ,CAAC,kBAAkB,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QAC1E,EAAE,MAAM,EAAE,QAAQ,CAAC,eAAe,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;QACvE,EAAE,MAAM,EAAE,QAAQ,CAAC,UAAU,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;QACnE,EAAE,MAAM,EAAE,QAAQ,CAAC,YAAY,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;KACtE,CAAA;IACD,MAAM,UAAU,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC,CAAA;IACrE,MAAM,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;IACjC,MAAM,GAAG,GAAG,cAAM,CAAC,MAAM,CACvB;QACE,eAAe,EAAE,IAAI,CAAC,eAAe;QACrC,sBAAsB,EAAE,IAAI,CAAC,sBAAsB;KACpD,EACD,MAAM,CACP,CAAA;IACD,MAAM,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,CAAA;IAClE,MAAM,EAAE,GAAG,IAAI,gCAAsB,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAA;IAChE,OAAO,EAAE,CAAA;AACX,CAAC;AA9CD,gEA8CC","sourcesContent":["import { TransactionInstruction, PublicKey, AccountMeta } from \"@solana/web3.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport BN from \"bn.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as borsh from \"@coral-xyz/borsh\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as types from \"../types\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport { PROGRAM_ID } from \"../programId\"\n\nexport interface FlashRepayReserveLiquidityArgs {\n liquidityAmount: BN\n borrowInstructionIndex: number\n}\n\nexport interface FlashRepayReserveLiquidityAccounts {\n userTransferAuthority: PublicKey\n lendingMarketAuthority: PublicKey\n lendingMarket: PublicKey\n reserve: PublicKey\n reserveDestinationLiquidity: PublicKey\n userSourceLiquidity: PublicKey\n reserveLiquidityFeeReceiver: PublicKey\n referrerTokenState: PublicKey\n referrerAccount: PublicKey\n sysvarInfo: PublicKey\n tokenProgram: PublicKey\n}\n\nexport const layout = borsh.struct([\n borsh.u64(\"liquidityAmount\"),\n borsh.u8(\"borrowInstructionIndex\"),\n])\n\nexport function flashRepayReserveLiquidity(\n args: FlashRepayReserveLiquidityArgs,\n accounts: FlashRepayReserveLiquidityAccounts,\n programId: PublicKey = PROGRAM_ID\n) {\n const keys: Array<AccountMeta> = [\n {\n pubkey: accounts.userTransferAuthority,\n isSigner: true,\n isWritable: false,\n },\n {\n pubkey: accounts.lendingMarketAuthority,\n isSigner: false,\n isWritable: false,\n },\n { pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },\n { pubkey: accounts.reserve, isSigner: false, isWritable: true },\n {\n pubkey: accounts.reserveDestinationLiquidity,\n isSigner: false,\n isWritable: true,\n },\n { pubkey: accounts.userSourceLiquidity, isSigner: false, isWritable: true },\n {\n pubkey: accounts.reserveLiquidityFeeReceiver,\n isSigner: false,\n isWritable: true,\n },\n { pubkey: accounts.referrerTokenState, isSigner: false, isWritable: true },\n { pubkey: accounts.referrerAccount, isSigner: false, isWritable: true },\n { pubkey: accounts.sysvarInfo, isSigner: false, isWritable: false },\n { pubkey: accounts.tokenProgram, isSigner: false, isWritable: false },\n ]\n const identifier = Buffer.from([185, 117, 0, 203, 96, 245, 180, 186])\n const buffer = Buffer.alloc(1000)\n const len = layout.encode(\n {\n liquidityAmount: args.liquidityAmount,\n borrowInstructionIndex: args.borrowInstructionIndex,\n },\n buffer\n )\n const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len)\n const ix = new TransactionInstruction({ keys, programId, data })\n return ix\n}\n"]}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { TransactionInstruction, PublicKey } from "@solana/web3.js";
|
|
2
|
+
import * as types from "../types";
|
|
3
|
+
export interface IdlMissingTypesArgs {
|
|
4
|
+
reserveFarmKind: types.ReserveFarmKindKind;
|
|
5
|
+
assetTier: types.AssetTierKind;
|
|
6
|
+
feeCalculation: types.FeeCalculationKind;
|
|
7
|
+
reserveStatus: types.ReserveStatusKind;
|
|
8
|
+
updateConfigMode: types.UpdateConfigModeKind;
|
|
9
|
+
updateLendingMarketConfigValue: types.UpdateLendingMarketConfigValueKind;
|
|
10
|
+
updateLendingMarketConfigMode: types.UpdateLendingMarketModeKind;
|
|
11
|
+
}
|
|
12
|
+
export interface IdlMissingTypesAccounts {
|
|
13
|
+
lendingMarketOwner: PublicKey;
|
|
14
|
+
lendingMarket: PublicKey;
|
|
15
|
+
reserve: PublicKey;
|
|
16
|
+
}
|
|
17
|
+
export declare const layout: any;
|
|
18
|
+
export declare function idlMissingTypes(args: IdlMissingTypesArgs, accounts: IdlMissingTypesAccounts, programId?: PublicKey): TransactionInstruction;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
+
exports.idlMissingTypes = exports.layout = void 0;
|
|
27
|
+
const web3_js_1 = require("@solana/web3.js"); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
28
|
+
const borsh = __importStar(require("@coral-xyz/borsh")); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
29
|
+
const types = __importStar(require("../types")); // eslint-disable-line @typescript-eslint/no-unused-vars
|
|
30
|
+
const programId_1 = require("../programId");
|
|
31
|
+
exports.layout = borsh.struct([
|
|
32
|
+
types.ReserveFarmKind.layout("reserveFarmKind"),
|
|
33
|
+
types.AssetTier.layout("assetTier"),
|
|
34
|
+
types.FeeCalculation.layout("feeCalculation"),
|
|
35
|
+
types.ReserveStatus.layout("reserveStatus"),
|
|
36
|
+
types.UpdateConfigMode.layout("updateConfigMode"),
|
|
37
|
+
types.UpdateLendingMarketConfigValue.layout("updateLendingMarketConfigValue"),
|
|
38
|
+
types.UpdateLendingMarketMode.layout("updateLendingMarketConfigMode"),
|
|
39
|
+
]);
|
|
40
|
+
function idlMissingTypes(args, accounts, programId = programId_1.PROGRAM_ID) {
|
|
41
|
+
const keys = [
|
|
42
|
+
{ pubkey: accounts.lendingMarketOwner, isSigner: true, isWritable: false },
|
|
43
|
+
{ pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },
|
|
44
|
+
{ pubkey: accounts.reserve, isSigner: false, isWritable: true },
|
|
45
|
+
];
|
|
46
|
+
const identifier = Buffer.from([130, 80, 38, 153, 80, 212, 182, 253]);
|
|
47
|
+
const buffer = Buffer.alloc(1000);
|
|
48
|
+
const len = exports.layout.encode({
|
|
49
|
+
reserveFarmKind: args.reserveFarmKind.toEncodable(),
|
|
50
|
+
assetTier: args.assetTier.toEncodable(),
|
|
51
|
+
feeCalculation: args.feeCalculation.toEncodable(),
|
|
52
|
+
reserveStatus: args.reserveStatus.toEncodable(),
|
|
53
|
+
updateConfigMode: args.updateConfigMode.toEncodable(),
|
|
54
|
+
updateLendingMarketConfigValue: args.updateLendingMarketConfigValue.toEncodable(),
|
|
55
|
+
updateLendingMarketConfigMode: args.updateLendingMarketConfigMode.toEncodable(),
|
|
56
|
+
}, buffer);
|
|
57
|
+
const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len);
|
|
58
|
+
const ix = new web3_js_1.TransactionInstruction({ keys, programId, data });
|
|
59
|
+
return ix;
|
|
60
|
+
}
|
|
61
|
+
exports.idlMissingTypes = idlMissingTypes;
|
|
62
|
+
//# sourceMappingURL=idlMissingTypes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"idlMissingTypes.js","sourceRoot":"","sources":["../../../src/idl_codegen/instructions/idlMissingTypes.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6CAAgF,CAAC,wDAAwD;AAEzI,wDAAyC,CAAC,wDAAwD;AAClG,gDAAiC,CAAC,wDAAwD;AAC1F,4CAAyC;AAkB5B,QAAA,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC;IACjC,KAAK,CAAC,eAAe,CAAC,MAAM,CAAC,iBAAiB,CAAC;IAC/C,KAAK,CAAC,SAAS,CAAC,MAAM,CAAC,WAAW,CAAC;IACnC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,gBAAgB,CAAC;IAC7C,KAAK,CAAC,aAAa,CAAC,MAAM,CAAC,eAAe,CAAC;IAC3C,KAAK,CAAC,gBAAgB,CAAC,MAAM,CAAC,kBAAkB,CAAC;IACjD,KAAK,CAAC,8BAA8B,CAAC,MAAM,CAAC,gCAAgC,CAAC;IAC7E,KAAK,CAAC,uBAAuB,CAAC,MAAM,CAAC,+BAA+B,CAAC;CACtE,CAAC,CAAA;AAEF,SAAgB,eAAe,CAC7B,IAAyB,EACzB,QAAiC,EACjC,YAAuB,sBAAU;IAEjC,MAAM,IAAI,GAAuB;QAC/B,EAAE,MAAM,EAAE,QAAQ,CAAC,kBAAkB,EAAE,QAAQ,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE;QAC1E,EAAE,MAAM,EAAE,QAAQ,CAAC,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE;QACtE,EAAE,MAAM,EAAE,QAAQ,CAAC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE;KAChE,CAAA;IACD,MAAM,UAAU,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,EAAE,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC,CAAA;IACrE,MAAM,MAAM,GAAG,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;IACjC,MAAM,GAAG,GAAG,cAAM,CAAC,MAAM,CACvB;QACE,eAAe,EAAE,IAAI,CAAC,eAAe,CAAC,WAAW,EAAE;QACnD,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,WAAW,EAAE;QACvC,cAAc,EAAE,IAAI,CAAC,cAAc,CAAC,WAAW,EAAE;QACjD,aAAa,EAAE,IAAI,CAAC,aAAa,CAAC,WAAW,EAAE;QAC/C,gBAAgB,EAAE,IAAI,CAAC,gBAAgB,CAAC,WAAW,EAAE;QACrD,8BAA8B,EAC5B,IAAI,CAAC,8BAA8B,CAAC,WAAW,EAAE;QACnD,6BAA6B,EAC3B,IAAI,CAAC,6BAA6B,CAAC,WAAW,EAAE;KACnD,EACD,MAAM,CACP,CAAA;IACD,MAAM,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,UAAU,EAAE,MAAM,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,GAAG,GAAG,CAAC,CAAA;IAClE,MAAM,EAAE,GAAG,IAAI,gCAAsB,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAA;IAChE,OAAO,EAAE,CAAA;AACX,CAAC;AA7BD,0CA6BC","sourcesContent":["import { TransactionInstruction, PublicKey, AccountMeta } from \"@solana/web3.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport BN from \"bn.js\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as borsh from \"@coral-xyz/borsh\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport * as types from \"../types\" // eslint-disable-line @typescript-eslint/no-unused-vars\nimport { PROGRAM_ID } from \"../programId\"\n\nexport interface IdlMissingTypesArgs {\n reserveFarmKind: types.ReserveFarmKindKind\n assetTier: types.AssetTierKind\n feeCalculation: types.FeeCalculationKind\n reserveStatus: types.ReserveStatusKind\n updateConfigMode: types.UpdateConfigModeKind\n updateLendingMarketConfigValue: types.UpdateLendingMarketConfigValueKind\n updateLendingMarketConfigMode: types.UpdateLendingMarketModeKind\n}\n\nexport interface IdlMissingTypesAccounts {\n lendingMarketOwner: PublicKey\n lendingMarket: PublicKey\n reserve: PublicKey\n}\n\nexport const layout = borsh.struct([\n types.ReserveFarmKind.layout(\"reserveFarmKind\"),\n types.AssetTier.layout(\"assetTier\"),\n types.FeeCalculation.layout(\"feeCalculation\"),\n types.ReserveStatus.layout(\"reserveStatus\"),\n types.UpdateConfigMode.layout(\"updateConfigMode\"),\n types.UpdateLendingMarketConfigValue.layout(\"updateLendingMarketConfigValue\"),\n types.UpdateLendingMarketMode.layout(\"updateLendingMarketConfigMode\"),\n])\n\nexport function idlMissingTypes(\n args: IdlMissingTypesArgs,\n accounts: IdlMissingTypesAccounts,\n programId: PublicKey = PROGRAM_ID\n) {\n const keys: Array<AccountMeta> = [\n { pubkey: accounts.lendingMarketOwner, isSigner: true, isWritable: false },\n { pubkey: accounts.lendingMarket, isSigner: false, isWritable: false },\n { pubkey: accounts.reserve, isSigner: false, isWritable: true },\n ]\n const identifier = Buffer.from([130, 80, 38, 153, 80, 212, 182, 253])\n const buffer = Buffer.alloc(1000)\n const len = layout.encode(\n {\n reserveFarmKind: args.reserveFarmKind.toEncodable(),\n assetTier: args.assetTier.toEncodable(),\n feeCalculation: args.feeCalculation.toEncodable(),\n reserveStatus: args.reserveStatus.toEncodable(),\n updateConfigMode: args.updateConfigMode.toEncodable(),\n updateLendingMarketConfigValue:\n args.updateLendingMarketConfigValue.toEncodable(),\n updateLendingMarketConfigMode:\n args.updateLendingMarketConfigMode.toEncodable(),\n },\n buffer\n )\n const data = Buffer.concat([identifier, buffer]).slice(0, 8 + len)\n const ix = new TransactionInstruction({ keys, programId, data })\n return ix\n}\n"]}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
export { initLendingMarket } from "./initLendingMarket";
|
|
2
|
+
export type { InitLendingMarketArgs, InitLendingMarketAccounts, } from "./initLendingMarket";
|
|
3
|
+
export { updateLendingMarket } from "./updateLendingMarket";
|
|
4
|
+
export type { UpdateLendingMarketArgs, UpdateLendingMarketAccounts, } from "./updateLendingMarket";
|
|
5
|
+
export { updateLendingMarketOwner } from "./updateLendingMarketOwner";
|
|
6
|
+
export type { UpdateLendingMarketOwnerAccounts } from "./updateLendingMarketOwner";
|
|
7
|
+
export { initReserve } from "./initReserve";
|
|
8
|
+
export type { InitReserveAccounts } from "./initReserve";
|
|
9
|
+
export { initFarmsForReserve } from "./initFarmsForReserve";
|
|
10
|
+
export type { InitFarmsForReserveArgs, InitFarmsForReserveAccounts, } from "./initFarmsForReserve";
|
|
11
|
+
export { updateSingleReserveConfig } from "./updateSingleReserveConfig";
|
|
12
|
+
export type { UpdateSingleReserveConfigArgs, UpdateSingleReserveConfigAccounts, } from "./updateSingleReserveConfig";
|
|
13
|
+
export { updateEntireReserveConfig } from "./updateEntireReserveConfig";
|
|
14
|
+
export type { UpdateEntireReserveConfigArgs, UpdateEntireReserveConfigAccounts, } from "./updateEntireReserveConfig";
|
|
15
|
+
export { refreshReserve } from "./refreshReserve";
|
|
16
|
+
export type { RefreshReserveAccounts } from "./refreshReserve";
|
|
17
|
+
export { depositReserveLiquidity } from "./depositReserveLiquidity";
|
|
18
|
+
export type { DepositReserveLiquidityArgs, DepositReserveLiquidityAccounts, } from "./depositReserveLiquidity";
|
|
19
|
+
export { redeemReserveCollateral } from "./redeemReserveCollateral";
|
|
20
|
+
export type { RedeemReserveCollateralArgs, RedeemReserveCollateralAccounts, } from "./redeemReserveCollateral";
|
|
21
|
+
export { initObligation } from "./initObligation";
|
|
22
|
+
export type { InitObligationArgs, InitObligationAccounts, } from "./initObligation";
|
|
23
|
+
export { initObligationFarmsForReserve } from "./initObligationFarmsForReserve";
|
|
24
|
+
export type { InitObligationFarmsForReserveArgs, InitObligationFarmsForReserveAccounts, } from "./initObligationFarmsForReserve";
|
|
25
|
+
export { refreshObligationFarmsForReserve } from "./refreshObligationFarmsForReserve";
|
|
26
|
+
export type { RefreshObligationFarmsForReserveArgs, RefreshObligationFarmsForReserveAccounts, } from "./refreshObligationFarmsForReserve";
|
|
27
|
+
export { refreshObligation } from "./refreshObligation";
|
|
28
|
+
export type { RefreshObligationAccounts } from "./refreshObligation";
|
|
29
|
+
export { depositObligationCollateral } from "./depositObligationCollateral";
|
|
30
|
+
export type { DepositObligationCollateralArgs, DepositObligationCollateralAccounts, } from "./depositObligationCollateral";
|
|
31
|
+
export { withdrawObligationCollateral } from "./withdrawObligationCollateral";
|
|
32
|
+
export type { WithdrawObligationCollateralArgs, WithdrawObligationCollateralAccounts, } from "./withdrawObligationCollateral";
|
|
33
|
+
export { borrowObligationLiquidity } from "./borrowObligationLiquidity";
|
|
34
|
+
export type { BorrowObligationLiquidityArgs, BorrowObligationLiquidityAccounts, } from "./borrowObligationLiquidity";
|
|
35
|
+
export { repayObligationLiquidity } from "./repayObligationLiquidity";
|
|
36
|
+
export type { RepayObligationLiquidityArgs, RepayObligationLiquidityAccounts, } from "./repayObligationLiquidity";
|
|
37
|
+
export { depositReserveLiquidityAndObligationCollateral } from "./depositReserveLiquidityAndObligationCollateral";
|
|
38
|
+
export type { DepositReserveLiquidityAndObligationCollateralArgs, DepositReserveLiquidityAndObligationCollateralAccounts, } from "./depositReserveLiquidityAndObligationCollateral";
|
|
39
|
+
export { withdrawObligationCollateralAndRedeemReserveCollateral } from "./withdrawObligationCollateralAndRedeemReserveCollateral";
|
|
40
|
+
export type { WithdrawObligationCollateralAndRedeemReserveCollateralArgs, WithdrawObligationCollateralAndRedeemReserveCollateralAccounts, } from "./withdrawObligationCollateralAndRedeemReserveCollateral";
|
|
41
|
+
export { liquidateObligationAndRedeemReserveCollateral } from "./liquidateObligationAndRedeemReserveCollateral";
|
|
42
|
+
export type { LiquidateObligationAndRedeemReserveCollateralArgs, LiquidateObligationAndRedeemReserveCollateralAccounts, } from "./liquidateObligationAndRedeemReserveCollateral";
|
|
43
|
+
export { redeemFees } from "./redeemFees";
|
|
44
|
+
export type { RedeemFeesAccounts } from "./redeemFees";
|
|
45
|
+
export { flashRepayReserveLiquidity } from "./flashRepayReserveLiquidity";
|
|
46
|
+
export type { FlashRepayReserveLiquidityArgs, FlashRepayReserveLiquidityAccounts, } from "./flashRepayReserveLiquidity";
|
|
47
|
+
export { flashBorrowReserveLiquidity } from "./flashBorrowReserveLiquidity";
|
|
48
|
+
export type { FlashBorrowReserveLiquidityArgs, FlashBorrowReserveLiquidityAccounts, } from "./flashBorrowReserveLiquidity";
|
|
49
|
+
export { socializeLoss } from "./socializeLoss";
|
|
50
|
+
export type { SocializeLossArgs, SocializeLossAccounts } from "./socializeLoss";
|
|
51
|
+
export { requestElevationGroup } from "./requestElevationGroup";
|
|
52
|
+
export type { RequestElevationGroupArgs, RequestElevationGroupAccounts, } from "./requestElevationGroup";
|
|
53
|
+
export { initReferrerTokenState } from "./initReferrerTokenState";
|
|
54
|
+
export type { InitReferrerTokenStateArgs, InitReferrerTokenStateAccounts, } from "./initReferrerTokenState";
|
|
55
|
+
export { initUserMetadata } from "./initUserMetadata";
|
|
56
|
+
export type { InitUserMetadataArgs, InitUserMetadataAccounts, } from "./initUserMetadata";
|
|
57
|
+
export { withdrawReferrerFees } from "./withdrawReferrerFees";
|
|
58
|
+
export type { WithdrawReferrerFeesAccounts } from "./withdrawReferrerFees";
|
|
59
|
+
export { withdrawProtocolFee } from "./withdrawProtocolFee";
|
|
60
|
+
export type { WithdrawProtocolFeeArgs, WithdrawProtocolFeeAccounts, } from "./withdrawProtocolFee";
|
|
61
|
+
export { initReferrerStateAndShortUrl } from "./initReferrerStateAndShortUrl";
|
|
62
|
+
export type { InitReferrerStateAndShortUrlArgs, InitReferrerStateAndShortUrlAccounts, } from "./initReferrerStateAndShortUrl";
|
|
63
|
+
export { deleteReferrerStateAndShortUrl } from "./deleteReferrerStateAndShortUrl";
|
|
64
|
+
export type { DeleteReferrerStateAndShortUrlAccounts } from "./deleteReferrerStateAndShortUrl";
|
|
65
|
+
export { idlMissingTypes } from "./idlMissingTypes";
|
|
66
|
+
export type { IdlMissingTypesArgs, IdlMissingTypesAccounts, } from "./idlMissingTypes";
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.idlMissingTypes = exports.deleteReferrerStateAndShortUrl = exports.initReferrerStateAndShortUrl = exports.withdrawProtocolFee = exports.withdrawReferrerFees = exports.initUserMetadata = exports.initReferrerTokenState = exports.requestElevationGroup = exports.socializeLoss = exports.flashBorrowReserveLiquidity = exports.flashRepayReserveLiquidity = exports.redeemFees = exports.liquidateObligationAndRedeemReserveCollateral = exports.withdrawObligationCollateralAndRedeemReserveCollateral = exports.depositReserveLiquidityAndObligationCollateral = exports.repayObligationLiquidity = exports.borrowObligationLiquidity = exports.withdrawObligationCollateral = exports.depositObligationCollateral = exports.refreshObligation = exports.refreshObligationFarmsForReserve = exports.initObligationFarmsForReserve = exports.initObligation = exports.redeemReserveCollateral = exports.depositReserveLiquidity = exports.refreshReserve = exports.updateEntireReserveConfig = exports.updateSingleReserveConfig = exports.initFarmsForReserve = exports.initReserve = exports.updateLendingMarketOwner = exports.updateLendingMarket = exports.initLendingMarket = void 0;
|
|
4
|
+
var initLendingMarket_1 = require("./initLendingMarket");
|
|
5
|
+
Object.defineProperty(exports, "initLendingMarket", { enumerable: true, get: function () { return initLendingMarket_1.initLendingMarket; } });
|
|
6
|
+
var updateLendingMarket_1 = require("./updateLendingMarket");
|
|
7
|
+
Object.defineProperty(exports, "updateLendingMarket", { enumerable: true, get: function () { return updateLendingMarket_1.updateLendingMarket; } });
|
|
8
|
+
var updateLendingMarketOwner_1 = require("./updateLendingMarketOwner");
|
|
9
|
+
Object.defineProperty(exports, "updateLendingMarketOwner", { enumerable: true, get: function () { return updateLendingMarketOwner_1.updateLendingMarketOwner; } });
|
|
10
|
+
var initReserve_1 = require("./initReserve");
|
|
11
|
+
Object.defineProperty(exports, "initReserve", { enumerable: true, get: function () { return initReserve_1.initReserve; } });
|
|
12
|
+
var initFarmsForReserve_1 = require("./initFarmsForReserve");
|
|
13
|
+
Object.defineProperty(exports, "initFarmsForReserve", { enumerable: true, get: function () { return initFarmsForReserve_1.initFarmsForReserve; } });
|
|
14
|
+
var updateSingleReserveConfig_1 = require("./updateSingleReserveConfig");
|
|
15
|
+
Object.defineProperty(exports, "updateSingleReserveConfig", { enumerable: true, get: function () { return updateSingleReserveConfig_1.updateSingleReserveConfig; } });
|
|
16
|
+
var updateEntireReserveConfig_1 = require("./updateEntireReserveConfig");
|
|
17
|
+
Object.defineProperty(exports, "updateEntireReserveConfig", { enumerable: true, get: function () { return updateEntireReserveConfig_1.updateEntireReserveConfig; } });
|
|
18
|
+
var refreshReserve_1 = require("./refreshReserve");
|
|
19
|
+
Object.defineProperty(exports, "refreshReserve", { enumerable: true, get: function () { return refreshReserve_1.refreshReserve; } });
|
|
20
|
+
var depositReserveLiquidity_1 = require("./depositReserveLiquidity");
|
|
21
|
+
Object.defineProperty(exports, "depositReserveLiquidity", { enumerable: true, get: function () { return depositReserveLiquidity_1.depositReserveLiquidity; } });
|
|
22
|
+
var redeemReserveCollateral_1 = require("./redeemReserveCollateral");
|
|
23
|
+
Object.defineProperty(exports, "redeemReserveCollateral", { enumerable: true, get: function () { return redeemReserveCollateral_1.redeemReserveCollateral; } });
|
|
24
|
+
var initObligation_1 = require("./initObligation");
|
|
25
|
+
Object.defineProperty(exports, "initObligation", { enumerable: true, get: function () { return initObligation_1.initObligation; } });
|
|
26
|
+
var initObligationFarmsForReserve_1 = require("./initObligationFarmsForReserve");
|
|
27
|
+
Object.defineProperty(exports, "initObligationFarmsForReserve", { enumerable: true, get: function () { return initObligationFarmsForReserve_1.initObligationFarmsForReserve; } });
|
|
28
|
+
var refreshObligationFarmsForReserve_1 = require("./refreshObligationFarmsForReserve");
|
|
29
|
+
Object.defineProperty(exports, "refreshObligationFarmsForReserve", { enumerable: true, get: function () { return refreshObligationFarmsForReserve_1.refreshObligationFarmsForReserve; } });
|
|
30
|
+
var refreshObligation_1 = require("./refreshObligation");
|
|
31
|
+
Object.defineProperty(exports, "refreshObligation", { enumerable: true, get: function () { return refreshObligation_1.refreshObligation; } });
|
|
32
|
+
var depositObligationCollateral_1 = require("./depositObligationCollateral");
|
|
33
|
+
Object.defineProperty(exports, "depositObligationCollateral", { enumerable: true, get: function () { return depositObligationCollateral_1.depositObligationCollateral; } });
|
|
34
|
+
var withdrawObligationCollateral_1 = require("./withdrawObligationCollateral");
|
|
35
|
+
Object.defineProperty(exports, "withdrawObligationCollateral", { enumerable: true, get: function () { return withdrawObligationCollateral_1.withdrawObligationCollateral; } });
|
|
36
|
+
var borrowObligationLiquidity_1 = require("./borrowObligationLiquidity");
|
|
37
|
+
Object.defineProperty(exports, "borrowObligationLiquidity", { enumerable: true, get: function () { return borrowObligationLiquidity_1.borrowObligationLiquidity; } });
|
|
38
|
+
var repayObligationLiquidity_1 = require("./repayObligationLiquidity");
|
|
39
|
+
Object.defineProperty(exports, "repayObligationLiquidity", { enumerable: true, get: function () { return repayObligationLiquidity_1.repayObligationLiquidity; } });
|
|
40
|
+
var depositReserveLiquidityAndObligationCollateral_1 = require("./depositReserveLiquidityAndObligationCollateral");
|
|
41
|
+
Object.defineProperty(exports, "depositReserveLiquidityAndObligationCollateral", { enumerable: true, get: function () { return depositReserveLiquidityAndObligationCollateral_1.depositReserveLiquidityAndObligationCollateral; } });
|
|
42
|
+
var withdrawObligationCollateralAndRedeemReserveCollateral_1 = require("./withdrawObligationCollateralAndRedeemReserveCollateral");
|
|
43
|
+
Object.defineProperty(exports, "withdrawObligationCollateralAndRedeemReserveCollateral", { enumerable: true, get: function () { return withdrawObligationCollateralAndRedeemReserveCollateral_1.withdrawObligationCollateralAndRedeemReserveCollateral; } });
|
|
44
|
+
var liquidateObligationAndRedeemReserveCollateral_1 = require("./liquidateObligationAndRedeemReserveCollateral");
|
|
45
|
+
Object.defineProperty(exports, "liquidateObligationAndRedeemReserveCollateral", { enumerable: true, get: function () { return liquidateObligationAndRedeemReserveCollateral_1.liquidateObligationAndRedeemReserveCollateral; } });
|
|
46
|
+
var redeemFees_1 = require("./redeemFees");
|
|
47
|
+
Object.defineProperty(exports, "redeemFees", { enumerable: true, get: function () { return redeemFees_1.redeemFees; } });
|
|
48
|
+
var flashRepayReserveLiquidity_1 = require("./flashRepayReserveLiquidity");
|
|
49
|
+
Object.defineProperty(exports, "flashRepayReserveLiquidity", { enumerable: true, get: function () { return flashRepayReserveLiquidity_1.flashRepayReserveLiquidity; } });
|
|
50
|
+
var flashBorrowReserveLiquidity_1 = require("./flashBorrowReserveLiquidity");
|
|
51
|
+
Object.defineProperty(exports, "flashBorrowReserveLiquidity", { enumerable: true, get: function () { return flashBorrowReserveLiquidity_1.flashBorrowReserveLiquidity; } });
|
|
52
|
+
var socializeLoss_1 = require("./socializeLoss");
|
|
53
|
+
Object.defineProperty(exports, "socializeLoss", { enumerable: true, get: function () { return socializeLoss_1.socializeLoss; } });
|
|
54
|
+
var requestElevationGroup_1 = require("./requestElevationGroup");
|
|
55
|
+
Object.defineProperty(exports, "requestElevationGroup", { enumerable: true, get: function () { return requestElevationGroup_1.requestElevationGroup; } });
|
|
56
|
+
var initReferrerTokenState_1 = require("./initReferrerTokenState");
|
|
57
|
+
Object.defineProperty(exports, "initReferrerTokenState", { enumerable: true, get: function () { return initReferrerTokenState_1.initReferrerTokenState; } });
|
|
58
|
+
var initUserMetadata_1 = require("./initUserMetadata");
|
|
59
|
+
Object.defineProperty(exports, "initUserMetadata", { enumerable: true, get: function () { return initUserMetadata_1.initUserMetadata; } });
|
|
60
|
+
var withdrawReferrerFees_1 = require("./withdrawReferrerFees");
|
|
61
|
+
Object.defineProperty(exports, "withdrawReferrerFees", { enumerable: true, get: function () { return withdrawReferrerFees_1.withdrawReferrerFees; } });
|
|
62
|
+
var withdrawProtocolFee_1 = require("./withdrawProtocolFee");
|
|
63
|
+
Object.defineProperty(exports, "withdrawProtocolFee", { enumerable: true, get: function () { return withdrawProtocolFee_1.withdrawProtocolFee; } });
|
|
64
|
+
var initReferrerStateAndShortUrl_1 = require("./initReferrerStateAndShortUrl");
|
|
65
|
+
Object.defineProperty(exports, "initReferrerStateAndShortUrl", { enumerable: true, get: function () { return initReferrerStateAndShortUrl_1.initReferrerStateAndShortUrl; } });
|
|
66
|
+
var deleteReferrerStateAndShortUrl_1 = require("./deleteReferrerStateAndShortUrl");
|
|
67
|
+
Object.defineProperty(exports, "deleteReferrerStateAndShortUrl", { enumerable: true, get: function () { return deleteReferrerStateAndShortUrl_1.deleteReferrerStateAndShortUrl; } });
|
|
68
|
+
var idlMissingTypes_1 = require("./idlMissingTypes");
|
|
69
|
+
Object.defineProperty(exports, "idlMissingTypes", { enumerable: true, get: function () { return idlMissingTypes_1.idlMissingTypes; } });
|
|
70
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/idl_codegen/instructions/index.ts"],"names":[],"mappings":";;;AAAA,yDAAuD;AAA9C,sHAAA,iBAAiB,OAAA;AAK1B,6DAA2D;AAAlD,0HAAA,mBAAmB,OAAA;AAK5B,uEAAqE;AAA5D,oIAAA,wBAAwB,OAAA;AAEjC,6CAA2C;AAAlC,0GAAA,WAAW,OAAA;AAEpB,6DAA2D;AAAlD,0HAAA,mBAAmB,OAAA;AAK5B,yEAAuE;AAA9D,sIAAA,yBAAyB,OAAA;AAKlC,yEAAuE;AAA9D,sIAAA,yBAAyB,OAAA;AAKlC,mDAAiD;AAAxC,gHAAA,cAAc,OAAA;AAEvB,qEAAmE;AAA1D,kIAAA,uBAAuB,OAAA;AAKhC,qEAAmE;AAA1D,kIAAA,uBAAuB,OAAA;AAKhC,mDAAiD;AAAxC,gHAAA,cAAc,OAAA;AAKvB,iFAA+E;AAAtE,8IAAA,6BAA6B,OAAA;AAKtC,uFAAqF;AAA5E,oJAAA,gCAAgC,OAAA;AAKzC,yDAAuD;AAA9C,sHAAA,iBAAiB,OAAA;AAE1B,6EAA2E;AAAlE,0IAAA,2BAA2B,OAAA;AAKpC,+EAA6E;AAApE,4IAAA,4BAA4B,OAAA;AAKrC,yEAAuE;AAA9D,sIAAA,yBAAyB,OAAA;AAKlC,uEAAqE;AAA5D,oIAAA,wBAAwB,OAAA;AAKjC,mHAAiH;AAAxG,gLAAA,8CAA8C,OAAA;AAKvD,mIAAiI;AAAxH,gMAAA,sDAAsD,OAAA;AAK/D,iHAA+G;AAAtG,8KAAA,6CAA6C,OAAA;AAKtD,2CAAyC;AAAhC,wGAAA,UAAU,OAAA;AAEnB,2EAAyE;AAAhE,wIAAA,0BAA0B,OAAA;AAKnC,6EAA2E;AAAlE,0IAAA,2BAA2B,OAAA;AAKpC,iDAA+C;AAAtC,8GAAA,aAAa,OAAA;AAEtB,iEAA+D;AAAtD,8HAAA,qBAAqB,OAAA;AAK9B,mEAAiE;AAAxD,gIAAA,sBAAsB,OAAA;AAK/B,uDAAqD;AAA5C,oHAAA,gBAAgB,OAAA;AAKzB,+DAA6D;AAApD,4HAAA,oBAAoB,OAAA;AAE7B,6DAA2D;AAAlD,0HAAA,mBAAmB,OAAA;AAK5B,+EAA6E;AAApE,4IAAA,4BAA4B,OAAA;AAKrC,mFAAiF;AAAxE,gJAAA,8BAA8B,OAAA;AAEvC,qDAAmD;AAA1C,kHAAA,eAAe,OAAA","sourcesContent":["export { initLendingMarket } from \"./initLendingMarket\"\nexport type {\n InitLendingMarketArgs,\n InitLendingMarketAccounts,\n} from \"./initLendingMarket\"\nexport { updateLendingMarket } from \"./updateLendingMarket\"\nexport type {\n UpdateLendingMarketArgs,\n UpdateLendingMarketAccounts,\n} from \"./updateLendingMarket\"\nexport { updateLendingMarketOwner } from \"./updateLendingMarketOwner\"\nexport type { UpdateLendingMarketOwnerAccounts } from \"./updateLendingMarketOwner\"\nexport { initReserve } from \"./initReserve\"\nexport type { InitReserveAccounts } from \"./initReserve\"\nexport { initFarmsForReserve } from \"./initFarmsForReserve\"\nexport type {\n InitFarmsForReserveArgs,\n InitFarmsForReserveAccounts,\n} from \"./initFarmsForReserve\"\nexport { updateSingleReserveConfig } from \"./updateSingleReserveConfig\"\nexport type {\n UpdateSingleReserveConfigArgs,\n UpdateSingleReserveConfigAccounts,\n} from \"./updateSingleReserveConfig\"\nexport { updateEntireReserveConfig } from \"./updateEntireReserveConfig\"\nexport type {\n UpdateEntireReserveConfigArgs,\n UpdateEntireReserveConfigAccounts,\n} from \"./updateEntireReserveConfig\"\nexport { refreshReserve } from \"./refreshReserve\"\nexport type { RefreshReserveAccounts } from \"./refreshReserve\"\nexport { depositReserveLiquidity } from \"./depositReserveLiquidity\"\nexport type {\n DepositReserveLiquidityArgs,\n DepositReserveLiquidityAccounts,\n} from \"./depositReserveLiquidity\"\nexport { redeemReserveCollateral } from \"./redeemReserveCollateral\"\nexport type {\n RedeemReserveCollateralArgs,\n RedeemReserveCollateralAccounts,\n} from \"./redeemReserveCollateral\"\nexport { initObligation } from \"./initObligation\"\nexport type {\n InitObligationArgs,\n InitObligationAccounts,\n} from \"./initObligation\"\nexport { initObligationFarmsForReserve } from \"./initObligationFarmsForReserve\"\nexport type {\n InitObligationFarmsForReserveArgs,\n InitObligationFarmsForReserveAccounts,\n} from \"./initObligationFarmsForReserve\"\nexport { refreshObligationFarmsForReserve } from \"./refreshObligationFarmsForReserve\"\nexport type {\n RefreshObligationFarmsForReserveArgs,\n RefreshObligationFarmsForReserveAccounts,\n} from \"./refreshObligationFarmsForReserve\"\nexport { refreshObligation } from \"./refreshObligation\"\nexport type { RefreshObligationAccounts } from \"./refreshObligation\"\nexport { depositObligationCollateral } from \"./depositObligationCollateral\"\nexport type {\n DepositObligationCollateralArgs,\n DepositObligationCollateralAccounts,\n} from \"./depositObligationCollateral\"\nexport { withdrawObligationCollateral } from \"./withdrawObligationCollateral\"\nexport type {\n WithdrawObligationCollateralArgs,\n WithdrawObligationCollateralAccounts,\n} from \"./withdrawObligationCollateral\"\nexport { borrowObligationLiquidity } from \"./borrowObligationLiquidity\"\nexport type {\n BorrowObligationLiquidityArgs,\n BorrowObligationLiquidityAccounts,\n} from \"./borrowObligationLiquidity\"\nexport { repayObligationLiquidity } from \"./repayObligationLiquidity\"\nexport type {\n RepayObligationLiquidityArgs,\n RepayObligationLiquidityAccounts,\n} from \"./repayObligationLiquidity\"\nexport { depositReserveLiquidityAndObligationCollateral } from \"./depositReserveLiquidityAndObligationCollateral\"\nexport type {\n DepositReserveLiquidityAndObligationCollateralArgs,\n DepositReserveLiquidityAndObligationCollateralAccounts,\n} from \"./depositReserveLiquidityAndObligationCollateral\"\nexport { withdrawObligationCollateralAndRedeemReserveCollateral } from \"./withdrawObligationCollateralAndRedeemReserveCollateral\"\nexport type {\n WithdrawObligationCollateralAndRedeemReserveCollateralArgs,\n WithdrawObligationCollateralAndRedeemReserveCollateralAccounts,\n} from \"./withdrawObligationCollateralAndRedeemReserveCollateral\"\nexport { liquidateObligationAndRedeemReserveCollateral } from \"./liquidateObligationAndRedeemReserveCollateral\"\nexport type {\n LiquidateObligationAndRedeemReserveCollateralArgs,\n LiquidateObligationAndRedeemReserveCollateralAccounts,\n} from \"./liquidateObligationAndRedeemReserveCollateral\"\nexport { redeemFees } from \"./redeemFees\"\nexport type { RedeemFeesAccounts } from \"./redeemFees\"\nexport { flashRepayReserveLiquidity } from \"./flashRepayReserveLiquidity\"\nexport type {\n FlashRepayReserveLiquidityArgs,\n FlashRepayReserveLiquidityAccounts,\n} from \"./flashRepayReserveLiquidity\"\nexport { flashBorrowReserveLiquidity } from \"./flashBorrowReserveLiquidity\"\nexport type {\n FlashBorrowReserveLiquidityArgs,\n FlashBorrowReserveLiquidityAccounts,\n} from \"./flashBorrowReserveLiquidity\"\nexport { socializeLoss } from \"./socializeLoss\"\nexport type { SocializeLossArgs, SocializeLossAccounts } from \"./socializeLoss\"\nexport { requestElevationGroup } from \"./requestElevationGroup\"\nexport type {\n RequestElevationGroupArgs,\n RequestElevationGroupAccounts,\n} from \"./requestElevationGroup\"\nexport { initReferrerTokenState } from \"./initReferrerTokenState\"\nexport type {\n InitReferrerTokenStateArgs,\n InitReferrerTokenStateAccounts,\n} from \"./initReferrerTokenState\"\nexport { initUserMetadata } from \"./initUserMetadata\"\nexport type {\n InitUserMetadataArgs,\n InitUserMetadataAccounts,\n} from \"./initUserMetadata\"\nexport { withdrawReferrerFees } from \"./withdrawReferrerFees\"\nexport type { WithdrawReferrerFeesAccounts } from \"./withdrawReferrerFees\"\nexport { withdrawProtocolFee } from \"./withdrawProtocolFee\"\nexport type {\n WithdrawProtocolFeeArgs,\n WithdrawProtocolFeeAccounts,\n} from \"./withdrawProtocolFee\"\nexport { initReferrerStateAndShortUrl } from \"./initReferrerStateAndShortUrl\"\nexport type {\n InitReferrerStateAndShortUrlArgs,\n InitReferrerStateAndShortUrlAccounts,\n} from \"./initReferrerStateAndShortUrl\"\nexport { deleteReferrerStateAndShortUrl } from \"./deleteReferrerStateAndShortUrl\"\nexport type { DeleteReferrerStateAndShortUrlAccounts } from \"./deleteReferrerStateAndShortUrl\"\nexport { idlMissingTypes } from \"./idlMissingTypes\"\nexport type {\n IdlMissingTypesArgs,\n IdlMissingTypesAccounts,\n} from \"./idlMissingTypes\"\n"]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { TransactionInstruction, PublicKey } from "@solana/web3.js";
|
|
2
|
+
export interface InitFarmsForReserveArgs {
|
|
3
|
+
mode: number;
|
|
4
|
+
}
|
|
5
|
+
export interface InitFarmsForReserveAccounts {
|
|
6
|
+
lendingMarketOwner: PublicKey;
|
|
7
|
+
lendingMarket: PublicKey;
|
|
8
|
+
lendingMarketAuthority: PublicKey;
|
|
9
|
+
reserve: PublicKey;
|
|
10
|
+
farmsProgram: PublicKey;
|
|
11
|
+
farmsGlobalConfig: PublicKey;
|
|
12
|
+
farmState: PublicKey;
|
|
13
|
+
farmsVaultAuthority: PublicKey;
|
|
14
|
+
rent: PublicKey;
|
|
15
|
+
tokenProgram: PublicKey;
|
|
16
|
+
systemProgram: PublicKey;
|
|
17
|
+
}
|
|
18
|
+
export declare const layout: any;
|
|
19
|
+
export declare function initFarmsForReserve(args: InitFarmsForReserveArgs, accounts: InitFarmsForReserveAccounts, programId?: PublicKey): TransactionInstruction;
|