@xoxno/sdk-js 0.1.183 → 0.1.184

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 (75) hide show
  1. package/dist/collection/index.d.ts +297 -0
  2. package/dist/collection/index.d.ts.map +1 -0
  3. package/dist/common/index.d.ts +71 -0
  4. package/dist/common/index.d.ts.map +1 -0
  5. package/dist/email/Markdown.d.ts +4 -0
  6. package/dist/email/Markdown.d.ts.map +1 -0
  7. package/dist/email/email.d.ts +31 -0
  8. package/dist/email/email.d.ts.map +1 -0
  9. package/dist/email/event-email.d.ts +20 -0
  10. package/dist/email/event-email.d.ts.map +1 -0
  11. package/dist/email/post-email.d.ts +19 -0
  12. package/dist/email/post-email.d.ts.map +1 -0
  13. package/dist/email/types.d.ts +68 -0
  14. package/dist/email/types.d.ts.map +1 -0
  15. package/dist/email/utils.d.ts +84 -0
  16. package/dist/email/utils.d.ts.map +1 -0
  17. package/dist/email.cjs.js +1854 -0
  18. package/dist/email.cjs.js.LICENSE.txt +102 -0
  19. package/dist/email.d.ts +15 -0
  20. package/dist/email.d.ts.map +1 -0
  21. package/dist/email.esm.js +1854 -0
  22. package/dist/email.esm.js.LICENSE.txt +102 -0
  23. package/dist/index.cjs.js +1 -0
  24. package/dist/index.d.ts +8 -0
  25. package/dist/index.d.ts.map +1 -0
  26. package/dist/index.esm.js +1 -0
  27. package/dist/interactions/index.d.ts +256 -0
  28. package/dist/interactions/index.d.ts.map +1 -0
  29. package/dist/interactor.cjs.js +2 -0
  30. package/dist/interactor.cjs.js.LICENSE.txt +10 -0
  31. package/dist/interactor.d.ts +6 -0
  32. package/dist/interactor.d.ts.map +1 -0
  33. package/dist/interactor.esm.js +2 -0
  34. package/dist/interactor.esm.js.LICENSE.txt +10 -0
  35. package/dist/launchpad/index.d.ts +79 -0
  36. package/dist/launchpad/index.d.ts.map +1 -0
  37. package/dist/nft/index.d.ts +69 -0
  38. package/dist/nft/index.d.ts.map +1 -0
  39. package/dist/staking/index.d.ts +12 -0
  40. package/dist/staking/index.d.ts.map +1 -0
  41. package/dist/types/collection.d.ts +851 -0
  42. package/dist/types/collection.d.ts.map +1 -0
  43. package/dist/types/common.d.ts +72 -0
  44. package/dist/types/common.d.ts.map +1 -0
  45. package/dist/types/index.d.ts +8 -0
  46. package/dist/types/index.d.ts.map +1 -0
  47. package/dist/types/interactions.d.ts +97 -0
  48. package/dist/types/interactions.d.ts.map +1 -0
  49. package/dist/types/nft.d.ts +105 -0
  50. package/dist/types/nft.d.ts.map +1 -0
  51. package/dist/types/staking.d.ts +67 -0
  52. package/dist/types/staking.d.ts.map +1 -0
  53. package/dist/types/trading.d.ts +115 -0
  54. package/dist/types/trading.d.ts.map +1 -0
  55. package/dist/types/user.d.ts +302 -0
  56. package/dist/types/user.d.ts.map +1 -0
  57. package/dist/users/index.d.ts +202 -0
  58. package/dist/users/index.d.ts.map +1 -0
  59. package/dist/utils/SmartContractAbis.d.ts +16 -0
  60. package/dist/utils/SmartContractAbis.d.ts.map +1 -0
  61. package/dist/utils/SmartContractService.d.ts +4 -0
  62. package/dist/utils/SmartContractService.d.ts.map +1 -0
  63. package/dist/utils/api.d.ts +31 -0
  64. package/dist/utils/api.d.ts.map +1 -0
  65. package/dist/utils/const.d.ts +14 -0
  66. package/dist/utils/const.d.ts.map +1 -0
  67. package/dist/utils/getActivity.d.ts +11 -0
  68. package/dist/utils/getActivity.d.ts.map +1 -0
  69. package/dist/utils/helpers.d.ts +4 -0
  70. package/dist/utils/helpers.d.ts.map +1 -0
  71. package/dist/utils/regex.d.ts +3 -0
  72. package/dist/utils/regex.d.ts.map +1 -0
  73. package/dist/utils/scCalls.d.ts +10 -0
  74. package/dist/utils/scCalls.d.ts.map +1 -0
  75. package/package.json +1 -1
@@ -0,0 +1,10 @@
1
+ /*!
2
+ * The buffer module from node.js, for the browser.
3
+ *
4
+ * @author Feross Aboukhadijeh <https://feross.org>
5
+ * @license MIT
6
+ */
7
+
8
+ /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
9
+
10
+ /*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
@@ -0,0 +1,79 @@
1
+ import type { SmartContract } from '@multiversx/sdk-core/out/smartcontracts/smartContract';
2
+ /**
3
+ * LaunchpadModule provides methods to interact with the minter smart contract.
4
+ * @class
5
+ */
6
+ export declare class LaunchpadModule {
7
+ private minter;
8
+ private call;
9
+ /**
10
+ * @constructor
11
+ * @param {SmartContract} minterAbiXOXNO - The minter smart contract instance.
12
+ */
13
+ constructor(minterAbiXOXNO: SmartContract);
14
+ /**
15
+ * Executes the provided interaction and returns the result.
16
+ * @private
17
+ * @param {Interaction} interaction - The smart contract interaction.
18
+ * @returns {Promise<any>} The result of the interaction.
19
+ */
20
+ private getResult;
21
+ /**
22
+ * Initializes the LaunchpadModule with a minter smart contract instance.
23
+ * @static
24
+ * @param {string} minterSC - The minter smart contract address.
25
+ * @returns {Promise<LaunchpadModule>} A new instance of LaunchpadModule.
26
+ */
27
+ static init(minterSC: string): Promise<LaunchpadModule>;
28
+ /**
29
+ * Fetches all unique tags from the minter smart contract.
30
+ * @public
31
+ * @returns {Promise<string[]>} An array of unique tags.
32
+ */
33
+ getAllUniqueTags: () => Promise<string[]>;
34
+ /**
35
+ * Fetches the global buy count for a user and tag.
36
+ * @public
37
+ * @param {string} user - The user's address.
38
+ * @param {string} tag - The tag.
39
+ * @returns {Promise<number>} The global buy count.
40
+ */
41
+ getWalletGlobalBuyCount: (user: string, tag: string) => Promise<number>;
42
+ /**
43
+ * Fetches the stage buy count for a user, tag, and stage.
44
+ * @public
45
+ * @param {string} user - The user's address.
46
+ * @param {string} tag - The tag.
47
+ * @param {string} stage - The stage.
48
+ * @returns {Promise<number>} The stage buy count.
49
+ */
50
+ getWalletStageBuyCount: (user: string, tag: string, stage: string) => Promise<number>;
51
+ /**
52
+ * Fetches the local owner's address from the minter smart contract.
53
+ * @public
54
+ * @returns {Promise<string>} The local owner's address.
55
+ */
56
+ getLocalOwner: () => Promise<string>;
57
+ /**
58
+ * Fetches the launchpad cut fee percentage from the minter smart contract.
59
+ * @public
60
+ * @returns {Promise<number>} The launchpad cut fee percentage.
61
+ */
62
+ getLaunchpadCutFee: () => Promise<number>;
63
+ /**
64
+ * Fetches the stage whitelist of wallets for a tag and stage.
65
+ * @public
66
+ * @param {string} tag - The tag.
67
+ * @param {string} stage - The stage.
68
+ * @returns {Promise<string[]>} An array of whitelisted wallet addresses.
69
+ */
70
+ getStageWhitelist: (tag: string, stage: string) => Promise<string[]>;
71
+ /**
72
+ * Fetches the list of stages for a tag.
73
+ * @public
74
+ * @param {string} tag - The tag.
75
+ * @returns {Promise<string[]>} An array of stages.
76
+ */
77
+ getStages: (tag: string) => Promise<string[]>;
78
+ }
79
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/launchpad/index.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uDAAuD,CAAC;AAE3F;;;GAGG;AACH,qBAAa,eAAe;IAC1B,OAAO,CAAC,MAAM,CAAgB;IAC9B,OAAO,CAAC,IAAI,CAAsB;IAClC;;;OAGG;gBACS,cAAc,EAAE,aAAa;IAKzC;;;;;OAKG;YACW,SAAS;IAIvB;;;;;OAKG;WACU,IAAI,CAAC,QAAQ,EAAE,MAAM;IAMlC;;;;OAIG;IACI,gBAAgB,QAAa,OAAO,CAAC,MAAM,EAAE,CAAC,CAInD;IAEF;;;;;;OAMG;IACI,uBAAuB,SACtB,MAAM,OACP,MAAM,KACV,OAAO,CAAC,MAAM,CAAC,CAIhB;IAEF;;;;;;;OAOG;IACI,sBAAsB,SACrB,MAAM,OACP,MAAM,SACJ,MAAM,KACZ,OAAO,CAAC,MAAM,CAAC,CAQhB;IAEF;;;;OAIG;IACI,aAAa,QAAa,OAAO,CAAC,MAAM,CAAC,CAI9C;IAEF;;;;OAIG;IAEI,kBAAkB,QAAa,OAAO,CAAC,MAAM,CAAC,CAInD;IAEF;;;;;;OAMG;IACI,iBAAiB,QACjB,MAAM,SACJ,MAAM,KACZ,OAAO,CAAC,MAAM,EAAE,CAAC,CAIlB;IAEF;;;;;OAKG;IACI,SAAS,QAAe,MAAM,KAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAuBvD;CACH"}
@@ -0,0 +1,69 @@
1
+ import { NftData } from '../types/nft';
2
+ import { TradingActivityResponse, TradincActivityArgs } from '../types/trading';
3
+ import { UserOffers } from '../types/user';
4
+ /**
5
+ * NFTModule provides a set of methods to interact with single NFTs.
6
+ * It includes methods for getting single NFT information, and searching NFTs by collection and nonce.
7
+ *
8
+ * @example
9
+ * const nftModule = new NFTModule();
10
+ */
11
+ export declare class NFTModule {
12
+ private api;
13
+ constructor();
14
+ /**
15
+ * @public
16
+ * @async
17
+ * @function getNFTByIdentifier
18
+ * @param {string} identifier - The identifier of the NFT to fetch data for.
19
+ * @returns {Promise<NftData>} A promise that resolves to the fetched NFT data.
20
+ *
21
+ * This function fetches data for a given NFT by its identifier. It takes the following parameter:
22
+ * - identifier (string): The identifier of the NFT to fetch data for.
23
+ *
24
+ * The function first validates the input identifier and checks if it is a valid NFT identifier.
25
+ * If it is valid, the function fetches the NFT data using the API.
26
+ * Finally, it returns a promise that resolves to the fetched NFT data.
27
+ */
28
+ getNFTByIdentifier: (identifier: string, extra?: RequestInit) => Promise<NftData>;
29
+ /**
30
+ * @public
31
+ * @async
32
+ * @function getNFTByIdentifier
33
+ * @param {string} identifier - The identifier of the NFT to fetch data for.
34
+ * @returns {Promise<NftData>} A promise that resolves to the fetched NFT data.
35
+ *
36
+ * This function fetches data for a given NFT by its identifier. It takes the following parameter:
37
+ * - identifier (string): The identifier of the NFT to fetch data for.
38
+ *
39
+ * The function first validates the input identifier and checks if it is a valid NFT identifier.
40
+ * If it is valid, the function fetches the NFT data using the API.
41
+ * Finally, it returns a promise that resolves to the fetched NFT data.
42
+ */
43
+ getNFTsOffers: (identifier: string, skip?: number, top?: number) => Promise<UserOffers>;
44
+ /**
45
+ * Gets an NFT by collection and nonce.
46
+ * @param collection The collection ticker.
47
+ * @param nonce The nonce of the NFT.
48
+ * @returns {Promise<NftData>} The NFT data.
49
+ * @throws Throws an error when the collection ticker is invalid.
50
+ */
51
+ getNFTByCollectionAndNonce: (collection: string, nonce: number) => Promise<NftData>;
52
+ /**
53
+ * Get NFT by collection and nonce hex
54
+ *
55
+ * @param collection - collection ticker
56
+ * @param nonceHex - nonce hex
57
+ * @return {Promise<NftData>} NFT data
58
+ */
59
+ getNFTByCollectionAndNonceHex: (collection: string, nonceHex: string) => Promise<NftData>;
60
+ /**
61
+ * Retrieves trading history based on the provided arguments.
62
+ *
63
+ * @param {TradincActivityArgs} args - The arguments for filtering the trading activity.
64
+ * @returns {Promise<TradingActivityResponse>} A promise resolving to a TradingActivityResponse object containing the activity.
65
+ * @throws {Error} Throws an error if the 'top' argument is greater than 100.
66
+ */
67
+ getTradingActivity: (args: TradincActivityArgs) => Promise<TradingActivityResponse>;
68
+ }
69
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/nft/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,uBAAuB,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAChF,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAK3C;;;;;;GAMG;AAEH,qBAAa,SAAS;IACpB,OAAO,CAAC,GAAG,CAAc;;IAKzB;;;;;;;;;;;;;OAaG;IACI,kBAAkB,eACX,MAAM,UACV,WAAW,KAClB,OAAO,CAAC,OAAO,CAAC,CAWjB;IAEF;;;;;;;;;;;;;OAaG;IACI,aAAa,eACN,MAAM,SACZ,MAAM,QACP,MAAM,KACV,OAAO,CAAC,UAAU,CAAC,CAcpB;IAEF;;;;;;OAMG;IACI,0BAA0B,eACnB,MAAM,SACX,MAAM,KACZ,OAAO,CAAC,OAAO,CAAC,CASjB;IAEF;;;;;;OAMG;IAEI,6BAA6B,eACtB,MAAM,YACR,MAAM,KACf,OAAO,CAAC,OAAO,CAAC,CAcjB;IAEF;;;;;;OAMG;IACI,kBAAkB,SACjB,mBAAmB,KACxB,OAAO,CAAC,uBAAuB,CAAC,CAEjC;CACH"}
@@ -0,0 +1,12 @@
1
+ import { StakingSummaryPools } from '../types/staking';
2
+ export declare class StakingModule {
3
+ private api;
4
+ constructor();
5
+ /** Gets pool details
6
+ * @param {number} poolId - User's address
7
+ * @returns {CreatoPoolDetailsrInfo} User's creator info
8
+ * @throws {Error} Throws an error if the address is invalid
9
+ * */
10
+ getPoolDetails: (poolId: number) => Promise<StakingSummaryPools>;
11
+ }
12
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/staking/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAGvD,qBAAa,aAAa;IACxB,OAAO,CAAC,GAAG,CAAc;;IAIzB;;;;UAIM;IACC,cAAc,WACX,MAAM,KACb,OAAO,CAAC,mBAAmB,CAAC,CAK7B;CACH"}