hedge-web3 0.2.27 → 0.2.31
Sign up to get free protection for your applications and to get access to all the features.
- package/declarations/Constants.d.ts +12 -0
- package/declarations/idl/vault.d.ts +743 -59
- package/declarations/index.d.ts +9 -0
- package/declarations/instructions/adminWithdrawCol.d.ts +5 -0
- package/declarations/instructions/adminWithdrawUsh.d.ts +5 -0
- package/declarations/instructions/createCompoundStakingPool.d.ts +5 -0
- package/declarations/instructions/createCompoundStakingPoolPosition.d.ts +6 -0
- package/declarations/instructions/createReferralAccount.d.ts +2 -2
- package/declarations/instructions/depositCompoundStakingPoolPosition.d.ts +6 -0
- package/declarations/instructions/depositRewardsToCompoundPool.d.ts +6 -0
- package/declarations/instructions/referralClaimFees.d.ts +2 -2
- package/declarations/instructions/setCompoundPoolActive.d.ts +5 -0
- package/declarations/instructions/setDelegateWallet.d.ts +5 -0
- package/declarations/instructions/withdrawCompoundStakingPoolPosition.d.ts +6 -0
- package/declarations/utils/getLinkedListAccounts.d.ts +2 -1
- package/lib/Constants.js +28 -1
- package/lib/idl/vault.js +741 -57
- package/lib/index.js +9 -0
- package/lib/instructions/adminWithdrawCol.js +60 -0
- package/lib/instructions/adminWithdrawUsh.js +57 -0
- package/lib/instructions/createCompoundStakingPool.js +58 -0
- package/lib/instructions/createCompoundStakingPoolPosition.js +56 -0
- package/lib/instructions/createReferralAccount.js +6 -3
- package/lib/instructions/depositCompoundStakingPoolPosition.js +55 -0
- package/lib/instructions/depositRewardsToCompoundPool.js +64 -0
- package/lib/instructions/liquidateVault.js +7 -1
- package/lib/instructions/loanVault.js +7 -1
- package/lib/instructions/referralClaimFees.js +6 -3
- package/lib/instructions/setCompoundPoolActive.js +43 -0
- package/lib/instructions/setDelegateWallet.js +43 -0
- package/lib/instructions/withdrawCompoundStakingPoolPosition.js +64 -0
- package/lib/utils/getLinkedListAccounts.js +5 -21
- package/package.json +5 -2
- package/src/Constants.ts +30 -0
- package/src/idl/vault.ts +3638 -2270
- package/src/index.ts +9 -2
- package/src/instructions/adminWithdrawCol.ts +87 -0
- package/src/instructions/adminWithdrawUsh.ts +78 -0
- package/src/instructions/createCompoundStakingPool.ts +63 -0
- package/src/instructions/createCompoundStakingPoolPosition.ts +85 -0
- package/src/instructions/createReferralAccount.ts +13 -9
- package/src/instructions/createStakingPool.ts +2 -9
- package/src/instructions/depositCompoundStakingPoolPosition.ts +78 -0
- package/src/instructions/depositRewardsToCompoundPool.ts +110 -0
- package/src/instructions/liquidateVault.ts +37 -27
- package/src/instructions/loanVault.ts +34 -21
- package/src/instructions/referralClaimFees.ts +16 -10
- package/src/instructions/setCompoundPoolActive.ts +51 -0
- package/src/instructions/setDelegateWallet.ts +51 -0
- package/src/instructions/withdrawCompoundStakingPoolPosition.ts +100 -0
- package/src/utils/getLinkedListAccounts.ts +6 -20
@@ -36,6 +36,11 @@ export declare function getReferralAccountPublicKey(hedgeProgramId: PublicKey, o
|
|
36
36
|
* @returns The user referral account public key based off the user's public key
|
37
37
|
*/
|
38
38
|
export declare function getUserReferralAccountPublicKey(hedgeProgramId: PublicKey, ownerPublicKey: PublicKey): Promise<PublicKey>;
|
39
|
+
/**
|
40
|
+
*
|
41
|
+
* @returns The compound pool position address for the given user
|
42
|
+
*/
|
43
|
+
export declare function getCompoundPoolPositionAddress(hedgeProgramId: PublicKey, poolPublicKey: PublicKey, ownerPublicKey: PublicKey): Promise<PublicKey>;
|
39
44
|
/**
|
40
45
|
*
|
41
46
|
* @returns The HDG mint public key
|
@@ -48,6 +53,13 @@ export declare function getHedgeMintPublicKey(hedgeProgramId: PublicKey): Promis
|
|
48
53
|
* @returns the public key for that staking pool
|
49
54
|
*/
|
50
55
|
export declare function getPoolPublicKeyForMint(hedgeProgramId: PublicKey, mintPublicKey: PublicKey): Promise<[PublicKey, number, string]>;
|
56
|
+
/**
|
57
|
+
* Get the public key for any compound staking pool
|
58
|
+
*
|
59
|
+
* @param mintPublicKey Staked collateral mint public key
|
60
|
+
* @returns the public key for that compound staking pool
|
61
|
+
*/
|
62
|
+
export declare function getCompoundPoolPublicKeyForMint(hedgeProgramId: PublicKey, mintPublicKey: PublicKey): Promise<[PublicKey, number]>;
|
51
63
|
/**
|
52
64
|
*
|
53
65
|
* @param collateralType String name of the collateral type (must be 16 chars)
|