@elasticpath/js-sdk 14.0.0 → 15.1.0
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/index.cjs.js +26 -6
- package/dist/index.d.ts +17 -1
- package/dist/index.esm.js +26 -6
- package/dist/index.js +26 -6
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -530,7 +530,7 @@ if (!globalThis.fetch) {
|
|
|
530
530
|
globalThis.Response = fetch$1.Response;
|
|
531
531
|
}
|
|
532
532
|
|
|
533
|
-
var version = "
|
|
533
|
+
var version = "15.1.0";
|
|
534
534
|
|
|
535
535
|
var LocalStorageFactory = /*#__PURE__*/function () {
|
|
536
536
|
function LocalStorageFactory() {
|
|
@@ -5444,6 +5444,26 @@ var Products = /*#__PURE__*/function (_ShopperCatalogProduc) {
|
|
|
5444
5444
|
includes: includes
|
|
5445
5445
|
}), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
5446
5446
|
}
|
|
5447
|
+
}, {
|
|
5448
|
+
key: "GetRelatedProducts",
|
|
5449
|
+
value: function GetRelatedProducts(_ref15) {
|
|
5450
|
+
var productId = _ref15.productId,
|
|
5451
|
+
customRelationshipSlug = _ref15.customRelationshipSlug,
|
|
5452
|
+
_ref15$token = _ref15.token,
|
|
5453
|
+
token = _ref15$token === void 0 ? null : _ref15$token,
|
|
5454
|
+
_ref15$additionalHead = _ref15.additionalHeaders,
|
|
5455
|
+
additionalHeaders = _ref15$additionalHead === void 0 ? null : _ref15$additionalHead;
|
|
5456
|
+
var limit = this.limit,
|
|
5457
|
+
offset = this.offset,
|
|
5458
|
+
filter = this.filter,
|
|
5459
|
+
includes = this.includes;
|
|
5460
|
+
return this.request.send(buildURL("catalog/".concat(this.endpoint, "/").concat(productId, "/relationships/").concat(customRelationshipSlug, "/products"), {
|
|
5461
|
+
limit: limit,
|
|
5462
|
+
offset: offset,
|
|
5463
|
+
filter: filter,
|
|
5464
|
+
includes: includes
|
|
5465
|
+
}), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
5466
|
+
}
|
|
5447
5467
|
}]);
|
|
5448
5468
|
return Products;
|
|
5449
5469
|
}(ShopperCatalogProductsQuery);
|
|
@@ -5468,11 +5488,11 @@ var ShopperCatalogEndpoint = /*#__PURE__*/function (_ShopperCatalogQuery4) {
|
|
|
5468
5488
|
_createClass(ShopperCatalogEndpoint, [{
|
|
5469
5489
|
key: "Get",
|
|
5470
5490
|
value: function Get() {
|
|
5471
|
-
var
|
|
5472
|
-
|
|
5473
|
-
token =
|
|
5474
|
-
|
|
5475
|
-
additionalHeaders =
|
|
5491
|
+
var _ref16 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
5492
|
+
_ref16$token = _ref16.token,
|
|
5493
|
+
token = _ref16$token === void 0 ? null : _ref16$token,
|
|
5494
|
+
_ref16$additionalHead = _ref16.additionalHeaders,
|
|
5495
|
+
additionalHeaders = _ref16$additionalHead === void 0 ? null : _ref16$additionalHead;
|
|
5476
5496
|
this.call = this.request.send("".concat(this.endpoint), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
5477
5497
|
return this.call;
|
|
5478
5498
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -5637,6 +5637,13 @@ interface ShopperCatalogProductsEndpoint
|
|
|
5637
5637
|
token?: string
|
|
5638
5638
|
additionalHeaders?: ShopperCatalogAdditionalHeaders
|
|
5639
5639
|
}): Promise<ShopperCatalogResourcePage<ProductResponse>>
|
|
5640
|
+
|
|
5641
|
+
GetRelatedProducts(options: {
|
|
5642
|
+
productId: string
|
|
5643
|
+
customRelationshipSlug: string
|
|
5644
|
+
token?: string
|
|
5645
|
+
additionalHeaders?: ShopperCatalogAdditionalHeaders
|
|
5646
|
+
}): Promise<ShopperCatalogResourcePage<ProductResponse>>
|
|
5640
5647
|
}
|
|
5641
5648
|
|
|
5642
5649
|
interface NodesShopperCatalogEndpoint
|
|
@@ -8532,7 +8539,16 @@ interface Location extends Identifiable, LocationBase {}
|
|
|
8532
8539
|
|
|
8533
8540
|
interface CreateLocationBody extends LocationAttributes {}
|
|
8534
8541
|
|
|
8535
|
-
interface UpdateLocationBody
|
|
8542
|
+
interface UpdateLocationBody
|
|
8543
|
+
extends Omit<
|
|
8544
|
+
LocationAttributes,
|
|
8545
|
+
'external_ref' | 'description' | 'address' | 'geolocation'
|
|
8546
|
+
> {
|
|
8547
|
+
external_ref?: string | null
|
|
8548
|
+
description?: string | null
|
|
8549
|
+
address?: string[] | null[]
|
|
8550
|
+
geolocation?: GeolocationDetails | null
|
|
8551
|
+
}
|
|
8536
8552
|
|
|
8537
8553
|
/**
|
|
8538
8554
|
* Location Endpoints
|
package/dist/index.esm.js
CHANGED
|
@@ -519,7 +519,7 @@ if (!globalThis.fetch) {
|
|
|
519
519
|
globalThis.Response = Response;
|
|
520
520
|
}
|
|
521
521
|
|
|
522
|
-
var version = "
|
|
522
|
+
var version = "15.1.0";
|
|
523
523
|
|
|
524
524
|
var LocalStorageFactory = /*#__PURE__*/function () {
|
|
525
525
|
function LocalStorageFactory() {
|
|
@@ -5433,6 +5433,26 @@ var Products = /*#__PURE__*/function (_ShopperCatalogProduc) {
|
|
|
5433
5433
|
includes: includes
|
|
5434
5434
|
}), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
5435
5435
|
}
|
|
5436
|
+
}, {
|
|
5437
|
+
key: "GetRelatedProducts",
|
|
5438
|
+
value: function GetRelatedProducts(_ref15) {
|
|
5439
|
+
var productId = _ref15.productId,
|
|
5440
|
+
customRelationshipSlug = _ref15.customRelationshipSlug,
|
|
5441
|
+
_ref15$token = _ref15.token,
|
|
5442
|
+
token = _ref15$token === void 0 ? null : _ref15$token,
|
|
5443
|
+
_ref15$additionalHead = _ref15.additionalHeaders,
|
|
5444
|
+
additionalHeaders = _ref15$additionalHead === void 0 ? null : _ref15$additionalHead;
|
|
5445
|
+
var limit = this.limit,
|
|
5446
|
+
offset = this.offset,
|
|
5447
|
+
filter = this.filter,
|
|
5448
|
+
includes = this.includes;
|
|
5449
|
+
return this.request.send(buildURL("catalog/".concat(this.endpoint, "/").concat(productId, "/relationships/").concat(customRelationshipSlug, "/products"), {
|
|
5450
|
+
limit: limit,
|
|
5451
|
+
offset: offset,
|
|
5452
|
+
filter: filter,
|
|
5453
|
+
includes: includes
|
|
5454
|
+
}), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
5455
|
+
}
|
|
5436
5456
|
}]);
|
|
5437
5457
|
return Products;
|
|
5438
5458
|
}(ShopperCatalogProductsQuery);
|
|
@@ -5457,11 +5477,11 @@ var ShopperCatalogEndpoint = /*#__PURE__*/function (_ShopperCatalogQuery4) {
|
|
|
5457
5477
|
_createClass(ShopperCatalogEndpoint, [{
|
|
5458
5478
|
key: "Get",
|
|
5459
5479
|
value: function Get() {
|
|
5460
|
-
var
|
|
5461
|
-
|
|
5462
|
-
token =
|
|
5463
|
-
|
|
5464
|
-
additionalHeaders =
|
|
5480
|
+
var _ref16 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
5481
|
+
_ref16$token = _ref16.token,
|
|
5482
|
+
token = _ref16$token === void 0 ? null : _ref16$token,
|
|
5483
|
+
_ref16$additionalHead = _ref16.additionalHeaders,
|
|
5484
|
+
additionalHeaders = _ref16$additionalHead === void 0 ? null : _ref16$additionalHead;
|
|
5465
5485
|
this.call = this.request.send("".concat(this.endpoint), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
5466
5486
|
return this.call;
|
|
5467
5487
|
}
|
package/dist/index.js
CHANGED
|
@@ -1085,7 +1085,7 @@
|
|
|
1085
1085
|
globalThis.Response = browserPonyfill.exports.Response;
|
|
1086
1086
|
}
|
|
1087
1087
|
|
|
1088
|
-
var version = "
|
|
1088
|
+
var version = "15.1.0";
|
|
1089
1089
|
|
|
1090
1090
|
var LocalStorageFactory = /*#__PURE__*/function () {
|
|
1091
1091
|
function LocalStorageFactory() {
|
|
@@ -6605,6 +6605,26 @@
|
|
|
6605
6605
|
includes: includes
|
|
6606
6606
|
}), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
6607
6607
|
}
|
|
6608
|
+
}, {
|
|
6609
|
+
key: "GetRelatedProducts",
|
|
6610
|
+
value: function GetRelatedProducts(_ref15) {
|
|
6611
|
+
var productId = _ref15.productId,
|
|
6612
|
+
customRelationshipSlug = _ref15.customRelationshipSlug,
|
|
6613
|
+
_ref15$token = _ref15.token,
|
|
6614
|
+
token = _ref15$token === void 0 ? null : _ref15$token,
|
|
6615
|
+
_ref15$additionalHead = _ref15.additionalHeaders,
|
|
6616
|
+
additionalHeaders = _ref15$additionalHead === void 0 ? null : _ref15$additionalHead;
|
|
6617
|
+
var limit = this.limit,
|
|
6618
|
+
offset = this.offset,
|
|
6619
|
+
filter = this.filter,
|
|
6620
|
+
includes = this.includes;
|
|
6621
|
+
return this.request.send(buildURL("catalog/".concat(this.endpoint, "/").concat(productId, "/relationships/").concat(customRelationshipSlug, "/products"), {
|
|
6622
|
+
limit: limit,
|
|
6623
|
+
offset: offset,
|
|
6624
|
+
filter: filter,
|
|
6625
|
+
includes: includes
|
|
6626
|
+
}), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
6627
|
+
}
|
|
6608
6628
|
}]);
|
|
6609
6629
|
return Products;
|
|
6610
6630
|
}(ShopperCatalogProductsQuery);
|
|
@@ -6629,11 +6649,11 @@
|
|
|
6629
6649
|
_createClass(ShopperCatalogEndpoint, [{
|
|
6630
6650
|
key: "Get",
|
|
6631
6651
|
value: function Get() {
|
|
6632
|
-
var
|
|
6633
|
-
|
|
6634
|
-
token =
|
|
6635
|
-
|
|
6636
|
-
additionalHeaders =
|
|
6652
|
+
var _ref16 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
6653
|
+
_ref16$token = _ref16.token,
|
|
6654
|
+
token = _ref16$token === void 0 ? null : _ref16$token,
|
|
6655
|
+
_ref16$additionalHead = _ref16.additionalHeaders,
|
|
6656
|
+
additionalHeaders = _ref16$additionalHead === void 0 ? null : _ref16$additionalHead;
|
|
6637
6657
|
this.call = this.request.send("".concat(this.endpoint), 'GET', undefined, token, undefined, false, undefined, additionalHeaders);
|
|
6638
6658
|
return this.call;
|
|
6639
6659
|
}
|
package/package.json
CHANGED