@sonarwatch/portfolio-plugins 0.12.40 → 0.12.41
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +1863 -1859
- package/README.md +3 -3
- package/package.json +1 -1
- package/src/Cache.js +2 -7
- package/src/Cache.js.map +1 -1
- package/src/plugins/balancer/helpers/pools.js +21 -21
- package/src/plugins/bonkrewards/constants.js +1 -1
- package/src/plugins/bonkrewards/constants.js.map +1 -1
- package/src/plugins/cropper/constants.js +1 -1
- package/src/plugins/cropper/constants.js.map +1 -1
- package/src/plugins/flowx/constants.js +1 -1
- package/src/plugins/flowx/constants.js.map +1 -1
- package/src/plugins/kriya/constants.js +1 -1
- package/src/plugins/kriya/constants.js.map +1 -1
- package/src/plugins/meteora/dlmmHelper.js +17 -31
- package/src/plugins/meteora/dlmmHelper.js.map +1 -1
- package/src/plugins/meteora/dlmmPositionsFetcher.js +27 -5
- package/src/plugins/meteora/dlmmPositionsFetcher.js.map +1 -1
- package/src/plugins/meteora/poolsJob.js +3 -5
- package/src/plugins/meteora/poolsJob.js.map +1 -1
- package/src/plugins/phoenix/helpers/deserializeMarketData.js +5 -11
- package/src/plugins/phoenix/helpers/deserializeMarketData.js.map +1 -1
- package/src/plugins/sushiswap/helpers.js +24 -24
- package/src/plugins/uniswap-v2/helpers.js +22 -22
- package/src/plugins/zeta/airdropFetcher.js +3 -2
- package/src/plugins/zeta/airdropFetcher.js.map +1 -1
- package/src/utils/misc/arrayToMap.js +2 -0
- package/src/utils/misc/arrayToMap.js.map +1 -1
- package/src/utils/misc/toBN.d.ts +3 -0
- package/src/utils/misc/toBN.js +22 -0
- package/src/utils/misc/toBN.js.map +1 -0
- package/src/utils/sei/constants.js +8 -8
- package/src/utils/sei/getQueryBalanceByOwner.js +4 -4
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"deserializeMarketData.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/phoenix/helpers/deserializeMarketData.ts"],"names":[],"mappings":";;;;;;AACA,kDAAuB;
|
1
|
+
{"version":3,"file":"deserializeMarketData.js","sourceRoot":"","sources":["../../../../../../../packages/plugins/src/plugins/phoenix/helpers/deserializeMarketData.ts"],"names":[],"mappings":";;;;;;AACA,kDAAuB;AACvB,6CAA4C;AAC5C,0CAOyB;AACzB,0DAGiC;AAEjC,mDAAgD;AAEhD,SAAS,cAAc,CACrB,IAAY,EACZ,eAAoC,EACpC,iBAAwC;IAExC,MAAM,QAAQ,GAAG,IAAI,GAAG,EAAe,CAAC;IACxC,MAAM,SAAS,GAAG,4BAA4B,CAC5C,IAAI,EACJ,eAAe,EACf,iBAAiB,CAClB,CAAC;IAEF,MAAM,KAAK,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC;IAC3B,MAAM,SAAS,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC;IAE/B,6DAA6D;IAC7D,KAAK,MAAM,CAAC,KAAK,EAAE,CAAC,GAAG,CAAC,CAAC,IAAI,KAAK,CAAC,OAAO,EAAE,EAAE,CAAC;QAC7C,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE,CAAC;YAC1B,QAAQ,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,GAAG,CAAC,CAAC,CAAC;QAC/B,CAAC;IACH,CAAC;IAED,OAAO,QAAQ,CAAC;AAClB,CAAC;AAED,SAAS,wBAAwB,CAAC,OAAgB;IAChD,MAAM,cAAc,GAAI,IAAA,WAAI,EAAC,OAAO,CAAC,mBAAmB,CAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;IAC9E,OAAO,cAAc,CAAC,KAAK,EAAE;QAC3B,CAAC,CAAC,cAAc,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,IAAI,eAAE,CAAC,CAAC,CAAC,CAAC;QACrC,CAAC,CAAC,cAAc,CAAC;AACrB,CAAC;AAED,SAAS,IAAI,CAAC,CAAK;IACjB,IAAI,CAAC,CAAC,EAAE,CAAC,IAAI,eAAE,CAAC,CAAC,CAAC,CAAC,EAA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Q,CAAC,QAAQ,EAAE,CAAC;IACnE,MAAM,UAAU,GAAG,aAAa,CAAC,gBAAgB,CAAC,QAAQ,CAAC,QAAQ,EAAE,CAAC;IACtE,MAAM,QAAQ,GACZ,EAAE,GAAG,CAAC,EAAE,GAAG,kBAAW,CAAC,QAAQ,GAAG,uBAAgB,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC;IACzE,MAAM,QAAQ,GACZ,EAAE,GAAG,CAAC,EAAE,GAAG,kBAAW,CAAC,QAAQ,GAAG,uBAAgB,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC;IACzE,MAAM,WAAW,GAAG,EAAE,GAAG,CAAC,EAAE,GAAG,sBAAe,CAAC,QAAQ,CAAC,GAAG,UAAU,CAAC;IACtE,MAAM,MAAM,GAAG,iCAAkB,CAAC,QAAQ,GAAG,GAAG,GAAG,QAAQ,GAAG,QAAQ,CAAC;IACvE,MAAM,YAAY,GAAG,IAAI,CAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,WAAW,CAAC,CAAC;IAEjE,OAAO,6BAA6B,CAClC,YAAY,EACZ,IAAI,mBAAS,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,EAChC,sBAAe,CAChB,CAAC;AACJ,CAAC;AAtBD,wCAsBC"}
|
@@ -54,30 +54,30 @@ function sushiV3PairToUniV2(pair) {
|
|
54
54
|
}
|
55
55
|
function getV3PairsAddresses(url, length = 300) {
|
56
56
|
return __awaiter(this, void 0, void 0, function* () {
|
57
|
-
const query = (0, graphql_request_1.gql) `
|
58
|
-
{
|
59
|
-
pools(
|
60
|
-
orderBy: totalValueLockedUSD
|
61
|
-
first: ${length}
|
62
|
-
orderDirection: desc
|
63
|
-
where: { volumeUSD_not: "0", liquidity_not: "0" }
|
64
|
-
) {
|
65
|
-
id
|
66
|
-
token0Price
|
67
|
-
token1Price
|
68
|
-
liquidity
|
69
|
-
token0 {
|
70
|
-
id
|
71
|
-
totalSupply
|
72
|
-
decimals
|
73
|
-
}
|
74
|
-
token1 {
|
75
|
-
id
|
76
|
-
totalSupply
|
77
|
-
decimals
|
78
|
-
}
|
79
|
-
}
|
80
|
-
}
|
57
|
+
const query = (0, graphql_request_1.gql) `
|
58
|
+
{
|
59
|
+
pools(
|
60
|
+
orderBy: totalValueLockedUSD
|
61
|
+
first: ${length}
|
62
|
+
orderDirection: desc
|
63
|
+
where: { volumeUSD_not: "0", liquidity_not: "0" }
|
64
|
+
) {
|
65
|
+
id
|
66
|
+
token0Price
|
67
|
+
token1Price
|
68
|
+
liquidity
|
69
|
+
token0 {
|
70
|
+
id
|
71
|
+
totalSupply
|
72
|
+
decimals
|
73
|
+
}
|
74
|
+
token1 {
|
75
|
+
id
|
76
|
+
totalSupply
|
77
|
+
decimals
|
78
|
+
}
|
79
|
+
}
|
80
|
+
}
|
81
81
|
`;
|
82
82
|
const res = yield (0, graphql_request_1.default)(url, query);
|
83
83
|
const pools = res.pools;
|
@@ -40,28 +40,28 @@ function getPairKey(version) {
|
|
40
40
|
exports.getPairKey = getPairKey;
|
41
41
|
function getPairsV2FromTheGraph(url, length = 300) {
|
42
42
|
return __awaiter(this, void 0, void 0, function* () {
|
43
|
-
const query = (0, graphql_request_1.gql) `
|
44
|
-
{
|
45
|
-
pairs(
|
46
|
-
orderBy: reserveUSD
|
47
|
-
first: ${length}
|
48
|
-
orderDirection: desc
|
49
|
-
where: { trackedReserveETH_not: "0" }
|
50
|
-
) {
|
51
|
-
id
|
52
|
-
reserve0
|
53
|
-
reserve1
|
54
|
-
totalSupply
|
55
|
-
token0 {
|
56
|
-
id
|
57
|
-
decimals
|
58
|
-
}
|
59
|
-
token1 {
|
60
|
-
id
|
61
|
-
decimals
|
62
|
-
}
|
63
|
-
}
|
64
|
-
}
|
43
|
+
const query = (0, graphql_request_1.gql) `
|
44
|
+
{
|
45
|
+
pairs(
|
46
|
+
orderBy: reserveUSD
|
47
|
+
first: ${length}
|
48
|
+
orderDirection: desc
|
49
|
+
where: { trackedReserveETH_not: "0" }
|
50
|
+
) {
|
51
|
+
id
|
52
|
+
reserve0
|
53
|
+
reserve1
|
54
|
+
totalSupply
|
55
|
+
token0 {
|
56
|
+
id
|
57
|
+
decimals
|
58
|
+
}
|
59
|
+
token1 {
|
60
|
+
id
|
61
|
+
decimals
|
62
|
+
}
|
63
|
+
}
|
64
|
+
}
|
65
65
|
`;
|
66
66
|
const res = yield (0, graphql_request_1.default)(url, query);
|
67
67
|
const pairs = res.pairs;
|
@@ -70,10 +70,11 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
|
|
70
70
|
return [];
|
71
71
|
const tokenPrice = yield cache.getTokenPrice(constants_1.zexMint, networkId);
|
72
72
|
const asset = tokenPrice
|
73
|
-
? (0, tokenPriceToAssetToken_1.default)(tokenPrice.address, amount, networkId, tokenPrice)
|
73
|
+
? (0, tokenPriceToAssetToken_1.default)(tokenPrice.address, amount, networkId, tokenPrice, undefined, { lockedUntil: 1719475200000 })
|
74
74
|
: {
|
75
75
|
type: 'generic',
|
76
76
|
data: {
|
77
|
+
address: constants_1.zexMint,
|
77
78
|
imageUri: 'https://statics.solscan.io/cdn/imgs/s60?ref=68747470733a2f2f7261772e67697468756275736572636f6e74656e742e636f6d2f7a6574616d61726b6574732f6272616e642f6d61737465722f6173736574732f7a6574612e706e67',
|
78
79
|
amount,
|
79
80
|
price: null,
|
@@ -81,7 +82,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
|
|
81
82
|
},
|
82
83
|
value: null,
|
83
84
|
networkId,
|
84
|
-
attributes: {},
|
85
|
+
attributes: { lockedUntil: 1719475200000 },
|
85
86
|
};
|
86
87
|
return [
|
87
88
|
{
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"airdropFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/zeta/airdropFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+DAAuE;AACvE,mEAA+C;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T,CAAC;AAEF,kBAAe,OAAO,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"arrayToMap.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/misc/arrayToMap.ts"],"names":[],"mappings":";;;AAAO,MAAM,UAAU,GAAG,CACxB,KAAU,EACV,QAAiB,EACD,EAAE;IAClB,MAAM,GAAG,GAAG,IAAI,GAAG,EAAa,CAAC;IACjC,KAAK,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,EAAE;QACrB,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAW,EAAE,IAAI,CAAC,CAAC;IAC1C,CAAC,CAAC,CAAC;IACH,OAAO,GAAG,CAAC;AACb,CAAC,CAAC;
|
1
|
+
{"version":3,"file":"arrayToMap.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/misc/arrayToMap.ts"],"names":[],"mappings":";;;AAAO,MAAM,UAAU,GAAG,CACxB,KAAU,EACV,QAAiB,EACD,EAAE;IAClB,MAAM,GAAG,GAAG,IAAI,GAAG,EAAa,CAAC;IACjC,KAAK,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,EAAE;QACrB,IAAI,CAAC,IAAI;YAAE,OAAO;QAClB,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAW,EAAE,IAAI,CAAC,CAAC;IAC1C,CAAC,CAAC,CAAC;IACH,OAAO,GAAG,CAAC;AACb,CAAC,CAAC;AAVW,QAAA,UAAU,cAUrB"}
|
@@ -0,0 +1,22 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
+
};
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
+
exports.toBN = void 0;
|
7
|
+
const bn_js_1 = __importDefault(require("bn.js"));
|
8
|
+
const bignumber_js_1 = __importDefault(require("bignumber.js"));
|
9
|
+
const toBN = (n) => {
|
10
|
+
if (typeof n === 'number') {
|
11
|
+
return new bn_js_1.default(n);
|
12
|
+
}
|
13
|
+
if (n instanceof bn_js_1.default) {
|
14
|
+
return n;
|
15
|
+
}
|
16
|
+
if (n instanceof bignumber_js_1.default) {
|
17
|
+
return new bn_js_1.default(n.toFixed(0)); // Convert BigNumber to a string without decimals
|
18
|
+
}
|
19
|
+
throw new Error('Unsupported type for conversion to BN');
|
20
|
+
};
|
21
|
+
exports.toBN = toBN;
|
22
|
+
//# sourceMappingURL=toBN.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"toBN.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/misc/toBN.ts"],"names":[],"mappings":";;;;;;AAAA,kDAAuB;AACvB,gEAAqC;AAE9B,MAAM,IAAI,GAAG,CAAC,CAA0B,EAAM,EAAE;IACrD,IAAI,OAAO,CAAC,KAAK,QAAQ,EAAE,CAAC;QAC1B,OAAO,IAAI,eAAE,CAAC,CAAC,CAAC,CAAC;IACnB,CAAC;IACD,IAAI,CAAC,YAAY,eAAE,EAAE,CAAC;QACpB,OAAO,CAAC,CAAC;IACX,CAAC;IACD,IAAI,CAAC,YAAY,sBAAS,EAAE,CAAC;QAC3B,OAAO,IAAI,eAAE,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,iDAAiD;IAChF,CAAC;IACD,MAAM,IAAI,KAAK,CAAC,uCAAuC,CAAC,CAAC;AAC3D,CAAC,CAAC;AAXW,QAAA,IAAI,QAWf"}
|
@@ -1,16 +1,16 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
exports.poolQueryMsg = exports.minterQueryMsg = exports.tokenInfoQueryMsg = exports.infoQueryMsg = void 0;
|
4
|
-
exports.infoQueryMsg = JSON.parse(`{
|
5
|
-
"info": {}
|
4
|
+
exports.infoQueryMsg = JSON.parse(`{
|
5
|
+
"info": {}
|
6
6
|
}`);
|
7
|
-
exports.tokenInfoQueryMsg = JSON.parse(`{
|
8
|
-
"token_info": {}
|
7
|
+
exports.tokenInfoQueryMsg = JSON.parse(`{
|
8
|
+
"token_info": {}
|
9
9
|
}`);
|
10
|
-
exports.minterQueryMsg = JSON.parse(`{
|
11
|
-
"minter": {}
|
10
|
+
exports.minterQueryMsg = JSON.parse(`{
|
11
|
+
"minter": {}
|
12
12
|
}`);
|
13
|
-
exports.poolQueryMsg = JSON.parse(`{
|
14
|
-
"pool": {}
|
13
|
+
exports.poolQueryMsg = JSON.parse(`{
|
14
|
+
"pool": {}
|
15
15
|
}`);
|
16
16
|
//# sourceMappingURL=constants.js.map
|
@@ -1,10 +1,10 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
function getQueryBalanceByOwner(owner) {
|
4
|
-
return JSON.parse(`{
|
5
|
-
"balance": {
|
6
|
-
"address": "${owner}"
|
7
|
-
}
|
4
|
+
return JSON.parse(`{
|
5
|
+
"balance": {
|
6
|
+
"address": "${owner}"
|
7
|
+
}
|
8
8
|
}`);
|
9
9
|
}
|
10
10
|
exports.default = getQueryBalanceByOwner;
|