impermax-sdk 2.1.61 → 2.1.62

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.
@@ -189,6 +189,9 @@ exports.AMM_FACTORY = {
189
189
  [types_1.Networks.Real]: {
190
190
  [Amms.pearl]: '0x2B965fDf04f9e9bEEf1659464Ef3A0094A68D923',
191
191
  [Amms.pearlStable]: '0x28E22D8c807b6E6c0ECa4373fC3B9920453cEEEe',
192
+ },
193
+ [types_1.Networks.Sonic]: {
194
+ [Amms.equalizer]: '0xDDD9845Ba0D8f38d3045f804f67A1a8B9A528FcC',
192
195
  }
193
196
  };
194
197
  function getAmmByFactory(network, address) {
@@ -261,6 +264,7 @@ exports.AMM_SUBGRAPH_URLS = {
261
264
  [types_1.Networks.Scroll]: {},
262
265
  [types_1.Networks.Real]: {},
263
266
  [types_1.Networks.Optimism]: {},
267
+ [types_1.Networks.Sonic]: {},
264
268
  };
265
269
  exports.ADD_LIQUIDITY_URLS = {
266
270
  [types_1.Networks.Ropsten]: {
@@ -346,6 +350,10 @@ exports.ADD_LIQUIDITY_URLS = {
346
350
  [types_1.Networks.Real]: {
347
351
  [Amms.pearlStable]: 'https://www.pearl.exchange/supply-liquidity/v2/',
348
352
  [Amms.pearl]: 'https://www.pearl.exchange/supply-liquidity/v2/',
353
+ },
354
+ [types_1.Networks.Sonic]: {
355
+ [Amms.pearlStable]: 'https://www.pearl.exchange/supply-liquidity/v2/',
356
+ [Amms.pearl]: 'https://www.pearl.exchange/supply-liquidity/v2/',
349
357
  }
350
358
  };
351
359
  exports.AMM_LP_FEE = {
@@ -432,5 +440,8 @@ exports.AMM_LP_FEE = {
432
440
  [types_1.Networks.Real]: {
433
441
  [Amms.pearlStable]: 0,
434
442
  [Amms.pearl]: 0,
443
+ },
444
+ [types_1.Networks.Sonic]: {
445
+ [Amms.equalizer]: 0
435
446
  }
436
447
  };
@@ -23,4 +23,5 @@ exports.CHAIN_IDS = {
23
23
  [types_1.Networks.Blast]: 81457,
24
24
  [types_1.Networks.Real]: 111188,
25
25
  [types_1.Networks.Optimism]: 10,
26
+ [types_1.Networks.Sonic]: 146
26
27
  };
@@ -23,4 +23,5 @@ exports.CLAIM_AGGREGATOR = {
23
23
  [types_1.Networks.Scroll]: '',
24
24
  [types_1.Networks.Optimism]: '',
25
25
  [types_1.Networks.Real]: '',
26
+ [types_1.Networks.Sonic]: '',
26
27
  };
@@ -24,4 +24,5 @@ exports.IMPERMAX_CHEF = {
24
24
  [types_1.Networks.Scroll]: '',
25
25
  [types_1.Networks.Optimism]: '',
26
26
  [types_1.Networks.Real]: '',
27
+ [types_1.Networks.Sonic]: '',
27
28
  };
@@ -23,4 +23,5 @@ exports.IMPERMAX_CONFIG_MANAGER = {
23
23
  [types_1.Networks.Mantle]: '0x6daC1AbEA1E903765358EFD4Ac4e6E817F78F4CB',
24
24
  [types_1.Networks.Optimism]: '0xC8301bD3f86e642904aeD9b588cA9d9350b3B160',
25
25
  [types_1.Networks.Real]: '0x274C36c461C02B39a110A0801EbB218eC076B79B',
26
+ [types_1.Networks.Sonic]: '0x1A3e33E38D2e70D43f65772f63c5B3f52073b37E',
26
27
  };
@@ -66,6 +66,9 @@ exports.IMPERMAX_FACTORY = {
66
66
  [types_1.Networks.Optimism]: {
67
67
  [types_1.Factory.SOLV2]: '0xa058Ba91958cD30D44c7B0Cf58A369876Fb70B05',
68
68
  },
69
+ [types_1.Networks.Sonic]: {
70
+ [types_1.Factory.SOLV2]: '0x26fca5916c20D252feEF7A58E39886d3d3112b91',
71
+ },
69
72
  };
70
73
  function getFactoryByAddress(network, address) {
71
74
  if (!address)
@@ -23,4 +23,5 @@ exports.IMX = {
23
23
  [types_1.Networks.Scroll]: '',
24
24
  [types_1.Networks.Optimism]: '',
25
25
  [types_1.Networks.Real]: '',
26
+ [types_1.Networks.Sonic]: ''
26
27
  };
@@ -23,4 +23,5 @@ exports.LENDING_VAULT_WATCHER = {
23
23
  [types_1.Networks.Scroll]: '0x0774eBA9e1b20B0f191AbC59a5798838F4bd938c',
24
24
  [types_1.Networks.Optimism]: '',
25
25
  [types_1.Networks.Real]: '',
26
+ [types_1.Networks.Sonic]: '0x0680AD510475844a0555914FD38979B31FdA3b2f',
26
27
  };
@@ -23,6 +23,7 @@ exports.MERKLE_DISTRIBUTOR_IBEX = {
23
23
  [types_1.Networks.Scroll]: '',
24
24
  [types_1.Networks.Optimism]: '',
25
25
  [types_1.Networks.Real]: '',
26
+ [types_1.Networks.Sonic]: '',
26
27
  };
27
28
  exports.MERKLE_DISTRIBUTOR_IBEX_2 = {
28
29
  [types_1.Networks.Polygon]: '0x1c813cDd6dAecE2CB83C52F0798504e42816E9C5',
@@ -45,6 +46,7 @@ exports.MERKLE_DISTRIBUTOR_IBEX_2 = {
45
46
  [types_1.Networks.Scroll]: '',
46
47
  [types_1.Networks.Optimism]: '',
47
48
  [types_1.Networks.Real]: '',
49
+ [types_1.Networks.Sonic]: '',
48
50
  };
49
51
  exports.MERKLE_DISTRIBUTOR_ETH = {
50
52
  [types_1.Networks.Polygon]: '0x7ce2f634f0698ecdca051ef1dc4be96ef3d05a62',
@@ -67,4 +69,5 @@ exports.MERKLE_DISTRIBUTOR_ETH = {
67
69
  [types_1.Networks.Scroll]: '',
68
70
  [types_1.Networks.Optimism]: '',
69
71
  [types_1.Networks.Real]: '',
72
+ [types_1.Networks.Sonic]: '',
70
73
  };
@@ -23,6 +23,7 @@ exports.POOL_TOKEN_ROUTER = {
23
23
  [types_1.Networks.Real]: '0x3784D354863fe8862d60E446E3f29A08c21D1Ea9',
24
24
  [types_1.Networks.Mantle]: '0xF4A9dda025e65945E7A3F873D6146A12c8110A19',
25
25
  [types_1.Networks.Optimism]: '0xb5657FA5ba87CaD11b9150c319069625d423aaD4',
26
+ [types_1.Networks.Sonic]: '0x35A0e3C5adbddF6D917353f9b468C5cdE80ee380' // '0xcBdf792456367a91708C0036E0678eCFB1f09654',
26
27
  };
27
28
  exports.ROUTER = {
28
29
  [types_1.Networks.Ropsten]: {
@@ -91,6 +92,9 @@ exports.ROUTER = {
91
92
  [types_1.Factory.SOLV2]: '0x64515b2f866Ac9B1297f03329d82a8507332fEf5',
92
93
  [types_1.Factory.SOL_STABLE]: '0x3784D354863fe8862d60E446E3f29A08c21D1Ea9'
93
94
  },
95
+ [types_1.Networks.Sonic]: {
96
+ [types_1.Factory.SOLV2]: '0xcBdf792456367a91708C0036E0678eCFB1f09654',
97
+ }
94
98
  };
95
99
  exports.ROUTER_V3 = {
96
100
  [types_1.Networks.Ropsten]: {},
@@ -115,4 +119,5 @@ exports.ROUTER_V3 = {
115
119
  [types_1.Networks.Optimism]: {},
116
120
  [types_1.Networks.Mantle]: {},
117
121
  [types_1.Networks.Real]: {},
122
+ [types_1.Networks.Sonic]: {}
118
123
  };
@@ -46,4 +46,5 @@ exports.SIMPLE_UNISWAP_ORACLE = {
46
46
  [types_1.Networks.Mantle]: {
47
47
  [types_1.Factory.V2V2]: '0x936c30E14daED88fd29bf4FCe2965EbEDe633846'
48
48
  },
49
+ [types_1.Networks.Sonic]: {},
49
50
  };
@@ -23,5 +23,6 @@ exports.WETH = {
23
23
  [types_1.Networks.Mantle]: '0x78c1b0C915c4FAA5FffA6CAbf0219DA63d7f4cb8',
24
24
  [types_1.Networks.Scroll]: '0x5300000000000000000000000000000000000004',
25
25
  [types_1.Networks.Optimism]: '0x4200000000000000000000000000000000000006',
26
- [types_1.Networks.Real]: '0x90c6E93849E06EC7478ba24522329d14A5954Df4', // reETH
26
+ [types_1.Networks.Real]: '0x90c6E93849E06EC7478ba24522329d14A5954Df4',
27
+ [types_1.Networks.Sonic]: '0x039e2fB66102314Ce7b64Ce5Ce3E5183bc94aD38', // ws
27
28
  };
@@ -23,4 +23,5 @@ exports.DEBANK_IDS = {
23
23
  [types_1.Networks.Scroll]: 'scrl',
24
24
  [types_1.Networks.Optimism]: 'op',
25
25
  [types_1.Networks.Real]: 'real',
26
+ [types_1.Networks.Sonic]: 'sonic'
26
27
  };
@@ -23,6 +23,7 @@ exports.MERKLE_URL_IBEX = {
23
23
  [types_1.Networks.Scroll]: '',
24
24
  [types_1.Networks.Optimism]: '',
25
25
  [types_1.Networks.Real]: '',
26
+ [types_1.Networks.Sonic]: '',
26
27
  };
27
28
  exports.MERKLE_URL_IBEX_2 = {
28
29
  [types_1.Networks.Polygon]: 'https://misty-rice-9880.impermax.workers.dev',
@@ -45,6 +46,7 @@ exports.MERKLE_URL_IBEX_2 = {
45
46
  [types_1.Networks.Scroll]: '',
46
47
  [types_1.Networks.Optimism]: '',
47
48
  [types_1.Networks.Real]: '',
49
+ [types_1.Networks.Sonic]: '',
48
50
  };
49
51
  exports.MERKLE_URL_ETH = {
50
52
  [types_1.Networks.Polygon]: 'https://damp-hill-13d0.impermax.workers.dev',
@@ -67,4 +69,5 @@ exports.MERKLE_URL_ETH = {
67
69
  [types_1.Networks.Scroll]: '',
68
70
  [types_1.Networks.Optimism]: '',
69
71
  [types_1.Networks.Real]: '',
72
+ [types_1.Networks.Sonic]: '',
70
73
  };
package/lib/config/eth.js CHANGED
@@ -23,6 +23,7 @@ exports.ETH_NAME = {
23
23
  [types_1.Networks.Scroll]: 'Ethereum',
24
24
  [types_1.Networks.Optimism]: 'Ethereum',
25
25
  [types_1.Networks.Real]: 'Ethereum',
26
+ [types_1.Networks.Sonic]: 'S'
26
27
  };
27
28
  exports.ETH_SYMBOL = {
28
29
  [types_1.Networks.Ropsten]: 'ETH',
@@ -45,4 +46,5 @@ exports.ETH_SYMBOL = {
45
46
  [types_1.Networks.Scroll]: 'ETH',
46
47
  [types_1.Networks.Optimism]: 'ETH',
47
48
  [types_1.Networks.Real]: 'reETH',
49
+ [types_1.Networks.Sonic]: 'S'
48
50
  };
@@ -192,7 +192,8 @@ exports.STAKED_LP_FACTORY = {
192
192
  [types_1.Networks.Real]: {
193
193
  [Farms.pearl]: '0x2B965fDf04f9e9bEEf1659464Ef3A0094A68D923',
194
194
  [Farms.pearlStable]: '0x28E22D8c807b6E6c0ECa4373fC3B9920453cEEEe',
195
- }
195
+ },
196
+ [types_1.Networks.Sonic]: {}
196
197
  };
197
198
  function getFarmByStakedLPFactory(network, address) {
198
199
  if (!address)
@@ -29,6 +29,7 @@ exports.IMPERMAX_POOLS_API = {
29
29
  [types_1.Networks.Optimism]: {},
30
30
  [types_1.Networks.Real]: {},
31
31
  [types_1.Networks.Blast]: {},
32
+ [types_1.Networks.Sonic]: {},
32
33
  };
33
34
  // For lending pools
34
35
  exports.IMPERMAX_VAULT_API = {
@@ -58,5 +59,6 @@ exports.IMPERMAX_VAULT_API = {
58
59
  [types_1.Networks.Blast]: {
59
60
  [types_1.VaultType.LENDING]: "https://blast-lendingvaults-production.up.railway.app/vaults/"
60
61
  },
62
+ [types_1.Networks.Sonic]: {},
61
63
  };
62
64
  // Add more here
@@ -24,6 +24,7 @@ export declare const CONFIG_MANAGER_SUBGRAPH_URL: {
24
24
  base: string;
25
25
  optimism: string;
26
26
  "re.al": string;
27
+ sonic: string;
27
28
  };
28
29
  export declare const WHITELIST_SUBGRAPH_URL: {
29
30
  ropsten: string;
@@ -129,6 +129,12 @@ exports.IMPERMAX_SUBGRAPH_URL = {
129
129
  "https://api.goldsky.com/api/public/project_cm2rhb30ot9wu01to8c9h9e37/subgraphs/impermax-real-solv2/3.0/gn",
130
130
  ],
131
131
  },
132
+ [types_1.Networks.Sonic]: {
133
+ [types_1.Factory.SOLV2]: [
134
+ 'https://sonic-factory-production.up.railway.app/',
135
+ 'https://gateway.thegraph.com/api/1350441d268f171aeb0934412dfadf3b/subgraphs/id/HK9BA4oFp1xaoQW7YVP4m2nbxX7q2bQCZWNPKBtudtZR'
136
+ ]
137
+ }
132
138
  };
133
139
  // TODO: Since these are part of core we should add redundancy like above, left arrays to fill
134
140
  exports.VAULT_SUBGRAPH_URL = {
@@ -185,6 +191,11 @@ exports.VAULT_SUBGRAPH_URL = {
185
191
  [types_1.VaultType.HEDGED]: [],
186
192
  [types_1.VaultType.LEVERAGED]: [],
187
193
  },
194
+ [types_1.Networks.Sonic]: {
195
+ [types_1.VaultType.LENDING]: [
196
+ "https://gateway.thegraph.com/api/1350441d268f171aeb0934412dfadf3b/subgraphs/id/AHj91C4xwYSfyHAnZiMa1pC4ZwRtzqG3QGVyJchEsJAC"
197
+ ]
198
+ }
188
199
  };
189
200
  exports.IMPERMAX_CHEF_SUBGRAPH_URL = {
190
201
  [types_1.Networks.Ropsten]: "",
@@ -208,6 +219,7 @@ exports.IMPERMAX_CHEF_SUBGRAPH_URL = {
208
219
  [types_1.Networks.Scroll]: "",
209
220
  [types_1.Networks.Optimism]: "",
210
221
  [types_1.Networks.Real]: "",
222
+ [types_1.Networks.Sonic]: "",
211
223
  };
212
224
  exports.BLOCKS_SUBGRAPH_URL = {
213
225
  [types_1.Networks.Ropsten]: "",
@@ -230,6 +242,7 @@ exports.BLOCKS_SUBGRAPH_URL = {
230
242
  [types_1.Networks.Scroll]: "",
231
243
  [types_1.Networks.Real]: "",
232
244
  [types_1.Networks.Optimism]: "",
245
+ [types_1.Networks.Sonic]: "",
233
246
  };
234
247
  exports.XIMX_SUBGRAPH_URL = "https://api.thegraph.com/subgraphs/name/impermax-finance/imx-staking";
235
248
  exports.CONFIG_MANAGER_SUBGRAPH_URL = {
@@ -252,6 +265,7 @@ exports.CONFIG_MANAGER_SUBGRAPH_URL = {
252
265
  [types_1.Networks.Base]: "https://gateway.thegraph.com/api/1350441d268f171aeb0934412dfadf3b/subgraphs/id/6y4Bb2KSFsqyjbARM8EpKkqFRt62ELasVCVckg2bv7jB",
253
266
  [types_1.Networks.Optimism]: "https://gateway.thegraph.com/api/1350441d268f171aeb0934412dfadf3b/subgraphs/id/GWFrv8MNg5fpD19fxdu32G1Wt6om8qb1wbacpgHDyvC8",
254
267
  [types_1.Networks.Real]: "https://api.goldsky.com/api/public/project_cm2d5q4l4w31601vz4swb3vmi/subgraphs/impermax-config-manager-real/1.0/gn",
268
+ [types_1.Networks.Sonic]: "https://gateway.thegraph.com/api/1350441d268f171aeb0934412dfadf3b/subgraphs/id/DqzQAecRNGsoRgwVre16Fha9XTPFf9QBo8iZxubysy2x"
255
269
  };
256
270
  exports.WHITELIST_SUBGRAPH_URL = {
257
271
  [types_1.Networks.Ropsten]: "",
@@ -19,7 +19,8 @@ export declare enum Networks {
19
19
  Mantle = "mantle",
20
20
  Scroll = "scroll",
21
21
  Optimism = "optimism",
22
- Real = "re.al"
22
+ Real = "re.al",
23
+ Sonic = "sonic"
23
24
  }
24
25
  export declare enum Factory {
25
26
  V2V1 = "1",
@@ -23,6 +23,7 @@ var Networks;
23
23
  Networks["Scroll"] = "scroll";
24
24
  Networks["Optimism"] = "optimism";
25
25
  Networks["Real"] = "re.al";
26
+ Networks["Sonic"] = "sonic";
26
27
  })(Networks = exports.Networks || (exports.Networks = {}));
27
28
  // FACTORIES
28
29
  var Factory;
@@ -31,6 +31,7 @@ const LlamaChains = {
31
31
  [types_1.Networks.Optimism]: "optimism",
32
32
  [types_1.Networks.Real]: "re.al",
33
33
  [types_1.Networks.Blast]: "blast",
34
+ [types_1.Networks.Sonic]: "sonic",
34
35
  };
35
36
  // Class to get the APR from DefiLlama directly, only makes 1 call to api and caches all pools
36
37
  class OffchainAPRHelper {
@@ -468,15 +468,16 @@ function initializeTvlData() {
468
468
  types_1.Networks.Arbitrum,
469
469
  types_1.Networks.Polygon,
470
470
  types_1.Networks.Avalanche,
471
- // Networks.Moonriver,
472
471
  types_1.Networks.Fantom,
472
+ // Networks.Moonriver,
473
473
  // Networks.Canto,
474
- types_1.Networks.ZksyncEra,
475
474
  // Networks.Mantle,
475
+ types_1.Networks.ZksyncEra,
476
476
  types_1.Networks.Base,
477
477
  types_1.Networks.Scroll,
478
478
  types_1.Networks.Real,
479
479
  types_1.Networks.Blast,
480
+ types_1.Networks.Sonic
480
481
  ]; // exclude ropsten
481
482
  const calls = [];
482
483
  for (const network of networks) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "impermax-sdk",
3
- "version": "2.1.61",
3
+ "version": "2.1.62",
4
4
  "description": "",
5
5
  "main": "./lib/index.js",
6
6
  "module": "./lib/index.js",