@strkfarm/sdk 1.1.4 → 1.1.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/dist/index.browser.global.js +541 -253
- package/dist/index.browser.mjs +364 -90
- package/dist/index.d.ts +10 -2
- package/dist/index.js +367 -95
- package/dist/index.mjs +367 -95
- package/package.json +2 -1
- package/src/global.ts +51 -1
- package/src/interfaces/common.tsx +2 -0
- package/src/interfaces/risks.ts +175 -0
- package/src/modules/harvests.ts +2 -1
- package/src/modules/pricer.ts +25 -8
- package/src/notifs/telegram.ts +3 -3
- package/src/strategies/constants.ts +5 -1
- package/src/strategies/ekubo-cl-vault.tsx +288 -81
- package/src/strategies/universal-adapters/vesu-adapter.ts +2 -1
- package/src/strategies/vesu-rebalance.tsx +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -73,6 +73,7 @@ interface TokenInfo {
|
|
|
73
73
|
logo: string;
|
|
74
74
|
coingeckId?: string;
|
|
75
75
|
displayDecimals: number;
|
|
76
|
+
priceProxySymbol?: string;
|
|
76
77
|
priceCheckAmount?: number;
|
|
77
78
|
}
|
|
78
79
|
declare enum Network {
|
|
@@ -133,6 +134,10 @@ interface IStrategyMetadata<T> {
|
|
|
133
134
|
}[];
|
|
134
135
|
docs?: string;
|
|
135
136
|
investmentSteps: string[];
|
|
137
|
+
curator?: {
|
|
138
|
+
name: string;
|
|
139
|
+
logo: string;
|
|
140
|
+
};
|
|
136
141
|
}
|
|
137
142
|
interface IInvestmentFlow {
|
|
138
143
|
id?: string;
|
|
@@ -232,13 +237,15 @@ declare class Pricer extends PricerBase {
|
|
|
232
237
|
protected prices: {
|
|
233
238
|
[key: string]: PriceInfo;
|
|
234
239
|
};
|
|
240
|
+
refreshInterval: number;
|
|
241
|
+
staleTime: number;
|
|
235
242
|
private methodToUse;
|
|
236
243
|
/**
|
|
237
244
|
* TOKENA and TOKENB are the two token names to get price of TokenA in terms of TokenB
|
|
238
245
|
*/
|
|
239
246
|
protected PRICE_API: string;
|
|
240
247
|
protected EKUBO_API: string;
|
|
241
|
-
constructor(config: IConfig, tokens: TokenInfo[]);
|
|
248
|
+
constructor(config: IConfig, tokens: TokenInfo[], refreshInterval?: number, staleTime?: number);
|
|
242
249
|
isReady(): boolean;
|
|
243
250
|
waitTillReady(): Promise<void>;
|
|
244
251
|
start(): void;
|
|
@@ -668,6 +675,7 @@ interface CLVaultStrategySettings {
|
|
|
668
675
|
direction: "any" | "uponly";
|
|
669
676
|
customShouldRebalance: (currentPoolPrice: number) => Promise<boolean>;
|
|
670
677
|
};
|
|
678
|
+
quoteAsset: TokenInfo;
|
|
671
679
|
}
|
|
672
680
|
declare class EkuboCLVault extends BaseStrategy<DualTokenInfo, DualActionAmount> {
|
|
673
681
|
/** Contract address of the strategy */
|
|
@@ -816,7 +824,7 @@ declare class EkuboCLVault extends BaseStrategy<DualTokenInfo, DualActionAmount>
|
|
|
816
824
|
getInvestmentFlows(): Promise<IInvestmentFlow[]>;
|
|
817
825
|
}
|
|
818
826
|
/**
|
|
819
|
-
* Represents the
|
|
827
|
+
* Represents the Ekubo CL Vault Strategies.
|
|
820
828
|
*/
|
|
821
829
|
declare const EkuboCLVaultStrategies: IStrategyMetadata<CLVaultStrategySettings>[];
|
|
822
830
|
|