@strkfarm/sdk 1.0.62 → 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.
package/dist/index.d.ts CHANGED
@@ -845,7 +845,7 @@ declare class SenseiVault extends BaseStrategy<SingleTokenInfo, SingleActionAmou
845
845
  collateralInSTRK: number;
846
846
  }>;
847
847
  getSecondaryTokenPriceRelativeToMain(retry?: number): Promise<number>;
848
- getSettings: () => Promise<starknet.Result>;
848
+ getSettings: () => Promise<starknet.CallResult>;
849
849
  }
850
850
  declare const SenseiStrategies: IStrategyMetadata<SenseiVaultSettings>[];
851
851
 
@@ -921,6 +921,9 @@ interface FlashloanCallParams {
921
921
  interface ApproveCallParams {
922
922
  amount: Web3Number;
923
923
  }
924
+ interface AvnuSwapCallParams {
925
+ props: SwapInfo;
926
+ }
924
927
  interface CommonAdapterConfig {
925
928
  id: string;
926
929
  vaultAddress: ContractAddr;
@@ -951,6 +954,8 @@ declare class CommonAdapter extends BaseAdapter {
951
954
  calldata: bigint[];
952
955
  };
953
956
  };
957
+ getAvnuAdapter(fromToken: ContractAddr, toToken: ContractAddr, id: string): () => AdapterLeafType<AvnuSwapCallParams>;
958
+ getAvnuCall(fromToken: ContractAddr, toToken: ContractAddr): GenerateCallFn<AvnuSwapCallParams>;
954
959
  }
955
960
 
956
961
  interface VesuPoolsInfo {
@@ -978,6 +983,10 @@ interface VesuModifyPositionCallParams {
978
983
  collateralAmount: VesuAmount;
979
984
  debtAmount: VesuAmount;
980
985
  }
986
+ interface VesuDefiSpringRewardsCallParams {
987
+ amount: Web3Number;
988
+ proofs: string[];
989
+ }
981
990
  interface VesuAdapterConfig {
982
991
  poolId: ContractAddr;
983
992
  collateral: TokenInfo;
@@ -1019,6 +1028,8 @@ declare class VesuAdapter extends BaseAdapter {
1019
1028
  };
1020
1029
  };
1021
1030
  getModifyPositionCall: (params: VesuModifyPositionCallParams) => ManageCall;
1031
+ getDefispringRewardsAdapter: (id: string) => () => AdapterLeafType<VesuDefiSpringRewardsCallParams>;
1032
+ getDefiSpringClaimCall: () => GenerateCallFn<VesuDefiSpringRewardsCallParams>;
1022
1033
  formatAmountTypeEnum(amountType: VesuAmountType): CairoCustomEnum;
1023
1034
  formatAmountDenominationEnum(denomination: VesuAmountDenomination): CairoCustomEnum;
1024
1035
  getVesuSingletonContract(config: IConfig): Contract;
@@ -1151,6 +1162,11 @@ declare class UniversalStrategy<S extends UniversalStrategySettings> extends Bas
1151
1162
  getBringLiquidityCall(params: {
1152
1163
  amount: Web3Number;
1153
1164
  }): Promise<Call>;
1165
+ getHarvestCall(): Promise<{
1166
+ call: Call;
1167
+ reward: Web3Number;
1168
+ tokenInfo: TokenInfo;
1169
+ }>;
1154
1170
  getRebalanceCall(params: {
1155
1171
  isLeg1toLeg2: boolean;
1156
1172
  amount: Web3Number;
@@ -1163,7 +1179,10 @@ declare enum UNIVERSAL_MANAGE_IDS {
1163
1179
  APPROVE_TOKEN1 = "approve_token1",
1164
1180
  APPROVE_TOKEN2 = "approve_token2",
1165
1181
  APPROVE_BRING_LIQUIDITY = "approve_bring_liquidity",
1166
- BRING_LIQUIDITY = "bring_liquidity"
1182
+ BRING_LIQUIDITY = "bring_liquidity",
1183
+ DEFISPRING_REWARDS = "defispring_rewards",
1184
+ APPROVE_SWAP_TOKEN1 = "approve_swap_token1",
1185
+ AVNU_SWAP_REWARDS = "avnu_swap_rewards"
1167
1186
  }
1168
1187
  declare enum UNIVERSAL_ADAPTERS {
1169
1188
  COMMON = "common_adapter",
@@ -1275,7 +1294,7 @@ declare class Store {
1275
1294
  private encryptor;
1276
1295
  constructor(config: IConfig, storeConfig: StoreConfig);
1277
1296
  static logPassword(password: string): void;
1278
- getAccount(accountKey: string, txVersion?: "0x2" | "0x3"): Account;
1297
+ getAccount(accountKey: string, txVersion: undefined | "0x3"): Account;
1279
1298
  addAccount(accountKey: string, address: string, pk: string): void;
1280
1299
  private getAccountFilePath;
1281
1300
  private getAllAccounts;
@@ -1304,4 +1323,4 @@ declare class PasswordJsonCryptoUtil {
1304
1323
  decrypt(encryptedData: string, password: string): any;
1305
1324
  }
1306
1325
 
1307
- export { AUMTypes, type AccountInfo, type AdapterLeafType, type AllAccountsStore, type ApproveCallParams, AutoCompounderSTRK, AvnuWrapper, BaseAdapter, BaseStrategy, type CLVaultStrategySettings, CommonAdapter, type CommonAdapterConfig, ContractAddr, Deployer, type DualActionAmount, type DualTokenInfo, ERC20, type EkuboBounds, EkuboCLVault, EkuboCLVaultStrategies, type EkuboPoolKey, type FAQ, FatalError, type FlashloanCallParams, FlowChartColors, type GenerateCallFn, Global, type IConfig, type IInvestmentFlow, ILending, type ILendingMetadata, type ILendingPosition, type IProtocol, type IStrategyMetadata, Initializable, type LeafAdapterFn, type LeafData, type LendingToken, type ManageCall, MarginType, Network, PasswordJsonCryptoUtil, Pragma, type PriceInfo, Pricer, PricerFromApi, PricerRedis, Protocols, type RequiredFields, type RequiredKeys, type RequiredStoreConfig, type RiskFactor, RiskType, type Route, SenseiStrategies, SenseiVault, type SenseiVaultSettings, type SingleActionAmount, type SingleTokenInfo, StandardMerkleTree, type StandardMerkleTreeData, Store, type StoreConfig, type SwapInfo, TelegramNotif, type TokenInfo, UNIVERSAL_ADAPTERS, UNIVERSAL_MANAGE_IDS, UniversalStrategies, UniversalStrategy, type UniversalStrategySettings, type VaultPosition, VesuAdapter, type VesuAdapterConfig, type VesuAmount, VesuAmountDenomination, VesuAmountType, type VesuModifyPositionCallParams, VesuPools, VesuRebalance, type VesuRebalanceSettings, VesuRebalanceStrategies, Web3Number, ZkLend, assert, getAPIUsingHeadlessBrowser, getDefaultStoreConfig, getMainnetConfig, getNoRiskTags, getRiskColor, getRiskExplaination, getTrovesEndpoint, highlightTextWithLinks, type i257, logger };
1326
+ export { AUMTypes, type AccountInfo, type AdapterLeafType, type AllAccountsStore, type ApproveCallParams, AutoCompounderSTRK, type AvnuSwapCallParams, AvnuWrapper, BaseAdapter, BaseStrategy, type CLVaultStrategySettings, CommonAdapter, type CommonAdapterConfig, ContractAddr, Deployer, type DualActionAmount, type DualTokenInfo, ERC20, type EkuboBounds, EkuboCLVault, EkuboCLVaultStrategies, type EkuboPoolKey, type FAQ, FatalError, type FlashloanCallParams, FlowChartColors, type GenerateCallFn, Global, type IConfig, type IInvestmentFlow, ILending, type ILendingMetadata, type ILendingPosition, type IProtocol, type IStrategyMetadata, Initializable, type LeafAdapterFn, type LeafData, type LendingToken, type ManageCall, MarginType, Network, PasswordJsonCryptoUtil, Pragma, type PriceInfo, Pricer, PricerFromApi, PricerRedis, Protocols, type RequiredFields, type RequiredKeys, type RequiredStoreConfig, type RiskFactor, RiskType, type Route, SenseiStrategies, SenseiVault, type SenseiVaultSettings, type SingleActionAmount, type SingleTokenInfo, StandardMerkleTree, type StandardMerkleTreeData, Store, type StoreConfig, type SwapInfo, TelegramNotif, type TokenInfo, UNIVERSAL_ADAPTERS, UNIVERSAL_MANAGE_IDS, UniversalStrategies, UniversalStrategy, type UniversalStrategySettings, type VaultPosition, VesuAdapter, type VesuAdapterConfig, type VesuAmount, VesuAmountDenomination, VesuAmountType, type VesuDefiSpringRewardsCallParams, type VesuModifyPositionCallParams, VesuPools, VesuRebalance, type VesuRebalanceSettings, VesuRebalanceStrategies, Web3Number, ZkLend, assert, getAPIUsingHeadlessBrowser, getDefaultStoreConfig, getMainnetConfig, getNoRiskTags, getRiskColor, getRiskExplaination, getTrovesEndpoint, highlightTextWithLinks, type i257, logger };