@sonarwatch/portfolio-plugins 0.14.157 → 0.14.159

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 (34) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/package.json +1 -1
  3. package/src/index.d.ts +1 -2
  4. package/src/index.js +2 -4
  5. package/src/index.js.map +1 -1
  6. package/src/utils/hasTransactions/hasTransactions.d.ts +2 -0
  7. package/src/utils/hasTransactions/hasTransactions.js +37 -0
  8. package/src/utils/hasTransactions/hasTransactions.js.map +1 -0
  9. package/src/utils/hasTransactions/hasTransactionsAptos.d.ts +2 -0
  10. package/src/utils/{blank/isBlankAddressAptos.js → hasTransactions/hasTransactionsAptos.js} +4 -6
  11. package/src/utils/hasTransactions/hasTransactionsAptos.js.map +1 -0
  12. package/src/utils/hasTransactions/hasTransactionsEvm.d.ts +2 -0
  13. package/src/utils/{blank/isBlankAddressEvm.js → hasTransactions/hasTransactionsEvm.js} +4 -6
  14. package/src/utils/hasTransactions/hasTransactionsEvm.js.map +1 -0
  15. package/src/utils/hasTransactions/hasTransactionsSolana.d.ts +2 -0
  16. package/src/utils/{blank/isBlankAddressSui.js → hasTransactions/hasTransactionsSolana.js} +10 -8
  17. package/src/utils/hasTransactions/hasTransactionsSolana.js.map +1 -0
  18. package/src/utils/hasTransactions/index.d.ts +4 -0
  19. package/src/utils/{blank → hasTransactions}/index.js +4 -1
  20. package/src/utils/hasTransactions/index.js.map +1 -0
  21. package/src/utils/blank/getBlankNetworkIds.d.ts +0 -4
  22. package/src/utils/blank/getBlankNetworkIds.js +0 -60
  23. package/src/utils/blank/getBlankNetworkIds.js.map +0 -1
  24. package/src/utils/blank/index.d.ts +0 -1
  25. package/src/utils/blank/index.js.map +0 -1
  26. package/src/utils/blank/isBlankAddressAptos.d.ts +0 -1
  27. package/src/utils/blank/isBlankAddressAptos.js.map +0 -1
  28. package/src/utils/blank/isBlankAddressEvm.d.ts +0 -2
  29. package/src/utils/blank/isBlankAddressEvm.js.map +0 -1
  30. package/src/utils/blank/isBlankAddressSui.d.ts +0 -1
  31. package/src/utils/blank/isBlankAddressSui.js.map +0 -1
  32. package/src/utils/solana/isActive.d.ts +0 -2
  33. package/src/utils/solana/isActive.js +0 -39
  34. package/src/utils/solana/isActive.js.map +0 -1
package/CHANGELOG.md CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
  This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
4
4
 
5
+ ## [0.14.159](https://github.com/sonarwatch/portfolio/compare/plugins-0.14.158...plugins-0.14.159) (2025-03-26)
6
+
7
+
8
+
9
+ ## [0.14.158](https://github.com/sonarwatch/portfolio/compare/plugins-0.14.157...plugins-0.14.158) (2025-03-26)
10
+
11
+
12
+
5
13
  ## [0.14.157](https://github.com/sonarwatch/portfolio/compare/plugins-0.14.156...plugins-0.14.157) (2025-03-26)
6
14
 
7
15
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sonarwatch/portfolio-plugins",
3
- "version": "0.14.157",
3
+ "version": "0.14.159",
4
4
  "type": "commonjs",
5
5
  "types": "./src/index.d.ts",
6
6
  "peerDependencies": {
package/src/index.d.ts CHANGED
@@ -2,13 +2,12 @@ import { Fetcher } from './Fetcher';
2
2
  import { AirdropFetcher } from './AirdropFetcher';
3
3
  import { Job } from './Job';
4
4
  export { getFetchersByAddressSystem } from './utils/misc/getFetchersByAddressSystem';
5
- export { isSolanaAddressActive } from './utils/solana/isActive';
6
5
  export * from './Cache';
7
6
  export * from './Fetcher';
8
7
  export * from './AirdropFetcher';
9
8
  export * from './Job';
10
9
  export * from './utils/name-service';
11
- export * from './utils/blank';
10
+ export * from './utils/hasTransactions';
12
11
  export { getLlamaProtocolsJob } from './plugins/llama-protocols';
13
12
  export { jupFetcherIds } from './plugins/jupiter';
14
13
  export { solanaSimpleFetcher } from './plugins/tokens';
package/src/index.js CHANGED
@@ -26,7 +26,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
26
26
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.airdropFetchersByAddressSystem = exports.airdropFetchers = exports.fetchersByAddressSystem = exports.fetchers = exports.jobs = exports.solanaSimpleFetcher = exports.jupFetcherIds = exports.getLlamaProtocolsJob = exports.isSolanaAddressActive = exports.getFetchersByAddressSystem = void 0;
29
+ exports.airdropFetchersByAddressSystem = exports.airdropFetchers = exports.fetchersByAddressSystem = exports.fetchers = exports.jobs = exports.solanaSimpleFetcher = exports.jupFetcherIds = exports.getLlamaProtocolsJob = exports.getFetchersByAddressSystem = void 0;
30
30
  const getFetchersByAddressSystem_1 = require("./utils/misc/getFetchersByAddressSystem");
31
31
  // PLUGINS
32
32
  const tokens = __importStar(require("./plugins/tokens"));
@@ -186,14 +186,12 @@ const coingecko = __importStar(require("./plugins/coingecko"));
186
186
  const zeus = __importStar(require("./plugins/zeus"));
187
187
  var getFetchersByAddressSystem_2 = require("./utils/misc/getFetchersByAddressSystem");
188
188
  Object.defineProperty(exports, "getFetchersByAddressSystem", { enumerable: true, get: function () { return getFetchersByAddressSystem_2.getFetchersByAddressSystem; } });
189
- var isActive_1 = require("./utils/solana/isActive");
190
- Object.defineProperty(exports, "isSolanaAddressActive", { enumerable: true, get: function () { return isActive_1.isSolanaAddressActive; } });
191
189
  __exportStar(require("./Cache"), exports);
192
190
  __exportStar(require("./Fetcher"), exports);
193
191
  __exportStar(require("./AirdropFetcher"), exports);
194
192
  __exportStar(require("./Job"), exports);
195
193
  __exportStar(require("./utils/name-service"), exports);
196
- __exportStar(require("./utils/blank"), exports);
194
+ __exportStar(require("./utils/hasTransactions"), exports);
197
195
  var llama_protocols_1 = require("./plugins/llama-protocols");
198
196
  Object.defineProperty(exports, "getLlamaProtocolsJob", { enumerable: true, get: function () { return llama_protocols_1.getLlamaProtocolsJob; } });
199
197
  var jupiter_1 = require("./plugins/jupiter");
package/src/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../packages/plugins/src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,wFAAqF;AAErF,UAAU;AACV,yDAA2C;AAC3C,oEAAsD;AACtD,mEAAqD;AACrD,6DAA+C;AAC/C,6DAA+C;AAC/C,uDAAyC;AACzC,qDAAuC;AACvC,2DAA6C;AAC7C,qDAAuC;AACvC,2DAA6C;AAC7C,uDAAyC;AACzC,yDAA2C;AAC3C,uDAAyC;AACzC,yDAA2C;AAC3C,yDAA2C;AAC3C,qDAAuC;AACvC,sEAAwD;AACxD,yDAA2C;AAC3C,uDAAyC;AACzC,uDAAyC;AACzC,gEAAkD;AAClD,gFAAkE;AAClE,mEAAqD;AACrD,+DAAiD;AACjD,iEAAmD;AACnD,mEAAqD;AACrD,uDAAyC;AACzC,yDAA2C;AAC3C,yDAA2C;AAC3C,qDAAuC;AACvC,2DAA6C;AAC7C,kEAAoD;AACpD,qDAAuC;AACvC,uDAAyC;AACzC,6DAA+C;AAC/C,6DAA+C;AAC/C,yDAA2C;AAC3C,2DAA6C;AAC7C,6DAA+C;AAC/C,6DAA+C;AAC/C,+DAAiD;AACjD,qDAAuC;AACvC,uDAAyC;AACzC,qDAAuC;AACvC,6DAA+C;AAC/C,2DAA6C;AAC7C,qDAAuC;AACvC,uDAAyC;AACzC,+DAAiD;AACjD,uDAAyC;AACzC,uDAAyC;AACzC,wDAA0C;AAC1C,2DAA6C;AAC7C,qDAAuC;AACvC,6DAA+C;AAC/C,qDAAuC;AACvC,+DAAiD;AACjD,iEAAmD;AACnD,uDAAyC;AACzC,uDAAyC;AACzC,qDAAuC;AACvC,4EAA8D;AAC9D,uDAAyC;AACzC,uDAAyC;AACzC,mEAAqD;AACrD,yEAA2D;AAC3D,uDAAyC;AACzC,qDAAuC;AACvC,+DAAiD;AACjD,yDAA2C;AAC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U,IAAI,MAAM,EAAE,CAAC;QACzB,OAAO,MAAM,CAAC,QAAqB,CAAC;IACtC,CAAC;IACD,OAAO,EAAE,CAAC;AACZ,CAAC,CAAC;KACD,IAAI,EAAE,CAAC;AACG,QAAA,uBAAuB,GAAG,IAAA,uDAA0B,EAAC,gBAAQ,CAAC,CAAC;AAE/D,QAAA,eAAe,GAAqB,OAAO;KACrD,GAAG,CAAC,CAAC,MAAM,EAAoB,EAAE;IAChC,IAAI,iBAAiB,IAAI,MAAM,EAAE,CAAC;QAChC,OAAO,MAAM,CAAC,eAAmC,CAAC;IACpD,CAAC;IACD,OAAO,EAAE,CAAC;AACZ,CAAC,CAAC;KACD,IAAI,EAAE,CAAC;AACG,QAAA,8BAA8B,GACzC,IAAA,uDAA0B,EAAC,uBAAe,CAAC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../packages/plugins/src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,wFAAqF;AAErF,UAAU;AACV,yDAA2C;AAC3C,oEAAsD;AACtD,mEAAqD;AACrD,6DAA+C;AAC/C,6DAA+C;AAC/C,uDAAyC;AACzC,qDAAuC;AACvC,2DAA6C;AAC7C,qDAAuC;AACvC,2DAA6C;AAC7C,uDAAyC;AACzC,yDAA2C;AAC3C,uDAAyC;AACzC,yDAA2C;AAC3C,yDAA2C;AAC3C,qDAAuC;AACvC,sEAAwD;AACxD,yDAA2C;AAC3C,uDAAyC;AACzC,uDAAyC;AACzC,gEAAkD;AAClD,gFAAkE;AAClE,mEAAqD;AACrD,+DAAiD;AACjD,iEAAmD;AACnD,mEAAqD;AACrD,uDAAyC;AACzC,yDAA2C;AAC3C,yDAA2C;AAC3C,qDAAuC;AACvC,2DAA6C;AAC7C,kEAAoD;AACpD,qDAAuC;AACvC,uDAAyC;AACzC,6DAA+C;AAC/C,6DAA+C;AAC/C,yDAA2C;AAC3C,2DAA6C;AAC7C,6DAA+C;AAC/C,6DA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;IACR,KAAK;IACL,KAAK;IACL,KAAK;IACL,SAAS;IACT,IAAI;CACL,CAAC;AAEF,UAAU;AACG,QAAA,IAAI,GAAU,OAAO;KAC/B,GAAG,CAAC,CAAC,MAAM,EAAS,EAAE;IACrB,IAAI,MAAM,IAAI,MAAM,EAAE,CAAC;QACrB,OAAO,MAAM,CAAC,IAAa,CAAC;IAC9B,CAAC;IACD,OAAO,EAAE,CAAC;AACZ,CAAC,CAAC;KACD,IAAI,EAAE,CAAC;AAEV,cAAc;AACD,QAAA,QAAQ,GAAc,OAAO;KACvC,GAAG,CAAC,CAAC,MAAM,EAAa,EAAE;IACzB,IAAI,UAAU,IAAI,MAAM,EAAE,CAAC;QACzB,OAAO,MAAM,CAAC,QAAqB,CAAC;IACtC,CAAC;IACD,OAAO,EAAE,CAAC;AACZ,CAAC,CAAC;KACD,IAAI,EAAE,CAAC;AACG,QAAA,uBAAuB,GAAG,IAAA,uDAA0B,EAAC,gBAAQ,CAAC,CAAC;AAE/D,QAAA,eAAe,GAAqB,OAAO;KACrD,GAAG,CAAC,CAAC,MAAM,EAAoB,EAAE;IAChC,IAAI,iBAAiB,IAAI,MAAM,EAAE,CAAC;QAChC,OAAO,MAAM,CAAC,eAAmC,CAAC;IACpD,CAAC;IACD,OAAO,EAAE,CAAC;AACZ,CAAC,CAAC;KACD,IAAI,EAAE,CAAC;AACG,QAAA,8BAA8B,GACzC,IAAA,uDAA0B,EAAC,uBAAe,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ import { NetworkIdType } from '@sonarwatch/portfolio-core';
2
+ export declare function hasTransactions(address: string, networkId: NetworkIdType): Promise<boolean>;
@@ -0,0 +1,37 @@
1
+ "use strict";
2
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
+ return new (P || (P = Promise))(function (resolve, reject) {
5
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
9
+ });
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.hasTransactions = void 0;
13
+ const portfolio_core_1 = require("@sonarwatch/portfolio-core");
14
+ const clients_1 = require("../clients");
15
+ const hasTransactionsAptos_1 = require("./hasTransactionsAptos");
16
+ const hasTransactionsEvm_1 = require("./hasTransactionsEvm");
17
+ const hasTransactionsSolana_1 = require("./hasTransactionsSolana");
18
+ function hasTransactions(address, networkId) {
19
+ return __awaiter(this, void 0, void 0, function* () {
20
+ const addressSystem = (0, portfolio_core_1.getAddressSystemFromNetworkId)(networkId);
21
+ (0, portfolio_core_1.assertAddress)(address, addressSystem);
22
+ if (addressSystem === portfolio_core_1.AddressSystem.evm) {
23
+ const client = (0, clients_1.getEvmClient)(networkId);
24
+ return (0, hasTransactionsEvm_1.hasTransactionsEvm)(address, client);
25
+ }
26
+ switch (networkId) {
27
+ case portfolio_core_1.NetworkId.aptos:
28
+ return (0, hasTransactionsAptos_1.hasTransactionsAptos)(address, (0, clients_1.getClientAptos)());
29
+ case portfolio_core_1.NetworkId.solana:
30
+ return (0, hasTransactionsSolana_1.hasTransactionsSolana)(address, (0, clients_1.getClientSolana)());
31
+ default:
32
+ throw new Error(`Network ${networkId} not supported`);
33
+ }
34
+ });
35
+ }
36
+ exports.hasTransactions = hasTransactions;
37
+ //# sourceMappingURL=hasTransactions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hasTransactions.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/hasTransactions/hasTransactions.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAOoC;AACpC,wCAA2E;AAC3E,iEAA8D;AAC9D,6DAA0D;AAC1D,mEAAgE;AAEhE,SAAsB,eAAe,CACnC,OAAe,EACf,SAAwB;;QAExB,MAAM,aAAa,GAAG,IAAA,8CAA6B,EAAC,SAAS,CAAC,CAAC;QAC/D,IAAA,8BAAa,EAAC,OAAO,EAAE,aAAa,CAAC,CAAC;QAEtC,IAAI,aAAa,KAAK,8BAAa,CAAC,GAAG,EAAE,CAAC;YACxC,MAAM,MAAM,GAAG,IAAA,sBAAY,EAAC,SAA6B,CAAC,CAAC;YAC3D,OAAO,IAAA,uCAAkB,EAAC,OAAO,EAAE,MAAM,CAAC,CAAC;QAC7C,CAAC;QAED,QAAQ,SAAS,EAAE,CAAC;YAClB,KAAK,0BAAS,CAAC,KAAK;gBAClB,OAAO,IAAA,2CAAoB,EAAC,OAAO,EAAE,IAAA,wBAAc,GAAE,CAAC,CAAC;YACzD,KAAK,0BAAS,CAAC,MAAM;gBACnB,OAAO,IAAA,6CAAqB,EAAC,OAAO,EAAE,IAAA,yBAAe,GAAE,CAAC,CAAC;YAC3D;gBACE,MAAM,IAAI,KAAK,CAAC,WAAW,SAAS,gBAAgB,CAAC,CAAC;QAC1D,CAAC;IACH,CAAC;CAAA;AApBD,0CAoBC"}
@@ -0,0 +1,2 @@
1
+ import { AptosClient } from '../clients/types';
2
+ export declare function hasTransactionsAptos(address: string, client: AptosClient): Promise<boolean>;
@@ -9,11 +9,9 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
9
9
  });
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.isBlankAddressAptos = void 0;
13
- const clients_1 = require("../clients");
14
- function isBlankAddressAptos(address) {
12
+ exports.hasTransactionsAptos = void 0;
13
+ function hasTransactionsAptos(address, client) {
15
14
  return __awaiter(this, void 0, void 0, function* () {
16
- const client = (0, clients_1.getClientAptos)();
17
15
  const ressources = yield client
18
16
  .getAccountResources({
19
17
  accountAddress: address,
@@ -22,5 +20,5 @@ function isBlankAddressAptos(address) {
22
20
  return ressources.length === 0;
23
21
  });
24
22
  }
25
- exports.isBlankAddressAptos = isBlankAddressAptos;
26
- //# sourceMappingURL=isBlankAddressAptos.js.map
23
+ exports.hasTransactionsAptos = hasTransactionsAptos;
24
+ //# sourceMappingURL=hasTransactionsAptos.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hasTransactionsAptos.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/hasTransactions/hasTransactionsAptos.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,SAAsB,oBAAoB,CACxC,OAAe,EACf,MAAmB;;QAEnB,MAAM,UAAU,GAAG,MAAM,MAAM;aAC5B,mBAAmB,CAAC;YACnB,cAAc,EAAE,OAAO;SACxB,CAAC;aACD,KAAK,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,CAAC;QACnB,OAAO,UAAU,CAAC,MAAM,KAAK,CAAC,CAAC;IACjC,CAAC;CAAA;AAVD,oDAUC"}
@@ -0,0 +1,2 @@
1
+ import { EvmClient } from '../clients/types';
2
+ export declare function hasTransactionsEvm(address: string, client: EvmClient): Promise<boolean>;
@@ -9,16 +9,14 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
9
9
  });
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.isBlankAddressEvm = void 0;
13
- const clients_1 = require("../clients");
14
- function isBlankAddressEvm(networkId, address) {
12
+ exports.hasTransactionsEvm = void 0;
13
+ function hasTransactionsEvm(address, client) {
15
14
  return __awaiter(this, void 0, void 0, function* () {
16
- const client = (0, clients_1.getEvmClient)(networkId);
17
15
  const count = yield client.getTransactionCount({
18
16
  address: address,
19
17
  });
20
18
  return count === 0;
21
19
  });
22
20
  }
23
- exports.isBlankAddressEvm = isBlankAddressEvm;
24
- //# sourceMappingURL=isBlankAddressEvm.js.map
21
+ exports.hasTransactionsEvm = hasTransactionsEvm;
22
+ //# sourceMappingURL=hasTransactionsEvm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hasTransactionsEvm.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/hasTransactions/hasTransactionsEvm.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,SAAsB,kBAAkB,CAAC,OAAe,EAAE,MAAiB;;QACzE,MAAM,KAAK,GAAG,MAAM,MAAM,CAAC,mBAAmB,CAAC;YAC7C,OAAO,EAAE,OAAwB;SAClC,CAAC,CAAC;QACH,OAAO,KAAK,KAAK,CAAC,CAAC;IACrB,CAAC;CAAA;AALD,gDAKC"}
@@ -0,0 +1,2 @@
1
+ import { SolanaClient } from '../clients/types';
2
+ export declare function hasTransactionsSolana(address: string, connection: SolanaClient): Promise<boolean>;
@@ -9,14 +9,16 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
9
9
  });
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.isBlankAddressSui = void 0;
13
- const clients_1 = require("../clients");
14
- function isBlankAddressSui(address) {
12
+ exports.hasTransactionsSolana = void 0;
13
+ const web3_js_1 = require("@solana/web3.js");
14
+ function hasTransactionsSolana(address, connection) {
15
15
  return __awaiter(this, void 0, void 0, function* () {
16
- const client = (0, clients_1.getClientSui)();
17
- const coinsBalances = yield client.getAllBalances({ owner: address });
18
- return coinsBalances.length === 0;
16
+ const pk = new web3_js_1.PublicKey(address);
17
+ const tx = yield connection.getSignaturesForAddress(pk, {
18
+ limit: 1,
19
+ });
20
+ return tx.length !== 0;
19
21
  });
20
22
  }
21
- exports.isBlankAddressSui = isBlankAddressSui;
22
- //# sourceMappingURL=isBlankAddressSui.js.map
23
+ exports.hasTransactionsSolana = hasTransactionsSolana;
24
+ //# sourceMappingURL=hasTransactionsSolana.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hasTransactionsSolana.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/hasTransactions/hasTransactionsSolana.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAA4C;AAG5C,SAAsB,qBAAqB,CACzC,OAAe,EACf,UAAwB;;QAExB,MAAM,EAAE,GAAG,IAAI,mBAAS,CAAC,OAAO,CAAC,CAAC;QAClC,MAAM,EAAE,GAAG,MAAM,UAAU,CAAC,uBAAuB,CAAC,EAAE,EAAE;YACtD,KAAK,EAAE,CAAC;SACT,CAAC,CAAC;QACH,OAAO,EAAE,CAAC,MAAM,KAAK,CAAC,CAAC;IACzB,CAAC;CAAA;AATD,sDASC"}
@@ -0,0 +1,4 @@
1
+ export * from './hasTransactions';
2
+ export * from './hasTransactionsAptos';
3
+ export * from './hasTransactionsEvm';
4
+ export * from './hasTransactionsSolana';
@@ -14,5 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./getBlankNetworkIds"), exports);
17
+ __exportStar(require("./hasTransactions"), exports);
18
+ __exportStar(require("./hasTransactionsAptos"), exports);
19
+ __exportStar(require("./hasTransactionsEvm"), exports);
20
+ __exportStar(require("./hasTransactionsSolana"), exports);
18
21
  //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/hasTransactions/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,yDAAuC;AACvC,uDAAqC;AACrC,0DAAwC"}
@@ -1,4 +0,0 @@
1
- import { AddressSystemType, EvmNetworkIdType, MoveNetworkIdType, NetworkIdType } from '@sonarwatch/portfolio-core';
2
- export declare function getBlankNetworkIds(address: string, addressSystem: AddressSystemType): Promise<NetworkIdType[]>;
3
- export declare function getBlankNetworkIdsMove(address: string): Promise<MoveNetworkIdType[]>;
4
- export declare function getBlankNetworkIdsEvm(address: string): Promise<EvmNetworkIdType[]>;
@@ -1,60 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.getBlankNetworkIdsEvm = exports.getBlankNetworkIdsMove = exports.getBlankNetworkIds = void 0;
13
- const portfolio_core_1 = require("@sonarwatch/portfolio-core");
14
- const isBlankAddressSui_1 = require("./isBlankAddressSui");
15
- const isBlankAddressAptos_1 = require("./isBlankAddressAptos");
16
- const isBlankAddressEvm_1 = require("./isBlankAddressEvm");
17
- function getBlankNetworkIds(address, addressSystem) {
18
- return __awaiter(this, void 0, void 0, function* () {
19
- switch (addressSystem) {
20
- case portfolio_core_1.AddressSystem.solana:
21
- return [];
22
- case portfolio_core_1.AddressSystem.bitcoin:
23
- return [];
24
- case portfolio_core_1.AddressSystem.evm:
25
- return getBlankNetworkIdsEvm(address);
26
- case portfolio_core_1.AddressSystem.move:
27
- return getBlankNetworkIdsMove(address);
28
- case portfolio_core_1.AddressSystem.sei:
29
- return [];
30
- default:
31
- return [];
32
- }
33
- });
34
- }
35
- exports.getBlankNetworkIds = getBlankNetworkIds;
36
- function getBlankNetworkIdsMove(address) {
37
- return __awaiter(this, void 0, void 0, function* () {
38
- const promises = [
39
- (0, isBlankAddressSui_1.isBlankAddressSui)(address).then((isBlank) => isBlank ? portfolio_core_1.NetworkId.sui : null),
40
- (0, isBlankAddressAptos_1.isBlankAddressAptos)(address).then((isBlank) => isBlank ? portfolio_core_1.NetworkId.aptos : null),
41
- ];
42
- return (yield Promise.all(promises)).filter((v) => v !== null);
43
- });
44
- }
45
- exports.getBlankNetworkIdsMove = getBlankNetworkIdsMove;
46
- const evmNetworkIds = portfolio_core_1.evmNetworks.map((n) => n.id);
47
- function getBlankNetworkIdsEvm(address) {
48
- return __awaiter(this, void 0, void 0, function* () {
49
- const promises = evmNetworkIds.map((n) => (0, isBlankAddressEvm_1.isBlankAddressEvm)(n, address));
50
- const res = yield Promise.all(promises);
51
- return res.reduce((acc, curr, i) => {
52
- if (curr) {
53
- acc.push(evmNetworkIds[i]);
54
- }
55
- return acc;
56
- }, []);
57
- });
58
- }
59
- exports.getBlankNetworkIdsEvm = getBlankNetworkIdsEvm;
60
- //# sourceMappingURL=getBlankNetworkIds.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"getBlankNetworkIds.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/blank/getBlankNetworkIds.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+DAQoC;AACpC,2DAAwD;AACxD,+DAA4D;AAC5D,2DAAwD;AAExD,SAAsB,kBAAkB,CACtC,OAAe,EACf,aAAgC;;QAEhC,QAAQ,aAAa,EAAE,CAAC;YACtB,KAAK,8BAAa,CAAC,MAAM;gBACvB,OAAO,EAAE,CAAC;YACZ,KAAK,8BAAa,CAAC,OAAO;gBACxB,OAAO,EAAE,CAAC;YACZ,KAAK,8BAAa,CAAC,GAAG;gBACpB,OAAO,qBAAqB,CAAC,OAAO,CAAC,CAAC;YACxC,KAAK,8BAAa,CAAC,IAAI;gBACrB,OAAO,sBAAsB,CAAC,OAAO,CAAC,CAAC;YACzC,KAAK,8BAAa,CAAC,GAAG;gBACpB,OAAO,EAAE,CAAC;YACZ;gBACE,OAAO,EAAE,CAAC;QACd,CAAC;IACH,CAAC;CAAA;AAlBD,gDAkBC;AAED,SAAsB,sBAAsB,CAC1C,OAAe;;QAEf,MAAM,QAAQ,GAAG;YACf,IAAA,qCAAiB,EAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAA4B,EAAE,CACpE,OAAO,CAAC,CAAC,CAAC,0BAAS,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAC/B;YACD,IAAA,yCAAmB,EAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAA4B,EAAE,CACtE,OAAO,CAAC,CAAC,CAAC,0BAAS,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CACjC;SACF,CAAC;QACF,OAAO,CAAC,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,CACzC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,IAAI,CACK,CAAC;IAC3B,CAAC;CAAA;AAdD,wDAcC;AAED,MAAM,aAAa,GAAG,4BAAW,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,CAAuB,CAAC;AACzE,SAAsB,qBAAqB,CACzC,OAAe;;QAEf,MAAM,QAAQ,GAAG,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,IAAA,qCAAiB,EAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC;QACzE,MAAM,GAAG,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;QACxC,OAAO,GAAG,CAAC,MAAM,CAAC,CAAC,GAAuB,EAAE,IAAI,EAAE,CAAC,EAAE,EAAE;YACrD,IAAI,IAAI,EAAE,CAAC;gBACT,GAAG,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CAAC;YAC7B,CAAC;YACD,OAAO,GAAG,CAAC;QACb,CAAC,EAAE,EAAE,CAAC,CAAC;IACT,CAAC;CAAA;AAXD,sDAWC"}
@@ -1 +0,0 @@
1
- export * from './getBlankNetworkIds';
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/blank/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC"}
@@ -1 +0,0 @@
1
- export declare function isBlankAddressAptos(address: string): Promise<boolean>;
@@ -1 +0,0 @@
1
- {"version":3,"file":"isBlankAddressAptos.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/blank/isBlankAddressAptos.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,wCAA4C;AAE5C,SAAsB,mBAAmB,CAAC,OAAe;;QACvD,MAAM,MAAM,GAAG,IAAA,wBAAc,GAAE,CAAC;QAChC,MAAM,UAAU,GAAG,MAAM,MAAM;aAC5B,mBAAmB,CAAC;YACnB,cAAc,EAAE,OAAO;SACxB,CAAC;aACD,KAAK,CAAC,GAAG,EAAE,CAAC,EAAE,CAAC,CAAC;QACnB,OAAO,UAAU,CAAC,MAAM,KAAK,CAAC,CAAC;IACjC,CAAC;CAAA;AARD,kDAQC"}
@@ -1,2 +0,0 @@
1
- import { EvmNetworkIdType } from '@sonarwatch/portfolio-core';
2
- export declare function isBlankAddressEvm(networkId: EvmNetworkIdType, address: string): Promise<boolean>;
@@ -1 +0,0 @@
1
- {"version":3,"file":"isBlankAddressEvm.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/blank/isBlankAddressEvm.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,wCAA0C;AAE1C,SAAsB,iBAAiB,CACrC,SAA2B,EAC3B,OAAe;;QAEf,MAAM,MAAM,GAAG,IAAA,sBAAY,EAAC,SAAS,CAAC,CAAC;QACvC,MAAM,KAAK,GAAG,MAAM,MAAM,CAAC,mBAAmB,CAAC;YAC7C,OAAO,EAAE,OAAwB;SAClC,CAAC,CAAC;QACH,OAAO,KAAK,KAAK,CAAC,CAAC;IACrB,CAAC;CAAA;AATD,8CASC"}
@@ -1 +0,0 @@
1
- export declare function isBlankAddressSui(address: string): Promise<boolean>;
@@ -1 +0,0 @@
1
- {"version":3,"file":"isBlankAddressSui.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/blank/isBlankAddressSui.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,wCAA0C;AAE1C,SAAsB,iBAAiB,CAAC,OAAe;;QACrD,MAAM,MAAM,GAAG,IAAA,sBAAY,GAAE,CAAC;QAC9B,MAAM,aAAa,GAAG,MAAM,MAAM,CAAC,cAAc,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,CAAC,CAAC;QACtE,OAAO,aAAa,CAAC,MAAM,KAAK,CAAC,CAAC;IACpC,CAAC;CAAA;AAJD,8CAIC"}
@@ -1,2 +0,0 @@
1
- import { Cache } from '../../Cache';
2
- export declare function isSolanaAddressActive(cache: Cache, address: string): Promise<boolean>;
@@ -1,39 +0,0 @@
1
- "use strict";
2
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
3
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
4
- return new (P || (P = Promise))(function (resolve, reject) {
5
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
6
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
7
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
8
- step((generator = generator.apply(thisArg, _arguments || [])).next());
9
- });
10
- };
11
- Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.isSolanaAddressActive = void 0;
13
- const web3_js_1 = require("@solana/web3.js");
14
- const portfolio_core_1 = require("@sonarwatch/portfolio-core");
15
- const clients_1 = require("../clients");
16
- function isSolanaAddressActive(cache, address) {
17
- return __awaiter(this, void 0, void 0, function* () {
18
- (0, portfolio_core_1.assertSolanaAddress)(address);
19
- const isActiveFromCache = yield cache.getItem(address, {
20
- prefix: 'isActive',
21
- });
22
- if (isActiveFromCache)
23
- return true;
24
- const client = (0, clients_1.getClientSolana)();
25
- const tx = yield client.getSignaturesForAddress(new web3_js_1.PublicKey(address), {
26
- limit: 1,
27
- });
28
- if (tx.length === 0) {
29
- return false;
30
- }
31
- yield cache.setItem(address, true, {
32
- prefix: 'isActive',
33
- ttl: 60 * 60 * 24 * 30, // 30 days
34
- });
35
- return true;
36
- });
37
- }
38
- exports.isSolanaAddressActive = isSolanaAddressActive;
39
- //# sourceMappingURL=isActive.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"isActive.js","sourceRoot":"","sources":["../../../../../../packages/plugins/src/utils/solana/isActive.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAA4C;AAC5C,+DAAiE;AACjE,wCAA6C;AAG7C,SAAsB,qBAAqB,CACzC,KAAY,EACZ,OAAe;;QAEf,IAAA,oCAAmB,EAAC,OAAO,CAAC,CAAC;QAC7B,MAAM,iBAAiB,GAAG,MAAM,KAAK,CAAC,OAAO,CAAU,OAAO,EAAE;YAC9D,MAAM,EAAE,UAAU;SACnB,CAAC,CAAC;QACH,IAAI,iBAAiB;YAAE,OAAO,IAAI,CAAC;QAEnC,MAAM,MAAM,GAAG,IAAA,yBAAe,GAAE,CAAC;QACjC,MAAM,EAAE,GAAG,MAAM,MAAM,CAAC,uBAAuB,CAAC,IAAI,mBAAS,CAAC,OAAO,CAAC,EAAE;YACtE,KAAK,EAAE,CAAC;SACT,CAAC,CAAC;QAEH,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YACpB,OAAO,KAAK,CAAC;QACf,CAAC;QACD,MAAM,KAAK,CAAC,OAAO,CAAC,OAAO,EAAE,IAAI,EAAE;YACjC,MAAM,EAAE,UAAU;YAClB,GAAG,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,EAAE,UAAU;SACnC,CAAC,CAAC;QAEH,OAAO,IAAI,CAAC;IACd,CAAC;CAAA;AAxBD,sDAwBC"}