@wix/auto_sdk_stores_customizations-v-3 1.0.80 → 1.0.82

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 (41) hide show
  1. package/build/cjs/index.d.ts +39 -3
  2. package/build/cjs/index.js.map +1 -1
  3. package/build/cjs/index.typings.d.ts +77 -10
  4. package/build/cjs/index.typings.js.map +1 -1
  5. package/build/cjs/meta.d.ts +29 -7
  6. package/build/cjs/meta.js +1 -0
  7. package/build/cjs/meta.js.map +1 -1
  8. package/build/cjs/schemas.d.ts +186 -1
  9. package/build/cjs/schemas.js +336 -25
  10. package/build/cjs/schemas.js.map +1 -1
  11. package/build/es/index.d.mts +39 -3
  12. package/build/es/index.mjs.map +1 -1
  13. package/build/es/index.typings.d.mts +77 -10
  14. package/build/es/index.typings.mjs.map +1 -1
  15. package/build/es/meta.d.mts +29 -7
  16. package/build/es/meta.mjs +1 -0
  17. package/build/es/meta.mjs.map +1 -1
  18. package/build/es/schemas.d.mts +186 -1
  19. package/build/es/schemas.mjs +332 -25
  20. package/build/es/schemas.mjs.map +1 -1
  21. package/build/internal/cjs/index.d.ts +6 -7
  22. package/build/internal/cjs/index.js.map +1 -1
  23. package/build/internal/cjs/index.typings.d.ts +22 -22
  24. package/build/internal/cjs/index.typings.js.map +1 -1
  25. package/build/internal/cjs/meta.d.ts +29 -7
  26. package/build/internal/cjs/meta.js +1 -0
  27. package/build/internal/cjs/meta.js.map +1 -1
  28. package/build/internal/cjs/schemas.d.ts +186 -1
  29. package/build/internal/cjs/schemas.js +336 -25
  30. package/build/internal/cjs/schemas.js.map +1 -1
  31. package/build/internal/es/index.d.mts +6 -7
  32. package/build/internal/es/index.mjs.map +1 -1
  33. package/build/internal/es/index.typings.d.mts +22 -22
  34. package/build/internal/es/index.typings.mjs.map +1 -1
  35. package/build/internal/es/meta.d.mts +29 -7
  36. package/build/internal/es/meta.mjs +1 -0
  37. package/build/internal/es/meta.mjs.map +1 -1
  38. package/build/internal/es/schemas.d.mts +186 -1
  39. package/build/internal/es/schemas.mjs +332 -25
  40. package/build/internal/es/schemas.mjs.map +1 -1
  41. package/package.json +2 -2
@@ -193,6 +193,23 @@ interface Choice extends ChoiceValueOneOf {
193
193
  * @decimalValue options { gte:0, lte:999999999, maxScale:3 }
194
194
  */
195
195
  defaultAddedPrice?: string | null;
196
+ /**
197
+ * Optional image displayed alongside a ONE_COLOR choice in the storefront.
198
+ * Only valid for ONE_COLOR choices; not populated for other choice types.
199
+ */
200
+ displayImage?: string;
201
+ /**
202
+ * IDs of the primary choices this choice is grouped under.
203
+ *
204
+ * A choice that has `primaryChoiceIds` is a "linked" choice; a choice without `primaryChoiceIds` is a "primary" choice.
205
+ * A linked choice can reference up to 4 primary choices and appears nested under each of them on the storefront,
206
+ * rather than in the top-level choice list.
207
+ *
208
+ * Only one level of grouping is supported: a primary choice cannot itself be a linked choice.
209
+ * @format GUID
210
+ * @maxSize 4
211
+ */
212
+ primaryChoiceIds?: string[];
196
213
  }
197
214
  /** @oneof */
198
215
  interface ChoiceValueOneOf {
@@ -425,10 +442,15 @@ interface GetCustomizationRequest {
425
442
  }
426
443
  declare enum RequestedFields {
427
444
  /** Assigned products count. */
428
- ASSIGNED_PRODUCTS_COUNT = "ASSIGNED_PRODUCTS_COUNT"
445
+ ASSIGNED_PRODUCTS_COUNT = "ASSIGNED_PRODUCTS_COUNT",
446
+ /**
447
+ * Returns display images for choices.
448
+ * @documentationMaturity preview
449
+ */
450
+ CHOICE_DISPLAY_IMAGE = "CHOICE_DISPLAY_IMAGE"
429
451
  }
430
452
  /** @enumType */
431
- type RequestedFieldsWithLiterals = RequestedFields | 'ASSIGNED_PRODUCTS_COUNT';
453
+ type RequestedFieldsWithLiterals = RequestedFields | 'ASSIGNED_PRODUCTS_COUNT' | 'CHOICE_DISPLAY_IMAGE';
432
454
  interface GetCustomizationResponse {
433
455
  /** Customization. */
434
456
  customization?: Customization;
@@ -783,7 +805,7 @@ interface ReorderCustomizationChoicesRequest {
783
805
  /** Revision number, which increments by 1 each time the customization is updated. To prevent conflicting changes, the current revision must be passed when updating the customization. */
784
806
  revision: string;
785
807
  /**
786
- * Choice IDs in the desired display order. Must contain exactly the same set of IDs as the customization's current choices no additions or removals.
808
+ * Choice IDs in the desired display order. Must contain exactly the same IDs as the customization's current choices, with no additions, removals, or duplicates.
787
809
  * @format GUID
788
810
  * @minSize 1
789
811
  * @maxSize 200
@@ -792,20 +814,20 @@ interface ReorderCustomizationChoicesRequest {
792
814
  /**
793
815
  * Fields to include in the response.
794
816
  *
795
- * Supported values: `ASSIGNED_PRODUCTS_COUNT`
817
+ * Supported values: `ASSIGNED_PRODUCTS_COUNT`.
796
818
  * @maxSize 100
797
819
  */
798
820
  fields?: RequestedFieldsWithLiterals[];
799
821
  }
800
822
  interface ReorderCustomizationChoicesResponse {
801
- /** Updated customization. */
823
+ /** Updated customization, with `choices` in the new order and `choicesSettings.sortOrder` set to `MANUAL`. */
802
824
  customization?: Customization;
803
825
  }
804
826
  /** Additional error details returned with the `CHOICE_IDS_MISMATCH` error. */
805
827
  interface ChoiceIdsMismatchData {
806
- /** Choice IDs that exist in the customization but are missing from the request. */
828
+ /** Choice IDs that exist in the customization but are missing from `choiceIds`. */
807
829
  missingIds?: string[];
808
- /** Choice IDs included in the request that don't exist in the customization. */
830
+ /** Choice IDs included in `choiceIds` that don't exist in the customization, or that appear in `choiceIds` more than once. */
809
831
  extraIds?: string[];
810
832
  }
811
833
  interface BulkAddCustomizationChoicesRequest {
@@ -1840,6 +1862,29 @@ interface RemoveCustomizationChoicesOptions {
1840
1862
  */
1841
1863
  fields?: RequestedFieldsWithLiterals[];
1842
1864
  }
1865
+ /**
1866
+ * Updates properties of existing choices in a customization.
1867
+ * Choices are identified by their IDs. Only the fields specified in `fieldMask` are updated.
1868
+ *
1869
+ * Currently supports updating `primaryChoiceIds`.
1870
+ * @param customizationId - Customization ID.
1871
+ * @param revision - Revision number, which increments by 1 each time the customization is updated.
1872
+ * To prevent conflicting changes,
1873
+ * the current revision must be passed when updating the customization.
1874
+ * @public
1875
+ * @documentationMaturity preview
1876
+ * @requiredField customizationId
1877
+ * @requiredField options.choices
1878
+ * @requiredField options.choices.choice
1879
+ * @requiredField revision
1880
+ * @permissionId WIX_STORES.CUSTOMIZATION_UPDATE
1881
+ * @applicableIdentity APP
1882
+ * @fqn wix.stores.catalog.customization.v3.CustomizationService.UpdateCustomizationChoices
1883
+ */
1884
+ declare function updateCustomizationChoices(customizationId: string, revision: string, options?: NonNullablePaths<UpdateCustomizationChoicesOptions, `choices` | `choices.${number}.choice`, 4>): Promise<NonNullablePaths<UpdateCustomizationChoicesResponse, `customization.freeTextInput.minCharCount` | `customization.freeTextInput.maxCharCount` | `customization.freeTextInput.title` | `customization.choicesSettings.choices` | `customization.choicesSettings.choices.${number}.colorCode` | `customization.choicesSettings.choices.${number}._id` | `customization.choicesSettings.choices.${number}.choiceType` | `customization.choicesSettings.choices.${number}.name` | `customization.name` | `customization.customizationType` | `customization.customizationRenderType`, 6> & {
1885
+ __applicationErrorsType?: UpdateCustomizationChoicesApplicationErrors;
1886
+ __validationErrorsType?: UpdateCustomizationChoicesValidationErrors;
1887
+ }>;
1843
1888
  interface UpdateCustomizationChoicesOptions {
1844
1889
  /**
1845
1890
  * Choices to update. Each item must include a `choice` with a valid `id` matching an existing choice in the customization.
@@ -1855,9 +1900,31 @@ interface UpdateCustomizationChoicesOptions {
1855
1900
  */
1856
1901
  fields?: RequestedFieldsWithLiterals[];
1857
1902
  }
1903
+ /**
1904
+ * Sets the display order of a customization's choices.
1905
+ *
1906
+ * Each time the customization is updated, `revision` increments by 1. The current `revision` must be passed when updating the customization. This ensures you're working with the latest customization and prevents unintended overwrites.
1907
+ *
1908
+ * The new order is persisted in the customization's `choices` list. Calling this method also sets `choicesSettings.sortOrder` to `MANUAL`.
1909
+ *
1910
+ * To change how choices are sorted in storefront filter panels without specifying an explicit order, call [Update Customization](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/customizations-v3/update-customization) and set the `choicesSettings.sortOrder` field.
1911
+ * @param customizationId - Customization ID.
1912
+ * @param revision - Revision number, which increments by 1 each time the customization is updated. To prevent conflicting changes, the current revision must be passed when updating the customization.
1913
+ * @public
1914
+ * @documentationMaturity preview
1915
+ * @requiredField customizationId
1916
+ * @requiredField options.choiceIds
1917
+ * @requiredField revision
1918
+ * @permissionId WIX_STORES.CUSTOMIZATION_UPDATE
1919
+ * @applicableIdentity APP
1920
+ * @fqn wix.stores.catalog.customization.v3.CustomizationService.ReorderCustomizationChoices
1921
+ */
1922
+ declare function reorderCustomizationChoices(customizationId: string, revision: string, options?: NonNullablePaths<ReorderCustomizationChoicesOptions, `choiceIds`, 2>): Promise<NonNullablePaths<ReorderCustomizationChoicesResponse, `customization.freeTextInput.minCharCount` | `customization.freeTextInput.maxCharCount` | `customization.freeTextInput.title` | `customization.choicesSettings.choices` | `customization.choicesSettings.choices.${number}.colorCode` | `customization.choicesSettings.choices.${number}._id` | `customization.choicesSettings.choices.${number}.choiceType` | `customization.choicesSettings.choices.${number}.name` | `customization.name` | `customization.customizationType` | `customization.customizationRenderType`, 6> & {
1923
+ __applicationErrorsType?: ReorderCustomizationChoicesApplicationErrors;
1924
+ }>;
1858
1925
  interface ReorderCustomizationChoicesOptions {
1859
1926
  /**
1860
- * Choice IDs in the desired display order. Must contain exactly the same set of IDs as the customization's current choices no additions or removals.
1927
+ * Choice IDs in the desired display order. Must contain exactly the same IDs as the customization's current choices, with no additions, removals, or duplicates.
1861
1928
  * @format GUID
1862
1929
  * @minSize 1
1863
1930
  * @maxSize 200
@@ -1866,7 +1933,7 @@ interface ReorderCustomizationChoicesOptions {
1866
1933
  /**
1867
1934
  * Fields to include in the response.
1868
1935
  *
1869
- * Supported values: `ASSIGNED_PRODUCTS_COUNT`
1936
+ * Supported values: `ASSIGNED_PRODUCTS_COUNT`.
1870
1937
  * @maxSize 100
1871
1938
  */
1872
1939
  fields?: RequestedFieldsWithLiterals[];
@@ -1934,4 +2001,4 @@ interface BulkUpdateCustomizationsOptions {
1934
2001
  fields?: RequestedFieldsWithLiterals[];
1935
2002
  }
1936
2003
 
1937
- 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, setCustomizationChoices, typedQueryCustomizations, updateCustomization, utils };
2004
+ 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 };