@wardenswap/bestrate-sdk-beta 2.7.0 → 2.8.0

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.d.ts CHANGED
@@ -306,29 +306,31 @@ declare enum DexModel {
306
306
  CurveMetaSol = 10,
307
307
  CurveCrypto = 11,
308
308
  CurveTriCryptoNG = 12,
309
- CurveLendingA = 13,
310
- CurveLendingCryptoZap = 14,
311
- CurveLendingCryptoTwoZap = 15,
312
- PolyDex = 16,
313
- FireBirdWeighted = 17,
314
- BalancerWeighted = 18,
315
- BalancerStable = 19,
316
- BalancerMetaStable = 20,
317
- BalancerBoostedStable = 21,
318
- BalancerLinear = 22,
319
- BalancerLiquidityBootstrapping = 23,
320
- Biswap = 24,
321
- DodoV1 = 25,
322
- DodoV2 = 26,
323
- Mdex = 27,
324
- Mars = 28,
325
- Smoothy = 29,
326
- Shibaswap = 30,
327
- GmxDex = 31,
328
- Solidly = 32,
329
- VelodromeV2 = 33,
330
- Synthetix = 34,
331
- Unknown = 35
309
+ CurveStableNG = 13,
310
+ CurveLendingA = 14,
311
+ CurveLendingCryptoZap = 15,
312
+ CurveLendingCryptoTwoZap = 16,
313
+ CurveLido = 17,
314
+ PolyDex = 18,
315
+ FireBirdWeighted = 19,
316
+ BalancerWeighted = 20,
317
+ BalancerStable = 21,
318
+ BalancerMetaStable = 22,
319
+ BalancerBoostedStable = 23,
320
+ BalancerLinear = 24,
321
+ BalancerLiquidityBootstrapping = 25,
322
+ Biswap = 26,
323
+ DodoV1 = 27,
324
+ DodoV2 = 28,
325
+ Mdex = 29,
326
+ Mars = 30,
327
+ Smoothy = 31,
328
+ Shibaswap = 32,
329
+ GmxDex = 33,
330
+ Solidly = 34,
331
+ VelodromeV2 = 35,
332
+ Synthetix = 36,
333
+ Unknown = 37
332
334
  }
333
335
  interface UniswapV2BasedModelInfo {
334
336
  model: DexModel.UniswapV2 | DexModel.Mdex | DexModel.Biswap | DexModel.Mars | DexModel.Shibaswap;
@@ -371,6 +373,11 @@ interface CurvePlainModelInfo {
371
373
  aPrecision?: bigint;
372
374
  balancesArgs?: string;
373
375
  }
376
+ interface CurveLidoModelInfo extends Omit<CurvePlainModelInfo, 'model'> {
377
+ model: DexModel.CurveLido;
378
+ oracleAddress: string;
379
+ stethCoinIdx: number;
380
+ }
374
381
  interface CurveLendingModelInfo {
375
382
  model: DexModel.CurveLendingA;
376
383
  poolContract: string;
@@ -388,6 +395,14 @@ interface CurveMetaModelInfo extends Omit<CurvePlainModelInfo, 'isUnderlying' |
388
395
  basePoolRouteId: string;
389
396
  isCacheExists: boolean;
390
397
  }
398
+ interface CurvePlainNGModelInfo {
399
+ model: DexModel.CurveStableNG;
400
+ poolContract: string;
401
+ tokens: string[];
402
+ precision: bigint;
403
+ feeDenominator: bigint;
404
+ aPrecision: bigint;
405
+ }
391
406
  interface CurveCryptoModelInfo {
392
407
  model: DexModel.CurveCrypto;
393
408
  tokens: string[];
@@ -515,7 +530,7 @@ interface RouteInfo {
515
530
  type RouteInfoModel = RouteInfo & {
516
531
  gas: bigint;
517
532
  isTradingAllowed: boolean;
518
- } & (UniswapV2BasedModelInfo | UniswapV3ModelInfo | PancakeV3ModelInfo | VelodromeSSModelInfo | CurvePlainModelInfo | CurveMetaModelInfo | CurveCryptoModelInfo | CurveCryptoNGModelInfo | CurveCryptoZapModelInfo | CurveCryptoTwoZapModelInfo | CurveLendingModelInfo | DodoV2ModelInfo | SmoothyModelInfo | DMMModelInfo | BalancerWeightedModelInfo | BalancerStableModelInfo | BalancerMetaStableModelInfo | BalancerBoostedStableModelInfo | BalancerLinearModelInfo | PolyDexModelInfo | GmxDexModelInfo | SolidlyModelInfo | VelodromeV2ModelInfo | SynthetixModelInfo | {
533
+ } & (UniswapV2BasedModelInfo | UniswapV3ModelInfo | PancakeV3ModelInfo | VelodromeSSModelInfo | CurvePlainModelInfo | CurvePlainNGModelInfo | CurveMetaModelInfo | CurveCryptoModelInfo | CurveCryptoNGModelInfo | CurveCryptoZapModelInfo | CurveCryptoTwoZapModelInfo | CurveLendingModelInfo | CurveLidoModelInfo | DodoV2ModelInfo | SmoothyModelInfo | DMMModelInfo | BalancerWeightedModelInfo | BalancerStableModelInfo | BalancerMetaStableModelInfo | BalancerBoostedStableModelInfo | BalancerLinearModelInfo | PolyDexModelInfo | GmxDexModelInfo | SolidlyModelInfo | VelodromeV2ModelInfo | SynthetixModelInfo | {
519
534
  model: DexModel.Unknown;
520
535
  });
521
536
 
@@ -306,29 +306,31 @@ declare enum DexModel {
306
306
  CurveMetaSol = 10,
307
307
  CurveCrypto = 11,
308
308
  CurveTriCryptoNG = 12,
309
- CurveLendingA = 13,
310
- CurveLendingCryptoZap = 14,
311
- CurveLendingCryptoTwoZap = 15,
312
- PolyDex = 16,
313
- FireBirdWeighted = 17,
314
- BalancerWeighted = 18,
315
- BalancerStable = 19,
316
- BalancerMetaStable = 20,
317
- BalancerBoostedStable = 21,
318
- BalancerLinear = 22,
319
- BalancerLiquidityBootstrapping = 23,
320
- Biswap = 24,
321
- DodoV1 = 25,
322
- DodoV2 = 26,
323
- Mdex = 27,
324
- Mars = 28,
325
- Smoothy = 29,
326
- Shibaswap = 30,
327
- GmxDex = 31,
328
- Solidly = 32,
329
- VelodromeV2 = 33,
330
- Synthetix = 34,
331
- Unknown = 35
309
+ CurveStableNG = 13,
310
+ CurveLendingA = 14,
311
+ CurveLendingCryptoZap = 15,
312
+ CurveLendingCryptoTwoZap = 16,
313
+ CurveLido = 17,
314
+ PolyDex = 18,
315
+ FireBirdWeighted = 19,
316
+ BalancerWeighted = 20,
317
+ BalancerStable = 21,
318
+ BalancerMetaStable = 22,
319
+ BalancerBoostedStable = 23,
320
+ BalancerLinear = 24,
321
+ BalancerLiquidityBootstrapping = 25,
322
+ Biswap = 26,
323
+ DodoV1 = 27,
324
+ DodoV2 = 28,
325
+ Mdex = 29,
326
+ Mars = 30,
327
+ Smoothy = 31,
328
+ Shibaswap = 32,
329
+ GmxDex = 33,
330
+ Solidly = 34,
331
+ VelodromeV2 = 35,
332
+ Synthetix = 36,
333
+ Unknown = 37
332
334
  }
333
335
  interface UniswapV2BasedModelInfo {
334
336
  model: DexModel.UniswapV2 | DexModel.Mdex | DexModel.Biswap | DexModel.Mars | DexModel.Shibaswap;
@@ -371,6 +373,11 @@ interface CurvePlainModelInfo {
371
373
  aPrecision?: bigint;
372
374
  balancesArgs?: string;
373
375
  }
376
+ interface CurveLidoModelInfo extends Omit<CurvePlainModelInfo, 'model'> {
377
+ model: DexModel.CurveLido;
378
+ oracleAddress: string;
379
+ stethCoinIdx: number;
380
+ }
374
381
  interface CurveLendingModelInfo {
375
382
  model: DexModel.CurveLendingA;
376
383
  poolContract: string;
@@ -388,6 +395,14 @@ interface CurveMetaModelInfo extends Omit<CurvePlainModelInfo, 'isUnderlying' |
388
395
  basePoolRouteId: string;
389
396
  isCacheExists: boolean;
390
397
  }
398
+ interface CurvePlainNGModelInfo {
399
+ model: DexModel.CurveStableNG;
400
+ poolContract: string;
401
+ tokens: string[];
402
+ precision: bigint;
403
+ feeDenominator: bigint;
404
+ aPrecision: bigint;
405
+ }
391
406
  interface CurveCryptoModelInfo {
392
407
  model: DexModel.CurveCrypto;
393
408
  tokens: string[];
@@ -515,7 +530,7 @@ interface RouteInfo {
515
530
  type RouteInfoModel = RouteInfo & {
516
531
  gas: bigint;
517
532
  isTradingAllowed: boolean;
518
- } & (UniswapV2BasedModelInfo | UniswapV3ModelInfo | PancakeV3ModelInfo | VelodromeSSModelInfo | CurvePlainModelInfo | CurveMetaModelInfo | CurveCryptoModelInfo | CurveCryptoNGModelInfo | CurveCryptoZapModelInfo | CurveCryptoTwoZapModelInfo | CurveLendingModelInfo | DodoV2ModelInfo | SmoothyModelInfo | DMMModelInfo | BalancerWeightedModelInfo | BalancerStableModelInfo | BalancerMetaStableModelInfo | BalancerBoostedStableModelInfo | BalancerLinearModelInfo | PolyDexModelInfo | GmxDexModelInfo | SolidlyModelInfo | VelodromeV2ModelInfo | SynthetixModelInfo | {
533
+ } & (UniswapV2BasedModelInfo | UniswapV3ModelInfo | PancakeV3ModelInfo | VelodromeSSModelInfo | CurvePlainModelInfo | CurvePlainNGModelInfo | CurveMetaModelInfo | CurveCryptoModelInfo | CurveCryptoNGModelInfo | CurveCryptoZapModelInfo | CurveCryptoTwoZapModelInfo | CurveLendingModelInfo | CurveLidoModelInfo | DodoV2ModelInfo | SmoothyModelInfo | DMMModelInfo | BalancerWeightedModelInfo | BalancerStableModelInfo | BalancerMetaStableModelInfo | BalancerBoostedStableModelInfo | BalancerLinearModelInfo | PolyDexModelInfo | GmxDexModelInfo | SolidlyModelInfo | VelodromeV2ModelInfo | SynthetixModelInfo | {
519
534
  model: DexModel.Unknown;
520
535
  });
521
536