@reflectmoney/stable.ts 1.0.6 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. package/dist/classes/ApiClient.js +117 -0
  2. package/dist/classes/Reflect.d.ts +7 -0
  3. package/dist/classes/Reflect.js +27 -0
  4. package/dist/classes/ReflectKeeper.d.ts +6 -3
  5. package/dist/classes/ReflectKeeper.js +11 -4
  6. package/dist/classes/ReflectTokenisedBond.d.ts +2 -0
  7. package/dist/classes/ReflectTokenisedBond.js +2 -2
  8. package/dist/classes/Stablecoin.d.ts +24 -9
  9. package/dist/classes/Stablecoin.js +136 -20
  10. package/dist/classes/index.d.ts +1 -0
  11. package/dist/classes/index.js +1 -0
  12. package/dist/constants/index.d.ts +1 -0
  13. package/dist/constants/index.js +3 -0
  14. package/dist/constants/lst.d.ts +3 -0
  15. package/dist/constants/lst.js +6 -0
  16. package/dist/generated/reflect_main/accounts/DriftJlpController.d.ts +2 -0
  17. package/dist/generated/reflect_main/accounts/DriftLstController.d.ts +2 -0
  18. package/dist/generated/reflect_main/accounts/DriftUsdcController.d.ts +28 -2
  19. package/dist/generated/reflect_main/accounts/DriftUsdcController.js +59 -9
  20. package/dist/generated/reflect_main/accounts/Main.d.ts +2 -0
  21. package/dist/generated/reflect_main/accounts/PerpMarket.d.ts +2 -0
  22. package/dist/generated/reflect_main/accounts/PrelaunchOracle.d.ts +2 -0
  23. package/dist/generated/reflect_main/accounts/PythLazerOracle.d.ts +2 -0
  24. package/dist/generated/reflect_main/accounts/RebalanceLst.d.ts +2 -0
  25. package/dist/generated/reflect_main/accounts/SpotMarket.d.ts +2 -0
  26. package/dist/generated/reflect_main/accounts/User.d.ts +2 -0
  27. package/dist/generated/reflect_main/accounts/UserPermissions.d.ts +2 -0
  28. package/dist/generated/reflect_main/accounts/UserStats.d.ts +2 -0
  29. package/dist/generated/reflect_main/errors/index.d.ts +11 -0
  30. package/dist/generated/reflect_main/errors/index.js +84 -65
  31. package/dist/generated/reflect_main/instructions/captureSpreadDriftS1.d.ts +58 -0
  32. package/dist/generated/reflect_main/instructions/captureSpreadDriftS1.js +125 -0
  33. package/dist/generated/reflect_main/instructions/index.d.ts +1 -0
  34. package/dist/generated/reflect_main/instructions/index.js +1 -0
  35. package/dist/generated/reflect_main/instructions/initDriftControllerS1.js +0 -2
  36. package/dist/generated/reflect_main/instructions/mintDriftS1.d.ts +0 -12
  37. package/dist/generated/reflect_main/instructions/mintDriftS1.js +0 -30
  38. package/dist/generated/reflect_main/instructions/redeemDriftS1.d.ts +0 -12
  39. package/dist/generated/reflect_main/instructions/redeemDriftS1.js +0 -30
  40. package/dist/generated/reflect_main/types/Capture.d.ts +17 -0
  41. package/dist/generated/reflect_main/types/Capture.js +42 -0
  42. package/dist/generated/reflect_main/types/PermissionLevel.d.ts +8 -2
  43. package/dist/generated/reflect_main/types/index.d.ts +1 -0
  44. package/dist/generated/reflect_main/types/index.js +1 -0
  45. package/dist/generated/reflect_tokenised_bonds/accounts/Admin.d.ts +2 -0
  46. package/dist/generated/reflect_tokenised_bonds/accounts/Admin.js +1 -1
  47. package/dist/generated/reflect_tokenised_bonds/accounts/Config.d.ts +2 -0
  48. package/dist/generated/reflect_tokenised_bonds/accounts/Config.js +1 -1
  49. package/dist/generated/reflect_tokenised_bonds/accounts/Vault.d.ts +2 -0
  50. package/dist/generated/reflect_tokenised_bonds/accounts/Vault.js +1 -1
  51. package/dist/generated/reflect_tokenised_bonds/index.d.ts +1 -1
  52. package/dist/generated/reflect_tokenised_bonds/index.js +1 -1
  53. package/dist/generated/reflect_tokenised_bonds/instructions/createVault.js +1 -1
  54. package/dist/generated/reflect_tokenised_bonds/instructions/deposit.js +1 -1
  55. package/dist/generated/reflect_tokenised_bonds/instructions/initialize.js +1 -1
  56. package/dist/generated/reflect_tokenised_bonds/instructions/withdraw.js +1 -1
  57. package/dist/stablecoins/LstStablecoin.d.ts +3 -2
  58. package/dist/stablecoins/LstStablecoin.js +124 -22
  59. package/dist/stablecoins/UsdcPlusStablecoin.d.ts +2 -1
  60. package/dist/stablecoins/UsdcPlusStablecoin.js +109 -34
  61. package/package.json +12 -6
@@ -0,0 +1,125 @@
1
+ "use strict";
2
+ /**
3
+ * This code was GENERATED using the solita package.
4
+ * Please DO NOT EDIT THIS FILE, instead rerun solita to update it or write a wrapper to add functionality.
5
+ *
6
+ * See: https://github.com/metaplex-foundation/solita
7
+ */
8
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
9
+ if (k2 === undefined) k2 = k;
10
+ var desc = Object.getOwnPropertyDescriptor(m, k);
11
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
12
+ desc = { enumerable: true, get: function() { return m[k]; } };
13
+ }
14
+ Object.defineProperty(o, k2, desc);
15
+ }) : (function(o, m, k, k2) {
16
+ if (k2 === undefined) k2 = k;
17
+ o[k2] = m[k];
18
+ }));
19
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
20
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
21
+ }) : function(o, v) {
22
+ o["default"] = v;
23
+ });
24
+ var __importStar = (this && this.__importStar) || function (mod) {
25
+ if (mod && mod.__esModule) return mod;
26
+ var result = {};
27
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
28
+ __setModuleDefault(result, mod);
29
+ return result;
30
+ };
31
+ Object.defineProperty(exports, "__esModule", { value: true });
32
+ exports.captureSpreadDriftS1InstructionDiscriminator = exports.captureSpreadDriftS1Struct = void 0;
33
+ exports.createCaptureSpreadDriftS1Instruction = createCaptureSpreadDriftS1Instruction;
34
+ const splToken = __importStar(require("@solana/spl-token"));
35
+ const beet = __importStar(require("@metaplex-foundation/beet"));
36
+ const web3 = __importStar(require("@solana/web3.js"));
37
+ /**
38
+ * @category Instructions
39
+ * @category CaptureSpreadDriftS1
40
+ * @category generated
41
+ */
42
+ exports.captureSpreadDriftS1Struct = new beet.BeetArgsStruct([['instructionDiscriminator', beet.uniformFixedSizeArray(beet.u8, 8)]], 'CaptureSpreadDriftS1InstructionArgs');
43
+ exports.captureSpreadDriftS1InstructionDiscriminator = [
44
+ 165, 109, 191, 22, 50, 39, 151, 219,
45
+ ];
46
+ /**
47
+ * Creates a _CaptureSpreadDriftS1_ instruction.
48
+ *
49
+ * Optional accounts that are not provided default to the program ID since
50
+ * this was indicated in the IDL from which this instruction was generated.
51
+ *
52
+ * @param accounts that will be accessed while the instruction is processed
53
+ * @category Instructions
54
+ * @category CaptureSpreadDriftS1
55
+ * @category generated
56
+ */
57
+ function createCaptureSpreadDriftS1Instruction(accounts, programId = new web3.PublicKey('9CtYQNCz3LaQ9DnqXa83q6gdHGwMeN6aQ7KqqotBmeke')) {
58
+ var _a, _b;
59
+ const [data] = exports.captureSpreadDriftS1Struct.serialize({
60
+ instructionDiscriminator: exports.captureSpreadDriftS1InstructionDiscriminator,
61
+ });
62
+ const keys = [
63
+ {
64
+ pubkey: accounts.capturer,
65
+ isWritable: true,
66
+ isSigner: true,
67
+ },
68
+ {
69
+ pubkey: accounts.main,
70
+ isWritable: false,
71
+ isSigner: false,
72
+ },
73
+ {
74
+ pubkey: accounts.usdcController,
75
+ isWritable: true,
76
+ isSigner: false,
77
+ },
78
+ {
79
+ pubkey: (_a = accounts.adminPermissions) !== null && _a !== void 0 ? _a : programId,
80
+ isWritable: false,
81
+ isSigner: false,
82
+ },
83
+ {
84
+ pubkey: accounts.drift,
85
+ isWritable: false,
86
+ isSigner: false,
87
+ },
88
+ {
89
+ pubkey: accounts.state,
90
+ isWritable: true,
91
+ isSigner: false,
92
+ },
93
+ {
94
+ pubkey: accounts.userAccount,
95
+ isWritable: true,
96
+ isSigner: false,
97
+ },
98
+ {
99
+ pubkey: accounts.controllerUsdcAta,
100
+ isWritable: true,
101
+ isSigner: false,
102
+ },
103
+ {
104
+ pubkey: accounts.receiptMint,
105
+ isWritable: true,
106
+ isSigner: false,
107
+ },
108
+ {
109
+ pubkey: (_b = accounts.tokenProgram) !== null && _b !== void 0 ? _b : splToken.TOKEN_PROGRAM_ID,
110
+ isWritable: false,
111
+ isSigner: false,
112
+ },
113
+ ];
114
+ if (accounts.anchorRemainingAccounts != null) {
115
+ for (const acc of accounts.anchorRemainingAccounts) {
116
+ keys.push(acc);
117
+ }
118
+ }
119
+ const ix = new web3.TransactionInstruction({
120
+ programId,
121
+ keys,
122
+ data,
123
+ });
124
+ return ix;
125
+ }
@@ -1,6 +1,7 @@
1
1
  export * from './addLstDrift';
2
2
  export * from './addSubAccount';
3
3
  export * from './captureSpreadDrift';
4
+ export * from './captureSpreadDriftS1';
4
5
  export * from './createAdminAccount';
5
6
  export * from './createUserStatsAccount';
6
7
  export * from './depositDrift';
@@ -17,6 +17,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./addLstDrift"), exports);
18
18
  __exportStar(require("./addSubAccount"), exports);
19
19
  __exportStar(require("./captureSpreadDrift"), exports);
20
+ __exportStar(require("./captureSpreadDriftS1"), exports);
20
21
  __exportStar(require("./createAdminAccount"), exports);
21
22
  __exportStar(require("./createUserStatsAccount"), exports);
22
23
  __exportStar(require("./depositDrift"), exports);
@@ -42,8 +42,6 @@ const beetSolana = __importStar(require("@metaplex-foundation/beet-solana"));
42
42
  exports.initDriftControllerS1Struct = new beet.FixableBeetArgsStruct([
43
43
  ['instructionDiscriminator', beet.uniformFixedSizeArray(beet.u8, 8)],
44
44
  ['mint', beetSolana.publicKey],
45
- ['lpReciptMint', beetSolana.publicKey],
46
- ['vault', beetSolana.publicKey],
47
45
  ['recipientAddresses', beet.array(beetSolana.publicKey)],
48
46
  ['recipientCuts', beet.array(beet.u16)],
49
47
  ['cap', beet.u64],
@@ -32,12 +32,7 @@ export declare const mintDriftS1Struct: beet.BeetArgsStruct<MintDriftS1Instructi
32
32
  * @property [] adminPermissions (optional)
33
33
  * @property [_writable_] userReceiptAta
34
34
  * @property [_writable_] userUsdcAta
35
- * @property [_writable_] controllerReceiptAta
36
- * @property [_writable_] controllerIntermediaryAta
37
35
  * @property [_writable_] controllerUsdcAta
38
- * @property [_writable_] vault
39
- * @property [_writable_] lpPoolIntermediaryAta
40
- * @property [_writable_] intermediaryMint
41
36
  * @property [_writable_] receiptMint
42
37
  * @property [] drift
43
38
  * @property [_writable_] state
@@ -48,7 +43,6 @@ export declare const mintDriftS1Struct: beet.BeetArgsStruct<MintDriftS1Instructi
48
43
  * @property [_writable_] spotMarketVault
49
44
  * @property [_writable_] driftVault
50
45
  * @property [] clock
51
- * @property [_writable_] lpProgram
52
46
  * @category Instructions
53
47
  * @category MintDriftS1
54
48
  * @category generated
@@ -60,12 +54,7 @@ export type MintDriftS1InstructionAccounts = {
60
54
  adminPermissions?: web3.PublicKey;
61
55
  userReceiptAta: web3.PublicKey;
62
56
  userUsdcAta: web3.PublicKey;
63
- controllerReceiptAta: web3.PublicKey;
64
- controllerIntermediaryAta: web3.PublicKey;
65
57
  controllerUsdcAta: web3.PublicKey;
66
- vault: web3.PublicKey;
67
- lpPoolIntermediaryAta: web3.PublicKey;
68
- intermediaryMint: web3.PublicKey;
69
58
  receiptMint: web3.PublicKey;
70
59
  drift: web3.PublicKey;
71
60
  state: web3.PublicKey;
@@ -78,7 +67,6 @@ export type MintDriftS1InstructionAccounts = {
78
67
  tokenProgram?: web3.PublicKey;
79
68
  systemProgram?: web3.PublicKey;
80
69
  clock: web3.PublicKey;
81
- lpProgram: web3.PublicKey;
82
70
  anchorRemainingAccounts?: web3.AccountMeta[];
83
71
  };
84
72
  export declare const mintDriftS1InstructionDiscriminator: number[];
@@ -94,36 +94,11 @@ function createMintDriftS1Instruction(accounts, args, programId = new web3.Publi
94
94
  isWritable: true,
95
95
  isSigner: false,
96
96
  },
97
- {
98
- pubkey: accounts.controllerReceiptAta,
99
- isWritable: true,
100
- isSigner: false,
101
- },
102
- {
103
- pubkey: accounts.controllerIntermediaryAta,
104
- isWritable: true,
105
- isSigner: false,
106
- },
107
97
  {
108
98
  pubkey: accounts.controllerUsdcAta,
109
99
  isWritable: true,
110
100
  isSigner: false,
111
101
  },
112
- {
113
- pubkey: accounts.vault,
114
- isWritable: true,
115
- isSigner: false,
116
- },
117
- {
118
- pubkey: accounts.lpPoolIntermediaryAta,
119
- isWritable: true,
120
- isSigner: false,
121
- },
122
- {
123
- pubkey: accounts.intermediaryMint,
124
- isWritable: true,
125
- isSigner: false,
126
- },
127
102
  {
128
103
  pubkey: accounts.receiptMint,
129
104
  isWritable: true,
@@ -184,11 +159,6 @@ function createMintDriftS1Instruction(accounts, args, programId = new web3.Publi
184
159
  isWritable: false,
185
160
  isSigner: false,
186
161
  },
187
- {
188
- pubkey: accounts.lpProgram,
189
- isWritable: true,
190
- isSigner: false,
191
- },
192
162
  ];
193
163
  if (accounts.anchorRemainingAccounts != null) {
194
164
  for (const acc of accounts.anchorRemainingAccounts) {
@@ -33,12 +33,7 @@ export declare const redeemDriftS1Struct: beet.BeetArgsStruct<RedeemDriftS1Instr
33
33
  * @property [] adminPermissions (optional)
34
34
  * @property [_writable_] userReceiptAta
35
35
  * @property [_writable_] userUsdcAta
36
- * @property [_writable_] controllerReceiptAta
37
- * @property [_writable_] controllerIntermediaryAta
38
36
  * @property [_writable_] controllerUsdcAta
39
- * @property [_writable_] vault
40
- * @property [_writable_] lpPoolIntermediaryAta
41
- * @property [_writable_] intermediaryMint
42
37
  * @property [_writable_] receiptMint
43
38
  * @property [] drift
44
39
  * @property [_writable_] state
@@ -49,7 +44,6 @@ export declare const redeemDriftS1Struct: beet.BeetArgsStruct<RedeemDriftS1Instr
49
44
  * @property [_writable_] spotMarketVault
50
45
  * @property [_writable_] driftVault
51
46
  * @property [] clock
52
- * @property [_writable_] lpProgram
53
47
  * @category Instructions
54
48
  * @category RedeemDriftS1
55
49
  * @category generated
@@ -61,12 +55,7 @@ export type RedeemDriftS1InstructionAccounts = {
61
55
  adminPermissions?: web3.PublicKey;
62
56
  userReceiptAta: web3.PublicKey;
63
57
  userUsdcAta: web3.PublicKey;
64
- controllerReceiptAta: web3.PublicKey;
65
- controllerIntermediaryAta: web3.PublicKey;
66
58
  controllerUsdcAta: web3.PublicKey;
67
- vault: web3.PublicKey;
68
- lpPoolIntermediaryAta: web3.PublicKey;
69
- intermediaryMint: web3.PublicKey;
70
59
  receiptMint: web3.PublicKey;
71
60
  drift: web3.PublicKey;
72
61
  state: web3.PublicKey;
@@ -79,7 +68,6 @@ export type RedeemDriftS1InstructionAccounts = {
79
68
  tokenProgram?: web3.PublicKey;
80
69
  systemProgram?: web3.PublicKey;
81
70
  clock: web3.PublicKey;
82
- lpProgram: web3.PublicKey;
83
71
  anchorRemainingAccounts?: web3.AccountMeta[];
84
72
  };
85
73
  export declare const redeemDriftS1InstructionDiscriminator: number[];
@@ -95,36 +95,11 @@ function createRedeemDriftS1Instruction(accounts, args, programId = new web3.Pub
95
95
  isWritable: true,
96
96
  isSigner: false,
97
97
  },
98
- {
99
- pubkey: accounts.controllerReceiptAta,
100
- isWritable: true,
101
- isSigner: false,
102
- },
103
- {
104
- pubkey: accounts.controllerIntermediaryAta,
105
- isWritable: true,
106
- isSigner: false,
107
- },
108
98
  {
109
99
  pubkey: accounts.controllerUsdcAta,
110
100
  isWritable: true,
111
101
  isSigner: false,
112
102
  },
113
- {
114
- pubkey: accounts.vault,
115
- isWritable: true,
116
- isSigner: false,
117
- },
118
- {
119
- pubkey: accounts.lpPoolIntermediaryAta,
120
- isWritable: true,
121
- isSigner: false,
122
- },
123
- {
124
- pubkey: accounts.intermediaryMint,
125
- isWritable: true,
126
- isSigner: false,
127
- },
128
103
  {
129
104
  pubkey: accounts.receiptMint,
130
105
  isWritable: true,
@@ -185,11 +160,6 @@ function createRedeemDriftS1Instruction(accounts, args, programId = new web3.Pub
185
160
  isWritable: false,
186
161
  isSigner: false,
187
162
  },
188
- {
189
- pubkey: accounts.lpProgram,
190
- isWritable: true,
191
- isSigner: false,
192
- },
193
163
  ];
194
164
  if (accounts.anchorRemainingAccounts != null) {
195
165
  for (const acc of accounts.anchorRemainingAccounts) {
@@ -0,0 +1,17 @@
1
+ /**
2
+ * This code was GENERATED using the solita package.
3
+ * Please DO NOT EDIT THIS FILE, instead rerun solita to update it or write a wrapper to add functionality.
4
+ *
5
+ * See: https://github.com/metaplex-foundation/solita
6
+ */
7
+ import * as beet from '@metaplex-foundation/beet';
8
+ export type Capture = {
9
+ minCaptureValue: beet.bignum;
10
+ captureInterval: beet.bignum;
11
+ lastCaptureTimestamp: beet.bignum;
12
+ };
13
+ /**
14
+ * @category userTypes
15
+ * @category generated
16
+ */
17
+ export declare const captureBeet: beet.BeetArgsStruct<Capture>;
@@ -0,0 +1,42 @@
1
+ "use strict";
2
+ /**
3
+ * This code was GENERATED using the solita package.
4
+ * Please DO NOT EDIT THIS FILE, instead rerun solita to update it or write a wrapper to add functionality.
5
+ *
6
+ * See: https://github.com/metaplex-foundation/solita
7
+ */
8
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
9
+ if (k2 === undefined) k2 = k;
10
+ var desc = Object.getOwnPropertyDescriptor(m, k);
11
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
12
+ desc = { enumerable: true, get: function() { return m[k]; } };
13
+ }
14
+ Object.defineProperty(o, k2, desc);
15
+ }) : (function(o, m, k, k2) {
16
+ if (k2 === undefined) k2 = k;
17
+ o[k2] = m[k];
18
+ }));
19
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
20
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
21
+ }) : function(o, v) {
22
+ o["default"] = v;
23
+ });
24
+ var __importStar = (this && this.__importStar) || function (mod) {
25
+ if (mod && mod.__esModule) return mod;
26
+ var result = {};
27
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
28
+ __setModuleDefault(result, mod);
29
+ return result;
30
+ };
31
+ Object.defineProperty(exports, "__esModule", { value: true });
32
+ exports.captureBeet = void 0;
33
+ const beet = __importStar(require("@metaplex-foundation/beet"));
34
+ /**
35
+ * @category userTypes
36
+ * @category generated
37
+ */
38
+ exports.captureBeet = new beet.BeetArgsStruct([
39
+ ['minCaptureValue', beet.u64],
40
+ ['captureInterval', beet.i64],
41
+ ['lastCaptureTimestamp', beet.i64],
42
+ ], 'Capture');
@@ -32,11 +32,17 @@ export type PermissionLevelRecord = {
32
32
  * @category generated
33
33
  */
34
34
  export type PermissionLevel = beet.DataEnumKeyAsKind<PermissionLevelRecord>;
35
- export declare const isPermissionLevelProtocol: (x: PermissionLevel) => x is PermissionLevel & {
35
+ export declare const isPermissionLevelProtocol: (x: PermissionLevel) => x is {
36
36
  __kind: "Protocol";
37
+ } & Omit<void, "void"> & {
38
+ __kind: 'Protocol';
37
39
  };
38
- export declare const isPermissionLevelStrategy: (x: PermissionLevel) => x is PermissionLevel & {
40
+ export declare const isPermissionLevelStrategy: (x: PermissionLevel) => x is {
39
41
  __kind: "Strategy";
42
+ } & Omit<{
43
+ fields: [number];
44
+ }, "void"> & {
45
+ __kind: 'Strategy';
40
46
  };
41
47
  /**
42
48
  * @category userTypes
@@ -7,6 +7,7 @@ export * from './ActionMapping';
7
7
  export * from './AssetTier';
8
8
  export * from './Attenuation';
9
9
  export * from './BalanceType';
10
+ export * from './Capture';
10
11
  export * from './ContractTier';
11
12
  export * from './ContractType';
12
13
  export * from './CorpAction';
@@ -23,6 +23,7 @@ __exportStar(require("./ActionMapping"), exports);
23
23
  __exportStar(require("./AssetTier"), exports);
24
24
  __exportStar(require("./Attenuation"), exports);
25
25
  __exportStar(require("./BalanceType"), exports);
26
+ __exportStar(require("./Capture"), exports);
26
27
  __exportStar(require("./ContractTier"), exports);
27
28
  __exportStar(require("./ContractType"), exports);
28
29
  __exportStar(require("./CorpAction"), exports);
@@ -4,6 +4,8 @@
4
4
  *
5
5
  * See: https://github.com/metaplex-foundation/solita
6
6
  */
7
+ /// <reference types="node" />
8
+ /// <reference types="node" />
7
9
  import * as web3 from '@solana/web3.js';
8
10
  import * as beetSolana from '@metaplex-foundation/beet-solana';
9
11
  import * as beet from '@metaplex-foundation/beet';
@@ -90,7 +90,7 @@ class Admin {
90
90
  *
91
91
  * @param programId - the program that owns the accounts we are filtering
92
92
  */
93
- static gpaBuilder(programId = new web3.PublicKey('6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop')) {
93
+ static gpaBuilder(programId = new web3.PublicKey('3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd')) {
94
94
  return beetSolana.GpaBuilder.fromStruct(programId, exports.adminBeet);
95
95
  }
96
96
  /**
@@ -4,6 +4,8 @@
4
4
  *
5
5
  * See: https://github.com/metaplex-foundation/solita
6
6
  */
7
+ /// <reference types="node" />
8
+ /// <reference types="node" />
7
9
  import * as beet from '@metaplex-foundation/beet';
8
10
  import * as web3 from '@solana/web3.js';
9
11
  import * as beetSolana from '@metaplex-foundation/beet-solana';
@@ -90,7 +90,7 @@ class Config {
90
90
  *
91
91
  * @param programId - the program that owns the accounts we are filtering
92
92
  */
93
- static gpaBuilder(programId = new web3.PublicKey('6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop')) {
93
+ static gpaBuilder(programId = new web3.PublicKey('3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd')) {
94
94
  return beetSolana.GpaBuilder.fromStruct(programId, exports.configBeet);
95
95
  }
96
96
  /**
@@ -4,6 +4,8 @@
4
4
  *
5
5
  * See: https://github.com/metaplex-foundation/solita
6
6
  */
7
+ /// <reference types="node" />
8
+ /// <reference types="node" />
7
9
  import * as beet from '@metaplex-foundation/beet';
8
10
  import * as web3 from '@solana/web3.js';
9
11
  import * as beetSolana from '@metaplex-foundation/beet-solana';
@@ -92,7 +92,7 @@ class Vault {
92
92
  *
93
93
  * @param programId - the program that owns the accounts we are filtering
94
94
  */
95
- static gpaBuilder(programId = new web3.PublicKey('6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop')) {
95
+ static gpaBuilder(programId = new web3.PublicKey('3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd')) {
96
96
  return beetSolana.GpaBuilder.fromStruct(programId, exports.vaultBeet);
97
97
  }
98
98
  /**
@@ -9,7 +9,7 @@ export * from './types';
9
9
  * @category constants
10
10
  * @category generated
11
11
  */
12
- export declare const PROGRAM_ADDRESS = "6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop";
12
+ export declare const PROGRAM_ADDRESS = "3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd";
13
13
  /**
14
14
  * Program public key
15
15
  *
@@ -26,7 +26,7 @@ __exportStar(require("./types"), exports);
26
26
  * @category constants
27
27
  * @category generated
28
28
  */
29
- exports.PROGRAM_ADDRESS = '6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop';
29
+ exports.PROGRAM_ADDRESS = '3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd';
30
30
  /**
31
31
  * Program public key
32
32
  *
@@ -51,7 +51,7 @@ exports.createVaultInstructionDiscriminator = [
51
51
  * @category CreateVault
52
52
  * @category generated
53
53
  */
54
- function createCreateVaultInstruction(accounts, programId = new web3.PublicKey('6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop')) {
54
+ function createCreateVaultInstruction(accounts, programId = new web3.PublicKey('3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd')) {
55
55
  var _a, _b;
56
56
  const [data] = exports.createVaultStruct.serialize({
57
57
  instructionDiscriminator: exports.createVaultInstructionDiscriminator,
@@ -57,7 +57,7 @@ exports.depositInstructionDiscriminator = [
57
57
  * @category Deposit
58
58
  * @category generated
59
59
  */
60
- function createDepositInstruction(accounts, args, programId = new web3.PublicKey('6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop')) {
60
+ function createDepositInstruction(accounts, args, programId = new web3.PublicKey('3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd')) {
61
61
  var _a;
62
62
  const [data] = exports.depositStruct.serialize(Object.assign({ instructionDiscriminator: exports.depositInstructionDiscriminator }, args));
63
63
  const keys = [
@@ -50,7 +50,7 @@ exports.initializeInstructionDiscriminator = [
50
50
  * @category Initialize
51
51
  * @category generated
52
52
  */
53
- function createInitializeInstruction(accounts, programId = new web3.PublicKey('6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop')) {
53
+ function createInitializeInstruction(accounts, programId = new web3.PublicKey('3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd')) {
54
54
  var _a;
55
55
  const [data] = exports.initializeStruct.serialize({
56
56
  instructionDiscriminator: exports.initializeInstructionDiscriminator,
@@ -57,7 +57,7 @@ exports.withdrawInstructionDiscriminator = [
57
57
  * @category Withdraw
58
58
  * @category generated
59
59
  */
60
- function createWithdrawInstruction(accounts, args, programId = new web3.PublicKey('6ZZ1sxKGuXUBL8HSsHqHaYCg92G9VhMNTcJv1gFURCop')) {
60
+ function createWithdrawInstruction(accounts, args, programId = new web3.PublicKey('3y4JooLs5Y2QQY5gqt49WPoeBirThj7GgQYamia5HxZd')) {
61
61
  var _a;
62
62
  const [data] = exports.withdrawStruct.serialize(Object.assign({ instructionDiscriminator: exports.withdrawInstructionDiscriminator }, args));
63
63
  const keys = [
@@ -1,6 +1,6 @@
1
1
  import { Stablecoin } from "../classes/Stablecoin";
2
2
  import { Connection, PublicKey, TransactionInstruction } from "@solana/web3.js";
3
- import { DriftLstData } from "../generated/reflect_main";
3
+ import { DriftLstController, DriftLstData } from "../generated/reflect_main";
4
4
  import BN from "bn.js";
5
5
  /**
6
6
  * LST (Liquid Staking Token) Delta-Neutral Stablecoin implementation.
@@ -11,7 +11,7 @@ import BN from "bn.js";
11
11
  * while maintaining delta-neutral exposure through perpetual futures hedging.
12
12
  * Strategy ID: 2
13
13
  */
14
- export declare class LstStablecoin extends Stablecoin {
14
+ export declare class LstStablecoin extends Stablecoin<DriftLstController> {
15
15
  /** Array of LST data containing market indices and sub-account mappings */
16
16
  lstMap: DriftLstData[];
17
17
  /**
@@ -61,4 +61,5 @@ export declare class LstStablecoin extends Stablecoin {
61
61
  mint(signer: PublicKey, amount: BN | number, minimumReceived: number | BN, lst: PublicKey): Promise<TransactionInstruction[]>;
62
62
  redeem(signer: PublicKey, amount: BN | number, minimumReceived: number | BN, lst: PublicKey): Promise<TransactionInstruction[]>;
63
63
  rebalance(): Promise<TransactionInstruction[]>;
64
+ whitelistCollateral(signer: PublicKey, mint: PublicKey): Promise<TransactionInstruction[]>;
64
65
  }