@wix/auto_sdk_ecom_wishlists 1.0.5 → 1.0.6

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.
@@ -1 +1 @@
1
- {"version":3,"sources":["../../index.ts","../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts","../../src/ecom-v1-wishlist-wishlists.public.ts","../../src/ecom-v1-wishlist-wishlists.context.ts"],"sourcesContent":["export * from './src/ecom-v1-wishlist-wishlists.context.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n","import { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n AddItemApplicationErrors,\n AddItemOptions,\n AddItemResponse,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsResponse,\n CatalogReference,\n GetDefaultWishlistOptions,\n GetDefaultWishlistResponse,\n RemoveItemOptions,\n RemoveItemResponse,\n addItem as universalAddItem,\n bulkUpdateWishlistTags as universalBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as universalBulkUpdateWishlistTagsByFilter,\n getDefaultWishlist as universalGetDefaultWishlist,\n removeItem as universalRemoveItem,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/ecom' };\n\n/** @internal */\nexport function getDefaultWishlist(\n httpClient: HttpClient\n): GetDefaultWishlistSignature {\n return (options?: GetDefaultWishlistOptions) =>\n universalGetDefaultWishlist(\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetDefaultWishlistSignature {\n /**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\n (options?: GetDefaultWishlistOptions): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n >;\n}\n\n/** @internal */\nexport function addItem(httpClient: HttpClient): AddItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n ) =>\n universalAddItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface AddItemSignature {\n /**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param - Reference to the catalog item to add.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n ): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function removeItem(httpClient: HttpClient): RemoveItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n ) =>\n universalRemoveItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface RemoveItemSignature {\n /**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param - Reference to the catalog item to remove.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n ): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTags(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsSignature {\n return (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions) =>\n universalBulkUpdateWishlistTags(\n wishlistIds,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsSignature {\n /**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param - IDs of the wishlists to update.\n */\n (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTagsByFilter(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsByFilterSignature {\n return (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ) =>\n universalBulkUpdateWishlistTagsByFilter(\n filter,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsByFilterSignature {\n /**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n >;\n}\n\nexport {\n AccountInfo,\n ActionEvent,\n AddItemOptions,\n AddItemRequest,\n AddItemResponse,\n ApplicationError,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n BulkUpdateWishlistTagsResult,\n CatalogReference,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n ExtendedFields,\n GetDefaultWishlistOptions,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemMetadata,\n MessageEnvelope,\n RemoveItemOptions,\n RemoveItemRequest,\n RemoveItemResponse,\n RestoreInfo,\n TagList,\n Tags,\n WebhookIdentityType,\n Wishlist,\n WishlistItem,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n","import {\n getDefaultWishlist as publicGetDefaultWishlist,\n addItem as publicAddItem,\n removeItem as publicRemoveItem,\n bulkUpdateWishlistTags as publicBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as publicBulkUpdateWishlistTagsByFilter,\n} from './ecom-v1-wishlist-wishlists.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { BuildRESTFunction, MaybeContext } from '@wix/sdk-types';\n\n/** @internal */\nexport const getDefaultWishlist: MaybeContext<\n BuildRESTFunction<typeof publicGetDefaultWishlist> &\n typeof publicGetDefaultWishlist\n> = /*#__PURE__*/ createRESTModule(publicGetDefaultWishlist);\n/** @internal */\nexport const addItem: MaybeContext<\n BuildRESTFunction<typeof publicAddItem> & typeof publicAddItem\n> = /*#__PURE__*/ createRESTModule(publicAddItem);\n/** @internal */\nexport const removeItem: MaybeContext<\n BuildRESTFunction<typeof publicRemoveItem> & typeof publicRemoveItem\n> = /*#__PURE__*/ createRESTModule(publicRemoveItem);\n/** @internal */\nexport const bulkUpdateWishlistTags: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTags> &\n typeof publicBulkUpdateWishlistTags\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTags);\n/** @internal */\nexport const bulkUpdateWishlistTagsByFilter: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTagsByFilter> &\n typeof publicBulkUpdateWishlistTagsByFilter\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTagsByFilter);\n\nexport { WebhookIdentityType } from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n Wishlist,\n WishlistItem,\n CatalogReference,\n ExtendedFields,\n Tags,\n TagList,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n AddItemRequest,\n AddItemResponse,\n RemoveItemRequest,\n RemoveItemResponse,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n ItemMetadata,\n ApplicationError,\n BulkUpdateWishlistTagsResult,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n AccountInfo,\n GetDefaultWishlistOptions,\n AddItemOptions,\n RemoveItemOptions,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsByFilterOptions,\n} from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n WebhookIdentityTypeWithLiterals,\n AddItemApplicationErrors,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA,iBAAAA;AAAA,EAAA,8BAAAC;AAAA,EAAA,sCAAAC;AAAA,EAAA,0BAAAC;AAAA,EAAA,kBAAAC;AAAA;AAAA;;;ACAA,6BAAoD;AACpD,oCAGO;;;ACJP,0BAAkC;AAClC,uBAAqD;AACrD,6BAA+B;AAC/B,IAAAC,uBAA2B;AAI3B,SAAS,qCACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,kBAAkB;AAAA,MAChB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,mBAAmB;AAAA,MACjB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA,aAAO,iCAAW,OAAO,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC7D;AAEA,IAAM,eAAe;AAOd,SAAS,mBACd,SAC4B;AAC5B,WAAS,qBAAqB,EAAE,KAAK,GAAQ;AAC3C,UAAM,WAAW;AAAA,MACf,YAAY;AAAA,MACZ,QAAQ;AAAA,MACR,WAAW;AAAA,MACX,aAA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AAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA4BO,SAASC,gCACd,YACyC;AACzC,SAAO,CACL,QACA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;;;AC9LA,IAAAC,uBAAiC;AAI1B,IAAMC,sBAGK,2DAAiBA,mBAAwB;AAEpD,IAAMC,WAEK,2DAAiBA,QAAa;AAEzC,IAAMC,cAEK,2DAAiBA,WAAgB;AAE5C,IAAMC,0BAGK,2DAAiBA,uBAA4B;AAExD,IAAMC,kCAGK,2DAAiBA,+BAAoC;","names":["addItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","removeItem","import_rest_modules","payload","WebhookIdentityType","getDefaultWishlist","sdkTransformError","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","import_rest_modules","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
1
+ {"version":3,"sources":["../../index.ts","../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts","../../src/ecom-v1-wishlist-wishlists.public.ts","../../src/ecom-v1-wishlist-wishlists.context.ts"],"sourcesContent":["export * from './src/ecom-v1-wishlist-wishlists.context.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 4\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n","import { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n AddItemApplicationErrors,\n AddItemOptions,\n AddItemResponse,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsResponse,\n CatalogReference,\n GetDefaultWishlistOptions,\n GetDefaultWishlistResponse,\n RemoveItemOptions,\n RemoveItemResponse,\n addItem as universalAddItem,\n bulkUpdateWishlistTags as universalBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as universalBulkUpdateWishlistTagsByFilter,\n getDefaultWishlist as universalGetDefaultWishlist,\n removeItem as universalRemoveItem,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/ecom' };\n\n/** @internal */\nexport function getDefaultWishlist(\n httpClient: HttpClient\n): GetDefaultWishlistSignature {\n return (options?: GetDefaultWishlistOptions) =>\n universalGetDefaultWishlist(\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetDefaultWishlistSignature {\n /**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\n (options?: GetDefaultWishlistOptions): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\n/** @internal */\nexport function addItem(httpClient: HttpClient): AddItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n ) =>\n universalAddItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface AddItemSignature {\n /**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param - Reference to the catalog item to add.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n ): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function removeItem(httpClient: HttpClient): RemoveItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n ) =>\n universalRemoveItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface RemoveItemSignature {\n /**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param - Reference to the catalog item to remove.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n ): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTags(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsSignature {\n return (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions) =>\n universalBulkUpdateWishlistTags(\n wishlistIds,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsSignature {\n /**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param - IDs of the wishlists to update.\n */\n (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 4\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTagsByFilter(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsByFilterSignature {\n return (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ) =>\n universalBulkUpdateWishlistTagsByFilter(\n filter,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsByFilterSignature {\n /**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n >;\n}\n\nexport {\n AccountInfo,\n ActionEvent,\n AddItemOptions,\n AddItemRequest,\n AddItemResponse,\n ApplicationError,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n BulkUpdateWishlistTagsResult,\n CatalogReference,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n ExtendedFields,\n GetDefaultWishlistOptions,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemMetadata,\n MessageEnvelope,\n RemoveItemOptions,\n RemoveItemRequest,\n RemoveItemResponse,\n RestoreInfo,\n TagList,\n Tags,\n WebhookIdentityType,\n Wishlist,\n WishlistItem,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n","import {\n getDefaultWishlist as publicGetDefaultWishlist,\n addItem as publicAddItem,\n removeItem as publicRemoveItem,\n bulkUpdateWishlistTags as publicBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as publicBulkUpdateWishlistTagsByFilter,\n} from './ecom-v1-wishlist-wishlists.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { BuildRESTFunction, MaybeContext } from '@wix/sdk-types';\n\n/** @internal */\nexport const getDefaultWishlist: MaybeContext<\n BuildRESTFunction<typeof publicGetDefaultWishlist> &\n typeof publicGetDefaultWishlist\n> = /*#__PURE__*/ createRESTModule(publicGetDefaultWishlist);\n/** @internal */\nexport const addItem: MaybeContext<\n BuildRESTFunction<typeof publicAddItem> & typeof publicAddItem\n> = /*#__PURE__*/ createRESTModule(publicAddItem);\n/** @internal */\nexport const removeItem: MaybeContext<\n BuildRESTFunction<typeof publicRemoveItem> & typeof publicRemoveItem\n> = /*#__PURE__*/ createRESTModule(publicRemoveItem);\n/** @internal */\nexport const bulkUpdateWishlistTags: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTags> &\n typeof publicBulkUpdateWishlistTags\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTags);\n/** @internal */\nexport const bulkUpdateWishlistTagsByFilter: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTagsByFilter> &\n typeof publicBulkUpdateWishlistTagsByFilter\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTagsByFilter);\n\nexport { WebhookIdentityType } from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n Wishlist,\n WishlistItem,\n CatalogReference,\n ExtendedFields,\n Tags,\n TagList,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n AddItemRequest,\n AddItemResponse,\n RemoveItemRequest,\n RemoveItemResponse,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n ItemMetadata,\n ApplicationError,\n BulkUpdateWishlistTagsResult,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n AccountInfo,\n GetDefaultWishlistOptions,\n AddItemOptions,\n RemoveItemOptions,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsByFilterOptions,\n} from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n WebhookIdentityTypeWithLiterals,\n AddItemApplicationErrors,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA,iBAAAA;AAAA,EAAA,8BAAAC;AAAA,EAAA,sCAAAC;AAAA,EAAA,0BAAAC;AAAA,EAAA,kBAAAC;AAAA;AAAA;;;ACAA,6BAAoD;AACpD,oCAGO;;;ACJP,0BAAkC;AAClC,uBAAqD;AACrD,6BAA+B;AAC/B,IAAAC,uBAA2B;AAI3B,SAAS,qCACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;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,cAAc;AAAA,QAChB;AAAA,QACA,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,UAAU,SAAS;AAAA,IACtB;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;;;AEz0BO,SAASK,oBACd,YAC6B;AAC7B,SAAO,CAAC,YACNA;AAAA,IACE;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AAqBO,SAASC,SAAQ,YAA0C;AAChE,SAAO,CACL,kBAKA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA+BO,SAASC,YAAW,YAA6C;AACtE,SAAO,CACL,kBAKA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA6BO,SAASC,wBACd,YACiC;AACjC,SAAO,CAAC,aAAuB,YAC7BA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA4BO,SAASC,gCACd,YACyC;AACzC,SAAO,CACL,QACA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;;;AC9LA,IAAAC,uBAAiC;AAI1B,IAAMC,sBAGK,2DAAiBA,mBAAwB;AAEpD,IAAMC,WAEK,2DAAiBA,QAAa;AAEzC,IAAMC,cAEK,2DAAiBA,WAAgB;AAE5C,IAAMC,0BAGK,2DAAiBA,uBAA4B;AAExD,IAAMC,kCAGK,2DAAiBA,+BAAoC;","names":["addItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","removeItem","import_rest_modules","payload","WebhookIdentityType","getDefaultWishlist","sdkTransformError","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","import_rest_modules","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../index.typings.ts","../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts"],"sourcesContent":["export * from './src/ecom-v1-wishlist-wishlists.universal.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA,iBAAAA;AAAA,EAAA,8BAAAC;AAAA,EAAA,sCAAAC;AAAA,EAAA,0BAAAC;AAAA,EAAA,kBAAAC;AAAA;AAAA;;;ACAA,6BAAoD;AACpD,oCAGO;;;ACJP,0BAAkC;AAClC,uBAAqD;AACrD,6BAA+B;AAC/B,IAAAC,uBAA2B;AAI3B,SAAS,qCACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,kBAAkB;AAAA,MAChB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,mBAAmB;AAAA,MACjB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA,aAAO,iCAAW,OAAO,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC7D;AAEA,IAAM,eAAe;AAOd,SAAS,mBACd,SAC4B;AAC5B,WAAS,qBAAqB,EAAE,KAAK,GAAQ;AAC3C,UAAM,WAAW;AAAA,MACf,YAAY;AAAA,MACZ,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AAAA,UACb,YAAY;AAAA,UACZ,cAAc;AAAA,QAChB;AAAA,QACA,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,eAAe,SAAS;AAAA,IAC3B;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;AAwBA,eAAsBI,gCACpB,QACA,SAKA;AAEA,QAAM,EAAE,YAAY,YAAY,IAAI,UAAU,CAAC;AAK/C,QAAM,cAAU,qEAAsC;AAAA,IACpD;AAAA,IACA,YAAY,SAAS;AAAA,IACrB,cAAc,SAAS;AAAA,EACzB,CAAC;AAED,QAAM,UACwB,+BAA+B,OAAO;AAEpE,eAAa,aAAa;AAC1B,MAAI;AACF,UAAM,SAAS,MAAM,WAAW,QAAQ,OAAO;AAC/C,iBAAa,YAAY,MAAM;AAE/B,eAAO,uEAAwC,OAAO,IAAI;AAAA,EAC5D,SAAS,KAAU;AACjB,UAAM,uBAAmB,uBAAAJ;AAAA,MACvB;AAAA,MACA;AAAA,QACE,wBAAwB,CAAC;AAAA,QACzB,0BAA0B;AAAA,UACxB,QAAQ;AAAA,UACR,YAAY;AAAA,UACZ,cAAc;AAAA,QAChB;AAAA,QACA,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,UAAU,SAAS;AAAA,IACtB;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;","names":["addItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","removeItem","import_rest_modules","payload","WebhookIdentityType","getDefaultWishlist","sdkTransformError","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
1
+ {"version":3,"sources":["../../index.typings.ts","../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts"],"sourcesContent":["export * from './src/ecom-v1-wishlist-wishlists.universal.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 4\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n"],"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AAAA,IACpD;AAAA,IACA,YAAY,SAAS;AAAA,IACrB,cAAc,SAAS;AAAA,EACzB,CAAC;AAED,QAAM,UACwB,+BAA+B,OAAO;AAEpE,eAAa,aAAa;AAC1B,MAAI;AACF,UAAM,SAAS,MAAM,WAAW,QAAQ,OAAO;AAC/C,iBAAa,YAAY,MAAM;AAE/B,eAAO,uEAAwC,OAAO,IAAI;AAAA,EAC5D,SAAS,KAAU;AACjB,UAAM,uBAAmB,uBAAAJ;AAAA,MACvB;AAAA,MACA;AAAA,QACE,wBAAwB,CAAC;AAAA,QACzB,0BAA0B;AAAA,UACxB,QAAQ;AAAA,UACR,YAAY;AAAA,UACZ,cAAc;AAAA,QAChB;AAAA,QACA,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,UAAU,SAAS;AAAA,IACtB;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;","names":["addItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","removeItem","import_rest_modules","payload","WebhookIdentityType","getDefaultWishlist","sdkTransformError","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts","../../src/ecom-v1-wishlist-wishlists.public.ts","../../src/ecom-v1-wishlist-wishlists.context.ts"],"sourcesContent":["import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n","import { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n AddItemApplicationErrors,\n AddItemOptions,\n AddItemResponse,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsResponse,\n CatalogReference,\n GetDefaultWishlistOptions,\n GetDefaultWishlistResponse,\n RemoveItemOptions,\n RemoveItemResponse,\n addItem as universalAddItem,\n bulkUpdateWishlistTags as universalBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as universalBulkUpdateWishlistTagsByFilter,\n getDefaultWishlist as universalGetDefaultWishlist,\n removeItem as universalRemoveItem,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/ecom' };\n\n/** @internal */\nexport function getDefaultWishlist(\n httpClient: HttpClient\n): GetDefaultWishlistSignature {\n return (options?: GetDefaultWishlistOptions) =>\n universalGetDefaultWishlist(\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetDefaultWishlistSignature {\n /**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\n (options?: GetDefaultWishlistOptions): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n >;\n}\n\n/** @internal */\nexport function addItem(httpClient: HttpClient): AddItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n ) =>\n universalAddItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface AddItemSignature {\n /**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param - Reference to the catalog item to add.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n ): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function removeItem(httpClient: HttpClient): RemoveItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n ) =>\n universalRemoveItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface RemoveItemSignature {\n /**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param - Reference to the catalog item to remove.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n ): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTags(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsSignature {\n return (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions) =>\n universalBulkUpdateWishlistTags(\n wishlistIds,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsSignature {\n /**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param - IDs of the wishlists to update.\n */\n (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTagsByFilter(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsByFilterSignature {\n return (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ) =>\n universalBulkUpdateWishlistTagsByFilter(\n filter,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsByFilterSignature {\n /**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n >;\n}\n\nexport {\n AccountInfo,\n ActionEvent,\n AddItemOptions,\n AddItemRequest,\n AddItemResponse,\n ApplicationError,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n BulkUpdateWishlistTagsResult,\n CatalogReference,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n ExtendedFields,\n GetDefaultWishlistOptions,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemMetadata,\n MessageEnvelope,\n RemoveItemOptions,\n RemoveItemRequest,\n RemoveItemResponse,\n RestoreInfo,\n TagList,\n Tags,\n WebhookIdentityType,\n Wishlist,\n WishlistItem,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n","import {\n getDefaultWishlist as publicGetDefaultWishlist,\n addItem as publicAddItem,\n removeItem as publicRemoveItem,\n bulkUpdateWishlistTags as publicBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as publicBulkUpdateWishlistTagsByFilter,\n} from './ecom-v1-wishlist-wishlists.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { BuildRESTFunction, MaybeContext } from '@wix/sdk-types';\n\n/** @internal */\nexport const getDefaultWishlist: MaybeContext<\n BuildRESTFunction<typeof publicGetDefaultWishlist> &\n typeof publicGetDefaultWishlist\n> = /*#__PURE__*/ createRESTModule(publicGetDefaultWishlist);\n/** @internal */\nexport const addItem: MaybeContext<\n BuildRESTFunction<typeof publicAddItem> & typeof publicAddItem\n> = /*#__PURE__*/ createRESTModule(publicAddItem);\n/** @internal */\nexport const removeItem: MaybeContext<\n BuildRESTFunction<typeof publicRemoveItem> & typeof publicRemoveItem\n> = /*#__PURE__*/ createRESTModule(publicRemoveItem);\n/** @internal */\nexport const bulkUpdateWishlistTags: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTags> &\n typeof publicBulkUpdateWishlistTags\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTags);\n/** @internal */\nexport const bulkUpdateWishlistTagsByFilter: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTagsByFilter> &\n typeof publicBulkUpdateWishlistTagsByFilter\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTagsByFilter);\n\nexport { WebhookIdentityType } from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n Wishlist,\n WishlistItem,\n CatalogReference,\n ExtendedFields,\n Tags,\n TagList,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n AddItemRequest,\n AddItemResponse,\n RemoveItemRequest,\n RemoveItemResponse,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n ItemMetadata,\n ApplicationError,\n BulkUpdateWishlistTagsResult,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n AccountInfo,\n GetDefaultWishlistOptions,\n AddItemOptions,\n RemoveItemOptions,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsByFilterOptions,\n} from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n WebhookIdentityTypeWithLiterals,\n AddItemApplicationErrors,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n"],"mappings":";AAAA,SAAS,kBAAkB,yBAAyB;AACpD;AAAA,EACE;AAAA,EACA;AAAA,OACK;;;ACJP,SAAS,yBAAyB;AAClC,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAI3B,SAAS,qCACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAA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C,oBACd,YAC6B;AAC7B,SAAO,CAAC,YACNA;AAAA,IACE;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AAqBO,SAASC,SAAQ,YAA0C;AAChE,SAAO,CACL,kBAKA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA+BO,SAASC,YAAW,YAA6C;AACtE,SAAO,CACL,kBAKA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA6BO,SAASC,wBACd,YACiC;AACjC,SAAO,CAAC,aAAuB,YAC7BA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA4BO,SAASC,gCACd,YACyC;AACzC,SAAO,CACL,QACA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;;;AC9LA,SAAS,wBAAwB;AAI1B,IAAMC,sBAGK,iCAAiBA,mBAAwB;AAEpD,IAAMC,WAEK,iCAAiBA,QAAa;AAEzC,IAAMC,cAEK,iCAAiBA,WAAgB;AAE5C,IAAMC,0BAGK,iCAAiBA,uBAA4B;AAExD,IAAMC,kCAGK,iCAAiBA,+BAAoC;","names":["payload","WebhookIdentityType","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
1
+ {"version":3,"sources":["../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts","../../src/ecom-v1-wishlist-wishlists.public.ts","../../src/ecom-v1-wishlist-wishlists.context.ts"],"sourcesContent":["import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 4\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n","import { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n AddItemApplicationErrors,\n AddItemOptions,\n AddItemResponse,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsResponse,\n CatalogReference,\n GetDefaultWishlistOptions,\n GetDefaultWishlistResponse,\n RemoveItemOptions,\n RemoveItemResponse,\n addItem as universalAddItem,\n bulkUpdateWishlistTags as universalBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as universalBulkUpdateWishlistTagsByFilter,\n getDefaultWishlist as universalGetDefaultWishlist,\n removeItem as universalRemoveItem,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/ecom' };\n\n/** @internal */\nexport function getDefaultWishlist(\n httpClient: HttpClient\n): GetDefaultWishlistSignature {\n return (options?: GetDefaultWishlistOptions) =>\n universalGetDefaultWishlist(\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface GetDefaultWishlistSignature {\n /**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\n (options?: GetDefaultWishlistOptions): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\n/** @internal */\nexport function addItem(httpClient: HttpClient): AddItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n ) =>\n universalAddItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface AddItemSignature {\n /**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param - Reference to the catalog item to add.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n ): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function removeItem(httpClient: HttpClient): RemoveItemSignature {\n return (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n ) =>\n universalRemoveItem(\n catalogReference,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface RemoveItemSignature {\n /**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param - Reference to the catalog item to remove.\n */\n (\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n ): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTags(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsSignature {\n return (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions) =>\n universalBulkUpdateWishlistTags(\n wishlistIds,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsSignature {\n /**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param - IDs of the wishlists to update.\n */\n (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 4\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n >;\n}\n\n/** @internal */\nexport function bulkUpdateWishlistTagsByFilter(\n httpClient: HttpClient\n): BulkUpdateWishlistTagsByFilterSignature {\n return (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ) =>\n universalBulkUpdateWishlistTagsByFilter(\n filter,\n options,\n // @ts-ignore\n { httpClient }\n );\n}\n\ninterface BulkUpdateWishlistTagsByFilterSignature {\n /**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n (\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n ): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n >;\n}\n\nexport {\n AccountInfo,\n ActionEvent,\n AddItemOptions,\n AddItemRequest,\n AddItemResponse,\n ApplicationError,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterOptions,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n BulkUpdateWishlistTagsResult,\n CatalogReference,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n EntityDeletedEvent,\n EntityUpdatedEvent,\n ExtendedFields,\n GetDefaultWishlistOptions,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n IdentificationData,\n IdentificationDataIdOneOf,\n ItemMetadata,\n MessageEnvelope,\n RemoveItemOptions,\n RemoveItemRequest,\n RemoveItemResponse,\n RestoreInfo,\n TagList,\n Tags,\n WebhookIdentityType,\n Wishlist,\n WishlistItem,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n","import {\n getDefaultWishlist as publicGetDefaultWishlist,\n addItem as publicAddItem,\n removeItem as publicRemoveItem,\n bulkUpdateWishlistTags as publicBulkUpdateWishlistTags,\n bulkUpdateWishlistTagsByFilter as publicBulkUpdateWishlistTagsByFilter,\n} from './ecom-v1-wishlist-wishlists.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { BuildRESTFunction, MaybeContext } from '@wix/sdk-types';\n\n/** @internal */\nexport const getDefaultWishlist: MaybeContext<\n BuildRESTFunction<typeof publicGetDefaultWishlist> &\n typeof publicGetDefaultWishlist\n> = /*#__PURE__*/ createRESTModule(publicGetDefaultWishlist);\n/** @internal */\nexport const addItem: MaybeContext<\n BuildRESTFunction<typeof publicAddItem> & typeof publicAddItem\n> = /*#__PURE__*/ createRESTModule(publicAddItem);\n/** @internal */\nexport const removeItem: MaybeContext<\n BuildRESTFunction<typeof publicRemoveItem> & typeof publicRemoveItem\n> = /*#__PURE__*/ createRESTModule(publicRemoveItem);\n/** @internal */\nexport const bulkUpdateWishlistTags: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTags> &\n typeof publicBulkUpdateWishlistTags\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTags);\n/** @internal */\nexport const bulkUpdateWishlistTagsByFilter: MaybeContext<\n BuildRESTFunction<typeof publicBulkUpdateWishlistTagsByFilter> &\n typeof publicBulkUpdateWishlistTagsByFilter\n> = /*#__PURE__*/ createRESTModule(publicBulkUpdateWishlistTagsByFilter);\n\nexport { WebhookIdentityType } from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n Wishlist,\n WishlistItem,\n CatalogReference,\n ExtendedFields,\n Tags,\n TagList,\n WishlistItemAdded,\n WishlistItemRemoved,\n WishlistTagsModified,\n GetDefaultWishlistRequest,\n GetDefaultWishlistResponse,\n AddItemRequest,\n AddItemResponse,\n RemoveItemRequest,\n RemoveItemResponse,\n BulkUpdateWishlistTagsRequest,\n BulkUpdateWishlistTagsResponse,\n ItemMetadata,\n ApplicationError,\n BulkUpdateWishlistTagsResult,\n BulkActionMetadata,\n BulkUpdateWishlistTagsByFilterRequest,\n BulkUpdateWishlistTagsByFilterResponse,\n DomainEvent,\n DomainEventBodyOneOf,\n EntityCreatedEvent,\n RestoreInfo,\n EntityUpdatedEvent,\n EntityDeletedEvent,\n ActionEvent,\n MessageEnvelope,\n IdentificationData,\n IdentificationDataIdOneOf,\n AccountInfo,\n GetDefaultWishlistOptions,\n AddItemOptions,\n RemoveItemOptions,\n BulkUpdateWishlistTagsOptions,\n BulkUpdateWishlistTagsByFilterOptions,\n} from './ecom-v1-wishlist-wishlists.universal.js';\nexport {\n WebhookIdentityTypeWithLiterals,\n AddItemApplicationErrors,\n BulkUpdateWishlistTagsApplicationErrors,\n BulkUpdateWishlistTagsByFilterApplicationErrors,\n} from './ecom-v1-wishlist-wishlists.universal.js';\n"],"mappings":";AAAA,SAAS,kBAAkB,yBAAyB;AACpD;AAAA,EACE;AAAA,EACA;AAAA,OACK;;;ACJP,SAAS,yBAAyB;AAClC,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;A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AAM,mBAAmB;AAAA,MACvB;AAAA,MACA;AAAA,QACE,wBAAwB,CAAC;AAAA,QACzB,0BAA0B;AAAA,UACxB,QAAQ;AAAA,UACR,YAAY;AAAA,UACZ,cAAc;AAAA,QAChB;AAAA,QACA,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,UAAU,SAAS;AAAA,IACtB;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;;;AEz0BO,SAASC,oBACd,YAC6B;AAC7B,SAAO,CAAC,YACNA;AAAA,IACE;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AAqBO,SAASC,SAAQ,YAA0C;AAChE,SAAO,CACL,kBAKA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA+BO,SAASC,YAAW,YAA6C;AACtE,SAAO,CACL,kBAKA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA6BO,SAASC,wBACd,YACiC;AACjC,SAAO,CAAC,aAAuB,YAC7BA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;AA4BO,SAASC,gCACd,YACyC;AACzC,SAAO,CACL,QACA,YAEAA;AAAA,IACE;AAAA,IACA;AAAA;AAAA,IAEA,EAAE,WAAW;AAAA,EACf;AACJ;;;AC9LA,SAAS,wBAAwB;AAI1B,IAAMC,sBAGK,iCAAiBA,mBAAwB;AAEpD,IAAMC,WAEK,iCAAiBA,QAAa;AAEzC,IAAMC,cAEK,iCAAiBA,WAAgB;AAE5C,IAAMC,0BAGK,iCAAiBA,uBAA4B;AAExD,IAAMC,kCAGK,iCAAiBA,+BAAoC;","names":["payload","WebhookIdentityType","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts"],"sourcesContent":["import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 2\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 6\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 6\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n"],"mappings":";AAAA,SAAS,kBAAkB,yBAAyB;AACpD;AAAA,EACE;AAAA,EACA;AAAA,OACK;;;ACJP,SAAS,yBAAyB;AAClC,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAI3B,SAAS,qCACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,kBAAkB;AAAA,MAChB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,mBAAmB;AAAA,MACjB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,EACF;AAEA,SAAO,WAAW,OAAO,OAAO,MAAM,EAAE,iBAAiB,CAAC,CAAC;AAC7D;AAEA,IAAM,eAAe;AAOd,SAAS,mBACd,SAC4B;AAC5B,WAAS,qBAAqB,EAAE,KAAK,GAAQ;AAC3C,UAAM,WAAW;AAAA,MACf,YAAY;AAAA,MACZ,QAAQ;AAAA,MACR,WAAW;AAAA,MACX,aAAa;AAAA,MACb,kBAAkB;AAAA,QAChB,wBAAwB;AAAA,MAC1B;AAAA,MACA,KAAK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B,UAAM;AAAA,EACR;AACF;AAwBA,eAAsBC,gCACpB,QACA,SAKA;AAEA,QAAM,EAAE,YAAY,YAAY,IAAI,UAAU,CAAC;AAK/C,QAAM,UAAU,sCAAsC;AAAA,IACpD;AAAA,IACA,YAAY,SAAS;AAAA,IACrB,cAAc,SAAS;AAAA,EACzB,CAAC;AAED,QAAM,UACwB,+BAA+B,OAAO;AAEpE,eAAa,aAAa;AAC1B,MAAI;AACF,UAAM,SAAS,MAAM,WAAW,QAAQ,OAAO;AAC/C,iBAAa,YAAY,MAAM;AAE/B,WAAO,wCAAwC,OAAO,IAAI;AAAA,EAC5D,SAAS,KAAU;AACjB,UAAM,mBAAmB;AAAA,MACvB;AAAA,MACA;AAAA,QACE,wBAAwB,CAAC;AAAA,QACzB,0BAA0B;AAAA,UACxB,QAAQ;AAAA,UACR,YAAY;AAAA,UACZ,cAAc;AAAA,QAChB;AAAA,QACA,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,UAAU,SAAS;AAAA,IACtB;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;","names":["payload","WebhookIdentityType","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
1
+ {"version":3,"sources":["../../src/ecom-v1-wishlist-wishlists.universal.ts","../../src/ecom-v1-wishlist-wishlists.http.ts"],"sourcesContent":["import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport {\n renameKeysFromSDKRequestToRESTRequest,\n renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport * as ambassadorWixEcomV1Wishlist from './ecom-v1-wishlist-wishlists.http.js';\n\n/**\n * A wishlist is a collection of catalog items that a site member saves to return to later.\n *\n * Each member has one default wishlist that can hold items from any catalog app. A wishlist holds up to 100 items. Each item is identified by its catalog reference, so different variants of the same product are saved as distinct items. Learn more about [handling item variants](https://dev.wix.com/docs/rest/business-solutions/e-commerce/catalog-service-plugin/handle-item-variants).\n */\nexport interface Wishlist {\n /**\n * Wishlist ID.\n * @format GUID\n * @readonly\n */\n _id?: string | null;\n /**\n * ID of the member who owns the wishlist.\n * @readonly\n * @format GUID\n */\n memberId?: string | null;\n /**\n * Items saved in the wishlist. Add or remove items with [Add Item](TODO: Add link) and [Remove Item](TODO: Add link).\n * @maxSize 100\n * @readonly\n */\n items?: WishlistItem[];\n /**\n * Date and time the wishlist was created.\n * @readonly\n */\n _createdDate?: Date | null;\n /**\n * Date and time the wishlist was last updated.\n * @readonly\n */\n _updatedDate?: Date | null;\n /**\n * Custom field data for the wishlist.\n *\n * [Extended fields](https://dev.wix.com/docs/build-apps/develop-your-app/extensions/backend-extensions/schema-plugins/about-schema-plugin-extensions) must be configured in the app dashboard before they can be accessed with API calls.\n */\n extendedFields?: ExtendedFields;\n /** Tags assigned to the wishlist, organized into public and private tags. */\n tags?: Tags;\n}\n\n/** A single item saved in a wishlist. */\nexport interface WishlistItem {\n /** Reference to the catalog item that was saved. Identifies the item within the wishlist, so different variants of the same product are distinct items. */\n catalogReference?: CatalogReference;\n /**\n * Date and time the item was added to the wishlist.\n * @readonly\n */\n addedDate?: Date | null;\n}\n\n/** Used for grouping line items. Sent when an item is added to a cart, checkout, or order. */\nexport interface CatalogReference {\n /**\n * ID of the item within the catalog it belongs to.\n * @minLength 1\n * @maxLength 36\n */\n catalogItemId?: string;\n /**\n * ID of the app providing the catalog.\n *\n * You can get your app's ID from its page in the [app dashboard](https://dev.wix.com/dc3/my-apps/).\n *\n * For items from Wix catalogs, the following values always apply:\n * + Wix Stores: `\"215238eb-22a5-4c36-9e7b-e7c08025e04e\"`\n * + Wix Bookings: `\"13d21c63-b5ec-5912-8397-c3a5ddb27a97\"`\n * + Wix Restaurants: `\"9a5d83fd-8570-482e-81ab-cfa88942ee60\"`\n * @minLength 1\n */\n appId?: string;\n /**\n * Additional item details in `key:value` pairs.\n *\n * Use this optional field for more specificity with item selection. The values of the `options` field differ depending on which catalog is providing the items.\n *\n * For Wix Stores products, learn more about integrating with [Catalog V3](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v3/e-commerce-integration)\n * or [Catalog V1](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-v1/catalog/e-commerce-integration), depending on [the version the site uses](https://dev.wix.com/docs/api-reference/business-solutions/stores/catalog-versioning/introduction).\n */\n options?: Record<string, any> | null;\n}\n\nexport interface ExtendedFields {\n /**\n * Extended field data. Each key corresponds to the namespace of the app that created the extended fields.\n * The value of each key is structured according to the schema defined when the extended fields were configured.\n *\n * You can only access fields for which you have the appropriate permissions.\n *\n * Learn more about [extended fields](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields).\n */\n namespaces?: Record<string, Record<string, any>>;\n}\n\n/**\n * Common object for tags.\n * Should be use as in this example:\n * message Foo {\n * option (.wix.api.decomposite_of) = \"wix.commons.v2.tags.Foo\";\n * string id = 1;\n * ...\n * Tags tags = 5\n * }\n *\n * example of taggable entity\n * {\n * id: \"123\"\n * tags: {\n * public_tags: {\n * tag_ids:[\"11\",\"22\"]\n * },\n * private_tags: {\n * tag_ids: [\"33\", \"44\"]\n * }\n * }\n * }\n */\nexport interface Tags {\n /** Tags that require an additional permission in order to access them, normally not given to site members or visitors. */\n privateTags?: TagList;\n /** Tags that are exposed to anyone who has access to the labeled entity itself, including site members and visitors. */\n publicTags?: TagList;\n}\n\nexport interface TagList {\n /**\n * List of tag IDs.\n * @maxSize 100\n * @maxLength 5\n */\n tagIds?: string[];\n}\n\n/** Event payload sent when an item is added to a wishlist. */\nexport interface WishlistItemAdded {\n /**\n * ID of the wishlist the item was added to.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was added. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when an item is removed from a wishlist. */\nexport interface WishlistItemRemoved {\n /**\n * ID of the wishlist the item was removed from.\n * @format GUID\n */\n wishlistId?: string;\n /** Item that was removed. */\n item?: WishlistItem;\n}\n\n/** Event payload sent when a wishlist's tags change. */\nexport interface WishlistTagsModified {\n /** Wishlist whose tags changed. */\n wishlist?: Wishlist;\n /** Tags that were assigned. */\n assignedTags?: Tags;\n /** Tags that were unassigned. */\n unassignedTags?: Tags;\n}\n\nexport interface GetDefaultWishlistRequest {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\nexport interface GetDefaultWishlistResponse {\n /** Retrieved wishlist. Empty if the member doesn't have a wishlist yet. */\n wishlist?: Wishlist;\n}\n\nexport interface AddItemRequest {\n /** Reference to the catalog item to add. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface AddItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface RemoveItemRequest {\n /** Reference to the catalog item to remove. */\n catalogReference: CatalogReference;\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\nexport interface RemoveItemResponse {\n /**\n * Updated wishlist.\n *\n * Returned only when `returnEntity` is `true`.\n */\n wishlist?: Wishlist;\n}\n\nexport interface BulkUpdateWishlistTagsRequest {\n /**\n * IDs of the wishlists to update.\n * @minSize 1\n * @maxSize 100\n * @format GUID\n */\n wishlistIds: string[];\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsResponse {\n /**\n * Results for each wishlist, in the same order as the request.\n * @minSize 1\n * @maxSize 100\n */\n results?: BulkUpdateWishlistTagsResult[];\n /** Metadata about the bulk action as a whole. */\n bulkActionMetadata?: BulkActionMetadata;\n}\n\nexport interface ItemMetadata {\n /**\n * Item ID. Provided only whenever possible. For example, `itemId` can't be provided when item creation has failed.\n * @format GUID\n */\n _id?: string | null;\n /** Index of the item within the request array. Allows for correlation between request and response items. */\n originalIndex?: number;\n /** Whether the requested action for this item was successful. When `false`, the `error` field is returned. */\n success?: boolean;\n /** Details about the error in case of failure. */\n error?: ApplicationError;\n}\n\nexport interface ApplicationError {\n /** Error code. */\n code?: string;\n /** Description of the error. */\n description?: string;\n /** Data related to the error. */\n data?: Record<string, any> | null;\n}\n\nexport interface BulkUpdateWishlistTagsResult {\n /** Metadata about the update for a single wishlist, including whether it succeeded. */\n itemMetadata?: ItemMetadata;\n}\n\nexport interface BulkActionMetadata {\n /** Number of items that were successfully processed. */\n totalSuccesses?: number;\n /** Number of items that couldn't be processed. */\n totalFailures?: number;\n /** Number of failures without details because detailed failure threshold was exceeded. */\n undetailedFailures?: number;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterRequest {\n /**\n * Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n */\n filter: Record<string, any> | null;\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n\nexport interface BulkUpdateWishlistTagsByFilterResponse {\n /**\n * Job ID. Pass this ID to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job) to retrieve the status of the asynchronous operation.\n * @format GUID\n */\n jobId?: string;\n}\n\nexport interface DomainEvent extends DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n /** Event ID. With this ID you can easily spot duplicated events and ignore them. */\n _id?: string;\n /**\n * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.\n * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.\n */\n entityFqdn?: string;\n /**\n * Event action name, placed at the top level to make it easier for users to dispatch messages.\n * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.\n */\n slug?: string;\n /** ID of the entity associated with the event. */\n entityId?: string;\n /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */\n eventTime?: Date | null;\n /**\n * Whether the event was triggered as a result of a privacy regulation application\n * (for example, GDPR).\n */\n triggeredByAnonymizeRequest?: boolean | null;\n /** If present, indicates the action that triggered the event. */\n originatedFrom?: string | null;\n /**\n * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.\n * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.\n */\n entityEventSequence?: string | null;\n}\n\n/** @oneof */\nexport interface DomainEventBodyOneOf {\n createdEvent?: EntityCreatedEvent;\n updatedEvent?: EntityUpdatedEvent;\n deletedEvent?: EntityDeletedEvent;\n actionEvent?: ActionEvent;\n}\n\nexport interface EntityCreatedEvent {\n entity?: string;\n}\n\nexport interface RestoreInfo {\n deletedDate?: Date | null;\n}\n\nexport interface EntityUpdatedEvent {\n /**\n * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.\n * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.\n * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.\n */\n currentEntity?: string;\n}\n\nexport interface EntityDeletedEvent {\n /** Entity that was deleted. */\n deletedEntity?: string | null;\n}\n\nexport interface ActionEvent {\n body?: string;\n}\n\nexport interface MessageEnvelope {\n /**\n * App instance ID.\n * @format GUID\n */\n instanceId?: string | null;\n /**\n * Event type.\n * @maxLength 150\n */\n eventType?: string;\n /** The identification type and identity data. */\n identity?: IdentificationData;\n /** Stringify payload. */\n data?: string;\n /** Details related to the account */\n accountInfo?: AccountInfo;\n}\n\nexport interface IdentificationData extends IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n /** @readonly */\n identityType?: WebhookIdentityTypeWithLiterals;\n}\n\n/** @oneof */\nexport interface IdentificationDataIdOneOf {\n /**\n * ID of a site visitor that has not logged in to the site.\n * @format GUID\n */\n anonymousVisitorId?: string;\n /**\n * ID of a site visitor that has logged in to the site.\n * @format GUID\n */\n memberId?: string;\n /**\n * ID of a Wix user (site owner, contributor, etc.).\n * @format GUID\n */\n wixUserId?: string;\n /**\n * ID of an app.\n * @format GUID\n */\n appId?: string;\n}\n\nexport enum WebhookIdentityType {\n UNKNOWN = 'UNKNOWN',\n ANONYMOUS_VISITOR = 'ANONYMOUS_VISITOR',\n MEMBER = 'MEMBER',\n WIX_USER = 'WIX_USER',\n APP = 'APP',\n}\n\n/** @enumType */\nexport type WebhookIdentityTypeWithLiterals =\n | WebhookIdentityType\n | 'UNKNOWN'\n | 'ANONYMOUS_VISITOR'\n | 'MEMBER'\n | 'WIX_USER'\n | 'APP';\n\nexport interface AccountInfo {\n /**\n * ID of the Wix account associated with the event.\n * @format GUID\n */\n accountId?: string | null;\n /**\n * ID of the parent Wix account. Only included when accountId belongs to a child account.\n * @format GUID\n */\n parentAccountId?: string | null;\n /**\n * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.\n * @format GUID\n */\n siteId?: string | null;\n}\n\n/** @docsIgnore */\nexport type AddItemApplicationErrors = {\n code?: 'WISHLIST_ITEMS_LIMIT_EXCEEDED';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n/** @docsIgnore */\nexport type BulkUpdateWishlistTagsByFilterApplicationErrors = {\n code?: 'EMPTY_ASSIGN_AND_UNASSIGN_LISTS';\n description?: string;\n data?: Record<string, any>;\n};\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n * @internal\n * @documentationMaturity preview\n * @permissionId ecom:v1:wishlist:get_default_wishlist\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist\n */\nexport async function getDefaultWishlist(\n options?: GetDefaultWishlistOptions\n): Promise<\n NonNullablePaths<\n GetDefaultWishlistResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[1] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n appId: options?.appId,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.getDefaultWishlist(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: { appId: '$[0].appId' },\n singleArgumentUnchanged: false,\n },\n ['options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface GetDefaultWishlistOptions {\n /**\n * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.\n * When omitted, all items in the member's wishlist are returned.\n * @format GUID\n */\n appId?: string | null;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n * @param catalogReference - Reference to the catalog item to add.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:add_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem\n */\nexport async function addItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: AddItemOptions\n): Promise<\n NonNullablePaths<\n AddItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n > & {\n __applicationErrorsType?: AddItemApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.addItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface AddItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n * @param catalogReference - Reference to the catalog item to remove.\n * @internal\n * @documentationMaturity preview\n * @requiredField catalogReference\n * @requiredField catalogReference.appId\n * @requiredField catalogReference.catalogItemId\n * @permissionId ecom:v1:wishlist:remove_item\n * @applicableIdentity MEMBER\n * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem\n */\nexport async function removeItem(\n catalogReference: NonNullablePaths<\n CatalogReference,\n `appId` | `catalogItemId`,\n 0\n >,\n options?: RemoveItemOptions\n): Promise<\n NonNullablePaths<\n RemoveItemResponse,\n | `wishlist.items`\n | `wishlist.items.${number}.catalogReference.catalogItemId`\n | `wishlist.items.${number}.catalogReference.appId`\n | `wishlist.tags.privateTags.tagIds`,\n 4\n >\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n catalogReference: catalogReference,\n returnEntity: options?.returnEntity,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.removeItem(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n catalogReference: '$[0]',\n returnEntity: '$[1].returnEntity',\n },\n singleArgumentUnchanged: false,\n },\n ['catalogReference', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface RemoveItemOptions {\n /**\n * Whether to return the updated wishlist in the response.\n *\n * Default: `false`\n */\n returnEntity?: boolean;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n * @param wishlistIds - IDs of the wishlists to update.\n * @internal\n * @documentationMaturity preview\n * @requiredField wishlistIds\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags\n */\nexport async function bulkUpdateWishlistTags(\n wishlistIds: string[],\n options?: BulkUpdateWishlistTagsOptions\n): Promise<\n NonNullablePaths<\n BulkUpdateWishlistTagsResponse,\n | `results`\n | `results.${number}.itemMetadata.originalIndex`\n | `results.${number}.itemMetadata.success`\n | `results.${number}.itemMetadata.error.code`\n | `results.${number}.itemMetadata.error.description`\n | `bulkActionMetadata.totalSuccesses`\n | `bulkActionMetadata.totalFailures`\n | `bulkActionMetadata.undetailedFailures`,\n 4\n > & {\n __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n wishlistIds: wishlistIds,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts = ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTags(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n wishlistIds: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['wishlistIds', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsOptions {\n /** Tags to assign to each wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each wishlist. */\n unassignTags?: Tags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n * @param filter - Filter object. An empty filter matches all of the current member's wishlists.\n *\n * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.\n * @internal\n * @documentationMaturity preview\n * @requiredField filter\n * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter\n * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter\n */\nexport async function bulkUpdateWishlistTagsByFilter(\n filter: Record<string, any>,\n options?: BulkUpdateWishlistTagsByFilterOptions\n): Promise<\n NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {\n __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;\n }\n> {\n // @ts-ignore\n const { httpClient, sideEffects } = arguments[2] as {\n httpClient: HttpClient;\n sideEffects?: any;\n };\n\n const payload = renameKeysFromSDKRequestToRESTRequest({\n filter: filter,\n assignTags: options?.assignTags,\n unassignTags: options?.unassignTags,\n });\n\n const reqOpts =\n ambassadorWixEcomV1Wishlist.bulkUpdateWishlistTagsByFilter(payload);\n\n sideEffects?.onSiteCall?.();\n try {\n const result = await httpClient.request(reqOpts);\n sideEffects?.onSuccess?.(result);\n\n return renameKeysFromRESTResponseToSDKResponse(result.data)!;\n } catch (err: any) {\n const transformedError = sdkTransformError(\n err,\n {\n spreadPathsToArguments: {},\n explicitPathsToArguments: {\n filter: '$[0]',\n assignTags: '$[1].assignTags',\n unassignTags: '$[1].unassignTags',\n },\n singleArgumentUnchanged: false,\n },\n ['filter', 'options']\n );\n sideEffects?.onError?.(err);\n\n throw transformedError;\n }\n}\n\nexport interface BulkUpdateWishlistTagsByFilterOptions {\n /** Tags to assign to each matching wishlist. */\n assignTags?: Tags;\n /** Tags to unassign from each matching wishlist. */\n unassignTags?: Tags;\n}\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixEcomWishlistV1WishlistsUrl(\n opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n const domainToMappings = {\n _: [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'editor._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'blocks._base_domain_': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'create.editorx': [\n {\n srcPath: '/_api/wishlist',\n destPath: '',\n },\n ],\n 'www.wixapis.com': [\n {\n srcPath: '/ecom/v1/wishlists',\n destPath: '/v1/wishlists',\n },\n ],\n };\n\n return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_ecom_wishlists';\n\n/**\n * Retrieves the current member's default wishlist.\n *\n * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.\n */\nexport function getDefaultWishlist(\n payload: object\n): RequestOptionsFactory<any> {\n function __getDefaultWishlist({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'GET' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/get-default',\n data: payload,\n host,\n }),\n params: toURLSearchParams(payload),\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __getDefaultWishlist;\n}\n\n/**\n * Adds an item to the member's wishlist.\n *\n * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.\n */\nexport function addItem(payload: object): RequestOptionsFactory<any> {\n function __addItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.AddItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/add-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __addItem;\n}\n\n/**\n * Removes an item from the member's wishlist.\n *\n * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.\n */\nexport function removeItem(payload: object): RequestOptionsFactory<any> {\n function __removeItem({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.RemoveItem',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/wishlists/remove-item',\n data: payload,\n host,\n }),\n data: payload,\n transformResponse: (payload: any) =>\n transformPaths(payload, [\n {\n transformFn: transformRESTTimestampToSDKTimestamp,\n paths: [\n { path: 'wishlist.createdDate' },\n { path: 'wishlist.updatedDate' },\n { path: 'wishlist.items.addedDate' },\n ],\n },\n ]),\n };\n\n return metadata;\n }\n\n return __removeItem;\n}\n\n/**\n * Adds or removes tags on multiple wishlists.\n *\n * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.\n */\nexport function bulkUpdateWishlistTags(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTags({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn: 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTags;\n}\n\n/**\n * Asynchronously updates tags on multiple wishlists that match the provided filter.\n *\n * An empty filter matches all of the current member's wishlists.\n *\n * To check the status of the bulk update, pass the returned `jobId` to [Get Async Job](https://dev.wix.com/docs/api-reference/business-management/async-job/get-async-job).\n */\nexport function bulkUpdateWishlistTagsByFilter(\n payload: object\n): RequestOptionsFactory<any> {\n function __bulkUpdateWishlistTagsByFilter({ host }: any) {\n const metadata = {\n entityFqdn: 'wix.ecom.v1.wishlist',\n method: 'POST' as any,\n methodFqn:\n 'wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter',\n packageName: PACKAGE_NAME,\n migrationOptions: {\n optInTransformResponse: true,\n },\n url: resolveWixEcomWishlistV1WishlistsUrl({\n protoPath: '/v1/bulk/wishlists/update-tags-by-filter',\n data: payload,\n host,\n }),\n data: payload,\n };\n\n return metadata;\n }\n\n return __bulkUpdateWishlistTagsByFilter;\n}\n"],"mappings":";AAAA,SAAS,kBAAkB,yBAAyB;AACpD;AAAA,EACE;AAAA,EACA;AAAA,OACK;;;ACJP,SAAS,yBAAyB;AAClC,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAI3B,SAAS,qCACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAA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,QACA,yBAAyB;AAAA,MAC3B;AAAA,MACA,CAAC,UAAU,SAAS;AAAA,IACtB;AACA,iBAAa,UAAU,GAAG;AAE1B,UAAM;AAAA,EACR;AACF;","names":["payload","WebhookIdentityType","getDefaultWishlist","addItem","removeItem","bulkUpdateWishlistTags","bulkUpdateWishlistTagsByFilter"]}
@@ -10,7 +10,7 @@ interface GetDefaultWishlistSignature {
10
10
  *
11
11
  * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.
12
12
  */
13
- (options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
13
+ (options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
14
14
  }
15
15
  /** @internal */
16
16
  declare function addItem$1(httpClient: HttpClient): AddItemSignature;
@@ -21,7 +21,7 @@ interface AddItemSignature {
21
21
  * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.
22
22
  * @param - Reference to the catalog item to add.
23
23
  */
24
- (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6> & {
24
+ (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4> & {
25
25
  __applicationErrorsType?: AddItemApplicationErrors;
26
26
  }>;
27
27
  }
@@ -34,7 +34,7 @@ interface RemoveItemSignature {
34
34
  * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.
35
35
  * @param - Reference to the catalog item to remove.
36
36
  */
37
- (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
37
+ (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
38
38
  }
39
39
  /** @internal */
40
40
  declare function bulkUpdateWishlistTags$1(httpClient: HttpClient): BulkUpdateWishlistTagsSignature;
@@ -45,7 +45,7 @@ interface BulkUpdateWishlistTagsSignature {
45
45
  * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.
46
46
  * @param - IDs of the wishlists to update.
47
47
  */
48
- (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 6> & {
48
+ (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 4> & {
49
49
  __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;
50
50
  }>;
51
51
  }
@@ -62,7 +62,7 @@ interface BulkUpdateWishlistTagsByFilterSignature {
62
62
  *
63
63
  * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.
64
64
  */
65
- (filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {
65
+ (filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {
66
66
  __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;
67
67
  }>;
68
68
  }
@@ -464,7 +464,7 @@ type BulkUpdateWishlistTagsByFilterApplicationErrors = {
464
464
  * @applicableIdentity MEMBER
465
465
  * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist
466
466
  */
467
- declare function getDefaultWishlist(options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
467
+ declare function getDefaultWishlist(options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
468
468
  interface GetDefaultWishlistOptions {
469
469
  /**
470
470
  * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.
@@ -487,7 +487,7 @@ interface GetDefaultWishlistOptions {
487
487
  * @applicableIdentity MEMBER
488
488
  * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem
489
489
  */
490
- declare function addItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6> & {
490
+ declare function addItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4> & {
491
491
  __applicationErrorsType?: AddItemApplicationErrors;
492
492
  }>;
493
493
  interface AddItemOptions {
@@ -512,7 +512,7 @@ interface AddItemOptions {
512
512
  * @applicableIdentity MEMBER
513
513
  * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem
514
514
  */
515
- declare function removeItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
515
+ declare function removeItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
516
516
  interface RemoveItemOptions {
517
517
  /**
518
518
  * Whether to return the updated wishlist in the response.
@@ -532,7 +532,7 @@ interface RemoveItemOptions {
532
532
  * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags
533
533
  * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags
534
534
  */
535
- declare function bulkUpdateWishlistTags(wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 6> & {
535
+ declare function bulkUpdateWishlistTags(wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 4> & {
536
536
  __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;
537
537
  }>;
538
538
  interface BulkUpdateWishlistTagsOptions {
@@ -556,7 +556,7 @@ interface BulkUpdateWishlistTagsOptions {
556
556
  * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter
557
557
  * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter
558
558
  */
559
- declare function bulkUpdateWishlistTagsByFilter(filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {
559
+ declare function bulkUpdateWishlistTagsByFilter(filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {
560
560
  __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;
561
561
  }>;
562
562
  interface BulkUpdateWishlistTagsByFilterOptions {
@@ -10,7 +10,7 @@ interface GetDefaultWishlistSignature {
10
10
  *
11
11
  * If `appId` is provided, only items whose `catalogReference.appId` matches are returned. If omitted, all items are returned. If the member doesn't have a wishlist yet, an empty wishlist is returned.
12
12
  */
13
- (options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
13
+ (options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
14
14
  }
15
15
  /** @internal */
16
16
  declare function addItem$1(httpClient: HttpClient): AddItemSignature;
@@ -21,7 +21,7 @@ interface AddItemSignature {
21
21
  * The wishlist is created automatically on first use. If the item is already in the wishlist, the request is ignored. A wishlist can hold up to 100 items.
22
22
  * @param - Reference to the catalog item to add.
23
23
  */
24
- (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6> & {
24
+ (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4> & {
25
25
  __applicationErrorsType?: AddItemApplicationErrors;
26
26
  }>;
27
27
  }
@@ -34,7 +34,7 @@ interface RemoveItemSignature {
34
34
  * If the item isn't in the wishlist, or the member has no wishlist yet, the request is ignored.
35
35
  * @param - Reference to the catalog item to remove.
36
36
  */
37
- (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
37
+ (catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
38
38
  }
39
39
  /** @internal */
40
40
  declare function bulkUpdateWishlistTags$1(httpClient: HttpClient): BulkUpdateWishlistTagsSignature;
@@ -45,7 +45,7 @@ interface BulkUpdateWishlistTagsSignature {
45
45
  * Specify which tags to assign and which tags to unassign. A tag that appears in both the list to assign and the list to unassign is assigned. Tags that don't exist are ignored.
46
46
  * @param - IDs of the wishlists to update.
47
47
  */
48
- (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 6> & {
48
+ (wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 4> & {
49
49
  __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;
50
50
  }>;
51
51
  }
@@ -62,7 +62,7 @@ interface BulkUpdateWishlistTagsByFilterSignature {
62
62
  *
63
63
  * See [API Query Language](https://dev.wix.com/docs/api-reference/articles/work-with-wix-apis/data-retrieval/about-the-wix-api-query-language) for more information.
64
64
  */
65
- (filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {
65
+ (filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {
66
66
  __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;
67
67
  }>;
68
68
  }
@@ -464,7 +464,7 @@ type BulkUpdateWishlistTagsByFilterApplicationErrors = {
464
464
  * @applicableIdentity MEMBER
465
465
  * @fqn wix.ecom.wishlist.v1.Wishlists.GetDefaultWishlist
466
466
  */
467
- declare function getDefaultWishlist(options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
467
+ declare function getDefaultWishlist(options?: GetDefaultWishlistOptions): Promise<NonNullablePaths<GetDefaultWishlistResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
468
468
  interface GetDefaultWishlistOptions {
469
469
  /**
470
470
  * Optional. Filters the returned items to only those whose `catalogReference.appId` matches this value.
@@ -487,7 +487,7 @@ interface GetDefaultWishlistOptions {
487
487
  * @applicableIdentity MEMBER
488
488
  * @fqn wix.ecom.wishlist.v1.Wishlists.AddItem
489
489
  */
490
- declare function addItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6> & {
490
+ declare function addItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: AddItemOptions): Promise<NonNullablePaths<AddItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4> & {
491
491
  __applicationErrorsType?: AddItemApplicationErrors;
492
492
  }>;
493
493
  interface AddItemOptions {
@@ -512,7 +512,7 @@ interface AddItemOptions {
512
512
  * @applicableIdentity MEMBER
513
513
  * @fqn wix.ecom.wishlist.v1.Wishlists.RemoveItem
514
514
  */
515
- declare function removeItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 2>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 6>>;
515
+ declare function removeItem(catalogReference: NonNullablePaths<CatalogReference, `appId` | `catalogItemId`, 0>, options?: RemoveItemOptions): Promise<NonNullablePaths<RemoveItemResponse, `wishlist.items` | `wishlist.items.${number}.catalogReference.catalogItemId` | `wishlist.items.${number}.catalogReference.appId` | `wishlist.tags.privateTags.tagIds`, 4>>;
516
516
  interface RemoveItemOptions {
517
517
  /**
518
518
  * Whether to return the updated wishlist in the response.
@@ -532,7 +532,7 @@ interface RemoveItemOptions {
532
532
  * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags
533
533
  * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTags
534
534
  */
535
- declare function bulkUpdateWishlistTags(wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 6> & {
535
+ declare function bulkUpdateWishlistTags(wishlistIds: string[], options?: BulkUpdateWishlistTagsOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 4> & {
536
536
  __applicationErrorsType?: BulkUpdateWishlistTagsApplicationErrors;
537
537
  }>;
538
538
  interface BulkUpdateWishlistTagsOptions {
@@ -556,7 +556,7 @@ interface BulkUpdateWishlistTagsOptions {
556
556
  * @permissionId ecom:v1:wishlist:bulk_update_wishlist_tags_by_filter
557
557
  * @fqn wix.ecom.wishlist.v1.Wishlists.BulkUpdateWishlistTagsByFilter
558
558
  */
559
- declare function bulkUpdateWishlistTagsByFilter(filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 2> & {
559
+ declare function bulkUpdateWishlistTagsByFilter(filter: Record<string, any>, options?: BulkUpdateWishlistTagsByFilterOptions): Promise<NonNullablePaths<BulkUpdateWishlistTagsByFilterResponse, `jobId`, 0> & {
560
560
  __applicationErrorsType?: BulkUpdateWishlistTagsByFilterApplicationErrors;
561
561
  }>;
562
562
  interface BulkUpdateWishlistTagsByFilterOptions {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/auto_sdk_ecom_wishlists",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "license": "MIT",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/",
@@ -50,5 +50,5 @@
50
50
  "fqdn": "wix.ecom.v1.wishlist"
51
51
  }
52
52
  },
53
- "falconPackageHash": "13401fca212a6add708c2331e1d39ae6b67758b3e0226823a786c62d"
53
+ "falconPackageHash": "d96e7007c85e35182248fdd114dd624ac8986ebe189f0218b749a73d"
54
54
  }