@eluvio/elv-client-js 3.2.9 → 3.2.12
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.
- package/dist/ElvClient-min.js +8 -8
- package/dist/ElvClient-node-min.js +2 -2
- package/dist/ElvWalletClient-min.js +1 -1
- package/dist/ElvWalletClient-node-min.js +2 -2
- package/dist/src/ElvClient.js +5 -4
- package/dist/src/RemoteSigner.js +2 -2
- package/dist/src/walletClient/ClientMethods.js +13 -11
- package/dist/src/walletClient/Configuration.js +1 -1
- package/dist/src/walletClient/index.js +149 -127
- package/package.json +1 -1
- package/src/ElvClient.js +3 -2
- package/src/RemoteSigner.js +2 -2
- package/src/walletClient/ClientMethods.js +13 -11
- package/src/walletClient/Configuration.js +1 -1
- package/src/walletClient/index.js +80 -50
- package/testScripts/Test.js +33 -0
package/dist/src/ElvClient.js
CHANGED
|
@@ -652,6 +652,7 @@ var ElvClient = /*#__PURE__*/function () {
|
|
|
652
652
|
* @param {string=} authToken - Eluvio authorization token previously issued from OAuth ID token
|
|
653
653
|
* @param {string=} tenantId - If specified, user will be associated with the tenant
|
|
654
654
|
* @param {Object=} extraData - Additional data to pass to the login API
|
|
655
|
+
* @param {Array<string>=} signerURIs - (Only if using custom OAuth) - URIs corresponding to the key server(s) to use
|
|
655
656
|
* @param {boolean=} unsignedPublicAuth=false - If specified, the client will use an unsigned static token for calls that don't require authorization (reduces remote signature calls)
|
|
656
657
|
*/
|
|
657
658
|
|
|
@@ -659,14 +660,14 @@ var ElvClient = /*#__PURE__*/function () {
|
|
|
659
660
|
key: "SetRemoteSigner",
|
|
660
661
|
value: function () {
|
|
661
662
|
var _SetRemoteSigner = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee6(_ref8) {
|
|
662
|
-
var idToken, authToken, tenantId, extraData, unsignedPublicAuth, signer;
|
|
663
|
+
var idToken, authToken, tenantId, extraData, signerURIs, unsignedPublicAuth, signer;
|
|
663
664
|
return _regeneratorRuntime.wrap(function _callee6$(_context6) {
|
|
664
665
|
while (1) {
|
|
665
666
|
switch (_context6.prev = _context6.next) {
|
|
666
667
|
case 0:
|
|
667
|
-
idToken = _ref8.idToken, authToken = _ref8.authToken, tenantId = _ref8.tenantId, extraData = _ref8.extraData, unsignedPublicAuth = _ref8.unsignedPublicAuth;
|
|
668
|
+
idToken = _ref8.idToken, authToken = _ref8.authToken, tenantId = _ref8.tenantId, extraData = _ref8.extraData, signerURIs = _ref8.signerURIs, unsignedPublicAuth = _ref8.unsignedPublicAuth;
|
|
668
669
|
_context6.t0 = RemoteSigner;
|
|
669
|
-
_context6.t1 = this.authServiceURIs;
|
|
670
|
+
_context6.t1 = signerURIs || this.authServiceURIs;
|
|
670
671
|
_context6.t2 = idToken;
|
|
671
672
|
_context6.t3 = authToken;
|
|
672
673
|
_context6.t4 = tenantId;
|
|
@@ -678,7 +679,7 @@ var ElvClient = /*#__PURE__*/function () {
|
|
|
678
679
|
_context6.t6 = extraData;
|
|
679
680
|
_context6.t7 = unsignedPublicAuth;
|
|
680
681
|
_context6.t8 = {
|
|
681
|
-
|
|
682
|
+
signerURIs: _context6.t1,
|
|
682
683
|
idToken: _context6.t2,
|
|
683
684
|
authToken: _context6.t3,
|
|
684
685
|
tenantId: _context6.t4,
|
package/dist/src/RemoteSigner.js
CHANGED
|
@@ -34,7 +34,7 @@ var RemoteSigner = /*#__PURE__*/function (_Ethers$Signer) {
|
|
|
34
34
|
function RemoteSigner(_ref) {
|
|
35
35
|
var _this;
|
|
36
36
|
|
|
37
|
-
var
|
|
37
|
+
var signerURIs = _ref.signerURIs,
|
|
38
38
|
idToken = _ref.idToken,
|
|
39
39
|
authToken = _ref.authToken,
|
|
40
40
|
tenantId = _ref.tenantId,
|
|
@@ -50,7 +50,7 @@ var RemoteSigner = /*#__PURE__*/function (_Ethers$Signer) {
|
|
|
50
50
|
_this.remoteSigner = true;
|
|
51
51
|
_this.unsignedPublicAuth = unsignedPublicAuth;
|
|
52
52
|
_this.HttpClient = new HttpClient({
|
|
53
|
-
uris:
|
|
53
|
+
uris: signerURIs
|
|
54
54
|
});
|
|
55
55
|
_this.idToken = idToken;
|
|
56
56
|
_this.tenantId = tenantId;
|
|
@@ -295,7 +295,7 @@ exports.UserItemInfo = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regenerator
|
|
|
295
295
|
* @param {string=} contractAddress - Filter results by the address of the NFT contract
|
|
296
296
|
* @param {string=} tokenId - Filter by token ID (if filtering by contract address)
|
|
297
297
|
* @param {Object=} marketplaceParams - Filter results by marketplace
|
|
298
|
-
* @param {integer
|
|
298
|
+
* @param {Array<integer>=} collectionIndexes - If filtering by marketplace, filter by collection(s). The index refers to the index in the array `marketplace.collections`
|
|
299
299
|
*
|
|
300
300
|
* @returns {Promise<Object>} - Results of the query and pagination info
|
|
301
301
|
*/
|
|
@@ -1072,7 +1072,7 @@ exports.Listing = /*#__PURE__*/function () {
|
|
|
1072
1072
|
* <br /><br />
|
|
1073
1073
|
* NOTE: This string must be an <b>exact match</b> on the item name.
|
|
1074
1074
|
* You can retrieve all available item names from the <a href="#.ListingNames">ListingNames method</a>.
|
|
1075
|
-
* @param {string
|
|
1075
|
+
* @param {Array<string>=} editionFilters - Filter results by item edition.
|
|
1076
1076
|
* <br /><br />
|
|
1077
1077
|
* NOTE: This string must be an <b>exact match</b> on the edition name.
|
|
1078
1078
|
* You can retrieve all available item edition names from the <a href="#.ListingEditionNames">ListingEditionNames method</a>.
|
|
@@ -1080,12 +1080,13 @@ exports.Listing = /*#__PURE__*/function () {
|
|
|
1080
1080
|
* <br /><br />
|
|
1081
1081
|
* NOTE: These filters must be an <b>exact match</b> on the attribute name and value.
|
|
1082
1082
|
* You can retrieve all available item attributes from the <a href="#.ListingAttributes">ListingAttributes method</a>.
|
|
1083
|
+
* @param {Object=} priceRange - Filter min and/or max price (e.g. `{min: 1}` `{max: 2}` `{min: 1.50, max: 10.50})
|
|
1083
1084
|
* @param {string=} sellerAddress - Filter by a specific seller
|
|
1084
1085
|
* @param {string=} contractAddress - Filter results by the address of the NFT contract
|
|
1085
1086
|
* @param {string=} tokenId - Filter by token ID (if filtering by contract address)
|
|
1086
1087
|
* @param {string=} currency - Filter results by purchase currency. Available options: `usdc`
|
|
1087
1088
|
* @param {Object=} marketplaceParams - Filter results by marketplace
|
|
1088
|
-
* @param {integer
|
|
1089
|
+
* @param {Array<integer>=} collectionIndexes - If filtering by marketplace, filter by collection(s). The index refers to the index in the array `marketplace.collections`
|
|
1089
1090
|
* @param {integer=} lastNDays - Filter by results listed in the past N days
|
|
1090
1091
|
*
|
|
1091
1092
|
* @returns {Promise<Object>} - Results of the query and pagination info
|
|
@@ -1122,7 +1123,7 @@ exports.Listings = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRunt
|
|
|
1122
1123
|
* <br /><br />
|
|
1123
1124
|
* NOTE: This string must be an <b>exact match</b> on the item name.
|
|
1124
1125
|
* You can retrieve all available item names from the <a href="#.ListingNames">ListingNames method</a>.
|
|
1125
|
-
* @param {string
|
|
1126
|
+
* @param {Array<string>} editionFilters - Filter results by item edition.
|
|
1126
1127
|
* <br /><br />
|
|
1127
1128
|
* NOTE: This string must be an <b>exact match</b> on the edition name.
|
|
1128
1129
|
* You can retrieve all available item edition names from the <a href="#.ListingEditionNames">ListingEditionNames method</a>.
|
|
@@ -1130,12 +1131,13 @@ exports.Listings = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRunt
|
|
|
1130
1131
|
* <br /><br />
|
|
1131
1132
|
* NOTE: These filters must be an <b>exact match</b> on the attribute name and value.
|
|
1132
1133
|
* You can retrieve all available item attributes from the <a href="#.ListingAttributes">ListingAttributes method</a>.
|
|
1134
|
+
* @param {Object=} priceRange - Filter min and/or max price (e.g. `{min: 1}` `{max: 2}` `{min: 1.50, max: 10.50})
|
|
1133
1135
|
* @param {string=} sellerAddress - Filter by a specific seller
|
|
1134
1136
|
* @param {string=} contractAddress - Filter results by the address of the NFT contract
|
|
1135
1137
|
* @param {string=} tokenId - Filter by token ID (if filtering by contract address)
|
|
1136
1138
|
* @param {string=} currency - Filter results by purchase currency. Available options: `usdc`
|
|
1137
1139
|
* @param {Object=} marketplaceParams - Filter results by marketplace
|
|
1138
|
-
* @param {integer
|
|
1140
|
+
* @param {Array<integer>=} collectionIndexes - If filtering by marketplace, filter by collection(s). The index refers to the index in the array `marketplace.collections`
|
|
1139
1141
|
* @param {integer=} lastNDays - Filter by results listed in the past N days
|
|
1140
1142
|
*
|
|
1141
1143
|
* @returns {Promise<Object>} - Statistics about listings. All prices in USD.
|
|
@@ -1171,7 +1173,7 @@ exports.ListingStats = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regenerator
|
|
|
1171
1173
|
* <br /><br />
|
|
1172
1174
|
* NOTE: This string must be an <b>exact match</b> on the item name.
|
|
1173
1175
|
* You can retrieve all available item names from the <a href="#.ListingNames">ListingNames method</a>.
|
|
1174
|
-
* @param {string
|
|
1176
|
+
* @param {Array<string>} editionFilters - Filter results by item edition.
|
|
1175
1177
|
* <br /><br />
|
|
1176
1178
|
* NOTE: This string must be an <b>exact match</b> on the edition name.
|
|
1177
1179
|
* You can retrieve all available item edition names from the <a href="#.ListingEditionNames">ListingEditionNames method</a>.
|
|
@@ -1184,7 +1186,7 @@ exports.ListingStats = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regenerator
|
|
|
1184
1186
|
* @param {string=} tokenId - Filter by token ID (if filtering by contract address)
|
|
1185
1187
|
* @param {string=} currency - Filter results by purchase currency. Available options: `usdc`
|
|
1186
1188
|
* @param {Object=} marketplaceParams - Filter results by marketplace
|
|
1187
|
-
* @param {integer
|
|
1189
|
+
* @param {Array<integer>=} collectionIndexes - If filtering by marketplace, filter by collection(s). The index refers to the index in the array `marketplace.collections`
|
|
1188
1190
|
* @param {integer=} lastNDays - Filter by results listed in the past N days
|
|
1189
1191
|
*
|
|
1190
1192
|
* @returns {Promise<Object>} - Results of the query and pagination info
|
|
@@ -1220,7 +1222,7 @@ exports.Sales = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime
|
|
|
1220
1222
|
* <br /><br />
|
|
1221
1223
|
* NOTE: This string must be an <b>exact match</b> on the item name.
|
|
1222
1224
|
* You can retrieve all available item names from the <a href="#.ListingNames">ListingNames method</a>.
|
|
1223
|
-
* @param {string
|
|
1225
|
+
* @param {Array<string>} editionFilters - Filter results by item edition.
|
|
1224
1226
|
* <br /><br />
|
|
1225
1227
|
* NOTE: This string must be an <b>exact match</b> on the edition name.
|
|
1226
1228
|
* You can retrieve all available item edition names from the <a href="#.ListingEditionNames">ListingEditionNames method</a>.
|
|
@@ -1233,7 +1235,7 @@ exports.Sales = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime
|
|
|
1233
1235
|
* @param {string=} tokenId - Filter by token ID (if filtering by contract address)
|
|
1234
1236
|
* @param {string=} currency - Filter results by purchase currency. Available options: `usdc`
|
|
1235
1237
|
* @param {Object=} marketplaceParams - Filter results by marketplace
|
|
1236
|
-
* @param {integer
|
|
1238
|
+
* @param {Array<integer>=} collectionIndexes - If filtering by marketplace, filter by collection(s). The index refers to the index in the array `marketplace.collections`
|
|
1237
1239
|
* @param {integer=} lastNDays - Filter by results listed in the past N days
|
|
1238
1240
|
*
|
|
1239
1241
|
* @returns {Promise<Object>} - Results of the query and pagination info
|
|
@@ -1269,7 +1271,7 @@ exports.Transfers = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRun
|
|
|
1269
1271
|
* <br /><br />
|
|
1270
1272
|
* NOTE: This string must be an <b>exact match</b> on the item name.
|
|
1271
1273
|
* You can retrieve all available item names from the <a href="#.ListingNames">ListingNames method</a>.
|
|
1272
|
-
* @param {string
|
|
1274
|
+
* @param {Array<string>} editionFilters - Filter results by item edition.
|
|
1273
1275
|
* <br /><br />
|
|
1274
1276
|
* NOTE: This string must be an <b>exact match</b> on the edition name.
|
|
1275
1277
|
* You can retrieve all available item edition names from the <a href="#.ListingEditionNames">ListingEditionNames method</a>.
|
|
@@ -1282,7 +1284,7 @@ exports.Transfers = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRun
|
|
|
1282
1284
|
* @param {string=} tokenId - Filter by token ID (if filtering by contract address)
|
|
1283
1285
|
* @param {string=} currency - Filter results by purchase currency. Available options: `usdc`
|
|
1284
1286
|
* @param {Object=} marketplaceParams - Filter results by marketplace
|
|
1285
|
-
* @param {integer
|
|
1287
|
+
* @param {Array<integer>=} collectionIndexes - If filtering by marketplace, filter by collection(s). The index refers to the index in the array `marketplace.collections`
|
|
1286
1288
|
* @param {integer=} lastNDays - Filter by results listed in the past N days
|
|
1287
1289
|
*
|
|
1288
1290
|
* @returns {Promise<Object>} - Statistics about sales. All prices in USD.
|
|
@@ -12,7 +12,7 @@ var WalletConfiguration = {
|
|
|
12
12
|
staging: {
|
|
13
13
|
siteId: "iq__inauxD1KLyKWPHargCWjdCh2ayr",
|
|
14
14
|
purchaseMode: "production",
|
|
15
|
-
appUrl: "https://
|
|
15
|
+
appUrl: "https://wallet.preview.contentfabric.io"
|
|
16
16
|
},
|
|
17
17
|
production: {
|
|
18
18
|
siteId: "iq__suqRJUt2vmXsyiWS5ZaSGwtFU9R",
|