@juiceswapxyz/smart-order-router 0.1.0-beta.0 → 0.1.2-beta.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 (149) hide show
  1. package/build/main/providers/caching-subgraph-provider.d.ts +1 -1
  2. package/build/main/providers/eip-1559-gas-price-provider.d.ts +2 -2
  3. package/build/main/providers/eth-gas-station-info-gas-price-provider.d.ts +1 -1
  4. package/build/main/providers/gas-price-provider.d.ts +1 -1
  5. package/build/main/providers/multicall-provider.d.ts +6 -6
  6. package/build/main/providers/multicall-uniswap-provider.d.ts +1 -1
  7. package/build/main/providers/on-chain-quote-provider.d.ts +17 -17
  8. package/build/main/providers/pool-provider.d.ts +4 -4
  9. package/build/main/providers/provider.d.ts +2 -2
  10. package/build/main/providers/simulation-provider.d.ts +1 -1
  11. package/build/main/providers/subgraph-provider.d.ts +2 -2
  12. package/build/main/providers/subgraph-provider.js +1 -1
  13. package/build/main/providers/swap-router-provider.d.ts +1 -1
  14. package/build/main/providers/tenderly-simulation-provider.d.ts +5 -5
  15. package/build/main/providers/token-fee-fetcher.d.ts +3 -3
  16. package/build/main/providers/token-properties-provider.d.ts +3 -3
  17. package/build/main/providers/token-provider.d.ts +2 -2
  18. package/build/main/providers/token-provider.js +4 -4
  19. package/build/main/providers/v2/pool-provider.d.ts +2 -2
  20. package/build/main/providers/v2/quote-provider.d.ts +2 -2
  21. package/build/main/providers/v2/subgraph-provider.d.ts +1 -1
  22. package/build/main/providers/v2/subgraph-provider.js +1 -1
  23. package/build/main/providers/v3/gas-data-provider.d.ts +1 -1
  24. package/build/main/providers/v3/pool-provider.d.ts +5 -5
  25. package/build/main/providers/v3/subgraph-provider.d.ts +1 -1
  26. package/build/main/providers/v4/euler-swap-hooks-subgraph-provider.js +1 -1
  27. package/build/main/providers/v4/pool-provider.d.ts +5 -5
  28. package/build/main/providers/v4/subgraph-provider.d.ts +1 -1
  29. package/build/main/routers/alpha-router/alpha-router.d.ts +3 -3
  30. package/build/main/routers/alpha-router/entities/route-with-valid-quote.d.ts +9 -9
  31. package/build/main/routers/alpha-router/entities/route-with-valid-quote.js +13 -13
  32. package/build/main/routers/alpha-router/functions/best-swap-route.d.ts +1 -1
  33. package/build/main/routers/alpha-router/functions/get-candidate-pools.d.ts +14 -14
  34. package/build/main/routers/alpha-router/gas-models/gas-model.d.ts +7 -7
  35. package/build/main/routers/alpha-router/gas-models/gas-model.js +1 -1
  36. package/build/main/routers/legacy-router/bases.d.ts +1 -1
  37. package/build/main/routers/legacy-router/legacy-router.d.ts +2 -2
  38. package/build/main/routers/router.d.ts +14 -14
  39. package/build/main/tsconfig.tsbuildinfo +1 -1
  40. package/build/main/types/other/commons.d.ts +4 -4
  41. package/build/main/types/other/factories/Erc20__factory.d.ts +1 -1
  42. package/build/main/types/other/factories/Erc20__factory.js +1 -1
  43. package/build/main/types/other/factories/GasDataArbitrum__factory.d.ts +1 -1
  44. package/build/main/types/other/factories/GasDataArbitrum__factory.js +1 -1
  45. package/build/main/types/other/factories/IMixedRouteQuoterV1__factory.d.ts +1 -1
  46. package/build/main/types/other/factories/IMixedRouteQuoterV1__factory.js +1 -1
  47. package/build/main/types/other/factories/ITokenValidator__factory.d.ts +1 -1
  48. package/build/main/types/other/factories/ITokenValidator__factory.js +1 -1
  49. package/build/main/types/other/factories/MixedRouteQuoterV2__factory.d.ts +1 -1
  50. package/build/main/types/other/factories/MixedRouteQuoterV2__factory.js +1 -1
  51. package/build/main/types/other/factories/Permit2__factory.d.ts +2 -2
  52. package/build/main/types/other/factories/Permit2__factory.js +8 -3
  53. package/build/main/types/other/factories/StateView__factory.d.ts +1 -1
  54. package/build/main/types/other/factories/StateView__factory.js +1 -1
  55. package/build/main/types/other/factories/SwapRouter02__factory.d.ts +2 -2
  56. package/build/main/types/other/factories/SwapRouter02__factory.js +8 -3
  57. package/build/main/types/other/factories/TokenFeeDetector__factory.d.ts +1 -1
  58. package/build/main/types/other/factories/TokenFeeDetector__factory.js +1 -1
  59. package/build/main/types/other/factories/V4Quoter__factory.d.ts +1 -1
  60. package/build/main/types/other/factories/V4Quoter__factory.js +1 -1
  61. package/build/main/types/v2/commons.d.ts +4 -4
  62. package/build/main/types/v2/factories/IUniswapV2Pair__factory.d.ts +1 -1
  63. package/build/main/types/v2/factories/IUniswapV2Pair__factory.js +1 -1
  64. package/build/main/types/v3/commons.d.ts +4 -4
  65. package/build/main/types/v3/factories/IERC20Metadata__factory.d.ts +1 -1
  66. package/build/main/types/v3/factories/IERC20Metadata__factory.js +1 -1
  67. package/build/main/types/v3/factories/IQuoterV2__factory.d.ts +1 -1
  68. package/build/main/types/v3/factories/IQuoterV2__factory.js +1 -1
  69. package/build/main/types/v3/factories/IUniswapV3PoolState__factory.d.ts +1 -1
  70. package/build/main/types/v3/factories/IUniswapV3PoolState__factory.js +1 -1
  71. package/build/main/types/v3/factories/UniswapInterfaceMulticall__factory.d.ts +2 -2
  72. package/build/main/types/v3/factories/UniswapInterfaceMulticall__factory.js +8 -3
  73. package/build/main/util/addresses.d.ts +1 -1
  74. package/build/main/util/onchainQuoteProviderConfigs.d.ts +1 -1
  75. package/build/module/providers/caching-subgraph-provider.d.ts +1 -1
  76. package/build/module/providers/eip-1559-gas-price-provider.d.ts +2 -2
  77. package/build/module/providers/eth-gas-station-info-gas-price-provider.d.ts +1 -1
  78. package/build/module/providers/gas-price-provider.d.ts +1 -1
  79. package/build/module/providers/multicall-provider.d.ts +6 -6
  80. package/build/module/providers/multicall-uniswap-provider.d.ts +1 -1
  81. package/build/module/providers/on-chain-quote-provider.d.ts +17 -17
  82. package/build/module/providers/pool-provider.d.ts +4 -4
  83. package/build/module/providers/provider.d.ts +2 -2
  84. package/build/module/providers/simulation-provider.d.ts +1 -1
  85. package/build/module/providers/subgraph-provider.d.ts +2 -2
  86. package/build/module/providers/subgraph-provider.js +1 -1
  87. package/build/module/providers/swap-router-provider.d.ts +1 -1
  88. package/build/module/providers/tenderly-simulation-provider.d.ts +5 -5
  89. package/build/module/providers/token-fee-fetcher.d.ts +3 -3
  90. package/build/module/providers/token-properties-provider.d.ts +3 -3
  91. package/build/module/providers/token-provider.d.ts +2 -2
  92. package/build/module/providers/token-provider.js +3 -3
  93. package/build/module/providers/v2/pool-provider.d.ts +2 -2
  94. package/build/module/providers/v2/quote-provider.d.ts +2 -2
  95. package/build/module/providers/v2/subgraph-provider.d.ts +1 -1
  96. package/build/module/providers/v2/subgraph-provider.js +1 -1
  97. package/build/module/providers/v3/gas-data-provider.d.ts +1 -1
  98. package/build/module/providers/v3/pool-provider.d.ts +5 -5
  99. package/build/module/providers/v3/subgraph-provider.d.ts +1 -1
  100. package/build/module/providers/v4/euler-swap-hooks-subgraph-provider.js +1 -1
  101. package/build/module/providers/v4/pool-provider.d.ts +5 -5
  102. package/build/module/providers/v4/subgraph-provider.d.ts +1 -1
  103. package/build/module/routers/alpha-router/alpha-router.d.ts +3 -3
  104. package/build/module/routers/alpha-router/entities/route-with-valid-quote.d.ts +9 -9
  105. package/build/module/routers/alpha-router/entities/route-with-valid-quote.js +12 -12
  106. package/build/module/routers/alpha-router/functions/best-swap-route.d.ts +1 -1
  107. package/build/module/routers/alpha-router/functions/get-candidate-pools.d.ts +14 -14
  108. package/build/module/routers/alpha-router/gas-models/gas-model.d.ts +7 -7
  109. package/build/module/routers/alpha-router/gas-models/gas-model.js +2 -2
  110. package/build/module/routers/legacy-router/bases.d.ts +1 -1
  111. package/build/module/routers/legacy-router/legacy-router.d.ts +2 -2
  112. package/build/module/routers/router.d.ts +14 -14
  113. package/build/module/tsconfig.module.tsbuildinfo +1 -1
  114. package/build/module/types/other/commons.d.ts +4 -4
  115. package/build/module/types/other/factories/Erc20__factory.d.ts +1 -1
  116. package/build/module/types/other/factories/Erc20__factory.js +1 -1
  117. package/build/module/types/other/factories/GasDataArbitrum__factory.d.ts +1 -1
  118. package/build/module/types/other/factories/GasDataArbitrum__factory.js +1 -1
  119. package/build/module/types/other/factories/IMixedRouteQuoterV1__factory.d.ts +1 -1
  120. package/build/module/types/other/factories/IMixedRouteQuoterV1__factory.js +1 -1
  121. package/build/module/types/other/factories/ITokenValidator__factory.d.ts +1 -1
  122. package/build/module/types/other/factories/ITokenValidator__factory.js +1 -1
  123. package/build/module/types/other/factories/MixedRouteQuoterV2__factory.d.ts +1 -1
  124. package/build/module/types/other/factories/MixedRouteQuoterV2__factory.js +1 -1
  125. package/build/module/types/other/factories/Permit2__factory.d.ts +2 -2
  126. package/build/module/types/other/factories/Permit2__factory.js +9 -4
  127. package/build/module/types/other/factories/StateView__factory.d.ts +1 -1
  128. package/build/module/types/other/factories/StateView__factory.js +1 -1
  129. package/build/module/types/other/factories/SwapRouter02__factory.d.ts +2 -2
  130. package/build/module/types/other/factories/SwapRouter02__factory.js +9 -4
  131. package/build/module/types/other/factories/TokenFeeDetector__factory.d.ts +1 -1
  132. package/build/module/types/other/factories/TokenFeeDetector__factory.js +1 -1
  133. package/build/module/types/other/factories/V4Quoter__factory.d.ts +1 -1
  134. package/build/module/types/other/factories/V4Quoter__factory.js +1 -1
  135. package/build/module/types/v2/commons.d.ts +4 -4
  136. package/build/module/types/v2/factories/IUniswapV2Pair__factory.d.ts +1 -1
  137. package/build/module/types/v2/factories/IUniswapV2Pair__factory.js +1 -1
  138. package/build/module/types/v3/commons.d.ts +4 -4
  139. package/build/module/types/v3/factories/IERC20Metadata__factory.d.ts +1 -1
  140. package/build/module/types/v3/factories/IERC20Metadata__factory.js +1 -1
  141. package/build/module/types/v3/factories/IQuoterV2__factory.d.ts +1 -1
  142. package/build/module/types/v3/factories/IQuoterV2__factory.js +1 -1
  143. package/build/module/types/v3/factories/IUniswapV3PoolState__factory.d.ts +1 -1
  144. package/build/module/types/v3/factories/IUniswapV3PoolState__factory.js +1 -1
  145. package/build/module/types/v3/factories/UniswapInterfaceMulticall__factory.d.ts +2 -2
  146. package/build/module/types/v3/factories/UniswapInterfaceMulticall__factory.js +9 -4
  147. package/build/module/util/addresses.d.ts +1 -1
  148. package/build/module/util/onchainQuoteProviderConfigs.d.ts +1 -1
  149. package/package.json +6 -6
@@ -20,8 +20,8 @@ export declare class V2Route extends V2RouteRaw<Token, Token> {
20
20
  export declare class MixedRoute extends MixedRouteSDK<Currency, Currency> {
21
21
  protocol: Protocol.MIXED;
22
22
  }
23
- export declare type SupportedRoutes = V4Route | V3Route | V2Route | MixedRoute;
24
- export declare type SwapRoute = {
23
+ export type SupportedRoutes = V4Route | V3Route | V2Route | MixedRoute;
24
+ export type SwapRoute = {
25
25
  /**
26
26
  * The quote for the swap.
27
27
  * For EXACT_IN swaps this will be an amount of token out.
@@ -95,10 +95,10 @@ export declare type SwapRoute = {
95
95
  */
96
96
  portionAmount?: CurrencyAmount;
97
97
  };
98
- export declare type MethodParameters = SDKMethodParameters & {
98
+ export type MethodParameters = SDKMethodParameters & {
99
99
  to: string;
100
100
  };
101
- export declare type SwapToRatioRoute = SwapRoute & {
101
+ export type SwapToRatioRoute = SwapRoute & {
102
102
  optimalRatio: Fraction;
103
103
  postSwapTargetPool: Pool;
104
104
  };
@@ -107,30 +107,30 @@ export declare enum SwapToRatioStatus {
107
107
  NO_ROUTE_FOUND = 2,
108
108
  NO_SWAP_NEEDED = 3
109
109
  }
110
- export declare type SwapToRatioSuccess = {
110
+ export type SwapToRatioSuccess = {
111
111
  status: SwapToRatioStatus.SUCCESS;
112
112
  result: SwapToRatioRoute;
113
113
  };
114
- export declare type SwapToRatioFail = {
114
+ export type SwapToRatioFail = {
115
115
  status: SwapToRatioStatus.NO_ROUTE_FOUND;
116
116
  error: string;
117
117
  };
118
- export declare type SwapToRatioNoSwapNeeded = {
118
+ export type SwapToRatioNoSwapNeeded = {
119
119
  status: SwapToRatioStatus.NO_SWAP_NEEDED;
120
120
  };
121
- export declare type SwapToRatioResponse = SwapToRatioSuccess | SwapToRatioFail | SwapToRatioNoSwapNeeded;
121
+ export type SwapToRatioResponse = SwapToRatioSuccess | SwapToRatioFail | SwapToRatioNoSwapNeeded;
122
122
  export declare enum SwapType {
123
123
  UNIVERSAL_ROUTER = 0,
124
124
  SWAP_ROUTER_02 = 1
125
125
  }
126
- export declare type SwapOptionsUniversalRouter = UniversalRouterSwapOptions & {
126
+ export type SwapOptionsUniversalRouter = UniversalRouterSwapOptions & {
127
127
  type: SwapType.UNIVERSAL_ROUTER;
128
128
  version: UniversalRouterVersion;
129
129
  simulate?: {
130
130
  fromAddress: string;
131
131
  };
132
132
  };
133
- export declare type SwapOptionsSwapRouter02 = {
133
+ export type SwapOptionsSwapRouter02 = {
134
134
  type: SwapType.SWAP_ROUTER_02;
135
135
  recipient: string;
136
136
  slippageTolerance: Percent;
@@ -150,16 +150,16 @@ export declare type SwapOptionsSwapRouter02 = {
150
150
  expiry: string;
151
151
  });
152
152
  };
153
- export declare type SwapOptions = SwapOptionsUniversalRouter | SwapOptionsSwapRouter02;
154
- export declare type SwapAndAddConfig = {
153
+ export type SwapOptions = SwapOptionsUniversalRouter | SwapOptionsSwapRouter02;
154
+ export type SwapAndAddConfig = {
155
155
  maxIterations: number;
156
156
  ratioErrorTolerance: Fraction;
157
157
  };
158
- export declare type SwapAndAddOptions = {
158
+ export type SwapAndAddOptions = {
159
159
  swapOptions: SwapOptionsSwapRouter02;
160
160
  addLiquidityOptions: CondensedAddLiquidityOptions;
161
161
  };
162
- export declare type SwapAndAddParameters = {
162
+ export type SwapAndAddParameters = {
163
163
  initialBalanceTokenIn: CurrencyAmount;
164
164
  initialBalanceTokenOut: CurrencyAmount;
165
165
  preLiquidityPosition: Position;