@sonarwatch/portfolio-plugins 0.12.46 → 0.12.48
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +12 -0
- package/package.json +1 -1
- package/src/index.js +4 -0
- package/src/index.js.map +1 -1
- package/src/plugins/01/constants.js +2 -1
- package/src/plugins/01/constants.js.map +1 -1
- package/src/plugins/hedgehog/ammJob.js +5 -5
- package/src/plugins/hedgehog/ammJob.js.map +1 -1
- package/src/plugins/hedgehog/constants.d.ts +0 -2
- package/src/plugins/hedgehog/constants.js +1 -3
- package/src/plugins/hedgehog/constants.js.map +1 -1
- package/src/plugins/jito/helper.d.ts +3 -0
- package/src/plugins/jito/helper.js +21 -0
- package/src/plugins/jito/helper.js.map +1 -0
- package/src/plugins/mango/redeemFetcher.js +1 -1
- package/src/plugins/mango/redeemFetcher.js.map +1 -1
- package/src/plugins/native-stake/solana/constants.d.ts +1 -1
- package/src/plugins/native-stake/solana/constants.js +2 -2
- package/src/plugins/native-stake/solana/constants.js.map +1 -1
- package/src/plugins/native-stake/solana/solanaFetcher.js +1 -1
- package/src/plugins/native-stake/solana/solanaFetcher.js.map +1 -1
- package/src/plugins/native-stake/solana/solanaValidatorsJob.js +17 -38
- package/src/plugins/native-stake/solana/solanaValidatorsJob.js.map +1 -1
- package/src/plugins/native-stake/solana/types.d.ts +7 -11
- package/src/plugins/nxfinance/constants.d.ts +8 -0
- package/src/plugins/nxfinance/constants.js +22 -0
- package/src/plugins/nxfinance/constants.js.map +1 -0
- package/src/plugins/nxfinance/idl.d.ts +166 -0
- package/src/plugins/nxfinance/idl.js +2169 -0
- package/src/plugins/nxfinance/idl.js.map +1 -0
- package/src/plugins/nxfinance/index.d.ts +6 -0
- package/src/plugins/nxfinance/index.js +12 -0
- package/src/plugins/nxfinance/index.js.map +1 -0
- package/src/plugins/nxfinance/positionsFetcher.d.ts +3 -0
- package/src/plugins/nxfinance/positionsFetcher.js +92 -0
- package/src/plugins/nxfinance/positionsFetcher.js.map +1 -0
- package/src/plugins/nxfinance/structs.d.ts +19 -0
- package/src/plugins/nxfinance/structs.js +22 -0
- package/src/plugins/nxfinance/structs.js.map +1 -0
- package/src/plugins/nxfinance/types.d.ts +21 -0
- package/src/plugins/nxfinance/types.js +3 -0
- package/src/plugins/nxfinance/types.js.map +1 -0
- package/src/plugins/parcl/constants.d.ts +0 -2
- package/src/plugins/parcl/constants.js +1 -3
- package/src/plugins/parcl/constants.js.map +1 -1
- package/src/plugins/parcl/marginFetcher.js +2 -2
- package/src/plugins/parcl/marginFetcher.js.map +1 -1
- package/src/plugins/zeta/airdropFetcher.js +8 -0
- package/src/plugins/zeta/airdropFetcher.js.map +1 -1
- package/src/plugins/zeta/constants.d.ts +5 -1
- package/src/plugins/zeta/constants.js +46 -2
- package/src/plugins/zeta/constants.js.map +1 -1
- package/src/plugins/zeta/depositsFetcher.js +2 -2
- package/src/plugins/zeta/depositsFetcher.js.map +1 -1
- package/src/plugins/zeta/helpers.d.ts +3 -0
- package/src/plugins/zeta/helpers.js +27 -1
- package/src/plugins/zeta/helpers.js.map +1 -1
- package/src/plugins/zeta/idls.d.ts +70 -0
- package/src/plugins/zeta/idls.js +749 -0
- package/src/plugins/zeta/idls.js.map +1 -0
- package/src/plugins/zeta/index.js +6 -1
- package/src/plugins/zeta/index.js.map +1 -1
- package/src/plugins/zeta/stakingFetcher.d.ts +3 -0
- package/src/plugins/zeta/stakingFetcher.js +69 -0
- package/src/plugins/zeta/stakingFetcher.js.map +1 -0
- package/src/plugins/zeta/structs.d.ts +7 -0
- package/src/plugins/zeta/structs.js +7 -1
- package/src/plugins/zeta/structs.js.map +1 -1
- package/src/plugins/zeta/types.d.ts +26 -0
- package/src/plugins/zeta/types.js +7 -0
- package/src/plugins/zeta/types.js.map +1 -1
- package/src/utils/misc/checkComputeAndStoreTokensPrices.js +2 -1
- package/src/utils/misc/checkComputeAndStoreTokensPrices.js.map +1 -1
- package/src/utils/misc/getLpUnderlyingTokenSource.js +2 -1
- package/src/utils/misc/getLpUnderlyingTokenSource.js.map +1 -1
- package/src/utils/solana/das/getAssetBatchDas.js +3 -2
- package/src/utils/solana/das/getAssetBatchDas.js.map +1 -1
- package/src/utils/solana/das/heliusAssetToAssetCollectible.js +6 -4
- package/src/utils/solana/das/heliusAssetToAssetCollectible.js.map +1 -1
package/CHANGELOG.md
CHANGED
@@ -2,6 +2,18 @@
|
|
2
2
|
|
3
3
|
This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
|
4
4
|
|
5
|
+
## [0.12.48](https://github.com/sonarwatch/portfolio/compare/plugins-0.12.47...plugins-0.12.48) (2024-07-05)
|
6
|
+
|
7
|
+
|
8
|
+
|
9
|
+
## [0.12.47](https://github.com/sonarwatch/portfolio/compare/plugins-0.12.46...plugins-0.12.47) (2024-07-05)
|
10
|
+
|
11
|
+
|
12
|
+
|
13
|
+
## [0.12.47](https://github.com/sonarwatch/portfolio/compare/plugins-0.12.46...plugins-0.12.47) (2024-07-05)
|
14
|
+
|
15
|
+
|
16
|
+
|
5
17
|
## [0.12.46](https://github.com/sonarwatch/portfolio/compare/plugins-0.12.45...plugins-0.12.46) (2024-07-02)
|
6
18
|
|
7
19
|
|
package/package.json
CHANGED
package/src/index.js
CHANGED
@@ -125,6 +125,7 @@ const citrus_1 = require("./plugins/citrus");
|
|
125
125
|
const sharky_1 = require("./plugins/sharky");
|
126
126
|
const sanctum_1 = require("./plugins/sanctum");
|
127
127
|
const allbridge_1 = require("./plugins/allbridge");
|
128
|
+
const nxfinance_1 = require("./plugins/nxfinance");
|
128
129
|
var constants_1 = require("./plugins/tokens/constants");
|
129
130
|
Object.defineProperty(exports, "walletTokensPlatform", { enumerable: true, get: function () { return constants_1.walletTokensPlatform; } });
|
130
131
|
Object.defineProperty(exports, "walletNftsPlatform", { enumerable: true, get: function () { return constants_1.walletNftsPlatform; } });
|
@@ -243,6 +244,7 @@ exports.platforms = [
|
|
243
244
|
...sharky_1.platforms,
|
244
245
|
...sanctum_1.platforms,
|
245
246
|
...allbridge_1.platforms,
|
247
|
+
...nxfinance_1.platforms,
|
246
248
|
];
|
247
249
|
// JOBS //
|
248
250
|
exports.jobs = [
|
@@ -344,6 +346,7 @@ exports.jobs = [
|
|
344
346
|
...sharky_1.jobs,
|
345
347
|
...sanctum_1.jobs,
|
346
348
|
...allbridge_1.jobs,
|
349
|
+
...nxfinance_1.jobs,
|
347
350
|
];
|
348
351
|
// FETCHERS //
|
349
352
|
exports.fetchers = [
|
@@ -447,6 +450,7 @@ exports.fetchers = [
|
|
447
450
|
...sharky_1.fetchers,
|
448
451
|
...sanctum_1.fetchers,
|
449
452
|
...allbridge_1.fetchers,
|
453
|
+
...nxfinance_1.fetchers,
|
450
454
|
];
|
451
455
|
exports.fetchersByAddressSystem = (0, getFetchersByAddressSystem_1.getFetchersByAddressSystem)(exports.fetchers);
|
452
456
|
exports.airdropFetchers = [
|
package/src/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../packages/plugins/src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAIA,wFAAqF;AACrF,sEAA8C;AAC9C,6CAI0B;AAC1B,yDAIgC;AAChC,uDAAgE;AAChE,iDAG4B;AAC5B,iDAI4B;AAC5B,2CAGyB;AACzB,6CAI0B;AAC1B,+CAI2B;AAC3B,yCAIwB;AACxB,+CAI2B;AAC3B,2CAIyB;AACzB,6CAI0B;AAC1B,2CAIyB;AACzB,6CAG0B;AAC1B,6CAI0B;AAC1B,yCAIwB;AACxB,2DAGiC;AACjC,6CAI0B;AAC1B,2CAKyB;AACzB,2CAIyB;AACzB,qDAA6D;AAC7D,qEAIsC;AACtC,uDAI+B;AAC/B,mDAI6B;AAC7B,qDAG8B;AAC9B,uDAG+B;AAC/B,2CAIyB;AACzB,6CAI0B;AAC1B,6CAG0B;AAC1B,yCAIwB;AACxB,+CAI2B;AAC3B,uDAG+B;AAC/B,yCAGwB;AACxB,2CAIyB;AACzB,iDAI4B;AAC5B,iDAI4B;A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ACnB,GAAG,eAAY;IACf,GAAG,iBAAc;IACjB,GAAG,eAAY;IACf,GAAG,oBAAiB;IACpB,GAAG,gBAAa;IAChB,GAAG,oBAAiB;IACpB,GAAG,gBAAa;IAChB,GAAG,iBAAc;IACjB,GAAG,gBAAa;IAChB,GAAG,gBAAa;IAChB,GAAG,eAAY;IACf,GAAG,kBAAe;IAClB,GAAG,kBAAe;IAClB,GAAG,mBAAgB;IACnB,GAAG,uBAAoB;IACvB,GAAG,mBAAgB;IACnB,GAAG,iBAAc;IACjB,GAAG,mBAAgB;IACnB,GAAG,kBAAe;IAClB,GAAG,iBAAc;IACjB,GAAG,iBAAc;IACjB,GAAG,kBAAe;IAClB,GAAG,oBAAiB;IACpB,GAAG,oBAAiB;CACrB,CAAC;AACW,QAAA,uBAAuB,GAAG,IAAA,uDAA0B,EAAC,gBAAQ,CAAC,CAAC;AAE/D,QAAA,eAAe,GAAqB;IAC/C,sBAAmB;IACnB,sBAAmB;CACpB,CAAC;AACW,QAAA,8BAA8B,GACzC,IAAA,uDAA0B,EAAC,uBAAe,CAAC,CAAC"}
|
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.mints = exports.service = exports.config = exports.contract = exports.programId = exports.platform = exports.platformId = void 0;
|
4
4
|
const web3_js_1 = require("@solana/web3.js");
|
5
5
|
const portfolio_core_1 = require("@sonarwatch/portfolio-core");
|
6
|
+
const solana_1 = require("../../utils/solana");
|
6
7
|
exports.platformId = '01';
|
7
8
|
exports.platform = {
|
8
9
|
id: exports.platformId,
|
@@ -30,7 +31,7 @@ exports.service = {
|
|
30
31
|
configs: [exports.config],
|
31
32
|
};
|
32
33
|
exports.mints = [
|
33
|
-
|
34
|
+
solana_1.usdcSolanaMint,
|
34
35
|
'So11111111111111111111111111111111111111112',
|
35
36
|
'9n4nbM75f5Ui33ZbPYXn59EwSgE8CGsHtAeTH5YFeJ9E',
|
36
37
|
'Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB',
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/01/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAC5C,+DAMoC;
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/01/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAC5C,+DAMoC;AACpC,+CAAoD;AAEvC,QAAA,UAAU,GAAG,IAAI,CAAC;AAClB,QAAA,QAAQ,GAAa;IAChC,EAAE,EAAE,kBAAU;IACd,IAAI,EAAE,IAAI;IACV,KAAK,EAAE,0CAA0C;IACjD,WAAW,EAAE,IAAI,EAAE,sCAAsC;IACzD,OAAO,EAAE,iBAAiB;IAC1B,6CAA6C;CAC9C,CAAC;AAEW,QAAA,SAAS,GAAG,IAAI,mBAAS,CACpC,6CAA6C,CAC9C,CAAC;AAEW,QAAA,QAAQ,GAAa;IAChC,OAAO,EAAE,iBAAS,CAAC,QAAQ,EAAE;IAC7B,IAAI,EAAE,SAAS;IACf,OAAO,EAAE,0BAAS,CAAC,MAAM;CAC1B,CAAC;AAEW,QAAA,MAAM,GAAkB;IACnC,YAAY,EAAE,aAAa;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,SAAS,EAAE,CAAC,gBAAQ,CAAC;CACtB,CAAC;AAEW,QAAA,OAAO,GAAY;IAC9B,EAAE,EAAE,GAAG,kBAAU,UAAU;IAC3B,UAAU,EAAV,kBAAU;IACV,IAAI,EAAE,SAAS;IACf,OAAO,EAAE,CAAC,cAAM,CAAC;CAClB,CAAC;AAEW,QAAA,KAAK,GAAG;IACnB,uBAAc;IACd,6CAA6C;IAC7C,8CAA8C;IAC9C,8CAA8C;IAC9C,8CAA8C;IAC9C,8CAA8C;IAC9C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;CAC9C,CAAC"}
|
@@ -16,7 +16,7 @@ const solana_1 = require("../../utils/solana");
|
|
16
16
|
const structs_1 = require("./structs");
|
17
17
|
const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
|
18
18
|
const client = (0, clients_1.getClientSolana)();
|
19
|
-
const usdcTokenPrice = yield cache.getTokenPrice(
|
19
|
+
const usdcTokenPrice = yield cache.getTokenPrice(solana_1.usdcSolanaMint, portfolio_core_1.NetworkId.solana);
|
20
20
|
if (!usdcTokenPrice)
|
21
21
|
return;
|
22
22
|
const accounts = yield (0, solana_1.getParsedProgramAccounts)(client, structs_1.swapStruct, constants_1.ammPid, [
|
@@ -120,9 +120,9 @@ const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
|
|
120
120
|
price: shareA * usdcTokenPrice.price,
|
121
121
|
underlyings: [
|
122
122
|
{
|
123
|
-
address:
|
123
|
+
address: solana_1.usdcSolanaMint,
|
124
124
|
amountPerLp: shareA,
|
125
|
-
decimals:
|
125
|
+
decimals: solana_1.usdcSolanaDecimals,
|
126
126
|
networkId: portfolio_core_1.NetworkId.solana,
|
127
127
|
price: usdcTokenPrice.price,
|
128
128
|
},
|
@@ -144,9 +144,9 @@ const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
|
|
144
144
|
price: shareB * usdcTokenPrice.price,
|
145
145
|
underlyings: [
|
146
146
|
{
|
147
|
-
address:
|
147
|
+
address: solana_1.usdcSolanaMint,
|
148
148
|
amountPerLp: shareB,
|
149
|
-
decimals:
|
149
|
+
decimals: solana_1.usdcSolanaDecimals,
|
150
150
|
networkId: portfolio_core_1.NetworkId.solana,
|
151
151
|
price: usdcTokenPrice.price,
|
152
152
|
},
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ammJob.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/hedgehog/ammJob.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAAyE;AAGzE,
|
1
|
+
{"version":3,"file":"ammJob.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/hedgehog/ammJob.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAAyE;AAGzE,2CAAiD;AACjD,iDAAsD;AACtD,+CAU4B;AAC5B,uCAOmB;AAEnB,MAAM,QAAQ,GAAgB,CAAO,KAAY,EAAE,EAAE;IACnD,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,cAAc,GAAG,MAAM,KAAK,CAAC,aAAa,CAC9C,uBAAc,EACd,0BAAS,CAAC,MAAM,CACjB,CAAC;IACF,IAAI,CAAC,cAAc;QAAE,OAAO;IAE5B,MAAM,QAAQ,GAAG,MAAM,IAAA,iCAAwB,EAAC,MAAM,EAAE,oBAAU,EAAE,kBAAM,EAAE;QAC1E;YACE,QAAQ,EAAE,oBAAU,CAAC,QAAQ;SAC9B;KACF,CAAC,CAAC;IACH,IAAI,QAAQ,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IAElC,UAAU;IACV,MAAM,eAAe,GAAG,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC;IACtD,MAAM,cAAc,GAAG,CACrB,MAAM,IAAA,sCAA6B,EAAC,MAAM,EAAE,sBAAY,EAAE,eAAe,CAAC,CAC3E,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,IAAI,CAA4B,CAAC;IACvD,MAAM,iBAAiB,GAAuC,IAAI,GAAG,EAAE,CAAC;IACxE,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE;QA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AC3B,aAAa,EAAE,cAAc;YAC7B,MAAM,EAAE,CAAC;YACT,KAAK,EAAE,MAAM,GAAG,cAAc,CAAC,KAAK;YACpC,WAAW,EAAE;gBACX;oBACE,OAAO,EAAE,uBAAc;oBACvB,WAAW,EAAE,MAAM;oBACnB,QAAQ,EAAE,2BAAkB;oBAC5B,SAAS,EAAE,0BAAS,CAAC,MAAM;oBAC3B,KAAK,EAAE,cAAc,CAAC,KAAK;iBAC5B;aACF;SACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IACjC,CAAC;IAED,MAAM,KAAK,CAAC,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAC5C,CAAC,CAAA,CAAC;AACF,MAAM,GAAG,GAAQ;IACf,EAAE,EAAE,GAAG,sBAAU,MAAM;IACvB,QAAQ;IACR,KAAK,EAAE,QAAQ;CAChB,CAAC;AACF,kBAAe,GAAG,CAAC"}
|
@@ -4,5 +4,3 @@ export declare const platformId = "hedgehog";
|
|
4
4
|
export declare const platform: Platform;
|
5
5
|
export declare const ammPid: PublicKey;
|
6
6
|
export declare const swapPid: PublicKey;
|
7
|
-
export declare const usdcMint = "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v";
|
8
|
-
export declare const usdcDecimals = 6;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
3
|
+
exports.swapPid = exports.ammPid = exports.platform = exports.platformId = void 0;
|
4
4
|
const web3_js_1 = require("@solana/web3.js");
|
5
5
|
exports.platformId = 'hedgehog';
|
6
6
|
exports.platform = {
|
@@ -13,6 +13,4 @@ exports.platform = {
|
|
13
13
|
};
|
14
14
|
exports.ammPid = new web3_js_1.PublicKey('Hr4whNgXr3yZsJvx3TVSwfsFgXuSEPB1xKmvgrtLhsrM');
|
15
15
|
exports.swapPid = new web3_js_1.PublicKey('2ZznCMfx2XP43zaPw9R9wKnjXWiEeEexyhdBPv3UqDtD');
|
16
|
-
exports.usdcMint = 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v';
|
17
|
-
exports.usdcDecimals = 6;
|
18
16
|
//# sourceMappingURL=constants.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/hedgehog/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAG/B,QAAA,UAAU,GAAG,UAAU,CAAC;AACxB,QAAA,QAAQ,GAAa;IAChC,EAAE,EAAE,kBAAU;IACd,IAAI,EAAE,kBAAkB;IACxB,KAAK,EAAE,iDAAiD;IACxD,OAAO,EAAE,0BAA0B;IACnC,OAAO,EAAE,oCAAoC;IAC7C,qEAAqE;CACtE,CAAC;AACW,QAAA,MAAM,GAAG,IAAI,mBAAS,CACjC,8CAA8C,CAC/C,CAAC;AACW,QAAA,OAAO,GAAG,IAAI,mBAAS,CAClC,8CAA8C,CAC/C,CAAC
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/hedgehog/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAG/B,QAAA,UAAU,GAAG,UAAU,CAAC;AACxB,QAAA,QAAQ,GAAa;IAChC,EAAE,EAAE,kBAAU;IACd,IAAI,EAAE,kBAAkB;IACxB,KAAK,EAAE,iDAAiD;IACxD,OAAO,EAAE,0BAA0B;IACnC,OAAO,EAAE,oCAAoC;IAC7C,qEAAqE;CACtE,CAAC;AACW,QAAA,MAAM,GAAG,IAAI,mBAAS,CACjC,8CAA8C,CAC/C,CAAC;AACW,QAAA,OAAO,GAAG,IAAI,mBAAS,CAClC,8CAA8C,CAC/C,CAAC"}
|
@@ -0,0 +1,3 @@
|
|
1
|
+
import { PublicKey } from '@solana/web3.js';
|
2
|
+
export declare function findClaimStatusKey(claimant: string, distributor: string, programId: string): PublicKey;
|
3
|
+
export declare function findClaimStatusesKeys(claimant: string, distributors: string[], programId: string): PublicKey[];
|
@@ -0,0 +1,21 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.findClaimStatusesKeys = exports.findClaimStatusKey = void 0;
|
4
|
+
const web3_js_1 = require("@solana/web3.js");
|
5
|
+
function findClaimStatusKey(claimant, distributor, programId) {
|
6
|
+
return web3_js_1.PublicKey.findProgramAddressSync([
|
7
|
+
Buffer.from('ClaimStatus'),
|
8
|
+
new web3_js_1.PublicKey(distributor).toBytes(),
|
9
|
+
new web3_js_1.PublicKey(claimant).toBytes(),
|
10
|
+
], new web3_js_1.PublicKey(programId))[0];
|
11
|
+
}
|
12
|
+
exports.findClaimStatusKey = findClaimStatusKey;
|
13
|
+
function findClaimStatusesKeys(claimant, distributors, programId) {
|
14
|
+
return distributors.map((distributor) => web3_js_1.PublicKey.findProgramAddressSync([
|
15
|
+
Buffer.from('ClaimStatus'),
|
16
|
+
new web3_js_1.PublicKey(distributor).toBytes(),
|
17
|
+
new web3_js_1.PublicKey(claimant).toBytes(),
|
18
|
+
], new web3_js_1.PublicKey(programId))[0]);
|
19
|
+
}
|
20
|
+
exports.findClaimStatusesKeys = findClaimStatusesKeys;
|
21
|
+
//# sourceMappingURL=helper.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"helper.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/jito/helper.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAE5C,SAAgB,kBAAkB,CAChC,QAAgB,EAChB,WAAmB,EACnB,SAAiB;IAEjB,OAAO,mBAAS,CAAC,sBAAsB,CACrC;QACE,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC;QAC1B,IAAI,mBAAS,CAAC,WAAW,CAAC,CAAC,OAAO,EAAE;QACpC,IAAI,mBAAS,CAAC,QAAQ,CAAC,CAAC,OAAO,EAAE;KAClC,EACD,IAAI,mBAAS,CAAC,SAAS,CAAC,CACzB,CAAC,CAAC,CAAC,CAAC;AACP,CAAC;AAbD,gDAaC;AAED,SAAgB,qBAAqB,CACnC,QAAgB,EAChB,YAAsB,EACtB,SAAiB;IAEjB,OAAO,YAAY,CAAC,GAAG,CACrB,CAAC,WAAW,EAAE,EAAE,CACd,mBAAS,CAAC,sBAAsB,CAC9B;QACE,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC;QAC1B,IAAI,mBAAS,CAAC,WAAW,CAAC,CAAC,OAAO,EAAE;QACpC,IAAI,mBAAS,CAAC,QAAQ,CAAC,CAAC,OAAO,EAAE;KAClC,EACD,IAAI,mBAAS,CAAC,SAAS,CAAC,CACzB,CAAC,CAAC,CAAC,CACP,CAAC;AACJ,CAAC;AAhBD,sDAgBC"}
|
@@ -36,7 +36,7 @@ const mints = [
|
|
36
36
|
'KgV1GvrHQmRBY8sHQQeUKwTm2r2h8t4C8qt12Cw1HVE',
|
37
37
|
'11111111111111111111111111111111',
|
38
38
|
'7i5KKsX2weiTkry7jA4ZwSuXGhs5eJBEjY8vVxR4pfRx',
|
39
|
-
|
39
|
+
solana_1.usdcSolanaMint,
|
40
40
|
];
|
41
41
|
const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* () {
|
42
42
|
const client = (0, clients_1.getClientSolana)();
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"redeemFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/mango/redeemFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAQoC;AAGpC,2CAKqB;AACrB,iDAAsD;AACtD,+
|
1
|
+
{"version":3,"file":"redeemFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/mango/redeemFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAQoC;AAGpC,2CAKqB;AACrB,iDAAsD;AACtD,+CAA8E;AAC9E,uCAAyC;AACzC,qCAAqE;AACrE,6EAAqD;AACrD,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stakeProgramId: PublicKey;
|
4
|
-
export declare const
|
4
|
+
export declare const stakewizApi = "https://api.stakewiz.com/validators";
|
5
5
|
export declare const marinadeManagerAddresses: string[];
|
@@ -1,10 +1,10 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.marinadeManagerAddresses = exports.
|
3
|
+
exports.marinadeManagerAddresses = exports.stakewizApi = exports.stakeProgramId = exports.epochInfoCacheKey = void 0;
|
4
4
|
const web3_js_1 = require("@solana/web3.js");
|
5
5
|
exports.epochInfoCacheKey = 'epoch-info';
|
6
6
|
exports.stakeProgramId = new web3_js_1.PublicKey('Stake11111111111111111111111111111111111111');
|
7
|
-
exports.
|
7
|
+
exports.stakewizApi = 'https://api.stakewiz.com/validators';
|
8
8
|
exports.marinadeManagerAddresses = [
|
9
9
|
'stWirqFCf2Uts1JBL1Jsd3r6VBWhgnpdPxCTe1MFjrq',
|
10
10
|
'noMa7dN4cHQLV4ZonXrC29HTKFpxrpFbDLK5Gub8W8t',
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/native-stake/solana/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAE/B,QAAA,iBAAiB,GAAG,YAAY,CAAC;AACjC,QAAA,cAAc,GAAG,IAAI,mBAAS,CACzC,6CAA6C,CAC9C,CAAC;AACW,QAAA,
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/native-stake/solana/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAE/B,QAAA,iBAAiB,GAAG,YAAY,CAAC;AACjC,QAAA,cAAc,GAAG,IAAI,mBAAS,CACzC,6CAA6C,CAC9C,CAAC;AACW,QAAA,WAAW,GAAG,qCAAqC,CAAC;AACpD,QAAA,wBAAwB,GAAG;IACtC,6CAA6C;IAC7C,6CAA6C;IAC7C,6CAA6C;CAC9C,CAAC"}
|
@@ -95,7 +95,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
|
|
95
95
|
nativeAssets.push(Object.assign(Object.assign({}, (0, tokenPriceToAssetToken_1.default)(portfolio_core_1.solanaNetwork.native.address, amount, portfolio_core_1.NetworkId.solana, solTokenPrice, undefined, {
|
96
96
|
tags,
|
97
97
|
lockedUntil,
|
98
|
-
})), { name: validator === null || validator === void 0 ? void 0 : validator.name, imageUri: validator === null || validator === void 0 ? void 0 : validator.
|
98
|
+
})), { name: validator === null || validator === void 0 ? void 0 : validator.name, imageUri: validator === null || validator === void 0 ? void 0 : validator.imageUri }));
|
99
99
|
}
|
100
100
|
if (nativeAssets.length > 30) {
|
101
101
|
nativeAssets = [
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"solanaFetcher.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/native-stake/solana/solanaFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAMoC;AACpC,gEAAqC;AAIrC,4CAA8E;AAC9E,oDAAyD;AACzD,kDAAiE;AACjE,uCAAgD;AAChD,uCAA+C;AAC/C,wGAAgF;AAChF,wDAA4E;AAC5E,oDAAoE;AACpE,2CAIqB;AACrB,qEAAkE;AAElE,+DAA4D;AAE5D,MAAM,cAAc,GAAG,IAAI,6BAAa,CACtC,yBAAa,EACb;IACE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,EACD,CAAC,GAAG,EAAE,EAAE,CAAC,IAAA,uBAAU,EAAC,GAAG,IAAI,EAAE,EAAE,OAAO,CAAC,CACxC,CAAC;AAEF,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IACjC,MAAM,OAAO,GAAG,IAAA,6BAAmB,EAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC;IAEtD,M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,CAAC;YACN,IAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;QACtB,CAAC;QAED,MAAM,WAAW,GACf,YAAY,CAAC,MAAM,CAAC,aAAa,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,IAAI,SAAS,CAAC;QAExE,YAAY,CAAC,IAAI,iCACZ,IAAA,gCAAsB,EACvB,8BAAa,CAAC,MAAM,CAAC,OAAO,EAC5B,MAAM,EACN,0BAAS,CAAC,MAAM,EAChB,aAAa,EACb,SAAS,EACT;YACE,IAAI;YACJ,WAAW;SACZ,CACF,KACD,IAAI,EAAE,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,IAAI,EACrB,QAAQ,EAAE,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,
|
1
|
+
{"version":3,"file":"solanaFetcher.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/native-stake/solana/solanaFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAMoC;AACpC,gEAAqC;AAIrC,4CAA8E;AAC9E,oDAAyD;AACzD,kDAAiE;AACjE,uCAAgD;AAChD,uCAA+C;AAC/C,wGAAgF;AAChF,wDAA4E;AAC5E,oDAAoE;AACpE,2CAIqB;AACrB,qEAAkE;AAElE,+DAA4D;AAE5D,MAAM,cAAc,GAAG,IAAI,6BAAa,CACtC,yBAAa,EACb;IACE,MAAM,EAAE,sBAAU;IAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;CAC5B,EACD,CAAC,GAAG,EAAE,EAAE,CAAC,IAAA,uBAAU,EAAC,GAAG,IAAI,EAAE,EAAE,OAAO,CAAC,CACxC,CAAC;AAEF,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IACjC,MAAM,OAAO,GAAG,IAAA,6BAAmB,EAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC;IAEtD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 -8,50 +8,29 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
9
9
|
});
|
10
10
|
};
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
13
|
+
};
|
11
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
12
|
-
const explorer_kit_idls_1 = require("@solanafm/explorer-kit-idls");
|
13
15
|
const portfolio_core_1 = require("@sonarwatch/portfolio-core");
|
14
|
-
const
|
16
|
+
const axios_1 = __importDefault(require("axios"));
|
15
17
|
const constants_1 = require("../constants");
|
16
|
-
const solana_1 = require("../../../utils/solana");
|
17
18
|
const constants_2 = require("./constants");
|
18
19
|
const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
|
19
|
-
const
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
(0, solana_1.getAutoParsedProgramAccounts)(client, SFMIdlItem),
|
26
|
-
]);
|
27
|
-
const voters = [...current, ...delinquent];
|
28
|
-
const configsByVoter = new Map();
|
29
|
-
configs.forEach((c) => {
|
30
|
-
if (!c.info)
|
31
|
-
return;
|
32
|
-
try {
|
33
|
-
const info = JSON.parse(c.info);
|
34
|
-
const voter = c.configKeys.keysTuple[1][0];
|
35
|
-
configsByVoter.set(voter, {
|
36
|
-
voter,
|
37
|
-
name: info.name,
|
38
|
-
iconUrl: info.iconUrl,
|
39
|
-
});
|
40
|
-
}
|
41
|
-
catch (err) {
|
42
|
-
/* empty */
|
43
|
-
}
|
44
|
-
});
|
45
|
-
const validators = [];
|
46
|
-
voters.forEach((voteAcc) => {
|
47
|
-
const config = configsByVoter.get(voteAcc.nodePubkey.toString());
|
48
|
-
validators.push({
|
49
|
-
voter: voteAcc.votePubkey.toString(),
|
50
|
-
commission: voteAcc.commission,
|
51
|
-
name: config === null || config === void 0 ? void 0 : config.name,
|
52
|
-
iconUrl: config === null || config === void 0 ? void 0 : config.iconUrl,
|
53
|
-
});
|
20
|
+
const res = yield axios_1.default
|
21
|
+
.get(constants_2.stakewizApi, {
|
22
|
+
timeout: 2000,
|
23
|
+
})
|
24
|
+
.catch((err) => {
|
25
|
+
throw Error(`STAKEWIZ_API ERR: ${err}`);
|
54
26
|
});
|
27
|
+
if (!res.data)
|
28
|
+
throw Error(`STAKEWIZ_API NO DATA`);
|
29
|
+
const validators = res.data.map((r) => ({
|
30
|
+
voter: r.vote_identity,
|
31
|
+
name: r.name,
|
32
|
+
imageUri: r.image,
|
33
|
+
}));
|
55
34
|
yield cache.setItem(constants_1.validatorsKey, validators, {
|
56
35
|
prefix: constants_1.platformId,
|
57
36
|
networkId: portfolio_core_1.NetworkId.solana,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"solanaValidatorsJob.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/native-stake/solana/solanaValidatorsJob.ts"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"solanaValidatorsJob.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/native-stake/solana/solanaValidatorsJob.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAAuD;AACvD,kDAA6C;AAG7C,4CAAyD;AACzD,2CAA0C;AAG1C,MAAM,QAAQ,GAAgB,CAAO,KAAY,EAAE,EAAE;IACnD,MAAM,GAAG,GAAG,MAAM,eAAK;SACpB,GAAG,CAAgD,uBAAW,EAAE;QAC/D,OAAO,EAAE,IAAI;KACd,CAAC;SACD,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE;QACb,MAAM,KAAK,CAAC,qBAAqB,GAAG,EAAE,CAAC,CAAC;IAC1C,CAAC,CAAC,CAAC;IAEL,IAAI,CAAC,GAAG,CAAC,IAAI;QAAE,MAAM,KAAK,CAAC,sBAAsB,CAAC,CAAC;IAEnD,MAAM,UAAU,GAAgB,GAAG,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC;QACnD,KAAK,EAAE,CAAC,CAAC,aAAa;QACtB,IAAI,EAAE,CAAC,CAAC,IAAI;QACZ,QAAQ,EAAE,CAAC,CAAC,KAAK;KAClB,CAAC,CAAC,CAAC;IAEJ,MAAM,KAAK,CAAC,OAAO,CAAC,yBAAa,EAAE,UAAU,EAAE;QAC7C,MAAM,EAAE,sBAAU;QAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;KAC5B,CAAC,CAAC;AACL,CAAC,CAAA,CAAC;AAEF,MAAM,GAAG,GAAQ;IACf,EAAE,EAAE,GAAG,sBAAU,oBAAoB;IACrC,QAAQ;IACR,KAAK,EAAE,QAAQ;CAChB,CAAC;AACF,kBAAe,GAAG,CAAC"}
|
@@ -1,15 +1,11 @@
|
|
1
|
-
export type
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
info: string;
|
1
|
+
export type ValidatorsApiResponse = ValidatorApiResponse[];
|
2
|
+
export type ValidatorApiResponse = {
|
3
|
+
vote_identity: string;
|
4
|
+
name: string;
|
5
|
+
image: string;
|
7
6
|
};
|
8
|
-
export type
|
7
|
+
export type Validator = {
|
9
8
|
voter: string;
|
10
9
|
name?: string;
|
11
|
-
|
12
|
-
};
|
13
|
-
export type Validator = ValidatorConfig & {
|
14
|
-
commission?: number;
|
10
|
+
imageUri?: string;
|
15
11
|
};
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import { Platform } from '@sonarwatch/portfolio-core';
|
2
|
+
import { IdlItem } from '@solanafm/explorer-kit-idls';
|
3
|
+
import { PublicKey } from '@solana/web3.js';
|
4
|
+
export declare const platformId = "nxfinance";
|
5
|
+
export declare const platform: Platform;
|
6
|
+
export declare const ID: PublicKey;
|
7
|
+
export declare const leverageFiProgramID: PublicKey;
|
8
|
+
export declare const nxfinanceLeverageIdlItem: IdlItem;
|
@@ -0,0 +1,22 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.nxfinanceLeverageIdlItem = exports.leverageFiProgramID = exports.ID = exports.platform = exports.platformId = void 0;
|
4
|
+
const web3_js_1 = require("@solana/web3.js");
|
5
|
+
const idl_1 = require("./idl");
|
6
|
+
exports.platformId = 'nxfinance';
|
7
|
+
exports.platform = {
|
8
|
+
id: exports.platformId,
|
9
|
+
name: 'NX Finance',
|
10
|
+
image: 'https://sonar.watch/img/platforms/nxfinance.webp',
|
11
|
+
website: 'https://nxfinance.io/',
|
12
|
+
twitter: 'https://twitter.com/NX_Finance',
|
13
|
+
defiLlamaId: 'nx-finance', // from https://defillama.com/docs/api
|
14
|
+
};
|
15
|
+
exports.ID = new web3_js_1.PublicKey('RaXcyfW8jK295UAU1XN2uLMTHnTWEaeCcNWLeDB4iD6');
|
16
|
+
exports.leverageFiProgramID = new web3_js_1.PublicKey('EHBN9YKtMmrZhj8JZqyBQRGqyyeHw5xUB1Q5eAHszuMt');
|
17
|
+
exports.nxfinanceLeverageIdlItem = {
|
18
|
+
programId: exports.leverageFiProgramID.toString(),
|
19
|
+
idl: idl_1.NxfinanceLeverageIDL,
|
20
|
+
idlType: 'anchor',
|
21
|
+
};
|
22
|
+
//# sourceMappingURL=constants.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/nxfinance/constants.ts"],"names":[],"mappings":";;;AAEA,6CAA4C;AAC5C,+BAA6C;AAEhC,QAAA,UAAU,GAAG,WAAW,CAAC;AACzB,QAAA,QAAQ,GAAa;IAChC,EAAE,EAAE,kBAAU;IACd,IAAI,EAAE,YAAY;IAClB,KAAK,EAAE,kDAAkD;IACzD,OAAO,EAAE,uBAAuB;IAChC,OAAO,EAAE,gCAAgC;IACzC,WAAW,EAAE,YAAY,EAAE,sCAAsC;CAClE,CAAC;AAEW,QAAA,EAAE,GAAG,IAAI,mBAAS,CAAC,6CAA6C,CAAC,CAAC;AAElE,QAAA,mBAAmB,GAAG,IAAI,mBAAS,CAC9C,8CAA8C,CAC/C,CAAC;AAEW,QAAA,wBAAwB,GAAG;IACtC,SAAS,EAAE,2BAAmB,CAAC,QAAQ,EAAE;IACzC,GAAG,EAAE,0BAAoB;IACzB,OAAO,EAAE,QAAQ;CACP,CAAC"}
|