@reflectmoney/stable.ts 1.1.4 → 1.1.5
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/dist/classes/ApiClient.d.ts +30 -2
- package/dist/classes/ApiClient.js +24 -2
- package/dist/classes/ReflectKeeper.d.ts +1 -1
- package/dist/classes/ReflectKeeper.js +4 -3
- package/dist/classes/index.d.ts +1 -0
- package/dist/classes/index.js +1 -0
- package/dist/constants/lookupTables.js +1 -1
- package/dist/generated/reflect_main/accounts/DriftJlpController.js +1 -1
- package/dist/generated/reflect_main/accounts/DriftLstController.js +1 -1
- package/dist/generated/reflect_main/accounts/DriftUsdcController.d.ts +6 -25
- package/dist/generated/reflect_main/accounts/DriftUsdcController.js +8 -60
- package/dist/generated/reflect_main/accounts/Main.js +1 -1
- package/dist/generated/reflect_main/accounts/PerpMarket.js +1 -1
- package/dist/generated/reflect_main/accounts/PrelaunchOracle.js +1 -1
- package/dist/generated/reflect_main/accounts/PythLazerOracle.js +1 -1
- package/dist/generated/reflect_main/accounts/RebalanceLst.js +1 -1
- package/dist/generated/reflect_main/accounts/SpotMarket.js +1 -1
- package/dist/generated/reflect_main/accounts/User.js +1 -1
- package/dist/generated/reflect_main/accounts/UserPermissions.js +1 -1
- package/dist/generated/reflect_main/accounts/UserStats.js +1 -1
- package/dist/generated/reflect_main/errors/index.d.ts +14 -14
- package/dist/generated/reflect_main/errors/index.js +133 -133
- package/dist/generated/reflect_main/index.d.ts +1 -1
- package/dist/generated/reflect_main/index.js +1 -1
- package/dist/generated/reflect_main/instructions/addLstDrift.js +1 -1
- package/dist/generated/reflect_main/instructions/addSubAccount.js +1 -1
- package/dist/generated/reflect_main/instructions/captureSpreadDrift.d.ts +2 -2
- package/dist/generated/reflect_main/instructions/captureSpreadDrift.js +3 -3
- package/dist/generated/reflect_main/instructions/createAdminAccount.d.ts +1 -0
- package/dist/generated/reflect_main/instructions/createAdminAccount.js +2 -1
- package/dist/generated/reflect_main/instructions/createUserStatsAccount.js +1 -1
- package/dist/generated/reflect_main/instructions/depositDrift.js +1 -1
- package/dist/generated/reflect_main/instructions/freezeProgram.js +1 -1
- package/dist/generated/reflect_main/instructions/freezeProtocolAction.js +1 -1
- package/dist/generated/reflect_main/instructions/freezeStrategyAction.js +1 -1
- package/dist/generated/reflect_main/instructions/increaseAdminSize.d.ts +51 -0
- package/dist/generated/reflect_main/instructions/increaseAdminSize.js +89 -0
- package/dist/generated/reflect_main/instructions/index.d.ts +1 -1
- package/dist/generated/reflect_main/instructions/index.js +1 -1
- package/dist/generated/reflect_main/instructions/initDriftAccountsS1.js +1 -1
- package/dist/generated/reflect_main/instructions/initDriftControllerS1.js +1 -1
- package/dist/generated/reflect_main/instructions/initDriftControllerS3.js +1 -1
- package/dist/generated/reflect_main/instructions/initMain.js +1 -1
- package/dist/generated/reflect_main/instructions/mintDriftS1.js +1 -1
- package/dist/generated/reflect_main/instructions/mintDriftS3.js +1 -1
- package/dist/generated/reflect_main/instructions/processSwapDeposit.js +1 -1
- package/dist/generated/reflect_main/instructions/processSwapWithdraw.js +1 -1
- package/dist/generated/reflect_main/instructions/redeemDriftS1.js +1 -1
- package/dist/generated/reflect_main/instructions/redeemDriftS3.js +1 -1
- package/dist/generated/reflect_main/instructions/settlePnl.d.ts +0 -5
- package/dist/generated/reflect_main/instructions/settlePnl.js +1 -10
- package/dist/generated/reflect_main/instructions/settlePnlMulti.d.ts +0 -5
- package/dist/generated/reflect_main/instructions/settlePnlMulti.js +1 -10
- package/dist/generated/reflect_main/instructions/suspendSplProtocol.js +1 -1
- package/dist/generated/reflect_main/instructions/suspendSplStrategy.js +1 -1
- package/dist/generated/reflect_main/instructions/swapOrca.js +1 -1
- package/dist/generated/reflect_main/instructions/swapOrcaTwoHop.js +1 -1
- package/dist/generated/reflect_main/instructions/updateActionRoleProtocol.js +1 -1
- package/dist/generated/reflect_main/instructions/updateActionRoleStrategy.js +1 -1
- package/dist/generated/reflect_main/instructions/updateAttenuation.js +1 -1
- package/dist/generated/reflect_main/instructions/updateCap.js +1 -1
- package/dist/generated/reflect_main/instructions/updateRebalanceSlippage.js +1 -1
- package/dist/generated/reflect_main/instructions/updateRecipients.js +1 -1
- package/dist/generated/reflect_main/instructions/updateRoleHolderProtocol.js +1 -1
- package/dist/generated/reflect_main/instructions/updateRoleHolderStrategy.js +1 -1
- package/dist/generated/reflect_main/types/AutoCompound.d.ts +18 -0
- package/dist/generated/reflect_main/types/AutoCompound.js +43 -0
- package/dist/generated/reflect_main/types/Capture.d.ts +2 -0
- package/dist/generated/reflect_main/types/Capture.js +2 -0
- package/dist/generated/reflect_main/types/OrderParams.d.ts +1 -1
- package/dist/generated/reflect_main/types/OrderParams.js +1 -1
- package/dist/generated/reflect_main/types/Strategy.d.ts +2 -0
- package/dist/generated/reflect_main/types/Strategy.js +2 -0
- package/dist/generated/reflect_main/types/YieldDistribution.d.ts +20 -0
- package/dist/generated/reflect_main/types/YieldDistribution.js +47 -0
- package/dist/generated/reflect_main/types/index.d.ts +2 -0
- package/dist/generated/reflect_main/types/index.js +2 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/dist/types/api.d.ts +212 -0
- package/package.json +2 -2
|
@@ -50,7 +50,35 @@ declare class ApiClient {
|
|
|
50
50
|
name: string;
|
|
51
51
|
}[];
|
|
52
52
|
}>;
|
|
53
|
-
|
|
54
|
-
|
|
53
|
+
getHistoricalUsdExchangeRate(stablecoin: number, period: paths["/stablecoin/exchange-rates/historical"]["get"]["parameters"]["query"]["period"]): Promise<{
|
|
54
|
+
success: boolean;
|
|
55
|
+
data: {
|
|
56
|
+
id: number;
|
|
57
|
+
stablecoin: 0 | 2;
|
|
58
|
+
base_usd_value_bps: number;
|
|
59
|
+
receipt_usd_value_bps: number;
|
|
60
|
+
timestamp: string;
|
|
61
|
+
}[];
|
|
62
|
+
}>;
|
|
63
|
+
getRealtimeUsdExchangeRate(stablecoin: number): Promise<{
|
|
64
|
+
success: boolean;
|
|
65
|
+
data: {
|
|
66
|
+
id: number;
|
|
67
|
+
stablecoin: 0 | 2;
|
|
68
|
+
base_usd_value_bps: number;
|
|
69
|
+
receipt_usd_value_bps: number;
|
|
70
|
+
timestamp: string;
|
|
71
|
+
};
|
|
72
|
+
}>;
|
|
73
|
+
getRealtimeUsdExchangeRatesForAllStablecoins(): Promise<{
|
|
74
|
+
success: boolean;
|
|
75
|
+
data: {
|
|
76
|
+
id: number;
|
|
77
|
+
stablecoin: 0 | 2;
|
|
78
|
+
base_usd_value_bps: number;
|
|
79
|
+
receipt_usd_value_bps: number;
|
|
80
|
+
timestamp: string;
|
|
81
|
+
}[];
|
|
82
|
+
}>;
|
|
55
83
|
}
|
|
56
84
|
export { ApiClient };
|
|
@@ -105,12 +105,34 @@ class ApiClient {
|
|
|
105
105
|
return data;
|
|
106
106
|
});
|
|
107
107
|
}
|
|
108
|
-
|
|
108
|
+
getHistoricalUsdExchangeRate(stablecoin, period) {
|
|
109
109
|
return __awaiter(this, void 0, void 0, function* () {
|
|
110
|
+
const { data } = yield axios_1.default
|
|
111
|
+
.get(`${this.url}/stablecoin/exchange-rates/historical`, {
|
|
112
|
+
params: {
|
|
113
|
+
strategy: stablecoin,
|
|
114
|
+
period
|
|
115
|
+
}
|
|
116
|
+
});
|
|
117
|
+
return data;
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
getRealtimeUsdExchangeRate(stablecoin) {
|
|
121
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
122
|
+
const { data } = yield axios_1.default
|
|
123
|
+
.get(`${this.url}/stablecoin/exchange-rates/realtime`, {
|
|
124
|
+
params: {
|
|
125
|
+
strategy: stablecoin,
|
|
126
|
+
}
|
|
127
|
+
});
|
|
128
|
+
return data;
|
|
110
129
|
});
|
|
111
130
|
}
|
|
112
|
-
|
|
131
|
+
getRealtimeUsdExchangeRatesForAllStablecoins() {
|
|
113
132
|
return __awaiter(this, void 0, void 0, function* () {
|
|
133
|
+
const { data } = yield axios_1.default
|
|
134
|
+
.get(`${this.url}/stablecoin/exchange-rates`);
|
|
135
|
+
return data;
|
|
114
136
|
});
|
|
115
137
|
}
|
|
116
138
|
}
|
|
@@ -59,7 +59,7 @@ export declare class ReflectKeeper {
|
|
|
59
59
|
* @param newAdmin - Public key of the new admin to create
|
|
60
60
|
* @returns Promise resolving to a TransactionInstruction
|
|
61
61
|
*/
|
|
62
|
-
createAdminAccount(signer: PublicKey, newAdmin: PublicKey): Promise<import("@solana/web3.js").TransactionInstruction>;
|
|
62
|
+
createAdminAccount(signer: PublicKey, newAdmin: PublicKey, roles?: number): Promise<import("@solana/web3.js").TransactionInstruction>;
|
|
63
63
|
/**
|
|
64
64
|
* Updates role holder permissions at the protocol level.
|
|
65
65
|
*
|
|
@@ -108,14 +108,15 @@ class ReflectKeeper {
|
|
|
108
108
|
* @param newAdmin - Public key of the new admin to create
|
|
109
109
|
* @returns Promise resolving to a TransactionInstruction
|
|
110
110
|
*/
|
|
111
|
-
createAdminAccount(
|
|
112
|
-
return __awaiter(this,
|
|
111
|
+
createAdminAccount(signer_1, newAdmin_1) {
|
|
112
|
+
return __awaiter(this, arguments, void 0, function* (signer, newAdmin, roles = 18) {
|
|
113
113
|
const ix = (0, reflect_main_1.createCreateAdminAccountInstruction)({
|
|
114
114
|
caller: signer,
|
|
115
115
|
newCreds: PdaClient_1.PdaClient.derivePermissions(newAdmin),
|
|
116
116
|
systemProgram: web3_js_1.SystemProgram.programId,
|
|
117
117
|
}, {
|
|
118
|
-
newAdmin
|
|
118
|
+
newAdmin,
|
|
119
|
+
roles
|
|
119
120
|
}, reflect_main_1.PROGRAM_ID);
|
|
120
121
|
return ix;
|
|
121
122
|
});
|
package/dist/classes/index.d.ts
CHANGED
package/dist/classes/index.js
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.LST_LOOKUP_TABLE = exports.JLP_LOOKUP_TABLE = exports.USDC_PLUS_LOOKUP_TABLE = void 0;
|
|
4
4
|
const web3_js_1 = require("@solana/web3.js");
|
|
5
|
-
exports.USDC_PLUS_LOOKUP_TABLE = new web3_js_1.PublicKey(
|
|
5
|
+
exports.USDC_PLUS_LOOKUP_TABLE = new web3_js_1.PublicKey("3ucoeL8gcwaYS35WiCCEqXZDwoFTYT8PdC1PEw6omX3t");
|
|
6
6
|
exports.JLP_LOOKUP_TABLE = new web3_js_1.PublicKey(0);
|
|
7
7
|
exports.LST_LOOKUP_TABLE = new web3_js_1.PublicKey(0);
|
|
@@ -97,7 +97,7 @@ class DriftJlpController {
|
|
|
97
97
|
*
|
|
98
98
|
* @param programId - the program that owns the accounts we are filtering
|
|
99
99
|
*/
|
|
100
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
100
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
101
101
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.driftJlpControllerBeet);
|
|
102
102
|
}
|
|
103
103
|
/**
|
|
@@ -97,7 +97,7 @@ class DriftLstController {
|
|
|
97
97
|
*
|
|
98
98
|
* @param programId - the program that owns the accounts we are filtering
|
|
99
99
|
*/
|
|
100
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
100
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
101
101
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.driftLstControllerBeet);
|
|
102
102
|
}
|
|
103
103
|
/**
|
|
@@ -4,11 +4,12 @@
|
|
|
4
4
|
*
|
|
5
5
|
* See: https://github.com/metaplex-foundation/solita
|
|
6
6
|
*/
|
|
7
|
-
import * as beet from '@metaplex-foundation/beet';
|
|
8
7
|
import * as web3 from '@solana/web3.js';
|
|
8
|
+
import * as beet from '@metaplex-foundation/beet';
|
|
9
9
|
import * as beetSolana from '@metaplex-foundation/beet-solana';
|
|
10
10
|
import { Strategy } from '../types/Strategy';
|
|
11
11
|
import { DriftControllerBase } from '../types/DriftControllerBase';
|
|
12
|
+
import { AutoCompound } from '../types/AutoCompound';
|
|
12
13
|
/**
|
|
13
14
|
* Arguments used to create {@link DriftUsdcController}
|
|
14
15
|
* @category Accounts
|
|
@@ -17,10 +18,7 @@ import { DriftControllerBase } from '../types/DriftControllerBase';
|
|
|
17
18
|
export type DriftUsdcControllerArgs = {
|
|
18
19
|
baseStrategy: Strategy;
|
|
19
20
|
baseDrift: DriftControllerBase;
|
|
20
|
-
|
|
21
|
-
lastPoolValue: beet.bignum;
|
|
22
|
-
effectiveSupply: beet.bignum;
|
|
23
|
-
depositedVaultValue: beet.bignum;
|
|
21
|
+
compounder: AutoCompound;
|
|
24
22
|
};
|
|
25
23
|
export declare const driftUsdcControllerDiscriminator: number[];
|
|
26
24
|
/**
|
|
@@ -33,10 +31,7 @@ export declare const driftUsdcControllerDiscriminator: number[];
|
|
|
33
31
|
export declare class DriftUsdcController implements DriftUsdcControllerArgs {
|
|
34
32
|
readonly baseStrategy: Strategy;
|
|
35
33
|
readonly baseDrift: DriftControllerBase;
|
|
36
|
-
readonly
|
|
37
|
-
readonly lastPoolValue: beet.bignum;
|
|
38
|
-
readonly effectiveSupply: beet.bignum;
|
|
39
|
-
readonly depositedVaultValue: beet.bignum;
|
|
34
|
+
readonly compounder: AutoCompound;
|
|
40
35
|
private constructor();
|
|
41
36
|
/**
|
|
42
37
|
* Creates a {@link DriftUsdcController} instance from the provided args.
|
|
@@ -64,10 +59,7 @@ export declare class DriftUsdcController implements DriftUsdcControllerArgs {
|
|
|
64
59
|
accountDiscriminator: any;
|
|
65
60
|
baseStrategy: any;
|
|
66
61
|
baseDrift: any;
|
|
67
|
-
|
|
68
|
-
lastPoolValue: any;
|
|
69
|
-
effectiveSupply: any;
|
|
70
|
-
depositedVaultValue: any;
|
|
62
|
+
compounder: any;
|
|
71
63
|
}>;
|
|
72
64
|
/**
|
|
73
65
|
* Deserializes the {@link DriftUsdcController} from the provided data Buffer.
|
|
@@ -103,18 +95,7 @@ export declare class DriftUsdcController implements DriftUsdcControllerArgs {
|
|
|
103
95
|
pretty(): {
|
|
104
96
|
baseStrategy: Strategy;
|
|
105
97
|
baseDrift: DriftControllerBase;
|
|
106
|
-
|
|
107
|
-
toNumber: () => number;
|
|
108
|
-
};
|
|
109
|
-
lastPoolValue: number | {
|
|
110
|
-
toNumber: () => number;
|
|
111
|
-
};
|
|
112
|
-
effectiveSupply: number | {
|
|
113
|
-
toNumber: () => number;
|
|
114
|
-
};
|
|
115
|
-
depositedVaultValue: number | {
|
|
116
|
-
toNumber: () => number;
|
|
117
|
-
};
|
|
98
|
+
compounder: AutoCompound;
|
|
118
99
|
};
|
|
119
100
|
}
|
|
120
101
|
/**
|
|
@@ -39,11 +39,12 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
39
39
|
};
|
|
40
40
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
41
41
|
exports.driftUsdcControllerBeet = exports.DriftUsdcController = exports.driftUsdcControllerDiscriminator = void 0;
|
|
42
|
-
const beet = __importStar(require("@metaplex-foundation/beet"));
|
|
43
42
|
const web3 = __importStar(require("@solana/web3.js"));
|
|
43
|
+
const beet = __importStar(require("@metaplex-foundation/beet"));
|
|
44
44
|
const beetSolana = __importStar(require("@metaplex-foundation/beet-solana"));
|
|
45
45
|
const Strategy_1 = require("../types/Strategy");
|
|
46
46
|
const DriftControllerBase_1 = require("../types/DriftControllerBase");
|
|
47
|
+
const AutoCompound_1 = require("../types/AutoCompound");
|
|
47
48
|
exports.driftUsdcControllerDiscriminator = [
|
|
48
49
|
148, 44, 102, 104, 86, 118, 225, 194,
|
|
49
50
|
];
|
|
@@ -55,19 +56,16 @@ exports.driftUsdcControllerDiscriminator = [
|
|
|
55
56
|
* @category generated
|
|
56
57
|
*/
|
|
57
58
|
class DriftUsdcController {
|
|
58
|
-
constructor(baseStrategy, baseDrift,
|
|
59
|
+
constructor(baseStrategy, baseDrift, compounder) {
|
|
59
60
|
this.baseStrategy = baseStrategy;
|
|
60
61
|
this.baseDrift = baseDrift;
|
|
61
|
-
this.
|
|
62
|
-
this.lastPoolValue = lastPoolValue;
|
|
63
|
-
this.effectiveSupply = effectiveSupply;
|
|
64
|
-
this.depositedVaultValue = depositedVaultValue;
|
|
62
|
+
this.compounder = compounder;
|
|
65
63
|
}
|
|
66
64
|
/**
|
|
67
65
|
* Creates a {@link DriftUsdcController} instance from the provided args.
|
|
68
66
|
*/
|
|
69
67
|
static fromArgs(args) {
|
|
70
|
-
return new DriftUsdcController(args.baseStrategy, args.baseDrift, args.
|
|
68
|
+
return new DriftUsdcController(args.baseStrategy, args.baseDrift, args.compounder);
|
|
71
69
|
}
|
|
72
70
|
/**
|
|
73
71
|
* Deserializes the {@link DriftUsdcController} from the data of the provided {@link web3.AccountInfo}.
|
|
@@ -97,7 +95,7 @@ class DriftUsdcController {
|
|
|
97
95
|
*
|
|
98
96
|
* @param programId - the program that owns the accounts we are filtering
|
|
99
97
|
*/
|
|
100
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
98
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
101
99
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.driftUsdcControllerBeet);
|
|
102
100
|
}
|
|
103
101
|
/**
|
|
@@ -147,54 +145,7 @@ class DriftUsdcController {
|
|
|
147
145
|
return {
|
|
148
146
|
baseStrategy: this.baseStrategy,
|
|
149
147
|
baseDrift: this.baseDrift,
|
|
150
|
-
|
|
151
|
-
const x = this.netUserFlowSinceCapture;
|
|
152
|
-
if (typeof x.toNumber === 'function') {
|
|
153
|
-
try {
|
|
154
|
-
return x.toNumber();
|
|
155
|
-
}
|
|
156
|
-
catch (_) {
|
|
157
|
-
return x;
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
return x;
|
|
161
|
-
})(),
|
|
162
|
-
lastPoolValue: (() => {
|
|
163
|
-
const x = this.lastPoolValue;
|
|
164
|
-
if (typeof x.toNumber === 'function') {
|
|
165
|
-
try {
|
|
166
|
-
return x.toNumber();
|
|
167
|
-
}
|
|
168
|
-
catch (_) {
|
|
169
|
-
return x;
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
return x;
|
|
173
|
-
})(),
|
|
174
|
-
effectiveSupply: (() => {
|
|
175
|
-
const x = this.effectiveSupply;
|
|
176
|
-
if (typeof x.toNumber === 'function') {
|
|
177
|
-
try {
|
|
178
|
-
return x.toNumber();
|
|
179
|
-
}
|
|
180
|
-
catch (_) {
|
|
181
|
-
return x;
|
|
182
|
-
}
|
|
183
|
-
}
|
|
184
|
-
return x;
|
|
185
|
-
})(),
|
|
186
|
-
depositedVaultValue: (() => {
|
|
187
|
-
const x = this.depositedVaultValue;
|
|
188
|
-
if (typeof x.toNumber === 'function') {
|
|
189
|
-
try {
|
|
190
|
-
return x.toNumber();
|
|
191
|
-
}
|
|
192
|
-
catch (_) {
|
|
193
|
-
return x;
|
|
194
|
-
}
|
|
195
|
-
}
|
|
196
|
-
return x;
|
|
197
|
-
})(),
|
|
148
|
+
compounder: this.compounder,
|
|
198
149
|
};
|
|
199
150
|
}
|
|
200
151
|
}
|
|
@@ -207,8 +158,5 @@ exports.driftUsdcControllerBeet = new beet.BeetStruct([
|
|
|
207
158
|
['accountDiscriminator', beet.uniformFixedSizeArray(beet.u8, 8)],
|
|
208
159
|
['baseStrategy', Strategy_1.strategyBeet],
|
|
209
160
|
['baseDrift', DriftControllerBase_1.driftControllerBaseBeet],
|
|
210
|
-
['
|
|
211
|
-
['lastPoolValue', beet.u64],
|
|
212
|
-
['effectiveSupply', beet.u64],
|
|
213
|
-
['depositedVaultValue', beet.u64],
|
|
161
|
+
['compounder', AutoCompound_1.autoCompoundBeet],
|
|
214
162
|
], DriftUsdcController.fromArgs, 'DriftUsdcController');
|
|
@@ -95,7 +95,7 @@ class Main {
|
|
|
95
95
|
*
|
|
96
96
|
* @param programId - the program that owns the accounts we are filtering
|
|
97
97
|
*/
|
|
98
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
98
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
99
99
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.mainBeet);
|
|
100
100
|
}
|
|
101
101
|
/**
|
|
@@ -122,7 +122,7 @@ class PerpMarket {
|
|
|
122
122
|
*
|
|
123
123
|
* @param programId - the program that owns the accounts we are filtering
|
|
124
124
|
*/
|
|
125
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
125
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
126
126
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.perpMarketBeet);
|
|
127
127
|
}
|
|
128
128
|
/**
|
|
@@ -94,7 +94,7 @@ class PrelaunchOracle {
|
|
|
94
94
|
*
|
|
95
95
|
* @param programId - the program that owns the accounts we are filtering
|
|
96
96
|
*/
|
|
97
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
97
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
98
98
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.prelaunchOracleBeet);
|
|
99
99
|
}
|
|
100
100
|
/**
|
|
@@ -93,7 +93,7 @@ class PythLazerOracle {
|
|
|
93
93
|
*
|
|
94
94
|
* @param programId - the program that owns the accounts we are filtering
|
|
95
95
|
*/
|
|
96
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
96
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
97
97
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.pythLazerOracleBeet);
|
|
98
98
|
}
|
|
99
99
|
/**
|
|
@@ -94,7 +94,7 @@ class RebalanceLst {
|
|
|
94
94
|
*
|
|
95
95
|
* @param programId - the program that owns the accounts we are filtering
|
|
96
96
|
*/
|
|
97
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
97
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
98
98
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.rebalanceLstBeet);
|
|
99
99
|
}
|
|
100
100
|
/**
|
|
@@ -151,7 +151,7 @@ class SpotMarket {
|
|
|
151
151
|
*
|
|
152
152
|
* @param programId - the program that owns the accounts we are filtering
|
|
153
153
|
*/
|
|
154
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
154
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
155
155
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.spotMarketBeet);
|
|
156
156
|
}
|
|
157
157
|
/**
|
|
@@ -117,7 +117,7 @@ class User {
|
|
|
117
117
|
*
|
|
118
118
|
* @param programId - the program that owns the accounts we are filtering
|
|
119
119
|
*/
|
|
120
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
120
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
121
121
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.userBeet);
|
|
122
122
|
}
|
|
123
123
|
/**
|
|
@@ -93,7 +93,7 @@ class UserPermissions {
|
|
|
93
93
|
*
|
|
94
94
|
* @param programId - the program that owns the accounts we are filtering
|
|
95
95
|
*/
|
|
96
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
96
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
97
97
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.userPermissionsBeet);
|
|
98
98
|
}
|
|
99
99
|
/**
|
|
@@ -113,7 +113,7 @@ class UserStats {
|
|
|
113
113
|
*
|
|
114
114
|
* @param programId - the program that owns the accounts we are filtering
|
|
115
115
|
*/
|
|
116
|
-
static gpaBuilder(programId = new web3.PublicKey('
|
|
116
|
+
static gpaBuilder(programId = new web3.PublicKey('rf1ctRXK4bmG5XNttAMYfB3TKd2vQjFv5cfQhDBxdAQ')) {
|
|
117
117
|
return beetSolana.GpaBuilder.fromStruct(programId, exports.userStatsBeet);
|
|
118
118
|
}
|
|
119
119
|
/**
|
|
@@ -108,12 +108,12 @@ export declare class ProtocolAlreadySupportsSplError extends Error {
|
|
|
108
108
|
constructor();
|
|
109
109
|
}
|
|
110
110
|
/**
|
|
111
|
-
*
|
|
111
|
+
* NotEnoughSplInput: 'Not enough funds for this transaction'
|
|
112
112
|
*
|
|
113
113
|
* @category Errors
|
|
114
114
|
* @category generated
|
|
115
115
|
*/
|
|
116
|
-
export declare class
|
|
116
|
+
export declare class NotEnoughSplInputError extends Error {
|
|
117
117
|
readonly code: number;
|
|
118
118
|
readonly name: string;
|
|
119
119
|
constructor();
|
|
@@ -129,17 +129,6 @@ export declare class SplNotFoundError extends Error {
|
|
|
129
129
|
readonly name: string;
|
|
130
130
|
constructor();
|
|
131
131
|
}
|
|
132
|
-
/**
|
|
133
|
-
* NotEnoughStable: 'Not enough SPL funds for this transaction'
|
|
134
|
-
*
|
|
135
|
-
* @category Errors
|
|
136
|
-
* @category generated
|
|
137
|
-
*/
|
|
138
|
-
export declare class NotEnoughStableError extends Error {
|
|
139
|
-
readonly code: number;
|
|
140
|
-
readonly name: string;
|
|
141
|
-
constructor();
|
|
142
|
-
}
|
|
143
132
|
/**
|
|
144
133
|
* StrategyDoesNotSupportSpl: 'Provided SPL mint is not supported at the strategy'
|
|
145
134
|
*
|
|
@@ -504,7 +493,7 @@ export declare class FailedUnwrapError extends Error {
|
|
|
504
493
|
constructor();
|
|
505
494
|
}
|
|
506
495
|
/**
|
|
507
|
-
* SpreadTooSmall: 'Difference
|
|
496
|
+
* SpreadTooSmall: 'Difference is too small to capture'
|
|
508
497
|
*
|
|
509
498
|
* @category Errors
|
|
510
499
|
* @category generated
|
|
@@ -701,6 +690,17 @@ export declare class CouldNotLoadSpotMarketDataError extends Error {
|
|
|
701
690
|
readonly name: string;
|
|
702
691
|
constructor();
|
|
703
692
|
}
|
|
693
|
+
/**
|
|
694
|
+
* UnsettledPnl: 'Position has unsettled PnL and must be settled first'
|
|
695
|
+
*
|
|
696
|
+
* @category Errors
|
|
697
|
+
* @category generated
|
|
698
|
+
*/
|
|
699
|
+
export declare class UnsettledPnlError extends Error {
|
|
700
|
+
readonly code: number;
|
|
701
|
+
readonly name: string;
|
|
702
|
+
constructor();
|
|
703
|
+
}
|
|
704
704
|
/**
|
|
705
705
|
* UnableToLoadOracle: 'Unable To Load Oracles'
|
|
706
706
|
*
|