@sonarwatch/portfolio-plugins 0.14.128 → 0.14.129

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 (190) hide show
  1. package/CHANGELOG.md +2124 -2120
  2. package/README.md +3 -3
  3. package/package.json +1 -1
  4. package/src/index.js +5 -0
  5. package/src/index.js.map +1 -1
  6. package/src/plugins/adrena/positionsFetcher.js +1 -0
  7. package/src/plugins/adrena/positionsFetcher.js.map +1 -1
  8. package/src/plugins/allbridge/positionsFetcher.js +9 -1
  9. package/src/plugins/allbridge/positionsFetcher.js.map +1 -1
  10. package/src/plugins/armada-staking/stakingFetcher.js +4 -1
  11. package/src/plugins/armada-staking/stakingFetcher.js.map +1 -1
  12. package/src/plugins/aurory/stakingFetcher.js +5 -1
  13. package/src/plugins/aurory/stakingFetcher.js.map +1 -1
  14. package/src/plugins/balancer/helpers/pools.js +21 -21
  15. package/src/plugins/bonfida/offersFetcher.js +30 -37
  16. package/src/plugins/bonfida/offersFetcher.js.map +1 -1
  17. package/src/plugins/bonkrewards/positionFetcher.js +16 -22
  18. package/src/plugins/bonkrewards/positionFetcher.js.map +1 -1
  19. package/src/plugins/cyberfrogs/thorDepositFetcher.js +2 -0
  20. package/src/plugins/cyberfrogs/thorDepositFetcher.js.map +1 -1
  21. package/src/plugins/daos/realmsDepositsFetcher.js +29 -43
  22. package/src/plugins/daos/realmsDepositsFetcher.js.map +1 -1
  23. package/src/plugins/debridge/dlmmVaultsFetcher.js +16 -10
  24. package/src/plugins/debridge/dlmmVaultsFetcher.js.map +1 -1
  25. package/src/plugins/defiland/stakingFetcher.js +8 -1
  26. package/src/plugins/defiland/stakingFetcher.js.map +1 -1
  27. package/src/plugins/defituna/lendingFetcher.js +3 -0
  28. package/src/plugins/defituna/lendingFetcher.js.map +1 -1
  29. package/src/plugins/defituna/positionsFetcher.js +7 -1
  30. package/src/plugins/defituna/positionsFetcher.js.map +1 -1
  31. package/src/plugins/defituna/structs.d.ts +1 -0
  32. package/src/plugins/defituna/structs.js.map +1 -1
  33. package/src/plugins/divvy/constants.d.ts +1 -0
  34. package/src/plugins/divvy/constants.js +2 -1
  35. package/src/plugins/divvy/constants.js.map +1 -1
  36. package/src/plugins/divvy/housePoolFetcher.js +3 -0
  37. package/src/plugins/divvy/housePoolFetcher.js.map +1 -1
  38. package/src/plugins/divvy/stakingFetcher.js +3 -1
  39. package/src/plugins/divvy/stakingFetcher.js.map +1 -1
  40. package/src/plugins/drift/depositsFetcher.js +15 -0
  41. package/src/plugins/drift/depositsFetcher.js.map +1 -1
  42. package/src/plugins/drift-market-maker-vault/depositsFetcher.js +2 -1
  43. package/src/plugins/drift-market-maker-vault/depositsFetcher.js.map +1 -1
  44. package/src/plugins/elemental/depositFetcher.js +3 -0
  45. package/src/plugins/elemental/depositFetcher.js.map +1 -1
  46. package/src/plugins/ensofi/solanaLoansFetcher.js +6 -0
  47. package/src/plugins/ensofi/solanaLoansFetcher.js.map +1 -1
  48. package/src/plugins/exponent/liquidityFetcher.js +1 -0
  49. package/src/plugins/exponent/liquidityFetcher.js.map +1 -1
  50. package/src/plugins/exponent/tradeFetcher.js +1 -0
  51. package/src/plugins/exponent/tradeFetcher.js.map +1 -1
  52. package/src/plugins/famousfoxfederation/stakingFetcher.js +18 -22
  53. package/src/plugins/famousfoxfederation/stakingFetcher.js.map +1 -1
  54. package/src/plugins/flash/perpetualFetcher.js +1 -1
  55. package/src/plugins/flash/perpetualFetcher.js.map +1 -1
  56. package/src/plugins/fragmetric/pricingJob.js +6 -0
  57. package/src/plugins/fragmetric/pricingJob.js.map +1 -1
  58. package/src/plugins/francium/lendingFetcher.js +1 -0
  59. package/src/plugins/francium/lendingFetcher.js.map +1 -1
  60. package/src/plugins/futarchy/daosJob.js +9 -0
  61. package/src/plugins/futarchy/daosJob.js.map +1 -1
  62. package/src/plugins/genesysgo/stakingFetcher.js +12 -25
  63. package/src/plugins/genesysgo/stakingFetcher.js.map +1 -1
  64. package/src/plugins/goosefx/stakingFetcher.js +18 -27
  65. package/src/plugins/goosefx/stakingFetcher.js.map +1 -1
  66. package/src/plugins/gpool/stakingFetcher.js +5 -1
  67. package/src/plugins/gpool/stakingFetcher.js.map +1 -1
  68. package/src/plugins/guano/constants.d.ts +8 -0
  69. package/src/plugins/guano/constants.js +15 -0
  70. package/src/plugins/guano/constants.js.map +1 -0
  71. package/src/plugins/guano/filters.d.ts +20 -0
  72. package/src/plugins/guano/filters.js +41 -0
  73. package/src/plugins/guano/filters.js.map +1 -0
  74. package/src/plugins/guano/index.d.ts +6 -0
  75. package/src/plugins/guano/index.js +10 -0
  76. package/src/plugins/guano/index.js.map +1 -0
  77. package/src/plugins/guano/stakingFetcher.d.ts +3 -0
  78. package/src/plugins/guano/stakingFetcher.js +70 -0
  79. package/src/plugins/guano/stakingFetcher.js.map +1 -0
  80. package/src/plugins/guano/structs.d.ts +34 -0
  81. package/src/plugins/guano/structs.js +33 -0
  82. package/src/plugins/guano/structs.js.map +1 -0
  83. package/src/plugins/guano/types.d.ts +15 -0
  84. package/src/plugins/guano/types.js +3 -0
  85. package/src/plugins/guano/types.js.map +1 -0
  86. package/src/plugins/hedgehog/ammJob.js +8 -0
  87. package/src/plugins/hedgehog/ammJob.js.map +1 -1
  88. package/src/plugins/hxro/stakingFetcher.js +2 -0
  89. package/src/plugins/hxro/stakingFetcher.js.map +1 -1
  90. package/src/plugins/iloop/depositsFetcher.js +8 -0
  91. package/src/plugins/iloop/depositsFetcher.js.map +1 -1
  92. package/src/plugins/jupiter/exchange/dcaFetcher.js +5 -1
  93. package/src/plugins/jupiter/exchange/dcaFetcher.js.map +1 -1
  94. package/src/plugins/jupiter/exchange/limitFetcher.js +2 -0
  95. package/src/plugins/jupiter/exchange/limitFetcher.js.map +1 -1
  96. package/src/plugins/jupiter/exchange/valueAverageFetcher.js +1 -0
  97. package/src/plugins/jupiter/exchange/valueAverageFetcher.js.map +1 -1
  98. package/src/plugins/kamino/lendsFetcher.js +6 -0
  99. package/src/plugins/kamino/lendsFetcher.js.map +1 -1
  100. package/src/plugins/kamino/ordersFetcher.js +2 -1
  101. package/src/plugins/kamino/ordersFetcher.js.map +1 -1
  102. package/src/plugins/layer3/stakingFetcher.js +1 -0
  103. package/src/plugins/layer3/stakingFetcher.js.map +1 -1
  104. package/src/plugins/lifinity/lockerFetcher.js +14 -17
  105. package/src/plugins/lifinity/lockerFetcher.js.map +1 -1
  106. package/src/plugins/loverflow/airdropClaimFetcher.js +1 -0
  107. package/src/plugins/loverflow/airdropClaimFetcher.js.map +1 -1
  108. package/src/plugins/magiceden/escrowFetcher.js +12 -18
  109. package/src/plugins/magiceden/escrowFetcher.js.map +1 -1
  110. package/src/plugins/marginfi/helpers.d.ts +2 -1
  111. package/src/plugins/marginfi/helpers.js +8 -2
  112. package/src/plugins/marginfi/helpers.js.map +1 -1
  113. package/src/plugins/marinade/ticketsFetcher.js +14 -31
  114. package/src/plugins/marinade/ticketsFetcher.js.map +1 -1
  115. package/src/plugins/metaplex/resizableNftFetcher.js +1 -0
  116. package/src/plugins/metaplex/resizableNftFetcher.js.map +1 -1
  117. package/src/plugins/nxfinance/positionsFetcher.js +19 -2
  118. package/src/plugins/nxfinance/positionsFetcher.js.map +1 -1
  119. package/src/plugins/orca/getWhirlpoolPositions.js +10 -1
  120. package/src/plugins/orca/getWhirlpoolPositions.js.map +1 -1
  121. package/src/plugins/parcl/depositsFetcher.js +1 -1
  122. package/src/plugins/parcl/depositsFetcher.js.map +1 -1
  123. package/src/plugins/parcl/marginFetcher.js +1 -1
  124. package/src/plugins/parcl/marginFetcher.js.map +1 -1
  125. package/src/plugins/parcl/stakingFetcher.js +6 -3
  126. package/src/plugins/parcl/stakingFetcher.js.map +1 -1
  127. package/src/plugins/photofinish/stakingFetcher.js +6 -1
  128. package/src/plugins/photofinish/stakingFetcher.js.map +1 -1
  129. package/src/plugins/picasso/unstakingPositionsFetcher.js +3 -2
  130. package/src/plugins/picasso/unstakingPositionsFetcher.js.map +1 -1
  131. package/src/plugins/quarry/calculatePositions.js +7 -1
  132. package/src/plugins/quarry/calculatePositions.js.map +1 -1
  133. package/src/plugins/quarry/positionsFetcher.js +2 -0
  134. package/src/plugins/quarry/positionsFetcher.js.map +1 -1
  135. package/src/plugins/quarry/types.d.ts +3 -0
  136. package/src/plugins/ratex/positionsFetcher.js +2 -0
  137. package/src/plugins/ratex/positionsFetcher.js.map +1 -1
  138. package/src/plugins/saber/lpTokensJob.js +1 -0
  139. package/src/plugins/saber/lpTokensJob.js.map +1 -1
  140. package/src/plugins/sandglass/depositFetcher.js +3 -0
  141. package/src/plugins/sandglass/depositFetcher.js.map +1 -1
  142. package/src/plugins/sharky/loansFetcher.js +1 -0
  143. package/src/plugins/sharky/loansFetcher.js.map +1 -1
  144. package/src/plugins/solayer/airdropFetcher.d.ts +3 -0
  145. package/src/plugins/solayer/airdropFetcher.js +55 -0
  146. package/src/plugins/solayer/airdropFetcher.js.map +1 -0
  147. package/src/plugins/solayer/constants.d.ts +5 -0
  148. package/src/plugins/solayer/constants.js +13 -1
  149. package/src/plugins/solayer/constants.js.map +1 -1
  150. package/src/plugins/solayer/index.d.ts +2 -0
  151. package/src/plugins/solayer/index.js +4 -2
  152. package/src/plugins/solayer/index.js.map +1 -1
  153. package/src/plugins/solayer/proofsFetcher.js +7 -6
  154. package/src/plugins/solayer/proofsFetcher.js.map +1 -1
  155. package/src/plugins/solayer/types.d.ts +8 -0
  156. package/src/plugins/solayer/types.js +3 -0
  157. package/src/plugins/solayer/types.js.map +1 -0
  158. package/src/plugins/spdr/stakingFetcher.js +3 -0
  159. package/src/plugins/spdr/stakingFetcher.js.map +1 -1
  160. package/src/plugins/stabble/poolsJob.js +1 -0
  161. package/src/plugins/stabble/poolsJob.js.map +1 -1
  162. package/src/plugins/staratlas/lockersFetcher.js +2 -0
  163. package/src/plugins/staratlas/lockersFetcher.js.map +1 -1
  164. package/src/plugins/staratlas/stakingFetcher.js +2 -1
  165. package/src/plugins/staratlas/stakingFetcher.js.map +1 -1
  166. package/src/plugins/streamflow/vestingFetcher.js +1 -1
  167. package/src/plugins/streamflow/vestingFetcher.js.map +1 -1
  168. package/src/plugins/sushiswap/helpers.js +24 -24
  169. package/src/plugins/tensor/bidsFetcher.js +1 -1
  170. package/src/plugins/tensor/bidsFetcher.js.map +1 -1
  171. package/src/plugins/texture/loansFetcher.js +2 -1
  172. package/src/plugins/texture/loansFetcher.js.map +1 -1
  173. package/src/plugins/tulip/depositsFetcher.js +3 -1
  174. package/src/plugins/tulip/depositsFetcher.js.map +1 -1
  175. package/src/plugins/uniswap-v2/helpers.js +22 -22
  176. package/src/plugins/uxd/stakingFetcher.js +4 -3
  177. package/src/plugins/uxd/stakingFetcher.js.map +1 -1
  178. package/src/plugins/vaultka/lendingFetcher.js +5 -0
  179. package/src/plugins/vaultka/lendingFetcher.js.map +1 -1
  180. package/src/plugins/vaultka/strategyFetcher.js +3 -0
  181. package/src/plugins/vaultka/strategyFetcher.js.map +1 -1
  182. package/src/plugins/whalesmarket/depositFetcher.js +7 -5
  183. package/src/plugins/whalesmarket/depositFetcher.js.map +1 -1
  184. package/src/plugins/zelo/positionsFetcher.js +2 -0
  185. package/src/plugins/zelo/positionsFetcher.js.map +1 -1
  186. package/src/plugins/zeta/airdropFetcher.js +14 -14
  187. package/src/plugins/zeta/depositsFetcher.js +5 -1
  188. package/src/plugins/zeta/depositsFetcher.js.map +1 -1
  189. package/src/utils/sei/constants.js +8 -8
  190. package/src/utils/sei/getQueryBalanceByOwner.js +4 -4
@@ -8,16 +8,13 @@ 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
- };
14
11
  Object.defineProperty(exports, "__esModule", { value: true });
15
12
  const portfolio_core_1 = require("@sonarwatch/portfolio-core");
16
13
  const constants_1 = require("./constants");
17
14
  const clients_1 = require("../../utils/clients");
18
15
  const solana_1 = require("../../utils/solana");
19
- const tokenPriceToAssetToken_1 = __importDefault(require("../../utils/misc/tokenPriceToAssetToken"));
20
16
  const helpers_1 = require("./helpers");
17
+ const ElementRegistry_1 = require("../../utils/elementbuilder/ElementRegistry");
21
18
  const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* () {
22
19
  const connection = (0, clients_1.getClientSolana)();
23
20
  const [accounts] = yield Promise.all([
@@ -41,25 +38,24 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
41
38
  ]);
42
39
  if (!tokenPrice || !configAccount)
43
40
  return [];
44
- const earnings = accounts.reduce((sum, stakingAccount) => {
45
- const earningForThisOne = (0, helpers_1.calcEarnings)(stakingAccount, configAccount);
46
- return earningForThisOne !== null ? sum + earningForThisOne : sum;
47
- }, 0);
48
- if (earnings === 0)
49
- return [];
50
- const asset = (0, tokenPriceToAssetToken_1.default)(constants_1.foxyMint, earnings, portfolio_core_1.NetworkId.solana, tokenPrice, undefined, { isClaimable: true });
51
- return [
52
- {
53
- type: portfolio_core_1.PortfolioElementType.multiple,
54
- networkId: portfolio_core_1.NetworkId.solana,
55
- platformId: constants_1.platformId,
56
- label: 'Rewards',
57
- value: asset.value,
58
- data: {
59
- assets: [asset],
41
+ const registry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
42
+ const element = registry.addElementMultiple({
43
+ label: 'Staked',
44
+ link: 'https://famousfoxes.com/stake',
45
+ });
46
+ accounts.forEach((stakingAccount) => {
47
+ const amount = (0, helpers_1.calcEarnings)(stakingAccount, configAccount);
48
+ element.addAsset({
49
+ address: constants_1.foxyMint,
50
+ amount,
51
+ alreadyShifted: true,
52
+ ref: stakingAccount.pubkey.toString(),
53
+ attributes: {
54
+ isClaimable: true,
60
55
  },
61
- },
62
- ];
56
+ });
57
+ });
58
+ return registry.getElements(cache);
63
59
  });
64
60
  const fetcher = {
65
61
  id: `${constants_1.platformId}-staking`,
@@ -1 +1 @@
1
- {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/famousfoxfederation/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAIoC;AAEpC,2CAMqB;AAErB,iDAAsD;AACtD,+CAAkE;AAElE,qGAA6E;AAC7E,uCAAyC;AAEzC,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,UAAU,GAAG,IAAA,yBAAe,GAAE,CAAC;IAErC,MAAM,CAAC,QAAQ,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACnC,IAAA,qCAA4B,EAAiB,UAAU,EAAE,0BAAc,EAAE;YACvE;gBACE,MAAM,EAAE;oBACN,KAAK,EAAE,KAAK;oBACZ,MAAM,EAAE,EAAE;iBACX;aACF;SACF,CAAC;KACH,CAAC,CAAC;IAEH,IAAI,CAAC,QAAQ,CAAC,MAAM;QAAE,OAAO,EAAE,CAAC;IAEhC,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACpD,KAAK,CAAC,aAAa,CACjB,IAAA,mCAAkB,EAAC,oBAAQ,EAAE,0BAAS,CAAC,MAAM,CAAC,EAC9C,0BAAS,CAAC,MAAM,CACjB;QACD,KAAK,CAAC,OAAO,CAAgB,iCAAqB,EAAE;YAClD,MAAM,EAAE,uBAAW;YACnB,SAAS,EAAE,0BAAS,CAAC,MAAM;SAC5B,CAAC;KACH,CAAC,CAAC;IAEH,IAAI,CAAC,UAAU,IAAI,CAAC,aAAa;QAAE,OAAO,EAAE,CAAC;IAE7C,MAAM,QAAQ,GAAG,QAAQ,CAAC,MAAM,CAAC,CAAC,GAAW,EAAE,cAAc,EAAE,EAAE;QAC/D,MAAM,iBAAiB,GAAG,IAAA,sBAAY,EAAC,cAAc,EAAE,aAAa,CAAC,CAAC;QACtE,OAAO,iBAAiB,KAAK,IAAI,CAAC,CAAC,CAAC,GAAG,GAAG,iBAAiB,CAAC,CAAC,CAAC,GAAG,CAAC;IACpE,CAAC,EAAE,CAAC,CAAC,CAAC;IAEN,IAAI,QAAQ,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAE9B,MAAM,KAAK,GAAG,IAAA,gCAAsB,EAClC,oBAAQ,EACR,QAAQ,EACR,0BAAS,CAAC,MAAM,EAChB,UAAU,EACV,SAAS,EACT,EAAE,WAAW,EAAE,IAAI,EAAE,CACtB,CAAC;IAEF,OAAO;QACL;YACE,IAAI,EAAE,qCAAoB,CAAC,QAAQ;YACnC,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,UAAU,EAAV,sBAAU;YACV,KAAK,EAAE,SAAS;YAChB,KAAK,EAAE,KAAK,CAAC,KAAK;YAClB,IAAI,EAAE;gBACJ,MAAM,EAAE,CAAC,KAAK,CAAC;aAChB;SACF;KACF,CAAC;AACJ,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/famousfoxfederation/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAA2E;AAE3E,2CAMqB;AAErB,iDAAsD;AACtD,+CAAkE;AAElE,uCAAyC;AACzC,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,UAAU,GAAG,IAAA,yBAAe,GAAE,CAAC;IAErC,MAAM,CAAC,QAAQ,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACnC,IAAA,qCAA4B,EAAiB,UAAU,EAAE,0BAAc,EAAE;YACvE;gBACE,MAAM,EAAE;oBACN,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B,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -33,7 +33,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
33
33
  networkId: portfolio_core_1.NetworkId.solana,
34
34
  });
35
35
  if (!marketsInfos)
36
- return [];
36
+ throw new Error('No markets in cache.');
37
37
  const oraclesPubkeys = [];
38
38
  const MarketById = new Map();
39
39
  marketsInfos.forEach((market) => {
@@ -1 +1 @@
1
- {"version":3,"file":"perpetualFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/flash/perpetualFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAOoC;AACpC,gEAAqC;AACrC,6CAA4C;AAG5C,2CAA+D;AAC/D,iDAAsD;AACtD,+CAG4B;AAC5B,uCAAsD;AACtD,uCAA+D;AAE/D,yDAAmD;AAEnD,MAAM,SAAS,GAAG,IAAI,sBAAS,CAAC,SAAA,EAAE,EAAI,CAAC,CAAA,CAAC,CAAC;AACzC,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,mBAAmB,GAAG,MAAM,IAAA,iCAAwB,EACxD,MAAM,EACN,wBAAc,EACd,oBAAQ,EACR,IAAA,mCAAyB,EAAC,KAAK,CAAC,CACjC,CAAC;IACF,IACE,mBAAmB,CAAC,MAAM,KAAK,CAAC;QAChC,CAAC,mBAAmB,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;QAElE,OAAO,EAAE,CAAC;IAEZ,MAAM,YAAY,GAAG,MAAM,KAAK,CAAC,OAAO,CAAe,sBAAU,EAAE;QACjE,MAAM,EAAE,sBAAU;QAClB,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AAClB,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,aAAa;IAC9B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"perpetualFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/flash/perpetualFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAOoC;AACpC,gEAAqC;AACrC,6CAA4C;AAG5C,2CAA+D;AAC/D,iDAAsD;AACtD,+CAG4B;AAC5B,uCAAsD;AACtD,uCAA+D;AAE/D,yDAAmD;AAEnD,MAAM,SAAS,GAAG,IAAI,sBAAS,CAAC,SAAA,EAAE,EAAI,CAAC,CAAA,CAAC,CAAC;AACzC,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,mBAAmB,GAAG,MAAM,IAAA,iCAAwB,EACxD,MAAM,EACN,wBAAc,EACd,oBAAQ,EACR,IAAA,mCAAyB,EAAC,KAAK,CAAC,CACjC,CAAC;IACF,IACE,mBAAmB,CAAC,MAAM,KAAK,CAAC;QAChC,CAAC,mBAAmB,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;QAElE,OAAO,EAAE,CAAC;IAEZ,MAAM,YAAY,GAAG,MAAM,KAAK,CAAC,OAAO,CAAe,sBAAU,EAAE;QACjE,MAAM,EAAE,sBAAU;QAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;KAC5B,CAAC,CAAC;IACH,IAAI,CAAC,YAAY;QAAE,MAAM,IAAI,KAAK,CAAC,sBAAsB,CAAC,CAAC;IAE3D,MAAM,cAAc,GAAgB,EAAE,CAAC;IACvC,MAAM,UAAU,G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kBAAe,OAAO,CAAC"}
@@ -82,6 +82,8 @@ const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
82
82
  .toNumber(),
83
83
  timestamp: Date.now(),
84
84
  weight: 1,
85
+ link: 'https://app.fragmetric.xyz/restake/',
86
+ sourceRefs: [{ address: vault.reserveAccount, name: 'Vault' }],
85
87
  });
86
88
  }
87
89
  const fundsAccounts = yield (0, solana_1.getParsedProgramAccounts)(connection, structs_1.FundAccountStruct, constants_1.fragmetricPid, [{ memcmp: { offset: 0, bytes: '9GKzjVzZPww' } }]);
@@ -111,6 +113,10 @@ const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
111
113
  .toNumber(),
112
114
  timestamp: Date.now(),
113
115
  weight: 1,
116
+ link: 'https://app.fragmetric.xyz/wrap/',
117
+ sourceRefs: [
118
+ { address: fundAccount.wrap_account.toString(), name: 'Vault' },
119
+ ],
114
120
  });
115
121
  }
116
122
  yield cache.setTokenPriceSources(sources);
@@ -1 +1 @@
1
- {"version":3,"file":"pricingJob.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/fragmetric/pricingJob.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAIoC;AACpC,6CAA4C;AAC5C,gEAAqC;AAGrC,2CAAgE;AAChE,uCAAyE;AACzE,+CAI4B;AAC5B,iDAAsD;AACtD,kFAA+E;AAE/E,MAAM,QAAQ,GAAgB,CAAO,KAAY,EAAE,EAAE;IACnD,MAAM,UAAU,GAAG,IAAA,yBAAe,GAAE,CAAC;IAErC,MAAM,OAAO,GAAuB,EAAE,CAAC;IAEvC,KAAK,MAAM,KAAK,IAAI,kBAAM,EAAE,CAAC;QAC3B,IAAI,cAAc,CAAC;QACnB,IAAI,KAAK,CAAC,0BAA0B,EAAE,CAAC;YACrC,MAAM,cAAc,GAAG,MAAM,IAAA,2CAAoB,EAC/C,UAAU,EACV,mCAAyB,EACzB,IAAI,mBAAS,CAAC,KAAK,CAAC,0BAA0B,CAAC,CAChD,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AAsB,CAAA,CAAC,CAAC;QAEvD,MAAM,UAAU,GAAG,WAAW,CAAC,aAAa,CAAC,MAAM,CAAC,SAAS,CAC3D,SAAA,EAAE,EAAI,WAAW,CAAC,aAAa,CAAC,QAAQ,CAAA,CACzC,CAAC;QAEF,oDAAoD;QACpD,OAAO,CAAC,IAAI,CAAC;YACX,OAAO,EAAE,WAAW,CAAC,aAAa,CAAC,IAAI,CAAC,QAAQ,EAAE;YAClD,QAAQ,EAAE,WAAW,CAAC,aAAa,CAAC,QAAQ;YAC5C,EAAE,EAAE,sBAAU;YACd,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,UAAU,EAAE,uCAAsB;YAClC,KAAK,EAAE,UAAU;iBACd,SAAS,CAAC,kBAAkB,CAAC;iBAC7B,KAAK,CAAC,uBAAuB,CAAC,KAAK,CAAC;iBACpC,QAAQ,EAAE;YACb,SAAS,EAAE,IAAI,CAAC,GAAG,EAAE;YACrB,MAAM,EAAE,CAAC;YACT,IAAI,EAAE,kCAAkC;YACxC,UAAU,EAAE;gBACV,EAAE,OAAO,EAAE,WAAW,CAAC,YAAY,CAAC,QAAQ,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE;aAChE;SACF,CAAC,CAAC;IACL,CAAC;IAED,MAAM,KAAK,CAAC,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAC5C,CAAC,CAAA,CAAC;AAEF,MAAM,GAAG,GAAQ;IACf,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,QAAQ;IACR,MAAM,EAAE,CAAC,QAAQ,CAAC;CACnB,CAAC;AACF,kBAAe,GAAG,CAAC"}
@@ -57,6 +57,7 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
57
57
  const elementRegistry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
58
58
  const element = elementRegistry.addElementBorrowlend({
59
59
  label: 'Lending',
60
+ link: 'https://francium.io/app/lend',
60
61
  });
61
62
  assets.forEach((asset) => asset && element.addSuppliedAsset(asset));
62
63
  return elementRegistry.getElements(cache);
@@ -1 +1 @@
1
- {"version":3,"file":"lendingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/francium/lendingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAAuD;AACvD,6CAA4C;AAC5C,gEAAqC;AAErC,2CAA+D;AAE/D,iDAAsD;AACtD,uCAAyE;AACzE,qCAAkC;AAClC,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,CAAC,WAAW,EAAE,WAAW,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACnD,IAAA,+BAAqB,EAAC,MAAM,EAAE,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC;QACnD,IAAA,+BAAqB,EAAC,MAAM,EAAE,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC;KACpD,CAAC,CAAC;IAEH,IACE,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,MAAM,KAAK,CAAC;QACrC,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,MAAM,KAAK,CAAC;QAErC,OAAO,EAAE,CAAC;IAEZ,MAAM,gBAAgB,GAAG,MAAM,KAAK,CAAC,OAAO,CAO1C,gCAAoB,EAAE;QACtB,MAAM,EAAE,sBAAU;QAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;KAC5B,CAAC,CAAC;IAEH,IAAI,CAAC,gBAAgB;QAAE,OAAO,EAAE,CAAC;IAEjC,MAAM,MAAM,GAAG,gBAAgB;SAC5B,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE;;QACZ,IAAI,CAAC,eAAM,CAAC,IAAI,CAAC,IAAI,CAAC;YAAE,OAAO,IAAI,CAAC;QACpC,MAAM,cAAc,GAAG,CAAA,MAAA,WAAW,CAA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U;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"lendingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/francium/lendingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAAuD;AACvD,6CAA4C;AAC5C,gEAAqC;AAErC,2CAA+D;AAE/D,iDAAsD;AACtD,uCAAyE;AACzE,qCAAkC;AAClC,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,CAAC,WAAW,EAAE,WAAW,CAAC,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC;QACnD,IAAA,+BAAqB,EAAC,MAAM,EAAE,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC;QACnD,IAAA,+BAAqB,EAAC,MAAM,EAAE,IAAI,mBAAS,CAAC,KAAK,CAAC,CAAC;KACpD,CAAC,CAAC;IAEH,IACE,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,MAAM,KAAK,CAAC;QACrC,MAAM,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,MAAM,KAAK,CAAC;QAErC,OAAO,EAAE,CAAC;IAEZ,MAAM,gBAAgB,GAAG,MAAM,KAAK,CAAC,OAAO,CAO1C,gCAAoB,EAAE;QACtB,MAAM,EAAE,sBAAU;QAClB,SAAS,EAAE,0BAAS,CAAC,MAAM;KAC5B,CAAC,CAAC;IAEH,IAAI,CAAC,gBAAgB;QAAE,OAAO,EAAE,CAAC;IAEjC,MAAM,MAAM,GAAG,gBAAgB;SAC5B,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE;;QACZ,IAAI,CAAC,eAAM,CAAC,IAAI,CAAC,IAAI,CAAC;YAAE,OAAO,IAAI,CAAC;QACpC,MAAM,cAAc,GA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AAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -137,6 +137,10 @@ const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
137
137
  ],
138
138
  liquidityName: symbol ? `f${symbol}` : 'fUSD',
139
139
  elementName,
140
+ sourceRefs: [
141
+ { name: 'Pool', address: proposal.pubkey.toString() },
142
+ { name: 'Vault', address: proposal.quoteVault.toString() },
143
+ ],
140
144
  };
141
145
  const pUSDSource = {
142
146
  address: pUSDMint,
@@ -158,6 +162,10 @@ const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
158
162
  ],
159
163
  liquidityName: symbol ? `p${symbol}` : 'pUSD',
160
164
  elementName,
165
+ sourceRefs: [
166
+ { name: 'Pool', address: proposal.pubkey.toString() },
167
+ { name: 'Vault', address: proposal.quoteVault.toString() },
168
+ ],
161
169
  };
162
170
  // If the Proposal has passed, fUSD will not be redeemable (price = 0)
163
171
  if (proposal.state === structs_1.ProposalState.Passed) {
@@ -214,6 +222,7 @@ const executor = (cache) => __awaiter(void 0, void 0, void 0, function* () {
214
222
  underlyings: [Object.assign(Object.assign({}, baseUnderlyingTokenPrice), { amountPerLp: 1 })],
215
223
  liquidityName: baseLiquidityName,
216
224
  elementName,
225
+ sourceRefs: [{ name: 'Pool', address: amm.pubkey.toString() }],
217
226
  };
218
227
  // If it's the amm handling the Pass LP and the Proposal has failed, pToken will not be redeemable (price = 0)
219
228
  // If it's the amm handling the Fail LP and the Proposal has passed, fToken will not be redeemable (price = 0)
@@ -1 +1 @@
1
- {"version":3,"file":"daosJob.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/futarchy/daosJob.ts"],"names":[],"mappings":";;;;;;;;;;;AACA,+DAKoC;AAGpC,iDAAsD;AACtD,+CAQ4B;AAC5B,wDAA4D;AAC5D,2CAA8D;AAC9D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E,CAAC;gBACnB,+GAA+G;gBAC/G,+GAA+G;gBAC/G,IACE,CAAC,QAAQ,CAAC,KAAK,KAAK,uBAAa,CAAC,MAAM,IAAI,SAAS,CAAC;oBACtD,CAAC,QAAQ,CAAC,KAAK,KAAK,uBAAa,CAAC,MAAM,IAAI,CAAC,SAAS,CAAC;oBAEvD,QAAQ,CAAC,CAAC,CAAC,CAAC,KAAK,GAAG,CAAC,CAAC;YAC1B,CAAC;YACD,iBAAiB,CAAC,IAAI,CAAC,GAAG,QAAQ,EAAE,oBAAoB,CAAC,CAAC;QAC5D,CAAC;IACH,CAAC;IACD,MAAM,KAAK,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;AACtD,CAAC,CAAA,CAAC;AAEF,MAAM,GAAG,GAAQ;IACf,EAAE,EAAE,GAAG,sBAAU,OAAO;IACxB,QAAQ;IACR,MAAM,EAAE,CAAC,QAAQ,CAAC;CACnB,CAAC;AACF,kBAAe,GAAG,CAAC"}
@@ -8,9 +8,6 @@ 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
- };
14
11
  Object.defineProperty(exports, "__esModule", { value: true });
15
12
  const portfolio_core_1 = require("@sonarwatch/portfolio-core");
16
13
  const constants_1 = require("./constants");
@@ -18,35 +15,25 @@ const clients_1 = require("../../utils/clients");
18
15
  const solana_1 = require("../../utils/solana");
19
16
  const vaults_1 = require("../kamino/structs/vaults");
20
17
  const filters_1 = require("../kamino/filters");
21
- const tokenPriceToAssetTokens_1 = __importDefault(require("../../utils/misc/tokenPriceToAssetTokens"));
18
+ const ElementRegistry_1 = require("../../utils/elementbuilder/ElementRegistry");
22
19
  const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* () {
23
20
  const client = (0, clients_1.getClientSolana)();
24
21
  const userStateAccounts = yield (0, solana_1.getParsedProgramAccounts)(client, vaults_1.userStateStruct, constants_1.programId, (0, filters_1.userStateFilter)(owner));
25
22
  if (userStateAccounts.length === 0)
26
23
  return [];
27
- const tokenPrice = yield cache.getTokenPrice(constants_1.shadowMint, portfolio_core_1.NetworkId.solana);
28
- const assets = [];
24
+ const registry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
25
+ const element = registry.addElementMultiple({
26
+ label: 'Staked',
27
+ link: 'https://testnet.shdwdrive.com/',
28
+ });
29
29
  for (const userState of userStateAccounts) {
30
- if (userState.activeStakeScaled.isZero())
31
- continue;
32
- const amount = userState.activeStakeScaled
33
- .dividedBy(Math.pow(10, 18))
34
- .dividedBy(Math.pow(10, constants_1.shadowDecimals))
35
- .toNumber();
36
- assets.push(...(0, tokenPriceToAssetTokens_1.default)(constants_1.shadowMint, amount, portfolio_core_1.NetworkId.solana, tokenPrice));
30
+ element.addAsset({
31
+ address: constants_1.shadowMint,
32
+ amount: userState.activeStakeScaled.dividedBy(Math.pow(10, 18)),
33
+ ref: userState.pubkey,
34
+ });
37
35
  }
38
- if (assets.length === 0)
39
- return [];
40
- return [
41
- {
42
- type: portfolio_core_1.PortfolioElementType.multiple,
43
- label: 'Staked',
44
- networkId: portfolio_core_1.NetworkId.solana,
45
- platformId: constants_1.platformId,
46
- data: { assets },
47
- value: (0, portfolio_core_1.getUsdValueSum)(assets.map((asset) => asset.value)),
48
- },
49
- ];
36
+ return registry.getElements(cache);
50
37
  });
51
38
  const fetcher = {
52
39
  id: `${constants_1.platformId}-staking`,
@@ -1 +1 @@
1
- {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/genesysgo/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,+DAKoC;AAGpC,2CAAgF;AAChF,iDAAsD;AACtD,+CAA8D;AAC9D,qDAA2D;AAC3D,+CAAoD;AACpD,uGAA+E;AAE/E,M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C,CAAC;SAC1D;KACF,CAAC;AACJ,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/genesysgo/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAAuD;AAGvD,2CAAgE;AAChE,iDAAsD;AACtD,+CAA8D;AAC9D,qDAA2D;AAC3D,+CAAoD;AACpD,gFAA6E;AAE7E,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAAE,EAAE;IACtE,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;IAEjC,MAAM,iBAAiB,GAAG,MAAM,IAAA,iCAAwB,EACtD,MAAM,EACN,wBAAe,EACf,qBAAS,EACT,IAAA,yBAAe,EAAC,KAAK,CAAC,CACvB,CAAC;IACF,IAAI,iBAAiB,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAE9C,MAAM,QAAQ,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IACnE,MAAM,OAAO,GAAG,QAAQ,CAAC,kBAAkB,CAAC;QAC1C,KAAK,EAAE,QAAQ;QACf,IAAI,EAAE,gCAAgC;KACvC,CAAC,CAAC;IAEH,KAAK,MAAM,SAAS,IAAI,iBAAiB,EAAE,CAAC;QAC1C,OAAO,CAAC,QAAQ,CAAC;YACf,OAAO,EAAE,sBAAU;YACnB,MAAM,EAAE,SAAS,CAAC,iBAAiB,CAAC,SAAS,CAAC,SAAA,EAAE,EAAI,EAAE,CAAA,CAAC;YACvD,GAAG,EAAE,SAAS,CAAC,MAAM;SACtB,CAAC,CAAC;IACL,CAAC;IAED,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -8,9 +8,6 @@ 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
- };
14
11
  Object.defineProperty(exports, "__esModule", { value: true });
15
12
  exports.sevenDays = void 0;
16
13
  const portfolio_core_1 = require("@sonarwatch/portfolio-core");
@@ -19,7 +16,7 @@ const clients_1 = require("../../utils/clients");
19
16
  const solana_1 = require("../../utils/solana");
20
17
  const structs_1 = require("./structs");
21
18
  const filters_1 = require("./filters");
22
- const tokenPriceToAssetToken_1 = __importDefault(require("../../utils/misc/tokenPriceToAssetToken"));
19
+ const ElementRegistry_1 = require("../../utils/elementbuilder/ElementRegistry");
23
20
  exports.sevenDays = 7 * 1000 * 60 * 60 * 24;
24
21
  const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* () {
25
22
  const client = (0, clients_1.getClientSolana)();
@@ -27,38 +24,32 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
27
24
  if (accounts.length === 0 || accounts.length > 1)
28
25
  return [];
29
26
  const stakingAccount = accounts[0];
30
- const gofxTokenPrice = yield cache.getTokenPrice(constants_1.gofxMint, portfolio_core_1.NetworkId.solana);
31
- if (!gofxTokenPrice)
32
- return [];
33
- const { decimals } = gofxTokenPrice;
34
- const assets = [];
27
+ const registry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
28
+ const element = registry.addElementMultiple({
29
+ label: 'Staked',
30
+ link: 'https://app.goosefx.io',
31
+ ref: stakingAccount.pubkey.toString(),
32
+ });
35
33
  for (const ticket of stakingAccount.unstakingTickets) {
36
34
  if (ticket.totalUnstaked.isZero())
37
35
  continue;
38
36
  const unlockStartedAt = new Date(ticket.createdAt.times(1000).toNumber());
39
37
  const unlockingAt = new Date(unlockStartedAt.getTime() + exports.sevenDays);
40
- assets.push(Object.assign(Object.assign({}, (0, tokenPriceToAssetToken_1.default)(constants_1.gofxMint, ticket.totalUnstaked.dividedBy(Math.pow(10, decimals)).toNumber(), portfolio_core_1.NetworkId.solana, gofxTokenPrice)), { attributes: {
38
+ element.addAsset({
39
+ address: constants_1.gofxMint,
40
+ amount: ticket.totalUnstaked,
41
+ attributes: {
41
42
  lockedUntil: unlockingAt.getTime(),
42
- } }));
43
+ },
44
+ });
43
45
  }
44
46
  if (stakingAccount.totalStaked.isGreaterThan(0)) {
45
- const amount = stakingAccount.totalStaked
46
- .dividedBy(Math.pow(10, decimals))
47
- .toNumber();
48
- assets.push((0, tokenPriceToAssetToken_1.default)(constants_1.gofxMint, amount, portfolio_core_1.NetworkId.solana, gofxTokenPrice));
47
+ element.addAsset({
48
+ address: constants_1.gofxMint,
49
+ amount: stakingAccount.totalStaked,
50
+ });
49
51
  }
50
- if (assets.length === 0)
51
- return [];
52
- return [
53
- {
54
- type: portfolio_core_1.PortfolioElementType.multiple,
55
- label: 'Staked',
56
- networkId: portfolio_core_1.NetworkId.solana,
57
- platformId: constants_1.platformId,
58
- data: { assets },
59
- value: (0, portfolio_core_1.getUsdValueSum)(assets.map((asset) => asset.value)),
60
- },
61
- ];
52
+ return registry.getElements(cache);
62
53
  });
63
54
  const fetcher = {
64
55
  id: `${constants_1.platformId}-staking`,
@@ -1 +1 @@
1
- {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/goosefx/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,+DAKoC;AAGpC,2CAAoE;AACpE,iDAAsD;AACtD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AA,EAAE,EAAI,QAAQ,CAAA,CAAC,CAAC,QAAQ,EAAE,EACzD,0BAAS,CAAC,MAAM,EAChB,cAAc,CACf,KACD,UAAU,EAAE;gBACV,WAAW,EAAE,WAAW,CAAC,OAAO,EAAE;aACnC,IACD,CAAC;IACL,CAAC;IACD,IAAI,cAAc,CAAC,WAAW,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC;QAChD,MAAM,MAAM,GAAG,cAAc,CAAC,WAAW;aACtC,SAAS,CAAC,SAAA,EAAE,EAAI,QAAQ,CAAA,CAAC;aACzB,QAAQ,EAAE,CAAC;QACd,MAAM,CAAC,IAAI,CACT,IAAA,gCAAsB,EAAC,oBAAQ,EAAE,MAAM,EAAE,0BAAS,CAAC,MAAM,EAAE,cAAc,CAAC,CAC3E,CAAC;IACJ,CAAC;IAED,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEnC,OAAO;QACL;YACE,IAAI,EAAE,qCAAoB,CAAC,QAAQ;YACnC,KAAK,EAAE,QAAQ;YACf,SAAS,EAAE,0BAAS,CAAC,MAAM;YAC3B,UAAU,EAAV,sBAAU;YACV,IAAI,EAAE,EAAE,MAAM,EAAE;YAChB,KAAK,EAAE,IAAA,+BAAc,EAAC,MAAM,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;SAC1D;KACF,CAAC;AACJ,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
1
+ {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/goosefx/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAAuD;AAGvD,2CAAoE;AACpE,iDAAsD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,EAAE,MAAM,CAAC,aAAa;YAC5B,UAAU,EAAE;gBACV,WAAW,EAAE,WAAW,CAAC,OAAO,EAAE;aACnC;SACF,CAAC,CAAC;IACL,CAAC;IACD,IAAI,cAAc,CAAC,WAAW,CAAC,aAAa,CAAC,CAAC,CAAC,EAAE,CAAC;QAChD,OAAO,CAAC,QAAQ,CAAC;YACf,OAAO,EAAE,oBAAQ;YACjB,MAAM,EAAE,cAAc,CAAC,WAAW;SACnC,CAAC,CAAC;IACL,CAAC;IAED,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -29,11 +29,15 @@ const executor = (owner, cache) => __awaiter(void 0, void 0, void 0, function* (
29
29
  if (!lockupAccounts)
30
30
  return [];
31
31
  const registry = new ElementRegistry_1.ElementRegistry(portfolio_core_1.NetworkId.solana, constants_1.platformId);
32
- const element = registry.addElementMultiple({ label: 'Staked' });
32
+ const element = registry.addElementMultiple({
33
+ label: 'Staked',
34
+ link: 'https://stake.gpool.cloud/',
35
+ });
33
36
  for (const lockupAccount of lockupAccounts) {
34
37
  element.addAsset({
35
38
  address: lockupAccount.mint,
36
39
  amount: lockupAccount.balance,
40
+ ref: lockupAccount.pubkey,
37
41
  });
38
42
  }
39
43
  return registry.getElements(cache);
@@ -1 +1 @@
1
- {"version":3,"file":"stakingFetcher.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/gpool/stakingFetcher.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,+DAAuD;AAGvD,2CAAqD;AACrD,iDAAsD;AACtD,uCAA4C;AAC5C,gFAA6E;AAC7E,+CAA8D;AAE9D,MAAM,QAAQ,GAAoB,CAAO,KAAa,EAAE,KAAY,EAA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A,yBAAe,GAAE,CAAC;IAEjC,MAAM,cAAc,GAAG,MAAM,IAAA,iCAAwB,EACnD,MAAM,EACN,yBAAe,EACf,sBAAU,EACV;QACE,EAAE,QAAQ,EAAE,yBAAe,CAAC,QAAQ,EAAE;QACtC;YACE,MAAM,EAAE;gBACN,MAAM,EAAE,CAAC;gBACT,KAAK,EAAE,KAAK;aACb;SACF;KACF,CACF,CAAC;IACF,IAAI,CAAC,cAAc;QAAE,OAAO,EAAE,CAAC;IAE/B,MAAM,QAAQ,GAAG,IAAI,iCAAe,CAAC,0BAAS,CAAC,MAAM,EAAE,sBAAU,CAAC,CAAC;IACnE,MAAM,OAAO,GAAG,QAAQ,CAAC,kBAAkB,CAAC;QAC1C,KAAK,EAAE,QAAQ;QACf,IAAI,EAAE,4BAA4B;KACnC,CAAC,CAAC;IAEH,KAAK,MAAM,aAAa,IAAI,cAAc,EAAE,CAAC;QAC3C,OAAO,CAAC,QAAQ,CAAC;YACf,OAAO,EAAE,aAAa,CAAC,IAAI;YAC3B,MAAM,EAAE,aAAa,CAAC,OAAO;YAC7B,GAAG,EAAE,aAAa,CAAC,MAAM;SAC1B,CAAC,CAAC;IACL,CAAC;IACD,OAAO,QAAQ,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC,CAAA,CAAC;AAEF,MAAM,OAAO,GAAY;IACvB,EAAE,EAAE,GAAG,sBAAU,UAAU;IAC3B,SAAS,EAAE,0BAAS,CAAC,MAAM;IAC3B,QAAQ;CACT,CAAC;AAEF,kBAAe,OAAO,CAAC"}
@@ -0,0 +1,8 @@
1
+ /// <reference types="@drift-labs/sdk/node_modules/@solana/web3.js" />
2
+ /// <reference types="jito-ts/node_modules/@solana/web3.js" />
3
+ import { PublicKey } from '@solana/web3.js';
4
+ import { Platform } from '@sonarwatch/portfolio-core';
5
+ export declare const platformId = "guano";
6
+ export declare const platform: Platform;
7
+ export declare const stakingPid: PublicKey;
8
+ export declare const guanoMint = "APmLv2VarkC5yEjjutYkeK3byr9L2KwCgrVMWHWsgaG7";
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.guanoMint = exports.stakingPid = exports.platform = exports.platformId = void 0;
4
+ const web3_js_1 = require("@solana/web3.js");
5
+ exports.platformId = 'guano';
6
+ exports.platform = {
7
+ id: exports.platformId,
8
+ name: 'Guano',
9
+ image: 'https://sonar.watch/img/platforms/guano.webp',
10
+ website: 'https://www.guanocoin.com/',
11
+ twitter: 'https://x.com/guanocoin',
12
+ };
13
+ exports.stakingPid = new web3_js_1.PublicKey('CFjLE5589EiPZvPFiSx7QgktBH8ZTkkGJU2dL7qbJU2a');
14
+ exports.guanoMint = 'APmLv2VarkC5yEjjutYkeK3byr9L2KwCgrVMWHWsgaG7';
15
+ //# sourceMappingURL=constants.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/guano/constants.ts"],"names":[],"mappings":";;;AAAA,6CAA4C;AAG/B,QAAA,UAAU,GAAG,OAAO,CAAC;AACrB,QAAA,QAAQ,GAAa;IAChC,EAAE,EAAE,kBAAU;IACd,IAAI,EAAE,OAAO;IACb,KAAK,EAAE,8CAA8C;IACrD,OAAO,EAAE,4BAA4B;IACrC,OAAO,EAAE,yBAAyB;CACnC,CAAC;AAEW,QAAA,UAAU,GAAG,IAAI,mBAAS,CACrC,8CAA8C,CAC/C,CAAC;AACW,QAAA,SAAS,GAAG,8CAA8C,CAAC"}
@@ -0,0 +1,20 @@
1
+ export declare const stakeAccountFilters: (owner: string) => ({
2
+ memcmp: {
3
+ offset: number;
4
+ bytes: string;
5
+ };
6
+ dataSize?: undefined;
7
+ } | {
8
+ dataSize: number;
9
+ memcmp?: undefined;
10
+ })[];
11
+ export declare const unstakeAccountFilters: (owner: string) => ({
12
+ memcmp: {
13
+ offset: number;
14
+ bytes: string;
15
+ };
16
+ dataSize?: undefined;
17
+ } | {
18
+ dataSize: number;
19
+ memcmp?: undefined;
20
+ })[];
@@ -0,0 +1,41 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.unstakeAccountFilters = exports.stakeAccountFilters = void 0;
4
+ const structs_1 = require("./structs");
5
+ const stakeAccountFilters = (owner) => [
6
+ {
7
+ memcmp: {
8
+ offset: 16,
9
+ bytes: owner,
10
+ },
11
+ },
12
+ {
13
+ memcmp: {
14
+ offset: 0,
15
+ bytes: 'EV6feDfKSVt',
16
+ },
17
+ },
18
+ {
19
+ dataSize: structs_1.stakeStruct.byteSize,
20
+ },
21
+ ];
22
+ exports.stakeAccountFilters = stakeAccountFilters;
23
+ const unstakeAccountFilters = (owner) => [
24
+ {
25
+ memcmp: {
26
+ offset: 16,
27
+ bytes: owner,
28
+ },
29
+ },
30
+ {
31
+ memcmp: {
32
+ offset: 0,
33
+ bytes: '8fHY7z1kRxS',
34
+ },
35
+ },
36
+ {
37
+ dataSize: structs_1.unstakeStruct.byteSize,
38
+ },
39
+ ];
40
+ exports.unstakeAccountFilters = unstakeAccountFilters;
41
+ //# sourceMappingURL=filters.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"filters.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/guano/filters.ts"],"names":[],"mappings":";;;AAAA,uCAAuD;AAEhD,MAAM,mBAAmB,GAAG,CAAC,KAAa,EAAE,EAAE,CAAC;IACpD;QACE,MAAM,EAAE;YACN,MAAM,EAAE,EAAE;YACV,KAAK,EAAE,KAAK;SACb;KACF;IACD;QACE,MAAM,EAAE;YACN,MAAM,EAAE,CAAC;YACT,KAAK,EAAE,aAAa;SACrB;KACF;IACD;QACE,QAAQ,EAAE,qBAAW,CAAC,QAAQ;KAC/B;CACF,CAAC;AAhBW,QAAA,mBAAmB,uBAgB9B;AAEK,MAAM,qBAAqB,GAAG,CAAC,KAAa,EAAE,EAAE,CAAC;IACtD;QACE,MAAM,EAAE;YACN,MAAM,EAAE,EAAE;YACV,KAAK,EAAE,KAAK;SACb;KACF;IACD;QACE,MAAM,EAAE;YACN,MAAM,EAAE,CAAC;YACT,KAAK,EAAE,aAAa;SACrB;KACF;IACD;QACE,QAAQ,EAAE,uBAAa,CAAC,QAAQ;KACjC;CACF,CAAC;AAhBW,QAAA,qBAAqB,yBAgBhC"}
@@ -0,0 +1,6 @@
1
+ import { Platform } from '@sonarwatch/portfolio-core';
2
+ import { Fetcher } from '../../Fetcher';
3
+ import { Job } from '../../Job';
4
+ export declare const platforms: Platform[];
5
+ export declare const jobs: Job[];
6
+ export declare const fetchers: Fetcher[];
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.fetchers = exports.jobs = exports.platforms = void 0;
4
+ const constants_1 = require("./constants");
5
+ exports.platforms = [constants_1.platform];
6
+ exports.jobs = [];
7
+ exports.fetchers = [
8
+ // stakingFetcher
9
+ ];
10
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/plugins/guano/index.ts"],"names":[],"mappings":";;;AAGA,2CAAuC;AAG1B,QAAA,SAAS,GAAe,CAAC,oBAAQ,CAAC,CAAC;AACnC,QAAA,IAAI,GAAU,EAAE,CAAC;AACjB,QAAA,QAAQ,GAAc;AACjC,iBAAiB;CAClB,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { Fetcher } from '../../Fetcher';
2
+ declare const fetcher: Fetcher;
3
+ export default fetcher;