@wix/auto_sdk_stores_customizations-v-3 1.0.90 → 1.0.92
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 +11 -3
- package/build/cjs/index.js +64 -10
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +22 -10
- package/build/cjs/index.typings.js +49 -3
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +11 -2
- package/build/cjs/meta.js +41 -0
- package/build/cjs/meta.js.map +1 -1
- package/build/cjs/schemas.d.ts +9 -1
- package/build/cjs/schemas.js +38 -26
- package/build/cjs/schemas.js.map +1 -1
- package/build/es/index.d.mts +11 -3
- package/build/es/index.mjs +63 -10
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +22 -10
- package/build/es/index.typings.mjs +48 -3
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +11 -2
- package/build/es/meta.mjs +40 -0
- package/build/es/meta.mjs.map +1 -1
- package/build/es/schemas.d.mts +9 -1
- package/build/es/schemas.mjs +36 -26
- package/build/es/schemas.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +11 -3
- package/build/internal/cjs/index.js +64 -10
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +22 -10
- package/build/internal/cjs/index.typings.js +49 -3
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +11 -2
- package/build/internal/cjs/meta.js +41 -0
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/cjs/schemas.d.ts +9 -1
- package/build/internal/cjs/schemas.js +38 -26
- package/build/internal/cjs/schemas.js.map +1 -1
- package/build/internal/es/index.d.mts +11 -3
- package/build/internal/es/index.mjs +63 -10
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +22 -10
- package/build/internal/es/index.typings.mjs +48 -3
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +11 -2
- package/build/internal/es/meta.mjs +40 -0
- package/build/internal/es/meta.mjs.map +1 -1
- package/build/internal/es/schemas.d.mts +9 -1
- package/build/internal/es/schemas.mjs +36 -26
- package/build/internal/es/schemas.mjs.map +1 -1
- package/package.json +3 -3
|
@@ -639,6 +639,14 @@ interface Cursors {
|
|
|
639
639
|
*/
|
|
640
640
|
prev?: string | null;
|
|
641
641
|
}
|
|
642
|
+
interface CountCustomizationsRequest {
|
|
643
|
+
/** Filter object. See API Query Language for more information. */
|
|
644
|
+
filter?: Record<string, any> | null;
|
|
645
|
+
}
|
|
646
|
+
interface CountCustomizationsResponse {
|
|
647
|
+
/** Number of customizations that match the filter. */
|
|
648
|
+
count?: number;
|
|
649
|
+
}
|
|
642
650
|
interface BulkCreateCustomizationsRequest {
|
|
643
651
|
/**
|
|
644
652
|
* Customizations to create.
|
|
@@ -1747,10 +1755,6 @@ interface CustomizationsQueryBuilder {
|
|
|
1747
1755
|
* @param string - String to compare against. Case-insensitive.
|
|
1748
1756
|
*/
|
|
1749
1757
|
startsWith: (propertyName: '_id' | 'name', value: string) => CustomizationsQueryBuilder;
|
|
1750
|
-
/** @param propertyName - Property whose value is compared with `values`.
|
|
1751
|
-
* @param values - List of values to compare against.
|
|
1752
|
-
*/
|
|
1753
|
-
hasSome: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name' | 'customizationType' | 'customizationRenderType', value: any[]) => CustomizationsQueryBuilder;
|
|
1754
1758
|
in: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name' | 'customizationType' | 'customizationRenderType', value: any) => CustomizationsQueryBuilder;
|
|
1755
1759
|
exists: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name' | 'customizationType' | 'customizationRenderType', value: boolean) => CustomizationsQueryBuilder;
|
|
1756
1760
|
/** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. */
|
|
@@ -1845,12 +1849,20 @@ type CustomizationQuery = {
|
|
|
1845
1849
|
}[];
|
|
1846
1850
|
};
|
|
1847
1851
|
declare const utils: {
|
|
1848
|
-
query:
|
|
1849
|
-
QueryBuilder: () => _wix_sdk_types.QueryBuilder<Customization, CustomizationQuerySpec, CustomizationQuery>;
|
|
1850
|
-
Filter: _wix_sdk_types.FilterFactory<Customization, CustomizationQuerySpec>;
|
|
1851
|
-
Sort: _wix_sdk_types.SortFactory<CustomizationQuerySpec>;
|
|
1852
|
-
};
|
|
1852
|
+
query: _wix_sdk_types.QueryHelpers<Customization, CustomizationQuerySpec, CustomizationQuery>;
|
|
1853
1853
|
};
|
|
1854
|
+
/**
|
|
1855
|
+
* Counts the customizations that match the provided filter.
|
|
1856
|
+
* @public
|
|
1857
|
+
* @permissionId WIX_STORES.CUSTOMIZATION_READ
|
|
1858
|
+
* @applicableIdentity APP
|
|
1859
|
+
* @fqn wix.stores.catalog.customization.v3.CustomizationService.CountCustomizations
|
|
1860
|
+
*/
|
|
1861
|
+
declare function countCustomizations(options?: CountCustomizationsOptions): Promise<NonNullablePaths<CountCustomizationsResponse, `count`, 2>>;
|
|
1862
|
+
interface CountCustomizationsOptions {
|
|
1863
|
+
/** Filter object. See API Query Language for more information. */
|
|
1864
|
+
filter?: Record<string, any> | null;
|
|
1865
|
+
}
|
|
1854
1866
|
/**
|
|
1855
1867
|
* Creates multiple customizations.
|
|
1856
1868
|
* @param customizations - Customizations to create.
|
|
@@ -2089,4 +2101,4 @@ interface BulkUpdateCustomizationsOptions {
|
|
|
2089
2101
|
fields?: RequestedFieldsWithLiterals[];
|
|
2090
2102
|
}
|
|
2091
2103
|
|
|
2092
|
-
export { type AccountInfo, type AccountInfoMetadata, type ActionEvent, type AddCustomizationChoicesApplicationErrors, type AddCustomizationChoicesOptions, type AddCustomizationChoicesRequest, type AddCustomizationChoicesResponse, type AddCustomizationChoicesValidationErrors, type App, type ApplicationError, type BaseEventMetadata, type BulkActionMetadata, type BulkAddCustomizationChoicesApplicationErrors, type BulkAddCustomizationChoicesOptions, type BulkAddCustomizationChoicesRequest, type BulkAddCustomizationChoicesResponse, type BulkAddCustomizationChoicesValidationErrors, type BulkCreateCustomizationsApplicationErrors, type BulkCreateCustomizationsForMigrationRequest, type BulkCreateCustomizationsForMigrationResponse, type BulkCreateCustomizationsOptions, type BulkCreateCustomizationsRequest, type BulkCreateCustomizationsResponse, type BulkCreateCustomizationsValidationErrors, type BulkCustomizationResult, type BulkUpdateCustomizationsOptions, type BulkUpdateCustomizationsRequest, type BulkUpdateCustomizationsResponse, type CatalogRollbackRequested, type Choice, type ChoiceIdsMismatchData, ChoiceSortStrategy, type ChoiceSortStrategyWithLiterals, ChoiceType, type ChoiceTypeWithLiterals, type ChoiceValueOneOf, type ChoicesSettings, type CommonQueryWithEntityContext, type CreateCustomizationApplicationErrors, type CreateCustomizationRequest, type CreateCustomizationResponse, type CreateCustomizationValidationErrors, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type CustomTag, type Customization, type CustomizationChoices, type CustomizationCreatedEnvelope, type CustomizationCustomizationSettingsOneOf, type CustomizationDeletedEnvelope, type CustomizationIdsWrapper, type CustomizationQuery, type CustomizationQuerySpec, CustomizationRenderType, type CustomizationRenderTypeWithLiterals, CustomizationType, type CustomizationTypeWithLiterals, type CustomizationUpdatedEnvelope, type CustomizationsQueryBuilder, type CustomizationsQueryResult, type DeleteCustomizationRequest, type DeleteCustomizationResponse, type DeleteCustomizationValidationErrors, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type EventMetadata, type File, type FocalPoint, type FreeTextSettings, type GetCustomizationOptions, type GetCustomizationRequest, type GetCustomizationResponse, type IdentificationData, type IdentificationDataIdOneOf, type InvalidateCache, type InvalidateCacheGetByOneOf, type ItemMetadata, type MaskedChoice, type MaskedCustomization, type MessageEnvelope, type MultipleColors, type Page, type Pages, type QueryCustomizationsOptions, type QueryCustomizationsRequest, type QueryCustomizationsResponse, type RecloneSiteRequest, type RecloneSiteResponse, type RemoveCustomizationChoicesApplicationErrors, type RemoveCustomizationChoicesOptions, type RemoveCustomizationChoicesRequest, type RemoveCustomizationChoicesResponse, type RemoveCustomizationChoicesValidationErrors, type ReorderCustomizationChoicesApplicationErrors, type ReorderCustomizationChoicesOptions, type ReorderCustomizationChoicesRequest, type ReorderCustomizationChoicesResponse, RequestedFields, type RequestedFieldsWithLiterals, type RestoreInfo, type SetCustomizationChoicesApplicationErrors, type SetCustomizationChoicesOptions, type SetCustomizationChoicesRequest, type SetCustomizationChoicesResponse, type SetCustomizationChoicesValidationErrors, SortOrder, type SortOrderWithLiterals, type Sorting, type URI, type URIs, type UpdateCustomization, type UpdateCustomizationChoicesApplicationErrors, type UpdateCustomizationChoicesOptions, type UpdateCustomizationChoicesRequest, type UpdateCustomizationChoicesResponse, type UpdateCustomizationChoicesValidationErrors, type UpdateCustomizationOptions, type UpdateCustomizationRequest, type UpdateCustomizationResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, addCustomizationChoices, bulkAddCustomizationChoices, bulkCreateCustomizations, bulkUpdateCustomizations, createCustomization, deleteCustomization, getCustomization, onCustomizationCreated, onCustomizationDeleted, onCustomizationUpdated, queryCustomizations, removeCustomizationChoices, reorderCustomizationChoices, setCustomizationChoices, typedQueryCustomizations, updateCustomization, updateCustomizationChoices, utils };
|
|
2104
|
+
export { type AccountInfo, type AccountInfoMetadata, type ActionEvent, type AddCustomizationChoicesApplicationErrors, type AddCustomizationChoicesOptions, type AddCustomizationChoicesRequest, type AddCustomizationChoicesResponse, type AddCustomizationChoicesValidationErrors, type App, type ApplicationError, type BaseEventMetadata, type BulkActionMetadata, type BulkAddCustomizationChoicesApplicationErrors, type BulkAddCustomizationChoicesOptions, type BulkAddCustomizationChoicesRequest, type BulkAddCustomizationChoicesResponse, type BulkAddCustomizationChoicesValidationErrors, type BulkCreateCustomizationsApplicationErrors, type BulkCreateCustomizationsForMigrationRequest, type BulkCreateCustomizationsForMigrationResponse, type BulkCreateCustomizationsOptions, type BulkCreateCustomizationsRequest, type BulkCreateCustomizationsResponse, type BulkCreateCustomizationsValidationErrors, type BulkCustomizationResult, type BulkUpdateCustomizationsOptions, type BulkUpdateCustomizationsRequest, type BulkUpdateCustomizationsResponse, type CatalogRollbackRequested, type Choice, type ChoiceIdsMismatchData, ChoiceSortStrategy, type ChoiceSortStrategyWithLiterals, ChoiceType, type ChoiceTypeWithLiterals, type ChoiceValueOneOf, type ChoicesSettings, type CommonQueryWithEntityContext, type CountCustomizationsOptions, type CountCustomizationsRequest, type CountCustomizationsResponse, type CreateCustomizationApplicationErrors, type CreateCustomizationRequest, type CreateCustomizationResponse, type CreateCustomizationValidationErrors, type CursorPaging, type CursorPagingMetadata, type CursorQuery, type CursorQueryPagingMethodOneOf, type Cursors, type CustomTag, type Customization, type CustomizationChoices, type CustomizationCreatedEnvelope, type CustomizationCustomizationSettingsOneOf, type CustomizationDeletedEnvelope, type CustomizationIdsWrapper, type CustomizationQuery, type CustomizationQuerySpec, CustomizationRenderType, type CustomizationRenderTypeWithLiterals, CustomizationType, type CustomizationTypeWithLiterals, type CustomizationUpdatedEnvelope, type CustomizationsQueryBuilder, type CustomizationsQueryResult, type DeleteCustomizationRequest, type DeleteCustomizationResponse, type DeleteCustomizationValidationErrors, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type EventMetadata, type File, type FocalPoint, type FreeTextSettings, type GetCustomizationOptions, type GetCustomizationRequest, type GetCustomizationResponse, type IdentificationData, type IdentificationDataIdOneOf, type InvalidateCache, type InvalidateCacheGetByOneOf, type ItemMetadata, type MaskedChoice, type MaskedCustomization, type MessageEnvelope, type MultipleColors, type Page, type Pages, type QueryCustomizationsOptions, type QueryCustomizationsRequest, type QueryCustomizationsResponse, type RecloneSiteRequest, type RecloneSiteResponse, type RemoveCustomizationChoicesApplicationErrors, type RemoveCustomizationChoicesOptions, type RemoveCustomizationChoicesRequest, type RemoveCustomizationChoicesResponse, type RemoveCustomizationChoicesValidationErrors, type ReorderCustomizationChoicesApplicationErrors, type ReorderCustomizationChoicesOptions, type ReorderCustomizationChoicesRequest, type ReorderCustomizationChoicesResponse, RequestedFields, type RequestedFieldsWithLiterals, type RestoreInfo, type SetCustomizationChoicesApplicationErrors, type SetCustomizationChoicesOptions, type SetCustomizationChoicesRequest, type SetCustomizationChoicesResponse, type SetCustomizationChoicesValidationErrors, SortOrder, type SortOrderWithLiterals, type Sorting, type URI, type URIs, type UpdateCustomization, type UpdateCustomizationChoicesApplicationErrors, type UpdateCustomizationChoicesOptions, type UpdateCustomizationChoicesRequest, type UpdateCustomizationChoicesResponse, type UpdateCustomizationChoicesValidationErrors, type UpdateCustomizationOptions, type UpdateCustomizationRequest, type UpdateCustomizationResponse, WebhookIdentityType, type WebhookIdentityTypeWithLiterals, addCustomizationChoices, bulkAddCustomizationChoices, bulkCreateCustomizations, bulkUpdateCustomizations, countCustomizations, createCustomization, deleteCustomization, getCustomization, onCustomizationCreated, onCustomizationDeleted, onCustomizationUpdated, queryCustomizations, removeCustomizationChoices, reorderCustomizationChoices, setCustomizationChoices, typedQueryCustomizations, updateCustomization, updateCustomizationChoices, utils };
|
|
@@ -31,6 +31,7 @@ __export(index_typings_exports, {
|
|
|
31
31
|
bulkAddCustomizationChoices: () => bulkAddCustomizationChoices2,
|
|
32
32
|
bulkCreateCustomizations: () => bulkCreateCustomizations2,
|
|
33
33
|
bulkUpdateCustomizations: () => bulkUpdateCustomizations2,
|
|
34
|
+
countCustomizations: () => countCustomizations2,
|
|
34
35
|
createCustomization: () => createCustomization2,
|
|
35
36
|
deleteCustomization: () => deleteCustomization2,
|
|
36
37
|
getCustomization: () => getCustomization2,
|
|
@@ -379,6 +380,27 @@ function queryCustomizations(payload) {
|
|
|
379
380
|
}
|
|
380
381
|
return __queryCustomizations;
|
|
381
382
|
}
|
|
383
|
+
function countCustomizations(payload) {
|
|
384
|
+
function __countCustomizations({ host }) {
|
|
385
|
+
const metadata = {
|
|
386
|
+
entityFqdn: "wix.stores.catalog.v3.customization",
|
|
387
|
+
method: "POST",
|
|
388
|
+
methodFqn: "wix.stores.catalog.customization.v3.CustomizationService.CountCustomizations",
|
|
389
|
+
packageName: PACKAGE_NAME,
|
|
390
|
+
migrationOptions: {
|
|
391
|
+
optInTransformResponse: true
|
|
392
|
+
},
|
|
393
|
+
url: resolveWixStoresCatalogCustomizationV3CustomizationServiceUrl({
|
|
394
|
+
protoPath: "/v3/customizations/count",
|
|
395
|
+
data: payload,
|
|
396
|
+
host
|
|
397
|
+
}),
|
|
398
|
+
data: payload
|
|
399
|
+
};
|
|
400
|
+
return metadata;
|
|
401
|
+
}
|
|
402
|
+
return __countCustomizations;
|
|
403
|
+
}
|
|
382
404
|
function bulkCreateCustomizations(payload) {
|
|
383
405
|
function __bulkCreateCustomizations({ host }) {
|
|
384
406
|
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
|
@@ -1177,10 +1199,33 @@ async function typedQueryCustomizations(query, options) {
|
|
|
1177
1199
|
}
|
|
1178
1200
|
}
|
|
1179
1201
|
var utils = {
|
|
1180
|
-
query:
|
|
1181
|
-
...(0, import_query_builder_utils.createQueryUtils)()
|
|
1182
|
-
}
|
|
1202
|
+
query: /* @__PURE__ */ (0, import_query_builder_utils.createQueryUtils)()
|
|
1183
1203
|
};
|
|
1204
|
+
async function countCustomizations2(options) {
|
|
1205
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
1206
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
1207
|
+
filter: options?.filter
|
|
1208
|
+
});
|
|
1209
|
+
const reqOpts = countCustomizations(payload);
|
|
1210
|
+
sideEffects?.onSiteCall?.();
|
|
1211
|
+
try {
|
|
1212
|
+
const result = await httpClient.request(reqOpts);
|
|
1213
|
+
sideEffects?.onSuccess?.(result);
|
|
1214
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
|
1215
|
+
} catch (err) {
|
|
1216
|
+
const transformedError = (0, import_transform_error.transformError)(
|
|
1217
|
+
err,
|
|
1218
|
+
{
|
|
1219
|
+
spreadPathsToArguments: {},
|
|
1220
|
+
explicitPathsToArguments: { filter: "$[0].filter" },
|
|
1221
|
+
singleArgumentUnchanged: false
|
|
1222
|
+
},
|
|
1223
|
+
["options"]
|
|
1224
|
+
);
|
|
1225
|
+
sideEffects?.onError?.(err);
|
|
1226
|
+
throw transformedError;
|
|
1227
|
+
}
|
|
1228
|
+
}
|
|
1184
1229
|
async function bulkCreateCustomizations2(customizations, options) {
|
|
1185
1230
|
const { httpClient, sideEffects } = arguments[2];
|
|
1186
1231
|
const payload = (0, import_transform_paths2.transformPaths)(
|
|
@@ -1604,6 +1649,7 @@ async function bulkUpdateCustomizations2(customizations, options) {
|
|
|
1604
1649
|
bulkAddCustomizationChoices,
|
|
1605
1650
|
bulkCreateCustomizations,
|
|
1606
1651
|
bulkUpdateCustomizations,
|
|
1652
|
+
countCustomizations,
|
|
1607
1653
|
createCustomization,
|
|
1608
1654
|
deleteCustomization,
|
|
1609
1655
|
getCustomization,
|