@continuumdao/ctm-mpc-defi 0.2.34 → 0.2.35

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 (83) hide show
  1. package/dist/agent/catalog.cjs +712 -44
  2. package/dist/agent/catalog.cjs.map +1 -1
  3. package/dist/agent/catalog.d.ts +1630 -244
  4. package/dist/agent/catalog.js +678 -45
  5. package/dist/agent/catalog.js.map +1 -1
  6. package/dist/agent/skills/aave-v4/SKILL.md +19 -4
  7. package/dist/agent/skills/aerodrome/SKILL.md +2 -2
  8. package/dist/agent/skills/compound-v3/SKILL.md +2 -2
  9. package/dist/agent/skills/curve-dao/SKILL.md +14 -0
  10. package/dist/agent/skills/ethena/SKILL.md +3 -1
  11. package/dist/agent/skills/euler-v2/SKILL.md +1 -1
  12. package/dist/agent/skills/gmx/SKILL.md +1 -1
  13. package/dist/agent/skills/hyperliquid/SKILL.md +7 -5
  14. package/dist/agent/skills/lido/SKILL.md +3 -0
  15. package/dist/agent/skills/maple-syrup/SKILL.md +35 -3
  16. package/dist/agent/skills/morpho/SKILL.md +1 -1
  17. package/dist/agent/skills/sky/SKILL.md +2 -0
  18. package/dist/agent/skills/yield-compare/SKILL.md +78 -0
  19. package/dist/index.cjs +129 -29
  20. package/dist/index.cjs.map +1 -1
  21. package/dist/index.js +129 -27
  22. package/dist/index.js.map +1 -1
  23. package/dist/protocols/evm/aave-v4/index.cjs +170 -0
  24. package/dist/protocols/evm/aave-v4/index.cjs.map +1 -1
  25. package/dist/protocols/evm/aave-v4/index.d.ts +59 -1
  26. package/dist/protocols/evm/aave-v4/index.js +164 -1
  27. package/dist/protocols/evm/aave-v4/index.js.map +1 -1
  28. package/dist/protocols/evm/aerodrome/index.cjs +1308 -901
  29. package/dist/protocols/evm/aerodrome/index.cjs.map +1 -1
  30. package/dist/protocols/evm/aerodrome/index.d.ts +69 -2
  31. package/dist/protocols/evm/aerodrome/index.js +1217 -807
  32. package/dist/protocols/evm/aerodrome/index.js.map +1 -1
  33. package/dist/protocols/evm/compound-v3/index.cjs +82 -6
  34. package/dist/protocols/evm/compound-v3/index.cjs.map +1 -1
  35. package/dist/protocols/evm/compound-v3/index.d.ts +89 -1
  36. package/dist/protocols/evm/compound-v3/index.js +80 -7
  37. package/dist/protocols/evm/compound-v3/index.js.map +1 -1
  38. package/dist/protocols/evm/curve-dao/index.cjs +447 -18
  39. package/dist/protocols/evm/curve-dao/index.cjs.map +1 -1
  40. package/dist/protocols/evm/curve-dao/index.d.ts +108 -1
  41. package/dist/protocols/evm/curve-dao/index.js +440 -19
  42. package/dist/protocols/evm/curve-dao/index.js.map +1 -1
  43. package/dist/protocols/evm/ethena/index.cjs +89 -0
  44. package/dist/protocols/evm/ethena/index.cjs.map +1 -1
  45. package/dist/protocols/evm/ethena/index.d.ts +17 -1
  46. package/dist/protocols/evm/ethena/index.js +89 -2
  47. package/dist/protocols/evm/ethena/index.js.map +1 -1
  48. package/dist/protocols/evm/euler-v2/index.cjs +29 -0
  49. package/dist/protocols/evm/euler-v2/index.cjs.map +1 -1
  50. package/dist/protocols/evm/euler-v2/index.d.ts +21 -1
  51. package/dist/protocols/evm/euler-v2/index.js +29 -1
  52. package/dist/protocols/evm/euler-v2/index.js.map +1 -1
  53. package/dist/protocols/evm/gmx/index.cjs +83 -1
  54. package/dist/protocols/evm/gmx/index.cjs.map +1 -1
  55. package/dist/protocols/evm/gmx/index.d.ts +22 -2
  56. package/dist/protocols/evm/gmx/index.js +80 -2
  57. package/dist/protocols/evm/gmx/index.js.map +1 -1
  58. package/dist/protocols/evm/hyperliquid/index.cjs +67 -11
  59. package/dist/protocols/evm/hyperliquid/index.cjs.map +1 -1
  60. package/dist/protocols/evm/hyperliquid/index.d.ts +39 -2
  61. package/dist/protocols/evm/hyperliquid/index.js +64 -12
  62. package/dist/protocols/evm/hyperliquid/index.js.map +1 -1
  63. package/dist/protocols/evm/lido/index.cjs +13 -0
  64. package/dist/protocols/evm/lido/index.cjs.map +1 -1
  65. package/dist/protocols/evm/lido/index.d.ts +9 -1
  66. package/dist/protocols/evm/lido/index.js +13 -1
  67. package/dist/protocols/evm/lido/index.js.map +1 -1
  68. package/dist/protocols/evm/maple/index.cjs +129 -1
  69. package/dist/protocols/evm/maple/index.cjs.map +1 -1
  70. package/dist/protocols/evm/maple/index.d.ts +45 -1
  71. package/dist/protocols/evm/maple/index.js +124 -3
  72. package/dist/protocols/evm/maple/index.js.map +1 -1
  73. package/dist/protocols/evm/morpho/index.cjs +34 -7
  74. package/dist/protocols/evm/morpho/index.cjs.map +1 -1
  75. package/dist/protocols/evm/morpho/index.d.ts +23 -1
  76. package/dist/protocols/evm/morpho/index.js +34 -8
  77. package/dist/protocols/evm/morpho/index.js.map +1 -1
  78. package/dist/protocols/evm/sky/index.cjs +52 -0
  79. package/dist/protocols/evm/sky/index.cjs.map +1 -1
  80. package/dist/protocols/evm/sky/index.d.ts +16 -1
  81. package/dist/protocols/evm/sky/index.js +50 -1
  82. package/dist/protocols/evm/sky/index.js.map +1 -1
  83. package/package.json +1 -1
@@ -3,29 +3,26 @@
3
3
  var viem = require('viem');
4
4
  var continuumNodeSdk = require('@continuumdao/continuum-node-sdk');
5
5
 
6
- // src/core/registry.ts
7
- var modules = [];
8
- function registerProtocolModule(mod) {
9
- const existing = modules.findIndex((m) => m.id === mod.id);
10
- if (existing >= 0) {
11
- modules[existing] = mod;
12
- } else {
13
- modules.push(mod);
14
- }
15
- }
6
+ var __defProp = Object.defineProperty;
7
+ var __getOwnPropNames = Object.getOwnPropertyNames;
8
+ var __esm = (fn, res) => function __init() {
9
+ return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
10
+ };
11
+ var __export = (target, all) => {
12
+ for (var name in all)
13
+ __defProp(target, name, { get: all[name], enumerable: true });
14
+ };
16
15
 
17
16
  // src/core/expiry.ts
18
- var DEFAULT_DEFI_MULTISIGN_EXPIRY_SECONDS = 30 * 60;
19
-
20
- // src/protocols/evm/aerodrome/support.ts
21
- var AERODROME_PROTOCOL_ID = "aerodrome";
22
- var AERODROME_CHAIN_ID = 8453;
23
- var AERODROME_NATIVE_PLACEHOLDER = viem.zeroAddress;
24
- var AERODROME_WETH_BASE = "0x4200000000000000000000000000000000000006";
25
- var AERODROME_USDC_BASE = "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913";
17
+ var DEFAULT_DEFI_MULTISIGN_EXPIRY_SECONDS;
18
+ var init_expiry = __esm({
19
+ "src/core/expiry.ts"() {
20
+ DEFAULT_DEFI_MULTISIGN_EXPIRY_SECONDS = 30 * 60;
21
+ }
22
+ });
26
23
  function isAerodromeChainSupported(chainId) {
27
24
  const n = typeof chainId === "number" ? chainId : Number.parseInt(String(chainId), 10);
28
- return n === AERODROME_CHAIN_ID;
25
+ return n === exports.AERODROME_CHAIN_ID;
29
26
  }
30
27
  function aerodromeOnChainDeadlineUnix(expiryDate) {
31
28
  if (typeof expiryDate === "number" && Number.isFinite(expiryDate) && expiryDate > 0) {
@@ -53,38 +50,17 @@ function isAerodromeNativeToken(address) {
53
50
  return false;
54
51
  }
55
52
  }
56
- var AERODROME_BASE_ADDRESSES_FALLBACK = {
57
- chainId: AERODROME_CHAIN_ID,
58
- aero: "0x940181a94A35A4569E4529A3CDfB74e38FD98631",
59
- router: "0xcF77a3Ba9A5CA399B7c97c74d54e5b1Beb874E43",
60
- poolFactory: "0x420DD381b31aEf6683db6B902084cB0FFECe40Da",
61
- factoryRegistry: "0x5C3F18F06CC09CA1910767A34a20F771039E37C0",
62
- voter: "0x16613524e02ad97eDfeF371bC883F2F5d6C480A5",
63
- votingEscrow: "0xeBf418Fe2512e7E6bd9b87a8F0f294aCDC67e6B4",
64
- rewardsDistributor: "0x227f65131A261548b057215bB1D5Ab2997964C7d",
65
- mixedQuoter: "0x0A5aA5D3a4d28014f967Bf0f29EAA3FF9807D5c6",
66
- /** MixedRouteQuoterV3 — v2 + all three CL factories (bitmask path encoding). */
67
- mixedQuoterV3: "0xCd2A7D98e82D6107eac1828ce8DeAA6acB65b555",
68
- nfpm: "0x827922686190790b37229fd06084350E74485b72",
69
- /** Oldest Slipstream CL factory (Gauges V1). Path bit 1<<20. */
70
- clFactory: "0x5e7BB104d84c7CB9B682AaC2F3d509f5F406809A",
71
- /** Slipstream CL factory 2 (gauge caps). Raw tickSpacing in MixedQuoterV3. */
72
- clFactory2: "0xaDe65c38CD4849aDBA595a4323a8C7DdfE89716a",
73
- /** Newest Slipstream CL factory (Gauges V3) — Coinbase B20 stock pools. Path bit 1<<19. */
74
- clFactory3: "0xf8f2eB4940CFE7d13603DDDD87f123820Fc061Ef",
75
- universalRouter: "0x6Cb442acF35158D5eDa88fe602221b67B400Be3E",
76
- swapRouter: "0xBE6D8f0d05cC4be24d5167a3eF062215bE6D18a5",
77
- swapRouter2: "0xcbBb8035cAc7D4B3Ca7aBb74cF7BdF900215Ce0D",
78
- swapRouter3: "0x698Cb2b6dd822994581fEa6eA4Fc755d1363A92F",
79
- pricesOracle: "0xee717411f6E44F9feE011835C8E6FAaC5dEfF166",
80
- slipstreamHelper: "0x0AD09A66af0154a84e86F761313d02d0abB6edd5",
81
- lpSugar: "0x69dD9db6d8f8E7d83887A704f447b1a584b599A1",
82
- sugarSlipstreamHelper: "0x9c62ab10577fB3C20A22E231b7703Ed6D456CC7a",
83
- swapper: "0x91616a7B9CF6D23f8C17845581051EBdC4BcB916",
84
- weth: AERODROME_WETH_BASE
85
- };
86
- var SUGAR_ENV_URL = "https://raw.githubusercontent.com/velodrome-finance/sugar/main/deployments/base.env";
87
- var SECURITY_MDX_URL = "https://raw.githubusercontent.com/aerodrome-finance/docs/main/content/security.mdx";
53
+ exports.AERODROME_PROTOCOL_ID = void 0; exports.AERODROME_CHAIN_ID = void 0; exports.AERODROME_NATIVE_PLACEHOLDER = void 0; exports.AERODROME_WETH_BASE = void 0; exports.AERODROME_USDC_BASE = void 0;
54
+ var init_support = __esm({
55
+ "src/protocols/evm/aerodrome/support.ts"() {
56
+ init_expiry();
57
+ exports.AERODROME_PROTOCOL_ID = "aerodrome";
58
+ exports.AERODROME_CHAIN_ID = 8453;
59
+ exports.AERODROME_NATIVE_PLACEHOLDER = viem.zeroAddress;
60
+ exports.AERODROME_WETH_BASE = "0x4200000000000000000000000000000000000006";
61
+ exports.AERODROME_USDC_BASE = "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913";
62
+ }
63
+ });
88
64
  function asAddr(raw) {
89
65
  const s = (raw ?? "").trim();
90
66
  if (!s) return null;
@@ -127,10 +103,10 @@ function firstAddr(csv) {
127
103
  return nthAddr(csv, 0);
128
104
  }
129
105
  function mergeLoaded(sugar, docs) {
130
- const fb = AERODROME_BASE_ADDRESSES_FALLBACK;
106
+ const fb = exports.AERODROME_BASE_ADDRESSES_FALLBACK;
131
107
  const pick = (loaded, fallback) => loaded ?? viem.getAddress(fallback);
132
108
  return {
133
- chainId: AERODROME_CHAIN_ID,
109
+ chainId: exports.AERODROME_CHAIN_ID,
134
110
  aero: pick(asAddr(docs.aero), fb.aero),
135
111
  router: pick(asAddr(docs.router), fb.router),
136
112
  poolFactory: pick(firstAddr(sugar.V2_FACTORIES_8453) ?? asAddr(docs.poolfactory), fb.poolFactory),
@@ -153,10 +129,9 @@ function mergeLoaded(sugar, docs) {
153
129
  lpSugar: pick(asAddr(sugar.LP_SUGAR_ADDRESS_8453), fb.lpSugar),
154
130
  sugarSlipstreamHelper: pick(asAddr(sugar.SLIPSTREAM_HELPER_8453), fb.sugarSlipstreamHelper),
155
131
  swapper: pick(asAddr(sugar.SWAPPER_8453), fb.swapper),
156
- weth: pick(asAddr(AERODROME_WETH_BASE), fb.weth)
132
+ weth: pick(asAddr(exports.AERODROME_WETH_BASE), fb.weth)
157
133
  };
158
134
  }
159
- var cache = null;
160
135
  async function fetchText(url) {
161
136
  try {
162
137
  const res = await fetch(url, { cache: "force-cache" });
@@ -192,782 +167,826 @@ function aerodromeClSwapRouterForFactory(addrs, factory) {
192
167
  if (f === addrs.clFactory2.toLowerCase()) return addrs.swapRouter2;
193
168
  return addrs.swapRouter;
194
169
  }
170
+ exports.AERODROME_BASE_ADDRESSES_FALLBACK = void 0; var SUGAR_ENV_URL, SECURITY_MDX_URL, cache;
171
+ var init_addresses = __esm({
172
+ "src/protocols/evm/aerodrome/addresses.ts"() {
173
+ init_support();
174
+ exports.AERODROME_BASE_ADDRESSES_FALLBACK = {
175
+ chainId: exports.AERODROME_CHAIN_ID,
176
+ aero: "0x940181a94A35A4569E4529A3CDfB74e38FD98631",
177
+ router: "0xcF77a3Ba9A5CA399B7c97c74d54e5b1Beb874E43",
178
+ poolFactory: "0x420DD381b31aEf6683db6B902084cB0FFECe40Da",
179
+ factoryRegistry: "0x5C3F18F06CC09CA1910767A34a20F771039E37C0",
180
+ voter: "0x16613524e02ad97eDfeF371bC883F2F5d6C480A5",
181
+ votingEscrow: "0xeBf418Fe2512e7E6bd9b87a8F0f294aCDC67e6B4",
182
+ rewardsDistributor: "0x227f65131A261548b057215bB1D5Ab2997964C7d",
183
+ mixedQuoter: "0x0A5aA5D3a4d28014f967Bf0f29EAA3FF9807D5c6",
184
+ /** MixedRouteQuoterV3 — v2 + all three CL factories (bitmask path encoding). */
185
+ mixedQuoterV3: "0xCd2A7D98e82D6107eac1828ce8DeAA6acB65b555",
186
+ nfpm: "0x827922686190790b37229fd06084350E74485b72",
187
+ /** Oldest Slipstream CL factory (Gauges V1). Path bit 1<<20. */
188
+ clFactory: "0x5e7BB104d84c7CB9B682AaC2F3d509f5F406809A",
189
+ /** Slipstream CL factory 2 (gauge caps). Raw tickSpacing in MixedQuoterV3. */
190
+ clFactory2: "0xaDe65c38CD4849aDBA595a4323a8C7DdfE89716a",
191
+ /** Newest Slipstream CL factory (Gauges V3) — Coinbase B20 stock pools. Path bit 1<<19. */
192
+ clFactory3: "0xf8f2eB4940CFE7d13603DDDD87f123820Fc061Ef",
193
+ universalRouter: "0x6Cb442acF35158D5eDa88fe602221b67B400Be3E",
194
+ swapRouter: "0xBE6D8f0d05cC4be24d5167a3eF062215bE6D18a5",
195
+ swapRouter2: "0xcbBb8035cAc7D4B3Ca7aBb74cF7BdF900215Ce0D",
196
+ swapRouter3: "0x698Cb2b6dd822994581fEa6eA4Fc755d1363A92F",
197
+ pricesOracle: "0xee717411f6E44F9feE011835C8E6FAaC5dEfF166",
198
+ slipstreamHelper: "0x0AD09A66af0154a84e86F761313d02d0abB6edd5",
199
+ lpSugar: "0x69dD9db6d8f8E7d83887A704f447b1a584b599A1",
200
+ sugarSlipstreamHelper: "0x9c62ab10577fB3C20A22E231b7703Ed6D456CC7a",
201
+ swapper: "0x91616a7B9CF6D23f8C17845581051EBdC4BcB916",
202
+ weth: exports.AERODROME_WETH_BASE
203
+ };
204
+ SUGAR_ENV_URL = "https://raw.githubusercontent.com/velodrome-finance/sugar/main/deployments/base.env";
205
+ SECURITY_MDX_URL = "https://raw.githubusercontent.com/aerodrome-finance/docs/main/content/security.mdx";
206
+ cache = null;
207
+ }
208
+ });
195
209
 
196
210
  // src/protocols/evm/aerodrome/abi.ts
197
- var lpSugarAbi = [
198
- {
199
- type: "function",
200
- name: "tokens",
201
- stateMutability: "view",
202
- inputs: [
203
- { name: "_limit", type: "uint256" },
204
- { name: "_offset", type: "uint256" },
205
- { name: "_account", type: "address" },
206
- { name: "_addresses", type: "address[]" }
207
- ],
208
- outputs: [
211
+ var lpSugarAbi, routerAbi, mixedQuoterAbi, mixedQuoterV3Abi, v2PoolFactoryAbi, clPoolFactoryAbi, clPoolAbi, sugarHelperAbi, nfpmAbi, clSwapRouterAbi, poolClaimFeesAbi, gaugeAbi, clGaugeAbi, aerodromePoolMetaAbi, aerodromeVoterAbi, erc20Abi;
212
+ var init_abi = __esm({
213
+ "src/protocols/evm/aerodrome/abi.ts"() {
214
+ lpSugarAbi = [
209
215
  {
210
- name: "",
211
- type: "tuple[]",
212
- components: [
213
- { name: "token_address", type: "address" },
214
- { name: "symbol", type: "string" },
215
- { name: "decimals", type: "uint8" },
216
- { name: "account_balance", type: "uint256" },
217
- { name: "listed", type: "bool" },
218
- { name: "emerging", type: "bool" }
216
+ type: "function",
217
+ name: "tokens",
218
+ stateMutability: "view",
219
+ inputs: [
220
+ { name: "_limit", type: "uint256" },
221
+ { name: "_offset", type: "uint256" },
222
+ { name: "_account", type: "address" },
223
+ { name: "_addresses", type: "address[]" }
224
+ ],
225
+ outputs: [
226
+ {
227
+ name: "",
228
+ type: "tuple[]",
229
+ components: [
230
+ { name: "token_address", type: "address" },
231
+ { name: "symbol", type: "string" },
232
+ { name: "decimals", type: "uint8" },
233
+ { name: "account_balance", type: "uint256" },
234
+ { name: "listed", type: "bool" },
235
+ { name: "emerging", type: "bool" }
236
+ ]
237
+ }
219
238
  ]
220
- }
221
- ]
222
- },
223
- {
224
- type: "function",
225
- name: "forSwaps",
226
- stateMutability: "view",
227
- inputs: [
228
- { name: "_limit", type: "uint256" },
229
- { name: "_offset", type: "uint256" }
230
- ],
231
- outputs: [
239
+ },
232
240
  {
233
- name: "",
234
- type: "tuple[]",
235
- components: [
236
- { name: "lp", type: "address" },
237
- { name: "type", type: "int24" },
238
- { name: "token0", type: "address" },
239
- { name: "token1", type: "address" },
240
- { name: "factory", type: "address" },
241
- { name: "pool_fee", type: "uint256" }
241
+ type: "function",
242
+ name: "forSwaps",
243
+ stateMutability: "view",
244
+ inputs: [
245
+ { name: "_limit", type: "uint256" },
246
+ { name: "_offset", type: "uint256" }
247
+ ],
248
+ outputs: [
249
+ {
250
+ name: "",
251
+ type: "tuple[]",
252
+ components: [
253
+ { name: "lp", type: "address" },
254
+ { name: "type", type: "int24" },
255
+ { name: "token0", type: "address" },
256
+ { name: "token1", type: "address" },
257
+ { name: "factory", type: "address" },
258
+ { name: "pool_fee", type: "uint256" }
259
+ ]
260
+ }
242
261
  ]
243
- }
244
- ]
245
- },
246
- {
247
- type: "function",
248
- name: "all",
249
- stateMutability: "view",
250
- inputs: [
251
- { name: "_limit", type: "uint256" },
252
- { name: "_offset", type: "uint256" },
253
- { name: "_filter", type: "uint256" }
254
- ],
255
- outputs: [
262
+ },
256
263
  {
257
- name: "",
258
- type: "tuple[]",
259
- components: [
260
- { name: "lp", type: "address" },
261
- { name: "symbol", type: "string" },
262
- { name: "decimals", type: "uint8" },
263
- { name: "liquidity", type: "uint256" },
264
- { name: "type", type: "int24" },
265
- { name: "tick", type: "int24" },
266
- { name: "sqrt_ratio", type: "uint160" },
267
- { name: "token0", type: "address" },
268
- { name: "reserve0", type: "uint256" },
269
- { name: "staked0", type: "uint256" },
270
- { name: "token1", type: "address" },
271
- { name: "reserve1", type: "uint256" },
272
- { name: "staked1", type: "uint256" },
273
- { name: "gauge", type: "address" },
274
- { name: "gauge_liquidity", type: "uint256" },
275
- { name: "gauge_alive", type: "bool" },
276
- { name: "fee", type: "address" },
277
- { name: "bribe", type: "address" },
278
- { name: "factory", type: "address" },
279
- { name: "emissions", type: "uint256" },
280
- { name: "emissions_token", type: "address" },
281
- { name: "emissions_cap", type: "uint256" },
282
- { name: "pool_fee", type: "uint256" },
283
- { name: "unstaked_fee", type: "uint256" },
284
- { name: "token0_fees", type: "uint256" },
285
- { name: "token1_fees", type: "uint256" },
286
- { name: "locked", type: "uint256" },
287
- { name: "emerging", type: "uint256" },
288
- { name: "created_at", type: "uint32" },
289
- { name: "nfpm", type: "address" },
290
- { name: "alm", type: "address" },
291
- { name: "root", type: "address" }
264
+ type: "function",
265
+ name: "all",
266
+ stateMutability: "view",
267
+ inputs: [
268
+ { name: "_limit", type: "uint256" },
269
+ { name: "_offset", type: "uint256" },
270
+ { name: "_filter", type: "uint256" }
271
+ ],
272
+ outputs: [
273
+ {
274
+ name: "",
275
+ type: "tuple[]",
276
+ components: [
277
+ { name: "lp", type: "address" },
278
+ { name: "symbol", type: "string" },
279
+ { name: "decimals", type: "uint8" },
280
+ { name: "liquidity", type: "uint256" },
281
+ { name: "type", type: "int24" },
282
+ { name: "tick", type: "int24" },
283
+ { name: "sqrt_ratio", type: "uint160" },
284
+ { name: "token0", type: "address" },
285
+ { name: "reserve0", type: "uint256" },
286
+ { name: "staked0", type: "uint256" },
287
+ { name: "token1", type: "address" },
288
+ { name: "reserve1", type: "uint256" },
289
+ { name: "staked1", type: "uint256" },
290
+ { name: "gauge", type: "address" },
291
+ { name: "gauge_liquidity", type: "uint256" },
292
+ { name: "gauge_alive", type: "bool" },
293
+ { name: "fee", type: "address" },
294
+ { name: "bribe", type: "address" },
295
+ { name: "factory", type: "address" },
296
+ { name: "emissions", type: "uint256" },
297
+ { name: "emissions_token", type: "address" },
298
+ { name: "emissions_cap", type: "uint256" },
299
+ { name: "pool_fee", type: "uint256" },
300
+ { name: "unstaked_fee", type: "uint256" },
301
+ { name: "token0_fees", type: "uint256" },
302
+ { name: "token1_fees", type: "uint256" },
303
+ { name: "locked", type: "uint256" },
304
+ { name: "emerging", type: "uint256" },
305
+ { name: "created_at", type: "uint32" },
306
+ { name: "nfpm", type: "address" },
307
+ { name: "alm", type: "address" },
308
+ { name: "root", type: "address" }
309
+ ]
310
+ }
292
311
  ]
293
- }
294
- ]
295
- },
296
- {
297
- type: "function",
298
- name: "byAddress",
299
- stateMutability: "view",
300
- inputs: [{ name: "_address", type: "address" }],
301
- outputs: [
312
+ },
302
313
  {
303
- name: "",
304
- type: "tuple",
305
- components: [
306
- { name: "lp", type: "address" },
307
- { name: "symbol", type: "string" },
308
- { name: "decimals", type: "uint8" },
309
- { name: "liquidity", type: "uint256" },
310
- { name: "type", type: "int24" },
311
- { name: "tick", type: "int24" },
312
- { name: "sqrt_ratio", type: "uint160" },
313
- { name: "token0", type: "address" },
314
- { name: "reserve0", type: "uint256" },
315
- { name: "staked0", type: "uint256" },
316
- { name: "token1", type: "address" },
317
- { name: "reserve1", type: "uint256" },
318
- { name: "staked1", type: "uint256" },
319
- { name: "gauge", type: "address" },
320
- { name: "gauge_liquidity", type: "uint256" },
321
- { name: "gauge_alive", type: "bool" },
322
- { name: "fee", type: "address" },
323
- { name: "bribe", type: "address" },
324
- { name: "factory", type: "address" },
325
- { name: "emissions", type: "uint256" },
326
- { name: "emissions_token", type: "address" },
327
- { name: "emissions_cap", type: "uint256" },
328
- { name: "pool_fee", type: "uint256" },
329
- { name: "unstaked_fee", type: "uint256" },
330
- { name: "token0_fees", type: "uint256" },
331
- { name: "token1_fees", type: "uint256" },
332
- { name: "locked", type: "uint256" },
333
- { name: "emerging", type: "uint256" },
334
- { name: "created_at", type: "uint32" },
335
- { name: "nfpm", type: "address" },
336
- { name: "alm", type: "address" },
337
- { name: "root", type: "address" }
314
+ type: "function",
315
+ name: "byAddress",
316
+ stateMutability: "view",
317
+ inputs: [{ name: "_address", type: "address" }],
318
+ outputs: [
319
+ {
320
+ name: "",
321
+ type: "tuple",
322
+ components: [
323
+ { name: "lp", type: "address" },
324
+ { name: "symbol", type: "string" },
325
+ { name: "decimals", type: "uint8" },
326
+ { name: "liquidity", type: "uint256" },
327
+ { name: "type", type: "int24" },
328
+ { name: "tick", type: "int24" },
329
+ { name: "sqrt_ratio", type: "uint160" },
330
+ { name: "token0", type: "address" },
331
+ { name: "reserve0", type: "uint256" },
332
+ { name: "staked0", type: "uint256" },
333
+ { name: "token1", type: "address" },
334
+ { name: "reserve1", type: "uint256" },
335
+ { name: "staked1", type: "uint256" },
336
+ { name: "gauge", type: "address" },
337
+ { name: "gauge_liquidity", type: "uint256" },
338
+ { name: "gauge_alive", type: "bool" },
339
+ { name: "fee", type: "address" },
340
+ { name: "bribe", type: "address" },
341
+ { name: "factory", type: "address" },
342
+ { name: "emissions", type: "uint256" },
343
+ { name: "emissions_token", type: "address" },
344
+ { name: "emissions_cap", type: "uint256" },
345
+ { name: "pool_fee", type: "uint256" },
346
+ { name: "unstaked_fee", type: "uint256" },
347
+ { name: "token0_fees", type: "uint256" },
348
+ { name: "token1_fees", type: "uint256" },
349
+ { name: "locked", type: "uint256" },
350
+ { name: "emerging", type: "uint256" },
351
+ { name: "created_at", type: "uint32" },
352
+ { name: "nfpm", type: "address" },
353
+ { name: "alm", type: "address" },
354
+ { name: "root", type: "address" }
355
+ ]
356
+ }
338
357
  ]
339
- }
340
- ]
341
- },
342
- {
343
- type: "function",
344
- name: "count",
345
- stateMutability: "view",
346
- inputs: [],
347
- outputs: [{ name: "", type: "uint256" }]
348
- },
349
- {
350
- type: "function",
351
- name: "positions",
352
- stateMutability: "view",
353
- inputs: [
354
- { name: "_limit", type: "uint256" },
355
- { name: "_offset", type: "uint256" },
356
- { name: "_account", type: "address" }
357
- ],
358
- outputs: [
358
+ },
359
359
  {
360
- name: "",
361
- type: "tuple[]",
362
- components: [
363
- { name: "id", type: "uint256" },
364
- { name: "lp", type: "address" },
365
- { name: "liquidity", type: "uint256" },
366
- { name: "staked", type: "uint256" },
367
- { name: "amount0", type: "uint256" },
368
- { name: "amount1", type: "uint256" },
369
- { name: "staked0", type: "uint256" },
370
- { name: "staked1", type: "uint256" },
371
- { name: "unstaked_earned0", type: "uint256" },
372
- { name: "unstaked_earned1", type: "uint256" },
373
- { name: "emissions_earned", type: "uint256" },
374
- { name: "tick_lower", type: "int24" },
375
- { name: "tick_upper", type: "int24" },
376
- { name: "sqrt_ratio_lower", type: "uint160" },
377
- { name: "sqrt_ratio_upper", type: "uint160" },
378
- { name: "locker", type: "address" },
379
- { name: "unlocks_at", type: "uint32" },
380
- { name: "alm", type: "address" }
360
+ type: "function",
361
+ name: "count",
362
+ stateMutability: "view",
363
+ inputs: [],
364
+ outputs: [{ name: "", type: "uint256" }]
365
+ },
366
+ {
367
+ type: "function",
368
+ name: "positions",
369
+ stateMutability: "view",
370
+ inputs: [
371
+ { name: "_limit", type: "uint256" },
372
+ { name: "_offset", type: "uint256" },
373
+ { name: "_account", type: "address" }
374
+ ],
375
+ outputs: [
376
+ {
377
+ name: "",
378
+ type: "tuple[]",
379
+ components: [
380
+ { name: "id", type: "uint256" },
381
+ { name: "lp", type: "address" },
382
+ { name: "liquidity", type: "uint256" },
383
+ { name: "staked", type: "uint256" },
384
+ { name: "amount0", type: "uint256" },
385
+ { name: "amount1", type: "uint256" },
386
+ { name: "staked0", type: "uint256" },
387
+ { name: "staked1", type: "uint256" },
388
+ { name: "unstaked_earned0", type: "uint256" },
389
+ { name: "unstaked_earned1", type: "uint256" },
390
+ { name: "emissions_earned", type: "uint256" },
391
+ { name: "tick_lower", type: "int24" },
392
+ { name: "tick_upper", type: "int24" },
393
+ { name: "sqrt_ratio_lower", type: "uint160" },
394
+ { name: "sqrt_ratio_upper", type: "uint160" },
395
+ { name: "locker", type: "address" },
396
+ { name: "unlocks_at", type: "uint32" },
397
+ { name: "alm", type: "address" }
398
+ ]
399
+ }
381
400
  ]
382
401
  }
383
- ]
384
- }
385
- ];
386
- var routerAbi = [
387
- {
388
- type: "function",
389
- name: "weth",
390
- stateMutability: "view",
391
- inputs: [],
392
- outputs: [{ name: "", type: "address" }]
393
- },
394
- {
395
- type: "function",
396
- name: "defaultFactory",
397
- stateMutability: "view",
398
- inputs: [],
399
- outputs: [{ name: "", type: "address" }]
400
- },
401
- {
402
- type: "function",
403
- name: "poolFor",
404
- stateMutability: "view",
405
- inputs: [
406
- { name: "tokenA", type: "address" },
407
- { name: "tokenB", type: "address" },
408
- { name: "stable", type: "bool" },
409
- { name: "_factory", type: "address" }
410
- ],
411
- outputs: [{ name: "pool", type: "address" }]
412
- },
413
- {
414
- type: "function",
415
- name: "getAmountsOut",
416
- stateMutability: "view",
417
- inputs: [
418
- { name: "amountIn", type: "uint256" },
402
+ ];
403
+ routerAbi = [
419
404
  {
420
- name: "routes",
421
- type: "tuple[]",
422
- components: [
423
- { name: "from", type: "address" },
424
- { name: "to", type: "address" },
405
+ type: "function",
406
+ name: "weth",
407
+ stateMutability: "view",
408
+ inputs: [],
409
+ outputs: [{ name: "", type: "address" }]
410
+ },
411
+ {
412
+ type: "function",
413
+ name: "defaultFactory",
414
+ stateMutability: "view",
415
+ inputs: [],
416
+ outputs: [{ name: "", type: "address" }]
417
+ },
418
+ {
419
+ type: "function",
420
+ name: "poolFor",
421
+ stateMutability: "view",
422
+ inputs: [
423
+ { name: "tokenA", type: "address" },
424
+ { name: "tokenB", type: "address" },
425
425
  { name: "stable", type: "bool" },
426
- { name: "factory", type: "address" }
427
- ]
428
- }
429
- ],
430
- outputs: [{ name: "amounts", type: "uint256[]" }]
431
- },
432
- {
433
- type: "function",
434
- name: "quoteAddLiquidity",
435
- stateMutability: "view",
436
- inputs: [
437
- { name: "tokenA", type: "address" },
438
- { name: "tokenB", type: "address" },
439
- { name: "stable", type: "bool" },
440
- { name: "_factory", type: "address" },
441
- { name: "amountADesired", type: "uint256" },
442
- { name: "amountBDesired", type: "uint256" }
443
- ],
444
- outputs: [
445
- { name: "amountA", type: "uint256" },
446
- { name: "amountB", type: "uint256" },
447
- { name: "liquidity", type: "uint256" }
448
- ]
449
- },
450
- {
451
- type: "function",
452
- name: "addLiquidity",
453
- stateMutability: "nonpayable",
454
- inputs: [
455
- { name: "tokenA", type: "address" },
456
- { name: "tokenB", type: "address" },
457
- { name: "stable", type: "bool" },
458
- { name: "amountADesired", type: "uint256" },
459
- { name: "amountBDesired", type: "uint256" },
460
- { name: "amountAMin", type: "uint256" },
461
- { name: "amountBMin", type: "uint256" },
462
- { name: "to", type: "address" },
463
- { name: "deadline", type: "uint256" }
464
- ],
465
- outputs: [
466
- { name: "amountA", type: "uint256" },
467
- { name: "amountB", type: "uint256" },
468
- { name: "liquidity", type: "uint256" }
469
- ]
470
- },
471
- {
472
- type: "function",
473
- name: "addLiquidityETH",
474
- stateMutability: "payable",
475
- inputs: [
476
- { name: "token", type: "address" },
477
- { name: "stable", type: "bool" },
478
- { name: "amountTokenDesired", type: "uint256" },
479
- { name: "amountTokenMin", type: "uint256" },
480
- { name: "amountETHMin", type: "uint256" },
481
- { name: "to", type: "address" },
482
- { name: "deadline", type: "uint256" }
483
- ],
484
- outputs: [
485
- { name: "amountToken", type: "uint256" },
486
- { name: "amountETH", type: "uint256" },
487
- { name: "liquidity", type: "uint256" }
488
- ]
489
- },
490
- {
491
- type: "function",
492
- name: "removeLiquidity",
493
- stateMutability: "nonpayable",
494
- inputs: [
495
- { name: "tokenA", type: "address" },
496
- { name: "tokenB", type: "address" },
497
- { name: "stable", type: "bool" },
498
- { name: "liquidity", type: "uint256" },
499
- { name: "amountAMin", type: "uint256" },
500
- { name: "amountBMin", type: "uint256" },
501
- { name: "to", type: "address" },
502
- { name: "deadline", type: "uint256" }
503
- ],
504
- outputs: [
505
- { name: "amountA", type: "uint256" },
506
- { name: "amountB", type: "uint256" }
507
- ]
508
- },
509
- {
510
- type: "function",
511
- name: "removeLiquidityETH",
512
- stateMutability: "nonpayable",
513
- inputs: [
514
- { name: "token", type: "address" },
515
- { name: "stable", type: "bool" },
516
- { name: "liquidity", type: "uint256" },
517
- { name: "amountTokenMin", type: "uint256" },
518
- { name: "amountETHMin", type: "uint256" },
519
- { name: "to", type: "address" },
520
- { name: "deadline", type: "uint256" }
521
- ],
522
- outputs: [
523
- { name: "amountToken", type: "uint256" },
524
- { name: "amountETH", type: "uint256" }
525
- ]
526
- },
527
- {
528
- type: "function",
529
- name: "swapExactTokensForTokens",
530
- stateMutability: "nonpayable",
531
- inputs: [
532
- { name: "amountIn", type: "uint256" },
533
- { name: "amountOutMin", type: "uint256" },
426
+ { name: "_factory", type: "address" }
427
+ ],
428
+ outputs: [{ name: "pool", type: "address" }]
429
+ },
534
430
  {
535
- name: "routes",
536
- type: "tuple[]",
537
- components: [
538
- { name: "from", type: "address" },
539
- { name: "to", type: "address" },
431
+ type: "function",
432
+ name: "getAmountsOut",
433
+ stateMutability: "view",
434
+ inputs: [
435
+ { name: "amountIn", type: "uint256" },
436
+ {
437
+ name: "routes",
438
+ type: "tuple[]",
439
+ components: [
440
+ { name: "from", type: "address" },
441
+ { name: "to", type: "address" },
442
+ { name: "stable", type: "bool" },
443
+ { name: "factory", type: "address" }
444
+ ]
445
+ }
446
+ ],
447
+ outputs: [{ name: "amounts", type: "uint256[]" }]
448
+ },
449
+ {
450
+ type: "function",
451
+ name: "quoteAddLiquidity",
452
+ stateMutability: "view",
453
+ inputs: [
454
+ { name: "tokenA", type: "address" },
455
+ { name: "tokenB", type: "address" },
540
456
  { name: "stable", type: "bool" },
541
- { name: "factory", type: "address" }
457
+ { name: "_factory", type: "address" },
458
+ { name: "amountADesired", type: "uint256" },
459
+ { name: "amountBDesired", type: "uint256" }
460
+ ],
461
+ outputs: [
462
+ { name: "amountA", type: "uint256" },
463
+ { name: "amountB", type: "uint256" },
464
+ { name: "liquidity", type: "uint256" }
542
465
  ]
543
466
  },
544
- { name: "to", type: "address" },
545
- { name: "deadline", type: "uint256" }
546
- ],
547
- outputs: [{ name: "amounts", type: "uint256[]" }]
548
- },
549
- {
550
- type: "function",
551
- name: "swapExactETHForTokens",
552
- stateMutability: "payable",
553
- inputs: [
554
- { name: "amountOutMin", type: "uint256" },
555
467
  {
556
- name: "routes",
557
- type: "tuple[]",
558
- components: [
559
- { name: "from", type: "address" },
468
+ type: "function",
469
+ name: "addLiquidity",
470
+ stateMutability: "nonpayable",
471
+ inputs: [
472
+ { name: "tokenA", type: "address" },
473
+ { name: "tokenB", type: "address" },
474
+ { name: "stable", type: "bool" },
475
+ { name: "amountADesired", type: "uint256" },
476
+ { name: "amountBDesired", type: "uint256" },
477
+ { name: "amountAMin", type: "uint256" },
478
+ { name: "amountBMin", type: "uint256" },
560
479
  { name: "to", type: "address" },
480
+ { name: "deadline", type: "uint256" }
481
+ ],
482
+ outputs: [
483
+ { name: "amountA", type: "uint256" },
484
+ { name: "amountB", type: "uint256" },
485
+ { name: "liquidity", type: "uint256" }
486
+ ]
487
+ },
488
+ {
489
+ type: "function",
490
+ name: "addLiquidityETH",
491
+ stateMutability: "payable",
492
+ inputs: [
493
+ { name: "token", type: "address" },
561
494
  { name: "stable", type: "bool" },
562
- { name: "factory", type: "address" }
495
+ { name: "amountTokenDesired", type: "uint256" },
496
+ { name: "amountTokenMin", type: "uint256" },
497
+ { name: "amountETHMin", type: "uint256" },
498
+ { name: "to", type: "address" },
499
+ { name: "deadline", type: "uint256" }
500
+ ],
501
+ outputs: [
502
+ { name: "amountToken", type: "uint256" },
503
+ { name: "amountETH", type: "uint256" },
504
+ { name: "liquidity", type: "uint256" }
563
505
  ]
564
506
  },
565
- { name: "to", type: "address" },
566
- { name: "deadline", type: "uint256" }
567
- ],
568
- outputs: [{ name: "amounts", type: "uint256[]" }]
569
- },
570
- {
571
- type: "function",
572
- name: "swapExactTokensForETH",
573
- stateMutability: "nonpayable",
574
- inputs: [
575
- { name: "amountIn", type: "uint256" },
576
- { name: "amountOutMin", type: "uint256" },
577
507
  {
578
- name: "routes",
579
- type: "tuple[]",
580
- components: [
581
- { name: "from", type: "address" },
508
+ type: "function",
509
+ name: "removeLiquidity",
510
+ stateMutability: "nonpayable",
511
+ inputs: [
512
+ { name: "tokenA", type: "address" },
513
+ { name: "tokenB", type: "address" },
514
+ { name: "stable", type: "bool" },
515
+ { name: "liquidity", type: "uint256" },
516
+ { name: "amountAMin", type: "uint256" },
517
+ { name: "amountBMin", type: "uint256" },
582
518
  { name: "to", type: "address" },
519
+ { name: "deadline", type: "uint256" }
520
+ ],
521
+ outputs: [
522
+ { name: "amountA", type: "uint256" },
523
+ { name: "amountB", type: "uint256" }
524
+ ]
525
+ },
526
+ {
527
+ type: "function",
528
+ name: "removeLiquidityETH",
529
+ stateMutability: "nonpayable",
530
+ inputs: [
531
+ { name: "token", type: "address" },
583
532
  { name: "stable", type: "bool" },
584
- { name: "factory", type: "address" }
533
+ { name: "liquidity", type: "uint256" },
534
+ { name: "amountTokenMin", type: "uint256" },
535
+ { name: "amountETHMin", type: "uint256" },
536
+ { name: "to", type: "address" },
537
+ { name: "deadline", type: "uint256" }
538
+ ],
539
+ outputs: [
540
+ { name: "amountToken", type: "uint256" },
541
+ { name: "amountETH", type: "uint256" }
585
542
  ]
586
543
  },
587
- { name: "to", type: "address" },
588
- { name: "deadline", type: "uint256" }
589
- ],
590
- outputs: [{ name: "amounts", type: "uint256[]" }]
591
- }
592
- ];
593
- var mixedQuoterAbi = [
594
- {
595
- type: "function",
596
- name: "quoteExactInput",
597
- stateMutability: "nonpayable",
598
- inputs: [
599
- { name: "path", type: "bytes" },
600
- { name: "amountIn", type: "uint256" }
601
- ],
602
- outputs: [
603
- { name: "amountOut", type: "uint256" },
604
- { name: "v3RouteStartTickSpacing", type: "uint160[]" },
605
- { name: "v3RouteStartSqrtPriceX96AfterList", type: "uint160[]" },
606
- { name: "v3RouteInitializedTicksCrossedList", type: "uint32[]" },
607
- { name: "v3SwapGasEstimate", type: "uint256" }
608
- ]
609
- }
610
- ];
611
- var mixedQuoterV3Abi = [
612
- {
613
- type: "function",
614
- name: "quoteExactInput",
615
- stateMutability: "nonpayable",
616
- inputs: [
617
- { name: "path", type: "bytes" },
618
- { name: "amountIn", type: "uint256" }
619
- ],
620
- outputs: [
621
- { name: "amountOut", type: "uint256" },
622
- { name: "v3SqrtPriceX96AfterList", type: "uint160[]" },
623
- { name: "v3InitializedTicksCrossedList", type: "uint32[]" },
624
- { name: "v3SwapGasEstimate", type: "uint256" }
625
- ]
626
- }
627
- ];
628
- var v2PoolFactoryAbi = [
629
- {
630
- type: "function",
631
- name: "getPool",
632
- stateMutability: "view",
633
- inputs: [
634
- { name: "tokenA", type: "address" },
635
- { name: "tokenB", type: "address" },
636
- { name: "stable", type: "bool" }
637
- ],
638
- outputs: [{ name: "", type: "address" }]
639
- }
640
- ];
641
- var clPoolFactoryAbi = [
642
- {
643
- type: "function",
644
- name: "getPool",
645
- stateMutability: "view",
646
- inputs: [
647
- { name: "tokenA", type: "address" },
648
- { name: "tokenB", type: "address" },
649
- { name: "tickSpacing", type: "int24" }
650
- ],
651
- outputs: [{ name: "", type: "address" }]
652
- },
653
- {
654
- type: "function",
655
- name: "tickSpacings",
656
- stateMutability: "view",
657
- inputs: [],
658
- outputs: [{ name: "", type: "int24[]" }]
659
- }
660
- ];
661
- var clPoolAbi = [
662
- {
663
- type: "function",
664
- name: "slot0",
665
- stateMutability: "view",
666
- inputs: [],
667
- outputs: [
668
- { name: "sqrtPriceX96", type: "uint160" },
669
- { name: "tick", type: "int24" },
670
- { name: "observationIndex", type: "uint16" },
671
- { name: "observationCardinality", type: "uint16" },
672
- { name: "observationCardinalityNext", type: "uint16" },
673
- { name: "unlocked", type: "bool" }
674
- ]
675
- },
676
- {
677
- type: "function",
678
- name: "liquidity",
679
- stateMutability: "view",
680
- inputs: [],
681
- outputs: [{ name: "", type: "uint128" }]
682
- }
683
- ];
684
- var sugarHelperAbi = [
685
- {
686
- type: "function",
687
- name: "estimateAmount0",
688
- stateMutability: "view",
689
- inputs: [
690
- { name: "amount1", type: "uint256" },
691
- { name: "sqrtRatioX96", type: "uint160" },
692
- { name: "sqrtRatioAX96", type: "uint160" },
693
- { name: "sqrtRatioBX96", type: "uint160" }
694
- ],
695
- outputs: [{ name: "", type: "uint256" }]
696
- },
697
- {
698
- type: "function",
699
- name: "estimateAmount1",
700
- stateMutability: "view",
701
- inputs: [
702
- { name: "amount0", type: "uint256" },
703
- { name: "sqrtRatioX96", type: "uint160" },
704
- { name: "sqrtRatioAX96", type: "uint160" },
705
- { name: "sqrtRatioBX96", type: "uint160" }
706
- ],
707
- outputs: [{ name: "", type: "uint256" }]
708
- }
709
- ];
710
- var nfpmAbi = [
711
- {
712
- type: "function",
713
- name: "mint",
714
- stateMutability: "payable",
715
- inputs: [
716
544
  {
717
- name: "params",
718
- type: "tuple",
719
- components: [
720
- { name: "token0", type: "address" },
721
- { name: "token1", type: "address" },
722
- { name: "tickSpacing", type: "int24" },
723
- { name: "tickLower", type: "int24" },
724
- { name: "tickUpper", type: "int24" },
725
- { name: "amount0Desired", type: "uint256" },
726
- { name: "amount1Desired", type: "uint256" },
727
- { name: "amount0Min", type: "uint256" },
728
- { name: "amount1Min", type: "uint256" },
729
- { name: "recipient", type: "address" },
730
- { name: "deadline", type: "uint256" },
731
- { name: "sqrtPriceX96", type: "uint160" }
545
+ type: "function",
546
+ name: "swapExactTokensForTokens",
547
+ stateMutability: "nonpayable",
548
+ inputs: [
549
+ { name: "amountIn", type: "uint256" },
550
+ { name: "amountOutMin", type: "uint256" },
551
+ {
552
+ name: "routes",
553
+ type: "tuple[]",
554
+ components: [
555
+ { name: "from", type: "address" },
556
+ { name: "to", type: "address" },
557
+ { name: "stable", type: "bool" },
558
+ { name: "factory", type: "address" }
559
+ ]
560
+ },
561
+ { name: "to", type: "address" },
562
+ { name: "deadline", type: "uint256" }
563
+ ],
564
+ outputs: [{ name: "amounts", type: "uint256[]" }]
565
+ },
566
+ {
567
+ type: "function",
568
+ name: "swapExactETHForTokens",
569
+ stateMutability: "payable",
570
+ inputs: [
571
+ { name: "amountOutMin", type: "uint256" },
572
+ {
573
+ name: "routes",
574
+ type: "tuple[]",
575
+ components: [
576
+ { name: "from", type: "address" },
577
+ { name: "to", type: "address" },
578
+ { name: "stable", type: "bool" },
579
+ { name: "factory", type: "address" }
580
+ ]
581
+ },
582
+ { name: "to", type: "address" },
583
+ { name: "deadline", type: "uint256" }
584
+ ],
585
+ outputs: [{ name: "amounts", type: "uint256[]" }]
586
+ },
587
+ {
588
+ type: "function",
589
+ name: "swapExactTokensForETH",
590
+ stateMutability: "nonpayable",
591
+ inputs: [
592
+ { name: "amountIn", type: "uint256" },
593
+ { name: "amountOutMin", type: "uint256" },
594
+ {
595
+ name: "routes",
596
+ type: "tuple[]",
597
+ components: [
598
+ { name: "from", type: "address" },
599
+ { name: "to", type: "address" },
600
+ { name: "stable", type: "bool" },
601
+ { name: "factory", type: "address" }
602
+ ]
603
+ },
604
+ { name: "to", type: "address" },
605
+ { name: "deadline", type: "uint256" }
606
+ ],
607
+ outputs: [{ name: "amounts", type: "uint256[]" }]
608
+ }
609
+ ];
610
+ mixedQuoterAbi = [
611
+ {
612
+ type: "function",
613
+ name: "quoteExactInput",
614
+ stateMutability: "nonpayable",
615
+ inputs: [
616
+ { name: "path", type: "bytes" },
617
+ { name: "amountIn", type: "uint256" }
618
+ ],
619
+ outputs: [
620
+ { name: "amountOut", type: "uint256" },
621
+ { name: "v3RouteStartTickSpacing", type: "uint160[]" },
622
+ { name: "v3RouteStartSqrtPriceX96AfterList", type: "uint160[]" },
623
+ { name: "v3RouteInitializedTicksCrossedList", type: "uint32[]" },
624
+ { name: "v3SwapGasEstimate", type: "uint256" }
732
625
  ]
733
626
  }
734
- ],
735
- outputs: [
736
- { name: "tokenId", type: "uint256" },
737
- { name: "liquidity", type: "uint128" },
738
- { name: "amount0", type: "uint256" },
739
- { name: "amount1", type: "uint256" }
740
- ]
741
- },
742
- {
743
- type: "function",
744
- name: "increaseLiquidity",
745
- stateMutability: "payable",
746
- inputs: [
627
+ ];
628
+ mixedQuoterV3Abi = [
747
629
  {
748
- name: "params",
749
- type: "tuple",
750
- components: [
751
- { name: "tokenId", type: "uint256" },
752
- { name: "amount0Desired", type: "uint256" },
753
- { name: "amount1Desired", type: "uint256" },
754
- { name: "amount0Min", type: "uint256" },
755
- { name: "amount1Min", type: "uint256" },
756
- { name: "deadline", type: "uint256" }
630
+ type: "function",
631
+ name: "quoteExactInput",
632
+ stateMutability: "nonpayable",
633
+ inputs: [
634
+ { name: "path", type: "bytes" },
635
+ { name: "amountIn", type: "uint256" }
636
+ ],
637
+ outputs: [
638
+ { name: "amountOut", type: "uint256" },
639
+ { name: "v3SqrtPriceX96AfterList", type: "uint160[]" },
640
+ { name: "v3InitializedTicksCrossedList", type: "uint32[]" },
641
+ { name: "v3SwapGasEstimate", type: "uint256" }
757
642
  ]
758
643
  }
759
- ],
760
- outputs: [
761
- { name: "liquidity", type: "uint128" },
762
- { name: "amount0", type: "uint256" },
763
- { name: "amount1", type: "uint256" }
764
- ]
765
- },
766
- {
767
- type: "function",
768
- name: "decreaseLiquidity",
769
- stateMutability: "payable",
770
- inputs: [
644
+ ];
645
+ v2PoolFactoryAbi = [
771
646
  {
772
- name: "params",
773
- type: "tuple",
774
- components: [
647
+ type: "function",
648
+ name: "getPool",
649
+ stateMutability: "view",
650
+ inputs: [
651
+ { name: "tokenA", type: "address" },
652
+ { name: "tokenB", type: "address" },
653
+ { name: "stable", type: "bool" }
654
+ ],
655
+ outputs: [{ name: "", type: "address" }]
656
+ }
657
+ ];
658
+ clPoolFactoryAbi = [
659
+ {
660
+ type: "function",
661
+ name: "getPool",
662
+ stateMutability: "view",
663
+ inputs: [
664
+ { name: "tokenA", type: "address" },
665
+ { name: "tokenB", type: "address" },
666
+ { name: "tickSpacing", type: "int24" }
667
+ ],
668
+ outputs: [{ name: "", type: "address" }]
669
+ },
670
+ {
671
+ type: "function",
672
+ name: "tickSpacings",
673
+ stateMutability: "view",
674
+ inputs: [],
675
+ outputs: [{ name: "", type: "int24[]" }]
676
+ }
677
+ ];
678
+ clPoolAbi = [
679
+ {
680
+ type: "function",
681
+ name: "slot0",
682
+ stateMutability: "view",
683
+ inputs: [],
684
+ outputs: [
685
+ { name: "sqrtPriceX96", type: "uint160" },
686
+ { name: "tick", type: "int24" },
687
+ { name: "observationIndex", type: "uint16" },
688
+ { name: "observationCardinality", type: "uint16" },
689
+ { name: "observationCardinalityNext", type: "uint16" },
690
+ { name: "unlocked", type: "bool" }
691
+ ]
692
+ },
693
+ {
694
+ type: "function",
695
+ name: "liquidity",
696
+ stateMutability: "view",
697
+ inputs: [],
698
+ outputs: [{ name: "", type: "uint128" }]
699
+ }
700
+ ];
701
+ sugarHelperAbi = [
702
+ {
703
+ type: "function",
704
+ name: "estimateAmount0",
705
+ stateMutability: "view",
706
+ inputs: [
707
+ { name: "amount1", type: "uint256" },
708
+ { name: "sqrtRatioX96", type: "uint160" },
709
+ { name: "sqrtRatioAX96", type: "uint160" },
710
+ { name: "sqrtRatioBX96", type: "uint160" }
711
+ ],
712
+ outputs: [{ name: "", type: "uint256" }]
713
+ },
714
+ {
715
+ type: "function",
716
+ name: "estimateAmount1",
717
+ stateMutability: "view",
718
+ inputs: [
719
+ { name: "amount0", type: "uint256" },
720
+ { name: "sqrtRatioX96", type: "uint160" },
721
+ { name: "sqrtRatioAX96", type: "uint160" },
722
+ { name: "sqrtRatioBX96", type: "uint160" }
723
+ ],
724
+ outputs: [{ name: "", type: "uint256" }]
725
+ }
726
+ ];
727
+ nfpmAbi = [
728
+ {
729
+ type: "function",
730
+ name: "mint",
731
+ stateMutability: "payable",
732
+ inputs: [
733
+ {
734
+ name: "params",
735
+ type: "tuple",
736
+ components: [
737
+ { name: "token0", type: "address" },
738
+ { name: "token1", type: "address" },
739
+ { name: "tickSpacing", type: "int24" },
740
+ { name: "tickLower", type: "int24" },
741
+ { name: "tickUpper", type: "int24" },
742
+ { name: "amount0Desired", type: "uint256" },
743
+ { name: "amount1Desired", type: "uint256" },
744
+ { name: "amount0Min", type: "uint256" },
745
+ { name: "amount1Min", type: "uint256" },
746
+ { name: "recipient", type: "address" },
747
+ { name: "deadline", type: "uint256" },
748
+ { name: "sqrtPriceX96", type: "uint160" }
749
+ ]
750
+ }
751
+ ],
752
+ outputs: [
775
753
  { name: "tokenId", type: "uint256" },
776
754
  { name: "liquidity", type: "uint128" },
777
- { name: "amount0Min", type: "uint256" },
778
- { name: "amount1Min", type: "uint256" },
779
- { name: "deadline", type: "uint256" }
755
+ { name: "amount0", type: "uint256" },
756
+ { name: "amount1", type: "uint256" }
757
+ ]
758
+ },
759
+ {
760
+ type: "function",
761
+ name: "increaseLiquidity",
762
+ stateMutability: "payable",
763
+ inputs: [
764
+ {
765
+ name: "params",
766
+ type: "tuple",
767
+ components: [
768
+ { name: "tokenId", type: "uint256" },
769
+ { name: "amount0Desired", type: "uint256" },
770
+ { name: "amount1Desired", type: "uint256" },
771
+ { name: "amount0Min", type: "uint256" },
772
+ { name: "amount1Min", type: "uint256" },
773
+ { name: "deadline", type: "uint256" }
774
+ ]
775
+ }
776
+ ],
777
+ outputs: [
778
+ { name: "liquidity", type: "uint128" },
779
+ { name: "amount0", type: "uint256" },
780
+ { name: "amount1", type: "uint256" }
780
781
  ]
782
+ },
783
+ {
784
+ type: "function",
785
+ name: "decreaseLiquidity",
786
+ stateMutability: "payable",
787
+ inputs: [
788
+ {
789
+ name: "params",
790
+ type: "tuple",
791
+ components: [
792
+ { name: "tokenId", type: "uint256" },
793
+ { name: "liquidity", type: "uint128" },
794
+ { name: "amount0Min", type: "uint256" },
795
+ { name: "amount1Min", type: "uint256" },
796
+ { name: "deadline", type: "uint256" }
797
+ ]
798
+ }
799
+ ],
800
+ outputs: [
801
+ { name: "amount0", type: "uint256" },
802
+ { name: "amount1", type: "uint256" }
803
+ ]
804
+ },
805
+ {
806
+ type: "function",
807
+ name: "collect",
808
+ stateMutability: "payable",
809
+ inputs: [
810
+ {
811
+ name: "params",
812
+ type: "tuple",
813
+ components: [
814
+ { name: "tokenId", type: "uint256" },
815
+ { name: "recipient", type: "address" },
816
+ { name: "amount0Max", type: "uint128" },
817
+ { name: "amount1Max", type: "uint128" }
818
+ ]
819
+ }
820
+ ],
821
+ outputs: [
822
+ { name: "amount0", type: "uint256" },
823
+ { name: "amount1", type: "uint256" }
824
+ ]
825
+ },
826
+ {
827
+ type: "function",
828
+ name: "burn",
829
+ stateMutability: "payable",
830
+ inputs: [{ name: "tokenId", type: "uint256" }],
831
+ outputs: []
832
+ },
833
+ {
834
+ type: "function",
835
+ name: "approve",
836
+ stateMutability: "nonpayable",
837
+ inputs: [
838
+ { name: "to", type: "address" },
839
+ { name: "tokenId", type: "uint256" }
840
+ ],
841
+ outputs: []
781
842
  }
782
- ],
783
- outputs: [
784
- { name: "amount0", type: "uint256" },
785
- { name: "amount1", type: "uint256" }
786
- ]
787
- },
788
- {
789
- type: "function",
790
- name: "collect",
791
- stateMutability: "payable",
792
- inputs: [
843
+ ];
844
+ clSwapRouterAbi = [
793
845
  {
794
- name: "params",
795
- type: "tuple",
796
- components: [
797
- { name: "tokenId", type: "uint256" },
798
- { name: "recipient", type: "address" },
799
- { name: "amount0Max", type: "uint128" },
800
- { name: "amount1Max", type: "uint128" }
846
+ type: "function",
847
+ name: "exactInputSingle",
848
+ stateMutability: "payable",
849
+ inputs: [
850
+ {
851
+ name: "params",
852
+ type: "tuple",
853
+ components: [
854
+ { name: "tokenIn", type: "address" },
855
+ { name: "tokenOut", type: "address" },
856
+ { name: "tickSpacing", type: "int24" },
857
+ { name: "recipient", type: "address" },
858
+ { name: "deadline", type: "uint256" },
859
+ { name: "amountIn", type: "uint256" },
860
+ { name: "amountOutMinimum", type: "uint256" },
861
+ { name: "sqrtPriceLimitX96", type: "uint160" }
862
+ ]
863
+ }
864
+ ],
865
+ outputs: [{ name: "amountOut", type: "uint256" }]
866
+ }
867
+ ];
868
+ poolClaimFeesAbi = [
869
+ {
870
+ type: "function",
871
+ name: "claimFees",
872
+ stateMutability: "nonpayable",
873
+ inputs: [],
874
+ outputs: [
875
+ { name: "claimed0", type: "uint256" },
876
+ { name: "claimed1", type: "uint256" }
801
877
  ]
802
878
  }
803
- ],
804
- outputs: [
805
- { name: "amount0", type: "uint256" },
806
- { name: "amount1", type: "uint256" }
807
- ]
808
- },
809
- {
810
- type: "function",
811
- name: "burn",
812
- stateMutability: "payable",
813
- inputs: [{ name: "tokenId", type: "uint256" }],
814
- outputs: []
815
- },
816
- {
817
- type: "function",
818
- name: "approve",
819
- stateMutability: "nonpayable",
820
- inputs: [
821
- { name: "to", type: "address" },
822
- { name: "tokenId", type: "uint256" }
823
- ],
824
- outputs: []
825
- }
826
- ];
827
- var clSwapRouterAbi = [
828
- {
829
- type: "function",
830
- name: "exactInputSingle",
831
- stateMutability: "payable",
832
- inputs: [
879
+ ];
880
+ gaugeAbi = [
833
881
  {
834
- name: "params",
835
- type: "tuple",
836
- components: [
837
- { name: "tokenIn", type: "address" },
838
- { name: "tokenOut", type: "address" },
839
- { name: "tickSpacing", type: "int24" },
840
- { name: "recipient", type: "address" },
841
- { name: "deadline", type: "uint256" },
842
- { name: "amountIn", type: "uint256" },
843
- { name: "amountOutMinimum", type: "uint256" },
844
- { name: "sqrtPriceLimitX96", type: "uint160" }
882
+ type: "function",
883
+ name: "deposit",
884
+ stateMutability: "nonpayable",
885
+ inputs: [{ name: "_amount", type: "uint256" }],
886
+ outputs: []
887
+ },
888
+ {
889
+ type: "function",
890
+ name: "withdraw",
891
+ stateMutability: "nonpayable",
892
+ inputs: [{ name: "_amount", type: "uint256" }],
893
+ outputs: []
894
+ },
895
+ {
896
+ type: "function",
897
+ name: "getReward",
898
+ stateMutability: "nonpayable",
899
+ inputs: [{ name: "_account", type: "address" }],
900
+ outputs: []
901
+ }
902
+ ];
903
+ clGaugeAbi = [
904
+ {
905
+ type: "function",
906
+ name: "deposit",
907
+ stateMutability: "nonpayable",
908
+ inputs: [{ name: "tokenId", type: "uint256" }],
909
+ outputs: []
910
+ },
911
+ {
912
+ type: "function",
913
+ name: "withdraw",
914
+ stateMutability: "nonpayable",
915
+ inputs: [{ name: "tokenId", type: "uint256" }],
916
+ outputs: []
917
+ },
918
+ {
919
+ type: "function",
920
+ name: "getReward",
921
+ stateMutability: "nonpayable",
922
+ inputs: [{ name: "tokenId", type: "uint256" }],
923
+ outputs: []
924
+ }
925
+ ];
926
+ aerodromePoolMetaAbi = [
927
+ { type: "function", name: "symbol", stateMutability: "view", inputs: [], outputs: [{ type: "string" }] },
928
+ { type: "function", name: "token0", stateMutability: "view", inputs: [], outputs: [{ type: "address" }] },
929
+ { type: "function", name: "token1", stateMutability: "view", inputs: [], outputs: [{ type: "address" }] },
930
+ { type: "function", name: "stable", stateMutability: "view", inputs: [], outputs: [{ type: "bool" }] },
931
+ {
932
+ type: "function",
933
+ name: "getReserves",
934
+ stateMutability: "view",
935
+ inputs: [],
936
+ outputs: [
937
+ { name: "_reserve0", type: "uint256" },
938
+ { name: "_reserve1", type: "uint256" },
939
+ { name: "_blockTimestampLast", type: "uint256" }
845
940
  ]
846
941
  }
847
- ],
848
- outputs: [{ name: "amountOut", type: "uint256" }]
849
- }
850
- ];
851
- var poolClaimFeesAbi = [
852
- {
853
- type: "function",
854
- name: "claimFees",
855
- stateMutability: "nonpayable",
856
- inputs: [],
857
- outputs: [
858
- { name: "claimed0", type: "uint256" },
859
- { name: "claimed1", type: "uint256" }
860
- ]
861
- }
862
- ];
863
- var gaugeAbi = [
864
- {
865
- type: "function",
866
- name: "deposit",
867
- stateMutability: "nonpayable",
868
- inputs: [{ name: "_amount", type: "uint256" }],
869
- outputs: []
870
- },
871
- {
872
- type: "function",
873
- name: "withdraw",
874
- stateMutability: "nonpayable",
875
- inputs: [{ name: "_amount", type: "uint256" }],
876
- outputs: []
877
- },
878
- {
879
- type: "function",
880
- name: "getReward",
881
- stateMutability: "nonpayable",
882
- inputs: [{ name: "_account", type: "address" }],
883
- outputs: []
884
- }
885
- ];
886
- var clGaugeAbi = [
887
- {
888
- type: "function",
889
- name: "deposit",
890
- stateMutability: "nonpayable",
891
- inputs: [{ name: "tokenId", type: "uint256" }],
892
- outputs: []
893
- },
894
- {
895
- type: "function",
896
- name: "withdraw",
897
- stateMutability: "nonpayable",
898
- inputs: [{ name: "tokenId", type: "uint256" }],
899
- outputs: []
900
- },
901
- {
902
- type: "function",
903
- name: "getReward",
904
- stateMutability: "nonpayable",
905
- inputs: [{ name: "tokenId", type: "uint256" }],
906
- outputs: []
907
- }
908
- ];
909
- var aerodromePoolMetaAbi = [
910
- { type: "function", name: "symbol", stateMutability: "view", inputs: [], outputs: [{ type: "string" }] },
911
- { type: "function", name: "token0", stateMutability: "view", inputs: [], outputs: [{ type: "address" }] },
912
- { type: "function", name: "token1", stateMutability: "view", inputs: [], outputs: [{ type: "address" }] },
913
- { type: "function", name: "stable", stateMutability: "view", inputs: [], outputs: [{ type: "bool" }] },
914
- {
915
- type: "function",
916
- name: "getReserves",
917
- stateMutability: "view",
918
- inputs: [],
919
- outputs: [
920
- { name: "_reserve0", type: "uint256" },
921
- { name: "_reserve1", type: "uint256" },
922
- { name: "_blockTimestampLast", type: "uint256" }
923
- ]
924
- }
925
- ];
926
- var aerodromeVoterAbi = [
927
- {
928
- type: "function",
929
- name: "gauges",
930
- stateMutability: "view",
931
- inputs: [{ name: "pool", type: "address" }],
932
- outputs: [{ type: "address" }]
933
- }
934
- ];
935
- var erc20Abi = [
936
- { type: "function", name: "name", stateMutability: "view", inputs: [], outputs: [{ type: "string" }] },
937
- { type: "function", name: "decimals", stateMutability: "view", inputs: [], outputs: [{ type: "uint8" }] },
938
- { type: "function", name: "totalSupply", stateMutability: "view", inputs: [], outputs: [{ type: "uint256" }] },
939
- {
940
- type: "function",
941
- name: "allowance",
942
- stateMutability: "view",
943
- inputs: [
944
- { name: "owner", type: "address" },
945
- { name: "spender", type: "address" }
946
- ],
947
- outputs: [{ type: "uint256" }]
948
- },
949
- {
950
- type: "function",
951
- name: "approve",
952
- stateMutability: "nonpayable",
953
- inputs: [
954
- { name: "spender", type: "address" },
955
- { name: "amount", type: "uint256" }
956
- ],
957
- outputs: [{ type: "bool" }]
958
- },
959
- {
960
- type: "function",
961
- name: "symbol",
962
- stateMutability: "view",
963
- inputs: [],
964
- outputs: [{ type: "string" }]
965
- }
966
- ];
942
+ ];
943
+ aerodromeVoterAbi = [
944
+ {
945
+ type: "function",
946
+ name: "gauges",
947
+ stateMutability: "view",
948
+ inputs: [{ name: "pool", type: "address" }],
949
+ outputs: [{ type: "address" }]
950
+ }
951
+ ];
952
+ erc20Abi = [
953
+ { type: "function", name: "name", stateMutability: "view", inputs: [], outputs: [{ type: "string" }] },
954
+ { type: "function", name: "decimals", stateMutability: "view", inputs: [], outputs: [{ type: "uint8" }] },
955
+ { type: "function", name: "totalSupply", stateMutability: "view", inputs: [], outputs: [{ type: "uint256" }] },
956
+ {
957
+ type: "function",
958
+ name: "allowance",
959
+ stateMutability: "view",
960
+ inputs: [
961
+ { name: "owner", type: "address" },
962
+ { name: "spender", type: "address" }
963
+ ],
964
+ outputs: [{ type: "uint256" }]
965
+ },
966
+ {
967
+ type: "function",
968
+ name: "approve",
969
+ stateMutability: "nonpayable",
970
+ inputs: [
971
+ { name: "spender", type: "address" },
972
+ { name: "amount", type: "uint256" }
973
+ ],
974
+ outputs: [{ type: "bool" }]
975
+ },
976
+ {
977
+ type: "function",
978
+ name: "symbol",
979
+ stateMutability: "view",
980
+ inputs: [],
981
+ outputs: [{ type: "string" }]
982
+ }
983
+ ];
984
+ }
985
+ });
967
986
  function aerodromePublicClient(rpcUrl) {
968
987
  const url = requireAerodromeRpcUrl(rpcUrl);
969
988
  const chain = viem.defineChain({
970
- id: AERODROME_CHAIN_ID,
989
+ id: exports.AERODROME_CHAIN_ID,
971
990
  name: "Base",
972
991
  nativeCurrency: { decimals: 18, name: "Ether", symbol: "ETH" },
973
992
  rpcUrls: { default: { http: [url] } },
@@ -980,32 +999,14 @@ function aerodromePublicClient(rpcUrl) {
980
999
  });
981
1000
  return viem.createPublicClient({ chain, transport: viem.http(url) });
982
1001
  }
983
-
984
- // src/protocols/evm/aerodrome/stockTokens.ts
985
- var AERODROME_COINBASE_STOCK_TOKENS = [
986
- { symbol: "AAPLc", name: "Apple Inc.", address: "0xb200000000000000000000C2e324d24d7eEcd1fb" },
987
- { symbol: "NVDAc", name: "NVIDIA Corporation", address: "0xb20000000000000000000078ee7ce2fE4908108C" },
988
- { symbol: "METAc", name: "Meta Platforms Inc.", address: "0xb2000000000000000000008bC8786B856E61707C" },
989
- { symbol: "GOOGLc", name: "Alphabet Inc.", address: "0xb2000000000000000000002D0BA3164cc74f58B7" },
990
- { symbol: "AMZNc", name: "Amazon.com Inc.", address: "0xb200000000000000000000d9192b6B456483C2E8" },
991
- { symbol: "TSLAc", name: "Tesla Inc.", address: "0xb2000000000000000000001e800a7f5189430cD0" },
992
- { symbol: "MSFTc", name: "Microsoft Corporation", address: "0xB200000000000000000000Ab99cFa739E253872B" },
993
- { symbol: "COINc", name: "Coinbase Global Inc.", address: "0xb200000000000000000000c85a31389D71F3ecfb" },
994
- { symbol: "MSTRc", name: "Strategy Inc.", address: "0xb2000000000000000000004884b426556b92883d" },
995
- { symbol: "CRCLc", name: "Circle Internet Group Inc.", address: "0xB20000000000000000000019f6E7C675b73C2e4D" },
996
- { symbol: "INTCc", name: "Intel Corporation", address: "0xB2000000000000000000004AFF16039bA04bdFBc" },
997
- { symbol: "SNDKc", name: "Sandisk Corporation", address: "0xb200000000000000000000397293Cb8cda9a10c5" },
998
- { symbol: "SPCXc", name: "Space Exploration Technologies Corp.", address: "0xb2000000000000000000007b9fcbd005511aCBd5" }
999
- ];
1000
- var AERODROME_COINBASE_STOCK_DECIMALS = 8;
1001
- var AERODROME_B20_ASSET_PREFIX = "0xb200000000000000000000";
1002
- var BASE_STOCKS_DOCS_URLS = [
1003
- "https://docs.base.org/base-chain/asset-issuance/tokenized-stocks-on-base.md",
1004
- "https://docs.base.org/base-chain/asset-issuance/tokenized-stocks-on-base"
1005
- ];
1002
+ var init_client = __esm({
1003
+ "src/protocols/evm/aerodrome/client.ts"() {
1004
+ init_support();
1005
+ }
1006
+ });
1006
1007
  function isAerodromeB20AssetToken(address) {
1007
1008
  try {
1008
- return viem.getAddress(address).toLowerCase().startsWith(AERODROME_B20_ASSET_PREFIX);
1009
+ return viem.getAddress(address).toLowerCase().startsWith(exports.AERODROME_B20_ASSET_PREFIX);
1009
1010
  } catch {
1010
1011
  return false;
1011
1012
  }
@@ -1021,37 +1022,37 @@ function lookupAerodromeKnownToken(token) {
1021
1022
  if (!key) return null;
1022
1023
  const lower = key.toLowerCase();
1023
1024
  if (lower === "weth") {
1024
- return { address: viem.getAddress(AERODROME_WETH_BASE), symbol: "WETH", decimals: 18 };
1025
+ return { address: viem.getAddress(exports.AERODROME_WETH_BASE), symbol: "WETH", decimals: 18 };
1025
1026
  }
1026
1027
  if (lower === "usdc") {
1027
- return { address: viem.getAddress(AERODROME_USDC_BASE), symbol: "USDC", decimals: 6 };
1028
+ return { address: viem.getAddress(exports.AERODROME_USDC_BASE), symbol: "USDC", decimals: 6 };
1028
1029
  }
1029
1030
  if (lower === "aero") {
1030
- return { address: viem.getAddress(AERODROME_BASE_ADDRESSES_FALLBACK.aero), symbol: "AERO", decimals: 18 };
1031
+ return { address: viem.getAddress(exports.AERODROME_BASE_ADDRESSES_FALLBACK.aero), symbol: "AERO", decimals: 18 };
1031
1032
  }
1032
- const stock = AERODROME_COINBASE_STOCK_TOKENS.find((t) => t.symbol.toLowerCase() === lower);
1033
+ const stock = exports.AERODROME_COINBASE_STOCK_TOKENS.find((t) => t.symbol.toLowerCase() === lower);
1033
1034
  if (stock) {
1034
1035
  return {
1035
1036
  address: viem.getAddress(stock.address),
1036
1037
  symbol: stock.symbol,
1037
- decimals: AERODROME_COINBASE_STOCK_DECIMALS
1038
+ decimals: exports.AERODROME_COINBASE_STOCK_DECIMALS
1038
1039
  };
1039
1040
  }
1040
1041
  try {
1041
1042
  const address = viem.getAddress(key);
1042
1043
  const want = address.toLowerCase();
1043
- if (want === viem.getAddress(AERODROME_WETH_BASE).toLowerCase()) {
1044
+ if (want === viem.getAddress(exports.AERODROME_WETH_BASE).toLowerCase()) {
1044
1045
  return { address, symbol: "WETH", decimals: 18 };
1045
1046
  }
1046
- if (want === viem.getAddress(AERODROME_USDC_BASE).toLowerCase()) {
1047
+ if (want === viem.getAddress(exports.AERODROME_USDC_BASE).toLowerCase()) {
1047
1048
  return { address, symbol: "USDC", decimals: 6 };
1048
1049
  }
1049
- if (want === viem.getAddress(AERODROME_BASE_ADDRESSES_FALLBACK.aero).toLowerCase()) {
1050
+ if (want === viem.getAddress(exports.AERODROME_BASE_ADDRESSES_FALLBACK.aero).toLowerCase()) {
1050
1051
  return { address, symbol: "AERO", decimals: 18 };
1051
1052
  }
1052
- const byAddr = AERODROME_COINBASE_STOCK_TOKENS.find((t) => viem.getAddress(t.address).toLowerCase() === want);
1053
+ const byAddr = exports.AERODROME_COINBASE_STOCK_TOKENS.find((t) => viem.getAddress(t.address).toLowerCase() === want);
1053
1054
  if (byAddr) {
1054
- return { address, symbol: byAddr.symbol, decimals: AERODROME_COINBASE_STOCK_DECIMALS };
1055
+ return { address, symbol: byAddr.symbol, decimals: exports.AERODROME_COINBASE_STOCK_DECIMALS };
1055
1056
  }
1056
1057
  } catch {
1057
1058
  }
@@ -1090,10 +1091,8 @@ async function assertAerodromeStockIssued(args) {
1090
1091
  }
1091
1092
  }
1092
1093
  function aerodromeCoinbaseStockAddresses() {
1093
- return AERODROME_COINBASE_STOCK_TOKENS.map((t) => viem.getAddress(t.address));
1094
+ return exports.AERODROME_COINBASE_STOCK_TOKENS.map((t) => viem.getAddress(t.address));
1094
1095
  }
1095
- var MAX_DOCS_CHARS = 4e5;
1096
- var MAX_OFFICIAL_STOCKS = 40;
1097
1096
  function parseBaseTokenizedStockDocs(text) {
1098
1097
  try {
1099
1098
  if (typeof text !== "string" || text.length < 20) return [];
@@ -1142,18 +1141,18 @@ async function fetchOfficialBaseTokenizedStocks() {
1142
1141
  }
1143
1142
  function seedName(address) {
1144
1143
  const want = address.toLowerCase();
1145
- return AERODROME_COINBASE_STOCK_TOKENS.find((t) => viem.getAddress(t.address).toLowerCase() === want)?.name;
1144
+ return exports.AERODROME_COINBASE_STOCK_TOKENS.find((t) => viem.getAddress(t.address).toLowerCase() === want)?.name;
1146
1145
  }
1147
1146
  function seedSymbol(address) {
1148
1147
  const want = address.toLowerCase();
1149
- return AERODROME_COINBASE_STOCK_TOKENS.find((t) => viem.getAddress(t.address).toLowerCase() === want)?.symbol;
1148
+ return exports.AERODROME_COINBASE_STOCK_TOKENS.find((t) => viem.getAddress(t.address).toLowerCase() === want)?.symbol;
1150
1149
  }
1151
1150
  function seedStockRows() {
1152
- return AERODROME_COINBASE_STOCK_TOKENS.map((t) => ({
1151
+ return exports.AERODROME_COINBASE_STOCK_TOKENS.map((t) => ({
1153
1152
  address: viem.getAddress(t.address),
1154
1153
  symbol: t.symbol,
1155
1154
  name: t.name,
1156
- decimals: AERODROME_COINBASE_STOCK_DECIMALS,
1155
+ decimals: exports.AERODROME_COINBASE_STOCK_DECIMALS,
1157
1156
  issued: false
1158
1157
  }));
1159
1158
  }
@@ -1177,11 +1176,11 @@ async function aerodromeResolveStockTokens(args) {
1177
1176
  decimals: meta?.decimals ?? prev?.decimals
1178
1177
  });
1179
1178
  };
1180
- for (const t of AERODROME_COINBASE_STOCK_TOKENS) {
1181
- add(t.address, { symbol: t.symbol, name: t.name, decimals: AERODROME_COINBASE_STOCK_DECIMALS });
1179
+ for (const t of exports.AERODROME_COINBASE_STOCK_TOKENS) {
1180
+ add(t.address, { symbol: t.symbol, name: t.name, decimals: exports.AERODROME_COINBASE_STOCK_DECIMALS });
1182
1181
  }
1183
1182
  for (const t of official) {
1184
- add(t.address, { symbol: t.symbol, decimals: AERODROME_COINBASE_STOCK_DECIMALS });
1183
+ add(t.address, { symbol: t.symbol, decimals: exports.AERODROME_COINBASE_STOCK_DECIMALS });
1185
1184
  }
1186
1185
  for (const t of args.knownTokens ?? []) {
1187
1186
  if (!isAerodromeB20AssetToken(t.address)) continue;
@@ -1213,7 +1212,7 @@ async function aerodromeResolveStockTokens(args) {
1213
1212
  address: row.address,
1214
1213
  symbol: onchainSymbol || row.symbol || seedSymbol(row.address) || row.address.slice(0, 8),
1215
1214
  name: seedName(row.address) || onchainName || onchainSymbol || row.symbol || "",
1216
- decimals: Number.isFinite(onchainDecimals) ? onchainDecimals : row.decimals ?? AERODROME_COINBASE_STOCK_DECIMALS,
1215
+ decimals: Number.isFinite(onchainDecimals) ? onchainDecimals : row.decimals ?? exports.AERODROME_COINBASE_STOCK_DECIMALS,
1217
1216
  issued: supply > 0n
1218
1217
  };
1219
1218
  });
@@ -1221,7 +1220,38 @@ async function aerodromeResolveStockTokens(args) {
1221
1220
  return seedStockRows();
1222
1221
  }
1223
1222
  }
1224
- var FALLBACK_TICK_SPACINGS = [1, 10, 50, 100, 200, 500, 2e3];
1223
+ exports.AERODROME_COINBASE_STOCK_TOKENS = void 0; exports.AERODROME_COINBASE_STOCK_DECIMALS = void 0; exports.AERODROME_B20_ASSET_PREFIX = void 0; var BASE_STOCKS_DOCS_URLS, MAX_DOCS_CHARS, MAX_OFFICIAL_STOCKS;
1224
+ var init_stockTokens = __esm({
1225
+ "src/protocols/evm/aerodrome/stockTokens.ts"() {
1226
+ init_addresses();
1227
+ init_abi();
1228
+ init_client();
1229
+ init_support();
1230
+ exports.AERODROME_COINBASE_STOCK_TOKENS = [
1231
+ { symbol: "AAPLc", name: "Apple Inc.", address: "0xb200000000000000000000C2e324d24d7eEcd1fb" },
1232
+ { symbol: "NVDAc", name: "NVIDIA Corporation", address: "0xb20000000000000000000078ee7ce2fE4908108C" },
1233
+ { symbol: "METAc", name: "Meta Platforms Inc.", address: "0xb2000000000000000000008bC8786B856E61707C" },
1234
+ { symbol: "GOOGLc", name: "Alphabet Inc.", address: "0xb2000000000000000000002D0BA3164cc74f58B7" },
1235
+ { symbol: "AMZNc", name: "Amazon.com Inc.", address: "0xb200000000000000000000d9192b6B456483C2E8" },
1236
+ { symbol: "TSLAc", name: "Tesla Inc.", address: "0xb2000000000000000000001e800a7f5189430cD0" },
1237
+ { symbol: "MSFTc", name: "Microsoft Corporation", address: "0xB200000000000000000000Ab99cFa739E253872B" },
1238
+ { symbol: "COINc", name: "Coinbase Global Inc.", address: "0xb200000000000000000000c85a31389D71F3ecfb" },
1239
+ { symbol: "MSTRc", name: "Strategy Inc.", address: "0xb2000000000000000000004884b426556b92883d" },
1240
+ { symbol: "CRCLc", name: "Circle Internet Group Inc.", address: "0xB20000000000000000000019f6E7C675b73C2e4D" },
1241
+ { symbol: "INTCc", name: "Intel Corporation", address: "0xB2000000000000000000004AFF16039bA04bdFBc" },
1242
+ { symbol: "SNDKc", name: "Sandisk Corporation", address: "0xb200000000000000000000397293Cb8cda9a10c5" },
1243
+ { symbol: "SPCXc", name: "Space Exploration Technologies Corp.", address: "0xb2000000000000000000007b9fcbd005511aCBd5" }
1244
+ ];
1245
+ exports.AERODROME_COINBASE_STOCK_DECIMALS = 8;
1246
+ exports.AERODROME_B20_ASSET_PREFIX = "0xb200000000000000000000";
1247
+ BASE_STOCKS_DOCS_URLS = [
1248
+ "https://docs.base.org/base-chain/asset-issuance/tokenized-stocks-on-base.md",
1249
+ "https://docs.base.org/base-chain/asset-issuance/tokenized-stocks-on-base"
1250
+ ];
1251
+ MAX_DOCS_CHARS = 4e5;
1252
+ MAX_OFFICIAL_STOCKS = 40;
1253
+ }
1254
+ });
1225
1255
  function checksum(addr) {
1226
1256
  return viem.getAddress(addr);
1227
1257
  }
@@ -1265,7 +1295,7 @@ async function tickSpacingsForFactory(rpcUrl, factory) {
1265
1295
  }
1266
1296
  async function aerodromeDiscoverConnectorPools(args) {
1267
1297
  const client = aerodromePublicClient(args.rpcUrl);
1268
- const connectors = [args.addrs.weth, viem.getAddress(AERODROME_USDC_BASE), args.addrs.aero];
1298
+ const connectors = [args.addrs.weth, viem.getAddress(exports.AERODROME_USDC_BASE), args.addrs.aero];
1269
1299
  const pairs = connectorPairs(args.tokenIn, args.tokenOut, connectors);
1270
1300
  const clFactories = aerodromeClFactoryList(args.addrs);
1271
1301
  const spacingsByFactory = await Promise.all(
@@ -1413,7 +1443,7 @@ function tokenLabel(raw, resolved, isNative) {
1413
1443
  }
1414
1444
  async function aerodromeDiscoverPoolsSummary(args) {
1415
1445
  if (!isAerodromeChainSupported(args.chainId)) {
1416
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
1446
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1417
1447
  }
1418
1448
  const rpcUrl = requireAerodromeRpcUrl(args.rpcUrl);
1419
1449
  const addrs = await loadAerodromeAddresses();
@@ -1431,7 +1461,7 @@ async function aerodromeDiscoverPoolsSummary(args) {
1431
1461
  const inLabel = tokenLabel(args.token, token, isNative);
1432
1462
  const outLabel = tokenLabel(counterpartRaw, tokenOut, isNativeOut);
1433
1463
  return {
1434
- chainId: AERODROME_CHAIN_ID,
1464
+ chainId: exports.AERODROME_CHAIN_ID,
1435
1465
  token: {
1436
1466
  address: isNative ? viem.zeroAddress : token,
1437
1467
  symbol: inLabel,
@@ -1453,6 +1483,322 @@ async function aerodromeDiscoverPoolsSummary(args) {
1453
1483
  notes: pools.length === 0 ? `No factory pool on the ${inLabel}/${outLabel} connector graph (direct + WETH/USDC/AERO hops). B20 stocks LP vs USDC; ETH\u2192stock quotes hop WETH\u2192USDC\u2192stock. Call ctm_aerodrome_quote with tickers for a price.` : `Factory-discovered pools on the ${inLabel}/${outLabel} connector graph (v2 + Slipstream 1/2/3). Not a Sugar dump. Call ctm_aerodrome_quote({ tokenIn: "${inLabel}", tokenOut: "${outLabel}", amountHuman }) for a price.`
1454
1484
  };
1455
1485
  }
1486
+ var FALLBACK_TICK_SPACINGS;
1487
+ var init_discover = __esm({
1488
+ "src/protocols/evm/aerodrome/discover.ts"() {
1489
+ init_abi();
1490
+ init_addresses();
1491
+ init_client();
1492
+ init_stockTokens();
1493
+ init_support();
1494
+ FALLBACK_TICK_SPACINGS = [1, 10, 50, 100, 200, 500, 2e3];
1495
+ }
1496
+ });
1497
+
1498
+ // src/protocols/evm/aerodrome/yields.ts
1499
+ var yields_exports = {};
1500
+ __export(yields_exports, {
1501
+ AERODROME_IMPORTANT_POOL_CAP: () => exports.AERODROME_IMPORTANT_POOL_CAP,
1502
+ aerodromeFetchImportantPoolsSummary: () => aerodromeFetchImportantPoolsSummary,
1503
+ aerodromeFetchLpYieldsForPair: () => aerodromeFetchLpYieldsForPair,
1504
+ aerodromeFetchLpYieldsForPools: () => aerodromeFetchLpYieldsForPools,
1505
+ aerodromeFetchLpYieldsSummary: () => aerodromeFetchLpYieldsSummary,
1506
+ aerodromeFetchStockLpYieldsSummary: () => aerodromeFetchStockLpYieldsSummary,
1507
+ formatAerodromeLpYieldLabel: () => formatAerodromeLpYieldLabel
1508
+ });
1509
+ function poolKind2(type) {
1510
+ if (type === 0) return "stable";
1511
+ if (type === -1) return "volatile";
1512
+ return "cl";
1513
+ }
1514
+ function formatApr(pct) {
1515
+ if (pct == null || !Number.isFinite(pct) || pct < 0) return null;
1516
+ return `${pct.toFixed(2)}%`;
1517
+ }
1518
+ function formatAerodromeLpYieldLabel(row) {
1519
+ const kind = row.kind === "stable" ? "sAMM" : row.kind === "volatile" ? "vAMM" : "Slipstream";
1520
+ if (row.emissionsApr) {
1521
+ return `${row.emissionsApr} emissions APR (${kind})`;
1522
+ }
1523
+ return `Emissions APR not priced (${kind})`;
1524
+ }
1525
+ function isMainPair(token0, token1, aero) {
1526
+ const mains = new Set(BASE_MAIN_TOKEN_ADDRESSES);
1527
+ mains.add(aero.toLowerCase());
1528
+ return mains.has(token0.toLowerCase()) && mains.has(token1.toLowerCase());
1529
+ }
1530
+ async function fetchSugarYieldPage(args) {
1531
+ const addrs = await loadAerodromeAddresses();
1532
+ const client = aerodromePublicClient(args.rpcUrl);
1533
+ const rows = await client.readContract({
1534
+ address: addrs.lpSugar,
1535
+ abi: lpSugarAbi,
1536
+ functionName: "all",
1537
+ args: [BigInt(args.limit), BigInt(args.offset), 0n]
1538
+ });
1539
+ return rows.map((p) => ({
1540
+ lp: viem.getAddress(p.lp),
1541
+ symbol: p.symbol,
1542
+ type: p.type,
1543
+ token0: viem.getAddress(p.token0),
1544
+ token1: viem.getAddress(p.token1),
1545
+ gauge: viem.getAddress(p.gauge),
1546
+ gauge_alive: Boolean(p.gauge_alive),
1547
+ reserve0: p.reserve0,
1548
+ reserve1: p.reserve1,
1549
+ liquidity: p.liquidity,
1550
+ emissions: p.emissions,
1551
+ pool_fee: p.pool_fee
1552
+ }));
1553
+ }
1554
+ function aeroUsdPriceFromRows(rows, aero) {
1555
+ const aeroLo = aero.toLowerCase();
1556
+ const usdcLo = exports.AERODROME_USDC_BASE.toLowerCase();
1557
+ for (const r of rows) {
1558
+ const t0 = r.token0.toLowerCase();
1559
+ const t1 = r.token1.toLowerCase();
1560
+ if (t0 === aeroLo && t1 === usdcLo || t0 === usdcLo && t1 === aeroLo) {
1561
+ const aeroRes = t0 === aeroLo ? Number(r.reserve0) / 1e18 : Number(r.reserve1) / 1e18;
1562
+ const usdcRes = t0 === usdcLo ? Number(r.reserve0) / 1e6 : Number(r.reserve1) / 1e6;
1563
+ if (aeroRes > 0 && usdcRes > 0) return usdcRes / aeroRes;
1564
+ }
1565
+ }
1566
+ return null;
1567
+ }
1568
+ function rowTvlUsd(r) {
1569
+ const fromLiq = Number(r.liquidity) / 1e18;
1570
+ if (Number.isFinite(fromLiq) && fromLiq > 1) return fromLiq;
1571
+ const t0 = r.token0.toLowerCase();
1572
+ const t1 = r.token1.toLowerCase();
1573
+ const usdc = exports.AERODROME_USDC_BASE.toLowerCase();
1574
+ if (t0 === usdc) {
1575
+ const usd = Number(r.reserve0) / 1e6;
1576
+ return Number.isFinite(usd) && usd > 0 ? usd * 2 : null;
1577
+ }
1578
+ if (t1 === usdc) {
1579
+ const usd = Number(r.reserve1) / 1e6;
1580
+ return Number.isFinite(usd) && usd > 0 ? usd * 2 : null;
1581
+ }
1582
+ return null;
1583
+ }
1584
+ function toYieldRow(r, aeroUsd) {
1585
+ const tvlUsd = rowTvlUsd(r);
1586
+ const emissionsPerSec = Number(r.emissions) / 1e18;
1587
+ let emissionsApr = null;
1588
+ if (aeroUsd != null && tvlUsd != null && tvlUsd > 0 && Number.isFinite(emissionsPerSec) && emissionsPerSec > 0) {
1589
+ emissionsApr = emissionsPerSec * SECONDS_PER_YEAR * aeroUsd / tvlUsd * 100;
1590
+ }
1591
+ const feeBpsRaw = Number(r.pool_fee);
1592
+ const feeBps = Number.isFinite(feeBpsRaw) && feeBpsRaw > 0 ? feeBpsRaw : null;
1593
+ return {
1594
+ lp: r.lp,
1595
+ symbol: r.symbol,
1596
+ kind: poolKind2(Number(r.type)),
1597
+ token0: r.token0,
1598
+ token1: r.token1,
1599
+ gauge: r.gauge === viem.zeroAddress ? "" : r.gauge,
1600
+ gaugeAlive: Boolean(r.gauge_alive),
1601
+ reserve0: r.reserve0.toString(),
1602
+ reserve1: r.reserve1.toString(),
1603
+ feeBps,
1604
+ feeApr: null,
1605
+ emissionsApr: formatApr(emissionsApr),
1606
+ totalApr: formatApr(emissionsApr),
1607
+ tvlUsd
1608
+ };
1609
+ }
1610
+ function rankAndCap(rows, query) {
1611
+ const q = (query ?? "").trim().toLowerCase();
1612
+ let filtered = rows.filter((r) => (r.tvlUsd ?? 0) > 0);
1613
+ if (q) {
1614
+ filtered = filtered.filter(
1615
+ (r) => [r.symbol, r.lp, r.token0, r.token1, r.kind].join(" ").toLowerCase().includes(q)
1616
+ );
1617
+ }
1618
+ filtered.sort((a, b) => (b.tvlUsd ?? 0) - (a.tvlUsd ?? 0));
1619
+ return filtered.slice(0, exports.AERODROME_IMPORTANT_POOL_CAP);
1620
+ }
1621
+ async function scanSugarTop(rpcUrl) {
1622
+ const pages = [];
1623
+ for (let i = 0; i < SUGAR_SCAN_PAGES; i++) {
1624
+ const page = await fetchSugarYieldPage({ rpcUrl, limit: SUGAR_PAGE, offset: i * SUGAR_PAGE });
1625
+ pages.push(page);
1626
+ if (page.length < SUGAR_PAGE) break;
1627
+ }
1628
+ return pages.flat();
1629
+ }
1630
+ async function aerodromeFetchImportantPoolsSummary(args) {
1631
+ if (!isAerodromeChainSupported(args.chainId)) {
1632
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1633
+ }
1634
+ const addrs = await loadAerodromeAddresses();
1635
+ const scanned = await scanSugarTop(args.rpcUrl);
1636
+ const aeroUsd = aeroUsdPriceFromRows(scanned, addrs.aero);
1637
+ const main = scanned.filter((r) => isMainPair(r.token0, r.token1, addrs.aero));
1638
+ const pools = rankAndCap(main.map((r) => toYieldRow(r, aeroUsd)), args.query);
1639
+ return {
1640
+ chainId: exports.AERODROME_CHAIN_ID,
1641
+ pools,
1642
+ notes: `At most ${exports.AERODROME_IMPORTANT_POOL_CAP} important Base pairs (ETH/WETH, USDC, AERO, major stables), TVL-ranked. Not an LpSugar.all dump. feeApr is omitted (Sugar exposes fee tier, not volume). emissionsApr uses on-chain AERO/USDC when priced.`
1643
+ };
1644
+ }
1645
+ async function aerodromeFetchLpYieldsSummary(args) {
1646
+ return aerodromeFetchImportantPoolsSummary(args);
1647
+ }
1648
+ async function fetchSugarByAddress(rpcUrl, lp) {
1649
+ const addrs = await loadAerodromeAddresses();
1650
+ const client = aerodromePublicClient(rpcUrl);
1651
+ try {
1652
+ const p = await client.readContract({
1653
+ address: addrs.lpSugar,
1654
+ abi: lpSugarAbi,
1655
+ functionName: "byAddress",
1656
+ args: [lp]
1657
+ });
1658
+ if (!p?.lp || p.lp === viem.zeroAddress) return null;
1659
+ return {
1660
+ lp: viem.getAddress(p.lp),
1661
+ symbol: p.symbol,
1662
+ type: p.type,
1663
+ token0: viem.getAddress(p.token0),
1664
+ token1: viem.getAddress(p.token1),
1665
+ gauge: viem.getAddress(p.gauge),
1666
+ gauge_alive: Boolean(p.gauge_alive),
1667
+ reserve0: p.reserve0,
1668
+ reserve1: p.reserve1,
1669
+ liquidity: p.liquidity,
1670
+ emissions: p.emissions,
1671
+ pool_fee: p.pool_fee
1672
+ };
1673
+ } catch {
1674
+ return null;
1675
+ }
1676
+ }
1677
+ function resolveYieldToken(addr, weth) {
1678
+ if (isAerodromeNativeToken(addr)) return viem.getAddress(weth);
1679
+ return viem.getAddress(addr);
1680
+ }
1681
+ async function aeroUsdFromUsdcPool(rpcUrl, aero) {
1682
+ const aeroUsdc = await aerodromeDiscoverDirectPools({
1683
+ rpcUrl,
1684
+ tokenA: viem.getAddress(aero),
1685
+ tokenB: viem.getAddress(exports.AERODROME_USDC_BASE)
1686
+ });
1687
+ const prefer = aeroUsdc.find((p) => p.kind === "volatile") ?? aeroUsdc[0];
1688
+ if (!prefer) return null;
1689
+ const raw = await fetchSugarByAddress(rpcUrl, prefer.lp);
1690
+ return raw ? aeroUsdPriceFromRows([raw], aero) : null;
1691
+ }
1692
+ async function aerodromeFetchLpYieldsForPools(args) {
1693
+ if (!isAerodromeChainSupported(args.chainId)) {
1694
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1695
+ }
1696
+ const addrs = await loadAerodromeAddresses();
1697
+ const aeroUsd = await aeroUsdFromUsdcPool(args.rpcUrl, addrs.aero);
1698
+ const seen = /* @__PURE__ */ new Set();
1699
+ const pools = [];
1700
+ for (const rawLp of args.lps) {
1701
+ let lp;
1702
+ try {
1703
+ lp = viem.getAddress(rawLp);
1704
+ } catch {
1705
+ continue;
1706
+ }
1707
+ if (lp === viem.zeroAddress || seen.has(lp.toLowerCase())) continue;
1708
+ seen.add(lp.toLowerCase());
1709
+ const raw = await fetchSugarByAddress(args.rpcUrl, lp);
1710
+ if (raw) pools.push(toYieldRow(raw, aeroUsd));
1711
+ }
1712
+ return {
1713
+ chainId: exports.AERODROME_CHAIN_ID,
1714
+ pools,
1715
+ notes: "Same Sugar emissions formula as fetch_lp_yields (AERO/USDC priced). feeApr is omitted (Sugar has fee tier, not volume)."
1716
+ };
1717
+ }
1718
+ async function aerodromeFetchLpYieldsForPair(args) {
1719
+ if (!isAerodromeChainSupported(args.chainId)) {
1720
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1721
+ }
1722
+ const addrs = await loadAerodromeAddresses();
1723
+ const tokenA = resolveYieldToken(args.tokenA, addrs.weth);
1724
+ const tokenB = resolveYieldToken(args.tokenB, addrs.weth);
1725
+ if (tokenA.toLowerCase() === tokenB.toLowerCase()) {
1726
+ return { chainId: exports.AERODROME_CHAIN_ID, pools: [], notes: "Pair tokens must differ." };
1727
+ }
1728
+ const discovered = await aerodromeDiscoverDirectPools({ rpcUrl: args.rpcUrl, tokenA, tokenB });
1729
+ return aerodromeFetchLpYieldsForPools({
1730
+ chainId: args.chainId,
1731
+ rpcUrl: args.rpcUrl,
1732
+ lps: discovered.map((p) => p.lp)
1733
+ });
1734
+ }
1735
+ async function aerodromeFetchStockLpYieldsSummary(args) {
1736
+ if (!isAerodromeChainSupported(args.chainId)) {
1737
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1738
+ }
1739
+ const addrs = await loadAerodromeAddresses();
1740
+ const scanned = await scanSugarTop(args.rpcUrl);
1741
+ const aeroUsd = aeroUsdPriceFromRows(scanned, addrs.aero);
1742
+ const stock = scanned.filter((r) => isAerodromeB20AssetToken(r.token0) || isAerodromeB20AssetToken(r.token1));
1743
+ const pools = rankAndCap(stock.map((r) => toYieldRow(r, aeroUsd)), args.query);
1744
+ return {
1745
+ chainId: exports.AERODROME_CHAIN_ID,
1746
+ pools,
1747
+ notes: "Coinbase B20 stock LP yields only (typically STOCK/USDC Slipstream). Separate from main-pair fetch_lp_yields. HIP-3 / Arcus stock trading is not this list."
1748
+ };
1749
+ }
1750
+ exports.AERODROME_IMPORTANT_POOL_CAP = void 0; var SUGAR_PAGE, SUGAR_SCAN_PAGES, SECONDS_PER_YEAR, BASE_MAIN_TOKEN_ADDRESSES;
1751
+ var init_yields = __esm({
1752
+ "src/protocols/evm/aerodrome/yields.ts"() {
1753
+ init_abi();
1754
+ init_addresses();
1755
+ init_client();
1756
+ init_discover();
1757
+ init_stockTokens();
1758
+ init_support();
1759
+ exports.AERODROME_IMPORTANT_POOL_CAP = 100;
1760
+ SUGAR_PAGE = 50;
1761
+ SUGAR_SCAN_PAGES = 4;
1762
+ SECONDS_PER_YEAR = 365.25 * 24 * 60 * 60;
1763
+ BASE_MAIN_TOKEN_ADDRESSES = new Set(
1764
+ [
1765
+ exports.AERODROME_WETH_BASE,
1766
+ exports.AERODROME_USDC_BASE,
1767
+ exports.AERODROME_BASE_ADDRESSES_FALLBACK.aero,
1768
+ "0x50c5725949A6F0c72E6C4a641F24049A917DB0Cb",
1769
+ "0xfde4C96c8593536E31F229EA8f37b2ADa2699bb2",
1770
+ "0x5d3a1Ff2b6BAb83b63cd9AD0787074081a52ef34",
1771
+ "0x2Ae3F1Ec7F1F5012CFEab0185bfc7aa3cf0DEc22",
1772
+ "0xc1CBa3fCea344f92D9239c08C0568f6F2F0ee452"
1773
+ ].map((a) => a.toLowerCase())
1774
+ );
1775
+ }
1776
+ });
1777
+
1778
+ // src/core/registry.ts
1779
+ var modules = [];
1780
+ function registerProtocolModule(mod) {
1781
+ const existing = modules.findIndex((m) => m.id === mod.id);
1782
+ if (existing >= 0) {
1783
+ modules[existing] = mod;
1784
+ } else {
1785
+ modules.push(mod);
1786
+ }
1787
+ }
1788
+
1789
+ // src/protocols/evm/aerodrome/index.ts
1790
+ init_support();
1791
+ init_support();
1792
+ init_addresses();
1793
+ init_stockTokens();
1794
+ init_discover();
1795
+
1796
+ // src/protocols/evm/aerodrome/sugar.ts
1797
+ init_abi();
1798
+ init_addresses();
1799
+ init_client();
1800
+ init_support();
1801
+ init_stockTokens();
1456
1802
  function poolKind(type) {
1457
1803
  if (type === 0) return "stable";
1458
1804
  if (type === -1) return "volatile";
@@ -1469,7 +1815,7 @@ async function paginate(pageSize, maxPages, readPage) {
1469
1815
  }
1470
1816
  async function aerodromeFetchListedTokens(args) {
1471
1817
  if (!isAerodromeChainSupported(args.chainId)) {
1472
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
1818
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1473
1819
  }
1474
1820
  const addrs = await loadAerodromeAddresses();
1475
1821
  const client = aerodromePublicClient(args.rpcUrl);
@@ -1511,7 +1857,7 @@ async function aerodromeFetchListedTokens(args) {
1511
1857
  }
1512
1858
  async function aerodromeFetchSwapPools(args) {
1513
1859
  if (!isAerodromeChainSupported(args.chainId)) {
1514
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
1860
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1515
1861
  }
1516
1862
  const addrs = await loadAerodromeAddresses();
1517
1863
  const client = aerodromePublicClient(args.rpcUrl);
@@ -1537,7 +1883,7 @@ async function aerodromeFetchSwapPools(args) {
1537
1883
  }
1538
1884
  async function aerodromeFetchPools(args) {
1539
1885
  if (!isAerodromeChainSupported(args.chainId)) {
1540
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
1886
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1541
1887
  }
1542
1888
  const addrs = await loadAerodromeAddresses();
1543
1889
  const client = aerodromePublicClient(args.rpcUrl);
@@ -1568,7 +1914,7 @@ function mapSugarLp(p) {
1568
1914
  }
1569
1915
  async function aerodromeFetchPoolsByAddress(args) {
1570
1916
  if (!isAerodromeChainSupported(args.chainId)) {
1571
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
1917
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1572
1918
  }
1573
1919
  const addrs = await loadAerodromeAddresses();
1574
1920
  const client = aerodromePublicClient(args.rpcUrl);
@@ -1658,7 +2004,7 @@ async function aerodromeFetchPoolsByAddress(args) {
1658
2004
  }
1659
2005
  async function aerodromeFetchPositions(args) {
1660
2006
  if (!isAerodromeChainSupported(args.chainId)) {
1661
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
2007
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1662
2008
  }
1663
2009
  const addrs = await loadAerodromeAddresses();
1664
2010
  const client = aerodromePublicClient(args.rpcUrl);
@@ -1745,6 +2091,7 @@ function formatAerodromePriceImpact(percent0to100) {
1745
2091
  }
1746
2092
 
1747
2093
  // src/protocols/evm/aerodrome/sdkSession.ts
2094
+ init_support();
1748
2095
  async function loadSdkJs() {
1749
2096
  try {
1750
2097
  return await import('@dromos-labs/sdk.js');
@@ -1761,8 +2108,8 @@ async function tryAerodromeSdkQuote(args) {
1761
2108
  });
1762
2109
  const quote = await sdk.getQuoteForSwap({
1763
2110
  config,
1764
- fromToken: { address: args.tokenIn, chainId: AERODROME_CHAIN_ID },
1765
- toToken: { address: args.tokenOut, chainId: AERODROME_CHAIN_ID },
2111
+ fromToken: { address: args.tokenIn, chainId: exports.AERODROME_CHAIN_ID },
2112
+ toToken: { address: args.tokenOut, chainId: exports.AERODROME_CHAIN_ID },
1766
2113
  amountIn: args.amountIn
1767
2114
  });
1768
2115
  if (!quote) return null;
@@ -1774,8 +2121,8 @@ async function tryAerodromeSdkQuote(args) {
1774
2121
  try {
1775
2122
  const probeQuote = await sdk.getQuoteForSwap({
1776
2123
  config,
1777
- fromToken: { address: args.tokenIn, chainId: AERODROME_CHAIN_ID },
1778
- toToken: { address: args.tokenOut, chainId: AERODROME_CHAIN_ID },
2124
+ fromToken: { address: args.tokenIn, chainId: exports.AERODROME_CHAIN_ID },
2125
+ toToken: { address: args.tokenOut, chainId: exports.AERODROME_CHAIN_ID },
1779
2126
  amountIn: probeIn
1780
2127
  });
1781
2128
  const probeOut = probeQuote?.amountOut ?? probeQuote?.expectedAmount;
@@ -1792,7 +2139,7 @@ async function tryAerodromeSdkQuote(args) {
1792
2139
  }
1793
2140
  }
1794
2141
  return {
1795
- chainId: AERODROME_CHAIN_ID,
2142
+ chainId: exports.AERODROME_CHAIN_ID,
1796
2143
  tokenIn: args.isNativeIn ? viem.zeroAddress : args.tokenIn,
1797
2144
  tokenOut: args.isNativeOut ? viem.zeroAddress : args.tokenOut,
1798
2145
  amountInWei: args.amountIn.toString(),
@@ -1833,6 +2180,15 @@ async function tryAerodromeSdkUnsignedSwap(args) {
1833
2180
  return null;
1834
2181
  }
1835
2182
  }
2183
+
2184
+ // src/protocols/evm/aerodrome/quote.ts
2185
+ init_abi();
2186
+ init_addresses();
2187
+ init_client();
2188
+ init_discover();
2189
+ init_stockTokens();
2190
+ init_support();
2191
+ init_stockTokens();
1836
2192
  var AERODROME_STABLE_FILLER = 2097152;
1837
2193
  var AERODROME_VOLATILE_FILLER = 4194304;
1838
2194
  var AERODROME_CL_FACTORY_OLDEST_BIT = 1048576;
@@ -1841,10 +2197,10 @@ function aerodromeMixedPathFiller(hop) {
1841
2197
  if (hop.kind === "stable") return AERODROME_STABLE_FILLER;
1842
2198
  if (hop.kind === "volatile") return AERODROME_VOLATILE_FILLER;
1843
2199
  const f = hop.factory.toLowerCase();
1844
- if (f === AERODROME_BASE_ADDRESSES_FALLBACK.clFactory3.toLowerCase()) {
2200
+ if (f === exports.AERODROME_BASE_ADDRESSES_FALLBACK.clFactory3.toLowerCase()) {
1845
2201
  return hop.type | AERODROME_CL_FACTORY_NEWEST_BIT;
1846
2202
  }
1847
- if (f === AERODROME_BASE_ADDRESSES_FALLBACK.clFactory.toLowerCase()) {
2203
+ if (f === exports.AERODROME_BASE_ADDRESSES_FALLBACK.clFactory.toLowerCase()) {
1848
2204
  return hop.type | AERODROME_CL_FACTORY_OLDEST_BIT;
1849
2205
  }
1850
2206
  return hop.type;
@@ -1969,8 +2325,8 @@ async function quoteAerodromeHopsAmountOut(args) {
1969
2325
  }
1970
2326
  async function readTokenDecimals(rpcUrl, token, isNative) {
1971
2327
  if (isNative) return 18;
1972
- if (isAerodromeCoinbaseStockToken(token)) return AERODROME_COINBASE_STOCK_DECIMALS;
1973
- if (token.toLowerCase() === AERODROME_USDC_BASE.toLowerCase()) return 6;
2328
+ if (isAerodromeCoinbaseStockToken(token)) return exports.AERODROME_COINBASE_STOCK_DECIMALS;
2329
+ if (token.toLowerCase() === exports.AERODROME_USDC_BASE.toLowerCase()) return 6;
1974
2330
  const client = aerodromePublicClient(rpcUrl);
1975
2331
  return Number(
1976
2332
  await client.readContract({
@@ -1985,7 +2341,7 @@ async function throwIfUnissuedStock(args) {
1985
2341
  }
1986
2342
  async function aerodromeQuote(args) {
1987
2343
  if (!isAerodromeChainSupported(args.chainId)) {
1988
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
2344
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
1989
2345
  }
1990
2346
  const rpcUrl = requireAerodromeRpcUrl(args.rpcUrl);
1991
2347
  const addrs = await loadAerodromeAddresses();
@@ -1998,7 +2354,7 @@ async function aerodromeQuote(args) {
1998
2354
  }
1999
2355
  let decimals = args.tokenInDecimals;
2000
2356
  if (isAerodromeCoinbaseStockToken(tokenIn)) {
2001
- decimals = AERODROME_COINBASE_STOCK_DECIMALS;
2357
+ decimals = exports.AERODROME_COINBASE_STOCK_DECIMALS;
2002
2358
  } else if (decimals == null) {
2003
2359
  decimals = await readTokenDecimals(rpcUrl, tokenIn, isNativeIn);
2004
2360
  }
@@ -2016,9 +2372,9 @@ async function aerodromeQuote(args) {
2016
2372
  let pools = await aerodromeDiscoverConnectorPools({ rpcUrl, tokenIn, tokenOut, addrs });
2017
2373
  let paths = findAerodromePaths(pools, tokenIn, tokenOut);
2018
2374
  if (paths.length === 0) {
2019
- const sugarPools = await aerodromeFetchSwapPools({ chainId: AERODROME_CHAIN_ID, rpcUrl });
2375
+ const sugarPools = await aerodromeFetchSwapPools({ chainId: exports.AERODROME_CHAIN_ID, rpcUrl });
2020
2376
  pools = mergePools(pools, sugarPools);
2021
- const connectors = [addrs.weth, viem.getAddress(AERODROME_USDC_BASE), addrs.aero];
2377
+ const connectors = [addrs.weth, viem.getAddress(exports.AERODROME_USDC_BASE), addrs.aero];
2022
2378
  const relevant = pools.filter((p) => {
2023
2379
  const a = p.token0.toLowerCase();
2024
2380
  const b = p.token1.toLowerCase();
@@ -2091,7 +2447,7 @@ async function aerodromeQuote(args) {
2091
2447
  }
2092
2448
  }
2093
2449
  return {
2094
- chainId: AERODROME_CHAIN_ID,
2450
+ chainId: exports.AERODROME_CHAIN_ID,
2095
2451
  tokenIn: isNativeIn ? viem.zeroAddress : tokenIn,
2096
2452
  tokenOut: isNativeOut ? viem.zeroAddress : tokenOut,
2097
2453
  amountInWei: amountIn.toString(),
@@ -2106,6 +2462,10 @@ async function aerodromeQuote(args) {
2106
2462
  };
2107
2463
  }
2108
2464
 
2465
+ // src/protocols/evm/aerodrome/swapMultisign.ts
2466
+ init_abi();
2467
+ init_addresses();
2468
+
2109
2469
  // src/core/purpose.ts
2110
2470
  function mergePurposeText(purposeText, purposeSuffix) {
2111
2471
  const t = (purposeText ?? "").trim();
@@ -2341,6 +2701,9 @@ async function buildEvmMultisignBatch(args) {
2341
2701
  }
2342
2702
 
2343
2703
  // src/protocols/evm/aerodrome/batch.ts
2704
+ init_abi();
2705
+ init_client();
2706
+ init_support();
2344
2707
  async function pushErc20ApproveIfNeeded(args) {
2345
2708
  const client = aerodromePublicClient(args.rpcUrl);
2346
2709
  const allowance = await client.readContract({
@@ -2383,7 +2746,7 @@ async function buildAerodromeMultisignBatch(args) {
2383
2746
  chainCategory: "evm",
2384
2747
  keyGen: args.keyGen,
2385
2748
  purposeText: args.purposeText,
2386
- chainId: AERODROME_CHAIN_ID,
2749
+ chainId: exports.AERODROME_CHAIN_ID,
2387
2750
  rpcUrl: args.rpcUrl,
2388
2751
  executorAddress: executor,
2389
2752
  chainDetail: args.chainDetail,
@@ -2406,6 +2769,7 @@ async function buildAerodromeMultisignBatch(args) {
2406
2769
  }
2407
2770
 
2408
2771
  // src/protocols/evm/aerodrome/swapMultisign.ts
2772
+ init_support();
2409
2773
  function applySlippage(amountOut, slippagePercent) {
2410
2774
  if (!Number.isFinite(slippagePercent) || slippagePercent <= 0 || slippagePercent >= 100) {
2411
2775
  throw new Error("Slippage must be between 0 and 100 (exclusive).");
@@ -2527,13 +2891,13 @@ async function appendSequentialMixedHops(args) {
2527
2891
  }
2528
2892
  }
2529
2893
  async function buildEvmMultisignBodyAerodromeSwapBatch(args) {
2530
- if (args.chainId !== AERODROME_CHAIN_ID) {
2531
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
2894
+ if (args.chainId !== exports.AERODROME_CHAIN_ID) {
2895
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
2532
2896
  }
2533
2897
  const executor = viem.getAddress(args.executorAddress);
2534
2898
  const addrs = await loadAerodromeAddresses();
2535
2899
  const quote = args.quoteSnapshot?.hops?.length && args.quoteSnapshot.amountOutWei ? args.quoteSnapshot : await aerodromeQuote({
2536
- chainId: AERODROME_CHAIN_ID,
2900
+ chainId: exports.AERODROME_CHAIN_ID,
2537
2901
  rpcUrl: args.rpcUrl,
2538
2902
  tokenIn: args.tokenIn,
2539
2903
  tokenOut: args.tokenOut,
@@ -2696,24 +3060,32 @@ async function buildEvmMultisignBodyAerodromeSwapBatch(args) {
2696
3060
  name: "ERC20.approve",
2697
3061
  note: "Allowance for this swap amount only."
2698
3062
  }),
2699
- evm: { type: "aerodrome_erc20_approve", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3063
+ evm: { type: "aerodrome_erc20_approve", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
2700
3064
  } : {
2701
3065
  signatureText: JSON.stringify({
2702
3066
  kind: "Aerodrome",
2703
3067
  name: "swap",
2704
3068
  hops: hops.map((h) => ({ from: h.from, to: h.to, kind: h.kind }))
2705
3069
  }),
2706
- evm: { type: "aerodrome_swap", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3070
+ evm: { type: "aerodrome_swap", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
2707
3071
  }
2708
3072
  });
2709
3073
  }
3074
+
3075
+ // src/protocols/evm/aerodrome/liquidityBasic.ts
3076
+ init_abi();
3077
+ init_addresses();
3078
+ init_client();
3079
+ init_discover();
3080
+ init_stockTokens();
3081
+ init_support();
2710
3082
  var OTHER_SIDE_DESIRED = 10n ** 36n;
2711
3083
  var Q96 = 1n << 96n;
2712
3084
  function pairTokenLabel(address, isNative) {
2713
3085
  if (isNative) return "ETH";
2714
- if (address.toLowerCase() === AERODROME_WETH_BASE.toLowerCase()) return "WETH";
2715
- if (address.toLowerCase() === AERODROME_USDC_BASE.toLowerCase()) return "USDC";
2716
- const stock = AERODROME_COINBASE_STOCK_TOKENS.find((t) => t.address.toLowerCase() === address.toLowerCase());
3086
+ if (address.toLowerCase() === exports.AERODROME_WETH_BASE.toLowerCase()) return "WETH";
3087
+ if (address.toLowerCase() === exports.AERODROME_USDC_BASE.toLowerCase()) return "USDC";
3088
+ const stock = exports.AERODROME_COINBASE_STOCK_TOKENS.find((t) => t.address.toLowerCase() === address.toLowerCase());
2717
3089
  return stock?.symbol || `${address.slice(0, 6)}\u2026${address.slice(-4)}`;
2718
3090
  }
2719
3091
  function noDirectPoolHint(args) {
@@ -2738,7 +3110,7 @@ function formatLpHuman(wei, decimals) {
2738
3110
  }
2739
3111
  async function aerodromeQuoteAddLiquidity(args) {
2740
3112
  if (!isAerodromeChainSupported(args.chainId)) {
2741
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
3113
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
2742
3114
  }
2743
3115
  const addrs = await loadAerodromeAddresses();
2744
3116
  const client = aerodromePublicClient(args.rpcUrl);
@@ -2761,8 +3133,8 @@ async function aerodromeQuoteAddLiquidity(args) {
2761
3133
  const rawA = (args.amountAHuman ?? "").trim().replace(/,/g, "");
2762
3134
  const rawB = (args.amountBHuman ?? "").trim().replace(/,/g, "");
2763
3135
  if (!rawA && !rawB) throw new Error("Enter amount A or amount B.");
2764
- const decA = isAerodromeCoinbaseStockToken(tokenA) ? AERODROME_COINBASE_STOCK_DECIMALS : args.tokenADecimals ?? (isNativeA ? 18 : Number(await client.readContract({ address: tokenA, abi: erc20Abi, functionName: "decimals" })));
2765
- const decB = isAerodromeCoinbaseStockToken(tokenB) ? AERODROME_COINBASE_STOCK_DECIMALS : args.tokenBDecimals ?? (isNativeB ? 18 : Number(await client.readContract({ address: tokenB, abi: erc20Abi, functionName: "decimals" })));
3136
+ const decA = isAerodromeCoinbaseStockToken(tokenA) ? exports.AERODROME_COINBASE_STOCK_DECIMALS : args.tokenADecimals ?? (isNativeA ? 18 : Number(await client.readContract({ address: tokenA, abi: erc20Abi, functionName: "decimals" })));
3137
+ const decB = isAerodromeCoinbaseStockToken(tokenB) ? exports.AERODROME_COINBASE_STOCK_DECIMALS : args.tokenBDecimals ?? (isNativeB ? 18 : Number(await client.readContract({ address: tokenB, abi: erc20Abi, functionName: "decimals" })));
2766
3138
  const pool = await client.readContract({
2767
3139
  address: addrs.router,
2768
3140
  abi: routerAbi,
@@ -2927,6 +3299,12 @@ async function estimateClOtherSide(client, helper, amount, sqrtP, amountIs0) {
2927
3299
  if (sqrtP === 0n) return 0n;
2928
3300
  return amountIs0 ? amount * sqrtP / Q96 * sqrtP / Q96 : amount * Q96 / sqrtP * Q96 / sqrtP;
2929
3301
  }
3302
+
3303
+ // src/protocols/evm/aerodrome/liquidityBasicMultisign.ts
3304
+ init_abi();
3305
+ init_addresses();
3306
+ init_client();
3307
+ init_support();
2930
3308
  function minAfterSlippage(amount, slippagePercent) {
2931
3309
  if (!Number.isFinite(slippagePercent) || slippagePercent <= 0 || slippagePercent >= 100) {
2932
3310
  throw new Error("Slippage must be between 0 and 100 (exclusive).");
@@ -3035,7 +3413,7 @@ async function buildEvmMultisignBodyAerodromeAddLiquidityBatch(args) {
3035
3413
  purposeSuffix: "Aerodrome: add basic-pool liquidity.",
3036
3414
  meta: () => ({
3037
3415
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "addLiquidity", stable: args.stable }),
3038
- evm: { type: "aerodrome_add_liquidity", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3416
+ evm: { type: "aerodrome_add_liquidity", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3039
3417
  })
3040
3418
  });
3041
3419
  }
@@ -3101,13 +3479,19 @@ async function buildEvmMultisignBodyAerodromeRemoveLiquidityBatch(args) {
3101
3479
  purposeSuffix: "Aerodrome: remove basic-pool liquidity.",
3102
3480
  meta: () => ({
3103
3481
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "removeLiquidity", lp }),
3104
- evm: { type: "aerodrome_remove_liquidity", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3482
+ evm: { type: "aerodrome_remove_liquidity", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3105
3483
  })
3106
3484
  });
3107
3485
  }
3486
+
3487
+ // src/protocols/evm/aerodrome/liquidityCl.ts
3488
+ init_abi();
3489
+ init_addresses();
3490
+ init_client();
3491
+ init_support();
3108
3492
  async function aerodromeQuoteClDeposit(args) {
3109
3493
  if (!isAerodromeChainSupported(args.chainId)) {
3110
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
3494
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
3111
3495
  }
3112
3496
  const addrs = await loadAerodromeAddresses();
3113
3497
  const client = aerodromePublicClient(args.rpcUrl);
@@ -3151,6 +3535,11 @@ async function aerodromeQuoteClDeposit(args) {
3151
3535
  sqrtPriceX96: args.sqrtPriceX96
3152
3536
  };
3153
3537
  }
3538
+
3539
+ // src/protocols/evm/aerodrome/liquidityClMultisign.ts
3540
+ init_abi();
3541
+ init_addresses();
3542
+ init_support();
3154
3543
  function minAfterSlippage2(amount, slippagePercent) {
3155
3544
  if (!Number.isFinite(slippagePercent) || slippagePercent <= 0 || slippagePercent >= 100) {
3156
3545
  throw new Error("Slippage must be between 0 and 100 (exclusive).");
@@ -3241,7 +3630,7 @@ async function buildEvmMultisignBodyAerodromeClMintBatch(args) {
3241
3630
  purposeSuffix: "Aerodrome Slipstream: mint concentrated position NFT.",
3242
3631
  meta: () => ({
3243
3632
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "nfpm.mint" }),
3244
- evm: { type: "aerodrome_cl_mint", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3633
+ evm: { type: "aerodrome_cl_mint", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3245
3634
  })
3246
3635
  });
3247
3636
  }
@@ -3307,7 +3696,7 @@ async function buildEvmMultisignBodyAerodromeClIncreaseBatch(args) {
3307
3696
  purposeSuffix: "Aerodrome Slipstream: increase liquidity.",
3308
3697
  meta: () => ({
3309
3698
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "nfpm.increaseLiquidity", tokenId: args.tokenId }),
3310
- evm: { type: "aerodrome_cl_increase", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3699
+ evm: { type: "aerodrome_cl_increase", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3311
3700
  })
3312
3701
  });
3313
3702
  }
@@ -3348,7 +3737,7 @@ async function buildEvmMultisignBodyAerodromeClDecreaseBatch(args) {
3348
3737
  purposeSuffix: "Aerodrome Slipstream: decrease liquidity.",
3349
3738
  meta: () => ({
3350
3739
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "nfpm.decreaseLiquidity", tokenId: args.tokenId }),
3351
- evm: { type: "aerodrome_cl_decrease", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3740
+ evm: { type: "aerodrome_cl_decrease", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3352
3741
  })
3353
3742
  });
3354
3743
  }
@@ -3382,7 +3771,7 @@ async function buildEvmMultisignBodyAerodromeClCollectBatch(args) {
3382
3771
  purposeSuffix: "Aerodrome Slipstream: collect fees.",
3383
3772
  meta: () => ({
3384
3773
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "nfpm.collect", tokenId: args.tokenId }),
3385
- evm: { type: "aerodrome_cl_collect", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3774
+ evm: { type: "aerodrome_cl_collect", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3386
3775
  })
3387
3776
  });
3388
3777
  }
@@ -3415,10 +3804,14 @@ async function buildEvmMultisignBodyAerodromeClBurnBatch(args) {
3415
3804
  purposeSuffix: "Aerodrome Slipstream: burn empty position NFT.",
3416
3805
  meta: () => ({
3417
3806
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "nfpm.burn", tokenId: args.tokenId }),
3418
- evm: { type: "aerodrome_cl_burn", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3807
+ evm: { type: "aerodrome_cl_burn", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3419
3808
  })
3420
3809
  });
3421
3810
  }
3811
+
3812
+ // src/protocols/evm/aerodrome/gaugeMultisign.ts
3813
+ init_abi();
3814
+ init_support();
3422
3815
  async function buildEvmMultisignBodyAerodromeGaugeStakeBatch(args) {
3423
3816
  const executor = viem.getAddress(args.executorAddress);
3424
3817
  const gauge = viem.getAddress(args.gauge);
@@ -3478,7 +3871,7 @@ async function buildEvmMultisignBodyAerodromeGaugeStakeBatch(args) {
3478
3871
  purposeSuffix: "Aerodrome: stake LP in gauge.",
3479
3872
  meta: () => ({
3480
3873
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "gauge.deposit" }),
3481
- evm: { type: "aerodrome_gauge_stake", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3874
+ evm: { type: "aerodrome_gauge_stake", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3482
3875
  })
3483
3876
  });
3484
3877
  }
@@ -3523,7 +3916,7 @@ async function buildEvmMultisignBodyAerodromeGaugeUnstakeBatch(args) {
3523
3916
  purposeSuffix: "Aerodrome: unstake LP from gauge.",
3524
3917
  meta: () => ({
3525
3918
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "gauge.withdraw" }),
3526
- evm: { type: "aerodrome_gauge_unstake", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3919
+ evm: { type: "aerodrome_gauge_unstake", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3527
3920
  })
3528
3921
  });
3529
3922
  }
@@ -3552,7 +3945,7 @@ async function buildEvmMultisignBodyAerodromeClaimFeesBatch(args) {
3552
3945
  purposeSuffix: "Aerodrome: claim basic-pool fees.",
3553
3946
  meta: () => ({
3554
3947
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "pool.claimFees", pool }),
3555
- evm: { type: "aerodrome_claim_fees", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3948
+ evm: { type: "aerodrome_claim_fees", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3556
3949
  })
3557
3950
  });
3558
3951
  }
@@ -3595,11 +3988,15 @@ async function buildEvmMultisignBodyAerodromeClaimEmissionsBatch(args) {
3595
3988
  purposeSuffix: "Aerodrome: claim gauge emissions.",
3596
3989
  meta: () => ({
3597
3990
  signatureText: JSON.stringify({ kind: "Aerodrome", name: "gauge.getReward" }),
3598
- evm: { type: "aerodrome_claim_emissions", version: 1, chainId: String(AERODROME_CHAIN_ID) }
3991
+ evm: { type: "aerodrome_claim_emissions", version: 1, chainId: String(exports.AERODROME_CHAIN_ID) }
3599
3992
  })
3600
3993
  });
3601
3994
  }
3602
3995
 
3996
+ // src/protocols/evm/aerodrome/reads.ts
3997
+ init_support();
3998
+ init_addresses();
3999
+
3603
4000
  // src/protocols/evm/aerodrome/purpose.ts
3604
4001
  function buildAerodromeSwapPurposePrefill(args) {
3605
4002
  const symIn = (args.tokenInSymbol || "").trim() || "token in";
@@ -3635,6 +4032,7 @@ function aerodromePositionKey(row) {
3635
4032
  }
3636
4033
 
3637
4034
  // src/protocols/evm/aerodrome/reads.ts
4035
+ init_stockTokens();
3638
4036
  function mergeStocksIntoListed(tokens, stocks) {
3639
4037
  const byAddr = new Map(tokens.map((t) => [t.address.toLowerCase(), { ...t }]));
3640
4038
  for (const stock of stocks) {
@@ -3643,7 +4041,7 @@ function mergeStocksIntoListed(tokens, stocks) {
3643
4041
  byAddr.set(key, {
3644
4042
  address: stock.address,
3645
4043
  symbol: stock.symbol || prev?.symbol || "",
3646
- decimals: stock.decimals || prev?.decimals || AERODROME_COINBASE_STOCK_DECIMALS,
4044
+ decimals: stock.decimals || prev?.decimals || exports.AERODROME_COINBASE_STOCK_DECIMALS,
3647
4045
  listed: prev?.listed ?? true,
3648
4046
  emerging: prev?.emerging ?? false,
3649
4047
  accountBalance: prev?.accountBalance ?? "0",
@@ -3669,7 +4067,7 @@ async function aerodromeFetchListedTokensSummary(args) {
3669
4067
  const core = [
3670
4068
  { address: viem.zeroAddress, symbol: "ETH", decimals: 18, listed: true, emerging: false, accountBalance: "0" },
3671
4069
  {
3672
- address: AERODROME_WETH_BASE,
4070
+ address: exports.AERODROME_WETH_BASE,
3673
4071
  symbol: "WETH",
3674
4072
  decimals: 18,
3675
4073
  listed: true,
@@ -3677,7 +4075,7 @@ async function aerodromeFetchListedTokensSummary(args) {
3677
4075
  accountBalance: "0"
3678
4076
  },
3679
4077
  {
3680
- address: AERODROME_USDC_BASE,
4078
+ address: exports.AERODROME_USDC_BASE,
3681
4079
  symbol: "USDC",
3682
4080
  decimals: 6,
3683
4081
  listed: true,
@@ -3687,7 +4085,7 @@ async function aerodromeFetchListedTokensSummary(args) {
3687
4085
  { address: addrs.aero, symbol: "AERO", decimals: 18, listed: true, emerging: false, accountBalance: "0" }
3688
4086
  ];
3689
4087
  return {
3690
- chainId: AERODROME_CHAIN_ID,
4088
+ chainId: exports.AERODROME_CHAIN_ID,
3691
4089
  native: { address: viem.zeroAddress, symbol: "ETH", decimals: 18 },
3692
4090
  aero: { address: addrs.aero, symbol: "AERO", decimals: 18 },
3693
4091
  stocks,
@@ -3697,14 +4095,25 @@ async function aerodromeFetchListedTokensSummary(args) {
3697
4095
  };
3698
4096
  }
3699
4097
  async function aerodromeFetchPoolsSummary(args) {
3700
- const pools = await aerodromeFetchPools(args);
3701
- return { chainId: AERODROME_CHAIN_ID, pools };
4098
+ const { aerodromeFetchImportantPoolsSummary: aerodromeFetchImportantPoolsSummary2 } = await Promise.resolve().then(() => (init_yields(), yields_exports));
4099
+ const { pools, notes } = await aerodromeFetchImportantPoolsSummary2({
4100
+ chainId: args.chainId,
4101
+ rpcUrl: args.rpcUrl,
4102
+ query: args.query
4103
+ });
4104
+ const offset = Math.max(0, args.offset ?? 0);
4105
+ const limit = Math.min(Math.max(args.limit ?? pools.length, 1), pools.length);
4106
+ return {
4107
+ chainId: exports.AERODROME_CHAIN_ID,
4108
+ pools: pools.slice(offset, offset + limit),
4109
+ notes
4110
+ };
3702
4111
  }
3703
4112
  async function aerodromeFetchPositionsSummary(args) {
3704
4113
  const account = (args.account ?? args.executorAddress ?? "").trim();
3705
4114
  if (!account) throw new Error("account or executorAddress is required.");
3706
4115
  if (!isAerodromeChainSupported(args.chainId)) {
3707
- throw new Error(`Aerodrome is Base-only (chainId ${AERODROME_CHAIN_ID}).`);
4116
+ throw new Error(`Aerodrome is Base-only (chainId ${exports.AERODROME_CHAIN_ID}).`);
3708
4117
  }
3709
4118
  const positions = await aerodromeFetchPositionsWithPools({
3710
4119
  chainId: args.chainId,
@@ -3712,7 +4121,7 @@ async function aerodromeFetchPositionsSummary(args) {
3712
4121
  account
3713
4122
  });
3714
4123
  return {
3715
- chainId: AERODROME_CHAIN_ID,
4124
+ chainId: exports.AERODROME_CHAIN_ID,
3716
4125
  account,
3717
4126
  notes: "Dust v2 rows hidden (liquidity < 1e12 and no stake/emissions). Claim fees from the pool (claimFees.pool = lp). Claim emissions from the gauge in AERO (claimEmissions); CL staked also needs tokenId + cl. Skip emissions when claimEmissions is null.",
3718
4127
  positions: positions.map((p) => {
@@ -3732,8 +4141,9 @@ async function aerodromeFetchPositionsSummary(args) {
3732
4141
  }
3733
4142
 
3734
4143
  // src/protocols/evm/aerodrome/index.ts
4144
+ init_yields();
3735
4145
  var aerodromeProtocolModule = {
3736
- id: AERODROME_PROTOCOL_ID,
4146
+ id: exports.AERODROME_PROTOCOL_ID,
3737
4147
  chainCategory: "evm",
3738
4148
  isChainSupported(ctx) {
3739
4149
  if (ctx.chainCategory !== "evm") return false;
@@ -3746,12 +4156,12 @@ var aerodromeProtocolModule = {
3746
4156
  actions: [
3747
4157
  {
3748
4158
  id: "aerodrome.quote",
3749
- protocolId: AERODROME_PROTOCOL_ID,
4159
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3750
4160
  chainCategory: "evm",
3751
4161
  description: "Quote an Aerodrome swap on Base via factory discovery + MixedRouteQuoterV3 / Router. Tickers (AAPLc, USDC, ETH) accepted.",
3752
4162
  commonParams: [],
3753
4163
  params: {
3754
- chainId: { type: "number", required: true, description: `Must be ${AERODROME_CHAIN_ID}` },
4164
+ chainId: { type: "number", required: true, description: `Must be ${exports.AERODROME_CHAIN_ID}` },
3755
4165
  tokenIn: { type: "address", required: true, description: "Ticker (AAPLc, USDC, ETH, WETH, AERO) or 0x / 0x0 native" },
3756
4166
  tokenOut: { type: "address", required: true, description: "Ticker (AAPLc, USDC, ETH, WETH, AERO) or 0x / 0x0 native" },
3757
4167
  amountHuman: { type: "string", required: true, description: "Human-readable input amount (B20 stocks are 8 decimals)" }
@@ -3759,7 +4169,7 @@ var aerodromeProtocolModule = {
3759
4169
  },
3760
4170
  {
3761
4171
  id: "aerodrome.swap",
3762
- protocolId: AERODROME_PROTOCOL_ID,
4172
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3763
4173
  chainCategory: "evm",
3764
4174
  description: "Swap via Aerodrome Router / Slipstream SwapRouter (optional ERC-20 approve batch)",
3765
4175
  commonParams: ["keyGen", "purposeText", "useCustomGas"],
@@ -3772,7 +4182,7 @@ var aerodromeProtocolModule = {
3772
4182
  },
3773
4183
  {
3774
4184
  id: "aerodrome.add-liquidity",
3775
- protocolId: AERODROME_PROTOCOL_ID,
4185
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3776
4186
  chainCategory: "evm",
3777
4187
  description: "Deposit into a basic vAMM/sAMM pool (one-sided amounts; tickers OK)",
3778
4188
  commonParams: ["keyGen", "purposeText", "useCustomGas"],
@@ -3787,7 +4197,7 @@ var aerodromeProtocolModule = {
3787
4197
  },
3788
4198
  {
3789
4199
  id: "aerodrome.remove-liquidity",
3790
- protocolId: AERODROME_PROTOCOL_ID,
4200
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3791
4201
  chainCategory: "evm",
3792
4202
  description: "Withdraw from a basic vAMM/sAMM pool",
3793
4203
  commonParams: ["keyGen", "purposeText", "useCustomGas"],
@@ -3798,7 +4208,7 @@ var aerodromeProtocolModule = {
3798
4208
  },
3799
4209
  {
3800
4210
  id: "aerodrome.cl-mint",
3801
- protocolId: AERODROME_PROTOCOL_ID,
4211
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3802
4212
  chainCategory: "evm",
3803
4213
  description: "Mint a Slipstream concentrated liquidity NFT",
3804
4214
  commonParams: ["keyGen", "purposeText", "useCustomGas"],
@@ -3812,7 +4222,7 @@ var aerodromeProtocolModule = {
3812
4222
  },
3813
4223
  {
3814
4224
  id: "aerodrome.gauge-stake",
3815
- protocolId: AERODROME_PROTOCOL_ID,
4225
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3816
4226
  chainCategory: "evm",
3817
4227
  description: "Stake basic LP tokens or a Slipstream NFT in a gauge",
3818
4228
  commonParams: ["keyGen", "purposeText", "useCustomGas"],
@@ -3822,7 +4232,7 @@ var aerodromeProtocolModule = {
3822
4232
  },
3823
4233
  {
3824
4234
  id: "aerodrome.claim-fees",
3825
- protocolId: AERODROME_PROTOCOL_ID,
4235
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3826
4236
  chainCategory: "evm",
3827
4237
  description: "Claim unstaked fees from the pool (not the gauge)",
3828
4238
  commonParams: ["keyGen", "purposeText", "useCustomGas"],
@@ -3830,7 +4240,7 @@ var aerodromeProtocolModule = {
3830
4240
  },
3831
4241
  {
3832
4242
  id: "aerodrome.claim-emissions",
3833
- protocolId: AERODROME_PROTOCOL_ID,
4243
+ protocolId: exports.AERODROME_PROTOCOL_ID,
3834
4244
  chainCategory: "evm",
3835
4245
  description: "Claim gauge emissions in AERO (not the pool)",
3836
4246
  commonParams: ["keyGen", "purposeText", "useCustomGas"],
@@ -3840,19 +4250,10 @@ var aerodromeProtocolModule = {
3840
4250
  };
3841
4251
  registerProtocolModule(aerodromeProtocolModule);
3842
4252
 
3843
- exports.AERODROME_B20_ASSET_PREFIX = AERODROME_B20_ASSET_PREFIX;
3844
- exports.AERODROME_BASE_ADDRESSES_FALLBACK = AERODROME_BASE_ADDRESSES_FALLBACK;
3845
- exports.AERODROME_CHAIN_ID = AERODROME_CHAIN_ID;
3846
4253
  exports.AERODROME_CL_FACTORY_NEWEST_BIT = AERODROME_CL_FACTORY_NEWEST_BIT;
3847
4254
  exports.AERODROME_CL_FACTORY_OLDEST_BIT = AERODROME_CL_FACTORY_OLDEST_BIT;
3848
- exports.AERODROME_COINBASE_STOCK_DECIMALS = AERODROME_COINBASE_STOCK_DECIMALS;
3849
- exports.AERODROME_COINBASE_STOCK_TOKENS = AERODROME_COINBASE_STOCK_TOKENS;
3850
- exports.AERODROME_NATIVE_PLACEHOLDER = AERODROME_NATIVE_PLACEHOLDER;
3851
- exports.AERODROME_PROTOCOL_ID = AERODROME_PROTOCOL_ID;
3852
4255
  exports.AERODROME_STABLE_FILLER = AERODROME_STABLE_FILLER;
3853
- exports.AERODROME_USDC_BASE = AERODROME_USDC_BASE;
3854
4256
  exports.AERODROME_VOLATILE_FILLER = AERODROME_VOLATILE_FILLER;
3855
- exports.AERODROME_WETH_BASE = AERODROME_WETH_BASE;
3856
4257
  exports.aerodromeClFactoryList = aerodromeClFactoryList;
3857
4258
  exports.aerodromeClSwapRouterForFactory = aerodromeClSwapRouterForFactory;
3858
4259
  exports.aerodromeCoinbaseStockAddresses = aerodromeCoinbaseStockAddresses;
@@ -3861,14 +4262,19 @@ exports.aerodromeDiscoverConnectorPoolsLoaded = aerodromeDiscoverConnectorPoolsL
3861
4262
  exports.aerodromeDiscoverDirectPools = aerodromeDiscoverDirectPools;
3862
4263
  exports.aerodromeDiscoverPoolsSummary = aerodromeDiscoverPoolsSummary;
3863
4264
  exports.aerodromeFallbackAddresses = aerodromeFallbackAddresses;
4265
+ exports.aerodromeFetchImportantPoolsSummary = aerodromeFetchImportantPoolsSummary;
3864
4266
  exports.aerodromeFetchListedTokens = aerodromeFetchListedTokens;
3865
4267
  exports.aerodromeFetchListedTokensSummary = aerodromeFetchListedTokensSummary;
4268
+ exports.aerodromeFetchLpYieldsForPair = aerodromeFetchLpYieldsForPair;
4269
+ exports.aerodromeFetchLpYieldsForPools = aerodromeFetchLpYieldsForPools;
4270
+ exports.aerodromeFetchLpYieldsSummary = aerodromeFetchLpYieldsSummary;
3866
4271
  exports.aerodromeFetchPools = aerodromeFetchPools;
3867
4272
  exports.aerodromeFetchPoolsByAddress = aerodromeFetchPoolsByAddress;
3868
4273
  exports.aerodromeFetchPoolsSummary = aerodromeFetchPoolsSummary;
3869
4274
  exports.aerodromeFetchPositions = aerodromeFetchPositions;
3870
4275
  exports.aerodromeFetchPositionsSummary = aerodromeFetchPositionsSummary;
3871
4276
  exports.aerodromeFetchPositionsWithPools = aerodromeFetchPositionsWithPools;
4277
+ exports.aerodromeFetchStockLpYieldsSummary = aerodromeFetchStockLpYieldsSummary;
3872
4278
  exports.aerodromeFetchSwapPools = aerodromeFetchSwapPools;
3873
4279
  exports.aerodromeMixedPathFiller = aerodromeMixedPathFiller;
3874
4280
  exports.aerodromeOnChainDeadlineUnix = aerodromeOnChainDeadlineUnix;
@@ -3901,6 +4307,7 @@ exports.computeAerodromePriceImpactPercent = computeAerodromePriceImpactPercent;
3901
4307
  exports.encodeAerodromeMixedPath = encodeAerodromeMixedPath;
3902
4308
  exports.fetchOfficialBaseTokenizedStocks = fetchOfficialBaseTokenizedStocks;
3903
4309
  exports.findAerodromePaths = findAerodromePaths;
4310
+ exports.formatAerodromeLpYieldLabel = formatAerodromeLpYieldLabel;
3904
4311
  exports.formatAerodromePriceImpact = formatAerodromePriceImpact;
3905
4312
  exports.isAerodromeB20AssetToken = isAerodromeB20AssetToken;
3906
4313
  exports.isAerodromeChainSupported = isAerodromeChainSupported;