@wix/auto_sdk_suppliers-hub_products 1.0.2 → 1.0.4
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/build/cjs/index.d.ts +2 -2
- package/build/cjs/index.js +58 -0
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +2 -2
- package/build/cjs/index.typings.js +50 -0
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +20 -8
- package/build/cjs/meta.js +43 -0
- package/build/cjs/meta.js.map +1 -1
- package/build/cjs/{suppliershub-marketplace-product-v1-product-products.universal-DURUOslP.d.ts → suppliershub-marketplace-product-v1-product-products.universal-CkW0SvC9.d.ts} +18 -7
- package/build/es/index.d.mts +2 -2
- package/build/es/index.mjs +57 -0
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +2 -2
- package/build/es/index.typings.mjs +49 -0
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +20 -8
- package/build/es/meta.mjs +42 -0
- package/build/es/meta.mjs.map +1 -1
- package/build/es/{suppliershub-marketplace-product-v1-product-products.universal-DURUOslP.d.mts → suppliershub-marketplace-product-v1-product-products.universal-CkW0SvC9.d.mts} +18 -7
- package/build/internal/cjs/index.d.ts +22 -3
- package/build/internal/cjs/index.js +58 -0
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +2 -2
- package/build/internal/cjs/index.typings.js +50 -0
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +20 -8
- package/build/internal/cjs/meta.js +43 -0
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/cjs/{suppliershub-marketplace-product-v1-product-products.universal-DURUOslP.d.ts → suppliershub-marketplace-product-v1-product-products.universal-DbaC5KlK.d.ts} +52 -7
- package/build/internal/es/index.d.mts +22 -3
- package/build/internal/es/index.mjs +57 -0
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +2 -2
- package/build/internal/es/index.typings.mjs +49 -0
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +20 -8
- package/build/internal/es/meta.mjs +42 -0
- package/build/internal/es/meta.mjs.map +1 -1
- package/build/internal/es/{suppliershub-marketplace-product-v1-product-products.universal-DURUOslP.d.mts → suppliershub-marketplace-product-v1-product-products.universal-DbaC5KlK.d.mts} +52 -7
- package/package.json +4 -4
package/build/cjs/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpClient, NonNullablePaths, EventDefinition, MaybeContext, BuildRESTFunction, BuildEventDefinition } from '@wix/sdk-types';
|
|
2
|
-
import { P as Product, U as UpdateProduct, B as BulkCreateProductsOptions, a as BulkCreateProductsResponse, M as MaskedProduct, b as BulkUpdateProductsOptions, c as BulkUpdateProductsResponse, d as BulkDeleteProductsResponse, e as ProductSearch, S as SearchProductsResponse, f as BulkUpdateProductTagsOptions, g as BulkUpdateProductTagsResponse, h as BulkUpdateProductTagsApplicationErrors, i as BulkUpdateProductTagsByFilterOptions, j as BulkUpdateProductTagsByFilterResponse, k as BulkUpdateProductTagsByFilterApplicationErrors, Q as QueryCategoriesOptions, l as QueryCategoriesResponse, m as ProductCreatedEnvelope, n as ProductDeletedEnvelope, o as ProductTagsModifiedEnvelope, p as ProductUpdatedEnvelope, q as ProductsQueryBuilder, r as ProductQuery, t as typedQueryProducts } from './suppliershub-marketplace-product-v1-product-products.universal-
|
|
3
|
-
export {
|
|
2
|
+
import { P as Product, U as UpdateProduct, B as BulkCreateProductsOptions, a as BulkCreateProductsResponse, M as MaskedProduct, b as BulkUpdateProductsOptions, c as BulkUpdateProductsResponse, d as BulkDeleteProductsResponse, e as ProductSearch, S as SearchProductsResponse, f as BulkUpdateProductTagsOptions, g as BulkUpdateProductTagsResponse, h as BulkUpdateProductTagsApplicationErrors, i as BulkUpdateProductTagsByFilterOptions, j as BulkUpdateProductTagsByFilterResponse, k as BulkUpdateProductTagsByFilterApplicationErrors, Q as QueryCategoriesOptions, l as QueryCategoriesResponse, m as ProductCreatedEnvelope, n as ProductDeletedEnvelope, o as ProductTagsModifiedEnvelope, p as ProductUpdatedEnvelope, q as ProductsQueryBuilder, r as ProductQuery, t as typedQueryProducts } from './suppliershub-marketplace-product-v1-product-products.universal-CkW0SvC9.js';
|
|
3
|
+
export { bG as AccountInfo, bJ as AccountInfoMetadata, bB as ActionEvent, aI as Aggregation, aV as AggregationData, aJ as AggregationKindOneOf, bc as AggregationResults, bd as AggregationResultsResultOneOf, b0 as AggregationResultsScalarResult, F as AggregationType, c0 as AggregationTypeWithLiterals, aq as ApplicationError, bH as BaseEventMetadata, bn as Breadcrumb, as as BulkActionMetadata, bu as BulkAddProductToStoreResult, br as BulkAddProductsToStoreRequest, bt as BulkAddProductsToStoreResponse, ao as BulkCreateProductsRequest, av as BulkDeleteProductsRequest, aw as BulkDeleteProductsResponseBulkProductResult, ar as BulkProductResult, bg as BulkUpdateProductTagsByFilterRequest, be as BulkUpdateProductTagsRequest, bf as BulkUpdateProductTagsResult, at as BulkUpdateProductsRequest, au as BulkUpdateProductsResponseBulkProductResult, bm as Category, u as CategoryNamespace, bS as CategoryNamespaceWithLiterals, X as ColorOption, aB as CommonCursorPaging, aD as CommonCursorPagingMetadata, ay as CommonCursorQuery, az as CommonCursorQueryPagingMethodOneOf, aE as CommonCursors, c4 as CommonQueryWithEntityContext, c5 as CommonSearchWithEntityContext, x as CommonSortOrder, bV as CommonSortOrderWithLiterals, aA as CommonSorting, a0 as Countries, C as CountrySelections, bQ as CountrySelectionsWithLiterals, ag as CreateProductRequest, ah as CreateProductResponse, bl as CursorPaging, bp as CursorPagingMetadata, bi as CursorQuery, bj as CursorQueryPagingMethodOneOf, aG as CursorSearch, aH as CursorSearchPagingMethodOneOf, bq as Cursors, aQ as DateHistogramAggregation, b8 as DateHistogramResult, ba as DateHistogramResults, am as DeleteProductRequest, an as DeleteProductResponse, bv as DomainEvent, bw as DomainEventBodyOneOf, ac as DropshippingOptions, bC as Empty, bx as EntityCreatedEvent, bA as EntityDeletedEvent, bz as EntityUpdatedEvent, bI as EventMetadata, L as FocalPoint, ai as GetProductRequest, aj as GetProductResponse, b9 as GroupByValueResults, bE as IdentificationData, bF as IdentificationDataIdOneOf, aL as IncludeMissingValuesOptions, E as Interval, b$ as IntervalWithLiterals, a1 as Inventory, I as InventoryTier, bR as InventoryTierWithLiterals, ap as ItemMetadata, a9 as Measurement, w as MeasurementUnit, bU as MeasurementUnitWithLiterals, aa as MeasurementValueOneOf, ab as MeasurementValueRange, K as Media, bD as MessageEnvelope, A as MissingValues, bY as MissingValuesWithLiterals, G as Mode, c1 as ModeWithLiterals, aT as NestedAggregation, aR as NestedAggregationItem, aS as NestedAggregationItemKindOneOf, aY as NestedAggregationResults, aZ as NestedAggregationResultsResultOneOf, N as NestedAggregationType, b_ as NestedAggregationTypeWithLiterals, b5 as NestedResultValue, b6 as NestedResultValueResultOneOf, bb as NestedResults, b1 as NestedValueAggregationResult, R as OptionValue, V as OptionValueValueOneOf, bo as ParentCategory, a4 as PriceTier, a6 as PrintOnDemandOptions, v as PrintTechnology, bT as PrintTechnologyWithLiterals, a2 as ProductCategory, O as ProductOption, bL as ProductQuerySpec, bs as ProductReference, bM as ProductSearchSpec, s as ProductType, bO as ProductTypeWithLiterals, bK as ProductsQueryResult, J as ProviderInfo, bh as QueryCategoriesRequest, ax as QueryProductsRequest, aC as QueryProductsResponse, aO as RangeAggregation, aX as RangeAggregationResult, aK as RangeBucket, b3 as RangeResult, a$ as RangeResults, by as RestoreInfo, b7 as Results, aP as ScalarAggregation, b4 as ScalarResult, D as ScalarType, bZ as ScalarTypeWithLiterals, aU as SearchDetails, aF as SearchProductsRequest, _ as ShippingDestination, $ as ShippingDestinationCountriesOptionsOneOf, a7 as SizeGuide, z as SortDirection, bX as SortDirectionWithLiterals, H as SortOrder, c2 as SortOrderWithLiterals, y as SortType, bW as SortTypeWithLiterals, bk as Sorting, a8 as Specification, a5 as SupplierInfo, ae as TagList, ad as Tags, af as TagsModified, Y as TimeInterval, T as TimeUnit, bP as TimeUnitWithLiterals, Z as TimeValue, ak as UpdateProductRequest, al as UpdateProductResponse, aM as ValueAggregation, aN as ValueAggregationOptionsOneOf, aW as ValueAggregationResult, b2 as ValueResult, a_ as ValueResults, W as WebhookIdentityType, c3 as WebhookIdentityTypeWithLiterals, a3 as WholesaleOptions, bN as utils } from './suppliershub-marketplace-product-v1-product-products.universal-CkW0SvC9.js';
|
|
4
4
|
|
|
5
5
|
declare function createProduct$1(httpClient: HttpClient): CreateProductSignature;
|
|
6
6
|
interface CreateProductSignature {
|
package/build/cjs/index.js
CHANGED
|
@@ -38,6 +38,7 @@ __export(index_exports, {
|
|
|
38
38
|
SortType: () => SortType,
|
|
39
39
|
TimeUnit: () => TimeUnit,
|
|
40
40
|
WebhookIdentityType: () => WebhookIdentityType,
|
|
41
|
+
bulkAddProductsToStore: () => bulkAddProductsToStore4,
|
|
41
42
|
bulkCreateProducts: () => bulkCreateProducts4,
|
|
42
43
|
bulkDeleteProducts: () => bulkDeleteProducts4,
|
|
43
44
|
bulkUpdateProductTags: () => bulkUpdateProductTags4,
|
|
@@ -745,6 +746,27 @@ function queryCategories(payload) {
|
|
|
745
746
|
}
|
|
746
747
|
return __queryCategories;
|
|
747
748
|
}
|
|
749
|
+
function bulkAddProductsToStore(payload) {
|
|
750
|
+
function __bulkAddProductsToStore({ host }) {
|
|
751
|
+
const metadata = {
|
|
752
|
+
entityFqdn: "wix.suppliershub.marketplace_product.v1.product",
|
|
753
|
+
method: "POST",
|
|
754
|
+
methodFqn: "wix.suppliershub.marketplace.product.v1.MarketplaceProduct.BulkAddProductsToStore",
|
|
755
|
+
packageName: PACKAGE_NAME,
|
|
756
|
+
migrationOptions: {
|
|
757
|
+
optInTransformResponse: true
|
|
758
|
+
},
|
|
759
|
+
url: resolveWixSuppliershubMarketplaceProductV1MarketplaceProductUrl({
|
|
760
|
+
protoPath: "/v1/bulk/add-products-to-store",
|
|
761
|
+
data: payload,
|
|
762
|
+
host
|
|
763
|
+
}),
|
|
764
|
+
data: payload
|
|
765
|
+
};
|
|
766
|
+
return metadata;
|
|
767
|
+
}
|
|
768
|
+
return __bulkAddProductsToStore;
|
|
769
|
+
}
|
|
748
770
|
|
|
749
771
|
// src/suppliershub-marketplace-product-v1-product-products.universal.ts
|
|
750
772
|
var import_image = require("@wix/sdk-runtime/transformations/image");
|
|
@@ -1386,6 +1408,33 @@ async function queryCategories2(options) {
|
|
|
1386
1408
|
throw transformedError;
|
|
1387
1409
|
}
|
|
1388
1410
|
}
|
|
1411
|
+
async function bulkAddProductsToStore2(productReferences) {
|
|
1412
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
1413
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
1414
|
+
productReferences
|
|
1415
|
+
});
|
|
1416
|
+
const reqOpts = bulkAddProductsToStore(
|
|
1417
|
+
payload
|
|
1418
|
+
);
|
|
1419
|
+
sideEffects?.onSiteCall?.();
|
|
1420
|
+
try {
|
|
1421
|
+
const result = await httpClient.request(reqOpts);
|
|
1422
|
+
sideEffects?.onSuccess?.(result);
|
|
1423
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
1424
|
+
} catch (err) {
|
|
1425
|
+
const transformedError = (0, import_transform_error.transformError)(
|
|
1426
|
+
err,
|
|
1427
|
+
{
|
|
1428
|
+
spreadPathsToArguments: {},
|
|
1429
|
+
explicitPathsToArguments: { productReferences: "$[0]" },
|
|
1430
|
+
singleArgumentUnchanged: false
|
|
1431
|
+
},
|
|
1432
|
+
["productReferences"]
|
|
1433
|
+
);
|
|
1434
|
+
sideEffects?.onError?.(err);
|
|
1435
|
+
throw transformedError;
|
|
1436
|
+
}
|
|
1437
|
+
}
|
|
1389
1438
|
|
|
1390
1439
|
// src/suppliershub-marketplace-product-v1-product-products.public.ts
|
|
1391
1440
|
function createProduct3(httpClient) {
|
|
@@ -1483,6 +1532,13 @@ function queryCategories3(httpClient) {
|
|
|
1483
1532
|
{ httpClient }
|
|
1484
1533
|
);
|
|
1485
1534
|
}
|
|
1535
|
+
function bulkAddProductsToStore3(httpClient) {
|
|
1536
|
+
return (productReferences) => bulkAddProductsToStore2(
|
|
1537
|
+
productReferences,
|
|
1538
|
+
// @ts-ignore
|
|
1539
|
+
{ httpClient }
|
|
1540
|
+
);
|
|
1541
|
+
}
|
|
1486
1542
|
var onProductCreated = (0, import_sdk_types.EventDefinition)(
|
|
1487
1543
|
"wix.suppliershub.marketplace_product.v1.product_created",
|
|
1488
1544
|
true,
|
|
@@ -1616,6 +1672,7 @@ var searchProducts4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)
|
|
|
1616
1672
|
var bulkUpdateProductTags4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(bulkUpdateProductTags3);
|
|
1617
1673
|
var bulkUpdateProductTagsByFilter4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(bulkUpdateProductTagsByFilter3);
|
|
1618
1674
|
var queryCategories4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(queryCategories3);
|
|
1675
|
+
var bulkAddProductsToStore4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(bulkAddProductsToStore3);
|
|
1619
1676
|
var queryProducts4 = /* @__PURE__ */ (0, import_rest_modules3.createRESTModule)(customQueryProducts);
|
|
1620
1677
|
var onProductCreated2 = (0, import_event_definition_modules.createEventModule)(onProductCreated);
|
|
1621
1678
|
var onProductDeleted2 = (0, import_event_definition_modules.createEventModule)(onProductDeleted);
|
|
@@ -1643,6 +1700,7 @@ var onProductUpdated2 = (0, import_event_definition_modules.createEventModule)(o
|
|
|
1643
1700
|
SortType,
|
|
1644
1701
|
TimeUnit,
|
|
1645
1702
|
WebhookIdentityType,
|
|
1703
|
+
bulkAddProductsToStore,
|
|
1646
1704
|
bulkCreateProducts,
|
|
1647
1705
|
bulkDeleteProducts,
|
|
1648
1706
|
bulkUpdateProductTags,
|