impermax-sdk 2.1.583 → 2.1.585
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/config/nftlp.js
CHANGED
|
@@ -47,10 +47,10 @@ exports.NFTLP_SUBGRAPH_URL = {
|
|
|
47
47
|
]*/
|
|
48
48
|
},
|
|
49
49
|
[types_1.Networks.HyperEVM]: {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
50
|
+
/*[Extension.HyperswapV3]: [
|
|
51
|
+
//"https://hyperevm-nftlp-hyperswapv3.up.railway.app/",
|
|
52
|
+
"https://api.goldsky.com/api/public/project_cm2d5q4l4w31601vz4swb3vmi/subgraphs/impermax-v3-nftlp-hyperswap-hyperevm/1.0.0/gn",
|
|
53
|
+
]*/
|
|
54
54
|
}
|
|
55
55
|
};
|
|
56
56
|
// NFTLP Factory addresses for each network
|
|
@@ -44,13 +44,13 @@ exports.IMPERMAX_VAULT_API = {
|
|
|
44
44
|
[types_1.Networks.Ropsten]: {},
|
|
45
45
|
[types_1.Networks.Mainnet]: {},
|
|
46
46
|
[types_1.Networks.Polygon]: {
|
|
47
|
-
|
|
47
|
+
//[VaultType.LENDING]: "https://polygon-lendingvaults-production.up.railway.app/"
|
|
48
48
|
},
|
|
49
49
|
[types_1.Networks.Arbitrum]: {
|
|
50
50
|
//[VaultType.LENDING]: "https://arbitrum-lendingvaults-production.up.railway.app/"
|
|
51
51
|
},
|
|
52
52
|
[types_1.Networks.Avalanche]: {
|
|
53
|
-
|
|
53
|
+
//[VaultType.LENDING]: "https://avalanche-lendingvaults-production.up.railway.app/"
|
|
54
54
|
},
|
|
55
55
|
[types_1.Networks.Moonriver]: {},
|
|
56
56
|
[types_1.Networks.Aurora]: {},
|
|
@@ -62,7 +62,7 @@ exports.IMPERMAX_VAULT_API = {
|
|
|
62
62
|
[types_1.Networks.Canto]: {},
|
|
63
63
|
[types_1.Networks.ZksyncEra]: {},
|
|
64
64
|
[types_1.Networks.Base]: {
|
|
65
|
-
|
|
65
|
+
//[VaultType.LENDING]: "https://base-lendingvaults-production.up.railway.app/"
|
|
66
66
|
},
|
|
67
67
|
[types_1.Networks.Mantle]: {},
|
|
68
68
|
[types_1.Networks.Scroll]: {
|
|
@@ -74,14 +74,14 @@ exports.IMPERMAX_VAULT_API = {
|
|
|
74
74
|
//[VaultType.LENDING]: "https://blast-lendingvaults-production.up.railway.app/"
|
|
75
75
|
},
|
|
76
76
|
[types_1.Networks.Sonic]: {
|
|
77
|
-
|
|
77
|
+
//[VaultType.LENDING]: "https://sonic-lendingvaults-production.up.railway.app/"
|
|
78
78
|
},
|
|
79
79
|
[types_1.Networks.Linea]: {},
|
|
80
80
|
[types_1.Networks.Unichain]: {
|
|
81
|
-
|
|
81
|
+
//[VaultType.LENDING]: "https://unichain-lendingvaults-production.up.railway.app/"
|
|
82
82
|
},
|
|
83
83
|
[types_1.Networks.HyperEVM]: {
|
|
84
|
-
|
|
84
|
+
//[VaultType.LENDING]: "https://hyperevm-lendingvaults-production.up.railway.app/"
|
|
85
85
|
}
|
|
86
86
|
};
|
|
87
87
|
// API: NFTLP
|
package/lib/config/subgraphs.js
CHANGED
|
@@ -178,7 +178,7 @@ exports.VAULT_SUBGRAPH_URL = {
|
|
|
178
178
|
[types_1.Networks.Polygon]: {
|
|
179
179
|
[types_1.VaultType.LENDING]: [
|
|
180
180
|
'https://gateway.thegraph.com/api/e9bbf185bbf657f7ea313387cdf0e5ce/deployments/id/QmWn3nvawVYgkFU4RU1DZ8Eux21azGz9wtUVy6SyoVLS1f',
|
|
181
|
-
"https://polygon-lendingvaults-production.up.railway.app/"
|
|
181
|
+
//"https://polygon-lendingvaults-production.up.railway.app/"
|
|
182
182
|
],
|
|
183
183
|
[types_1.VaultType.HEDGED]: [],
|
|
184
184
|
[types_1.VaultType.LEVERAGED]: [],
|
|
@@ -194,7 +194,7 @@ exports.VAULT_SUBGRAPH_URL = {
|
|
|
194
194
|
[types_1.Networks.Avalanche]: {
|
|
195
195
|
[types_1.VaultType.LENDING]: [
|
|
196
196
|
"https://gateway.thegraph.com/api/e9bbf185bbf657f7ea313387cdf0e5ce/deployments/id/QmPiqZ1iDsQvqm9gEC4CznBiHUdTpFjKEiZCS5koPUWyeb",
|
|
197
|
-
"https://avalanche-lendingvaults-production.up.railway.app/"
|
|
197
|
+
//"https://avalanche-lendingvaults-production.up.railway.app/"
|
|
198
198
|
]
|
|
199
199
|
},
|
|
200
200
|
[types_1.Networks.Moonriver]: {},
|
|
@@ -209,7 +209,7 @@ exports.VAULT_SUBGRAPH_URL = {
|
|
|
209
209
|
[types_1.Networks.Base]: {
|
|
210
210
|
[types_1.VaultType.LENDING]: [
|
|
211
211
|
"https://gateway.thegraph.com/api/e9bbf185bbf657f7ea313387cdf0e5ce/deployments/id/QmbTVD5FsMWK9jHt755LYaA677ZsXzdY73wd6zi5BHm78c",
|
|
212
|
-
"https://base-lendingvaults-production.up.railway.app/",
|
|
212
|
+
//"https://base-lendingvaults-production.up.railway.app/",
|
|
213
213
|
],
|
|
214
214
|
[types_1.VaultType.HEDGED]: [],
|
|
215
215
|
[types_1.VaultType.LEVERAGED]: [],
|
|
@@ -243,13 +243,13 @@ exports.VAULT_SUBGRAPH_URL = {
|
|
|
243
243
|
[types_1.Networks.Unichain]: {
|
|
244
244
|
[types_1.VaultType.LENDING]: [
|
|
245
245
|
"https://gateway.thegraph.com/api/e9bbf185bbf657f7ea313387cdf0e5ce/deployments/id/QmWeKz58sHj3Sge34wF1VgZfdPHXKHDCC1ZAYWCdBFSsSm",
|
|
246
|
-
"https://unichain-lendingvaults-production.up.railway.app/"
|
|
246
|
+
//"https://unichain-lendingvaults-production.up.railway.app/"
|
|
247
247
|
]
|
|
248
248
|
},
|
|
249
249
|
[types_1.Networks.HyperEVM]: {
|
|
250
250
|
[types_1.VaultType.LENDING]: [
|
|
251
251
|
"https://api.goldsky.com/api/public/project_cm2d5q4l4w31601vz4swb3vmi/subgraphs/lending-vault-hyperevm/0.0.1/gn",
|
|
252
|
-
"https://hyperevm-lendingvaults-production.up.railway.app/"
|
|
252
|
+
//"https://hyperevm-lendingvaults-production.up.railway.app/"
|
|
253
253
|
]
|
|
254
254
|
}
|
|
255
255
|
};
|
|
@@ -50,6 +50,8 @@ class OffchainLendingVault extends offchainVault_1.default {
|
|
|
50
50
|
// Available Liquidity
|
|
51
51
|
async getAvailableLiquidity() {
|
|
52
52
|
const entity = await this.getLendingVaultObject();
|
|
53
|
+
if (entity.positions.length === 0)
|
|
54
|
+
return this.getVaultSupply();
|
|
53
55
|
return entity.getAvailableLiquidity();
|
|
54
56
|
/*return Math.min(
|
|
55
57
|
await this.getPoolTokenParamFloat("availableLiquidity"),
|