{"version":3,"sources":["../../src/portfolio-collections-v1-collection-collections.public.ts","../../src/portfolio-collections-v1-collection-collections.universal.ts","../../src/portfolio-collections-v1-collection-collections.http.ts","../../src/portfolio-collections-v1-collection-collections.context.ts"],"sourcesContent":["import { renameKeysFromRESTResponseToSDKResponse } from '@wix/sdk-runtime/rename-all-nested-keys';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTImageToSDKImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformRESTPageURLV2ToSDKPageURLV2 } from '@wix/sdk-runtime/transformations/page-url-v2';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { EventDefinition, HttpClient, NonNullablePaths } from '@wix/sdk-types';\nimport {\n  Collection,\n  CollectionCreatedEnvelope,\n  CollectionDeletedEnvelope,\n  CollectionQuery,\n  CollectionUpdatedEnvelope,\n  CollectionsQueryBuilder,\n  DeleteCollectionResponse,\n  GetCollectionOptions,\n  ListCollectionsOptions,\n  ListCollectionsResponse,\n  QueryCollectionsOptions,\n  QueryCollectionsResponse,\n  UpdateCollection,\n  createCollection as universalCreateCollection,\n  deleteCollection as universalDeleteCollection,\n  getCollection as universalGetCollection,\n  listCollections as universalListCollections,\n  queryCollections as universalQueryCollections,\n  typedQueryCollections as universalTypedQueryCollections,\n  updateCollection as universalUpdateCollection,\n} from './portfolio-collections-v1-collection-collections.universal.js';\n\nexport const __metadata = { PACKAGE_NAME: '@wix/portfolio' };\n\nexport function createCollection(\n  httpClient: HttpClient\n): CreateCollectionSignature {\n  return (collection: Collection) =>\n    universalCreateCollection(\n      collection,\n      // @ts-ignore\n      { httpClient }\n    );\n}\n\ninterface CreateCollectionSignature {\n  /**\n   * Creates a collection.\n   * @param - Collection to create.\n   * @returns Created collection.\n   */\n  (collection: Collection): Promise<\n    NonNullablePaths<\n      Collection,\n      | `coverImage.focalPoint.x`\n      | `coverImage.focalPoint.y`\n      | `seoData.tags`\n      | `seoData.tags.${number}.type`\n      | `seoData.tags.${number}.children`\n      | `seoData.tags.${number}.custom`\n      | `seoData.tags.${number}.disabled`\n      | `seoData.settings.preventAutoRedirect`\n      | `seoData.settings.keywords`\n      | `seoData.settings.keywords.${number}.term`\n      | `seoData.settings.keywords.${number}.isMain`,\n      6\n    >\n  >;\n}\n\nexport function getCollection(httpClient: HttpClient): GetCollectionSignature {\n  return (collectionId: string, options?: GetCollectionOptions) =>\n    universalGetCollection(\n      collectionId,\n      options,\n      // @ts-ignore\n      { httpClient }\n    );\n}\n\ninterface GetCollectionSignature {\n  /**\n   * Retrieves a collection.\n   * @param - ID of the collection to retrieve.\n   * @returns The requested collection.\n   */\n  (collectionId: string, options?: GetCollectionOptions): Promise<\n    NonNullablePaths<\n      Collection,\n      | `coverImage.focalPoint.x`\n      | `coverImage.focalPoint.y`\n      | `seoData.tags`\n      | `seoData.tags.${number}.type`\n      | `seoData.tags.${number}.children`\n      | `seoData.tags.${number}.custom`\n      | `seoData.tags.${number}.disabled`\n      | `seoData.settings.preventAutoRedirect`\n      | `seoData.settings.keywords`\n      | `seoData.settings.keywords.${number}.term`\n      | `seoData.settings.keywords.${number}.isMain`,\n      6\n    >\n  >;\n}\n\nexport function listCollections(\n  httpClient: HttpClient\n): ListCollectionsSignature {\n  return (options?: ListCollectionsOptions) =>\n    universalListCollections(\n      options,\n      // @ts-ignore\n      { httpClient }\n    );\n}\n\ninterface ListCollectionsSignature {\n  /**\n   * Retrieves a list all collections in a portfolio.\n   */\n  (options?: ListCollectionsOptions): Promise<\n    NonNullablePaths<\n      ListCollectionsResponse,\n      | `collections`\n      | `collections.${number}.coverImage.focalPoint.x`\n      | `collections.${number}.coverImage.focalPoint.y`\n      | `collections.${number}.seoData.settings.preventAutoRedirect`,\n      6\n    >\n  >;\n}\n\nexport function updateCollection(\n  httpClient: HttpClient\n): UpdateCollectionSignature {\n  return (\n    _id: string,\n    collection: NonNullablePaths<UpdateCollection, `revision`, 2>\n  ) =>\n    universalUpdateCollection(\n      _id,\n      collection,\n      // @ts-ignore\n      { httpClient }\n    );\n}\n\ninterface UpdateCollectionSignature {\n  /**\n   * Updates a collection.\n   * @param - Collection ID.\n   * @returns Updated collection.\n   */\n  (\n    _id: string,\n    collection: NonNullablePaths<UpdateCollection, `revision`, 2>\n  ): Promise<\n    NonNullablePaths<\n      Collection,\n      | `coverImage.focalPoint.x`\n      | `coverImage.focalPoint.y`\n      | `seoData.tags`\n      | `seoData.tags.${number}.type`\n      | `seoData.tags.${number}.children`\n      | `seoData.tags.${number}.custom`\n      | `seoData.tags.${number}.disabled`\n      | `seoData.settings.preventAutoRedirect`\n      | `seoData.settings.keywords`\n      | `seoData.settings.keywords.${number}.term`\n      | `seoData.settings.keywords.${number}.isMain`,\n      6\n    >\n  >;\n}\n\nexport function deleteCollection(\n  httpClient: HttpClient\n): DeleteCollectionSignature {\n  return (collectionId: string) =>\n    universalDeleteCollection(\n      collectionId,\n      // @ts-ignore\n      { httpClient }\n    );\n}\n\ninterface DeleteCollectionSignature {\n  /**\n   * Deletes a collection.\n   * @param - ID of the collection to delete.\n   */\n  (collectionId: string): Promise<\n    NonNullablePaths<DeleteCollectionResponse, `collectionId`, 2>\n  >;\n}\n\nexport function queryCollections(\n  httpClient: HttpClient\n): QueryCollectionsSignature {\n  return (options?: QueryCollectionsOptions) =>\n    universalQueryCollections(\n      options,\n      // @ts-ignore\n      { httpClient }\n    );\n}\n\ninterface QueryCollectionsSignature {\n  /**\n   * Creates a query to retrieve a list of collections.\n   *\n   * The `queryCollections()` method builds a query to retrieve a list of collections and returns a `CollectionsQueryBuilder` object.\n   *\n   * The returned object contains the query definition, which is used to run the query using the [`find()`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/find) method.\n   *\n   * You can refine the query by chaining `CollectionsQueryBuilder` methods onto the query. `CollectionsQueryBuilder` methods enable you to filter, sort, and control the results that `queryCollections()` returns.\n   *\n   * `queryCollections()`  runs with the following `CollectionsQueryBuilder` defaults which you can override:\n   *\n   * + [`limit(100)`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/limit)\n   * + [`ascending('_id')`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/ascending)\n   *\n   * The following `CollectionsQueryBuilder` methods are supported for `queryCollections()`. For a full description of the operations object, see the object returned for the [`items`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-result/items) property in `CollectionsQueryResult`.\n   */\n  (options?: QueryCollectionsOptions): CollectionsQueryBuilder;\n}\n\nexport function typedQueryCollections(\n  httpClient: HttpClient\n): TypedQueryCollectionsSignature {\n  return (query: CollectionQuery, options?: QueryCollectionsOptions) =>\n    universalTypedQueryCollections(\n      query,\n      options,\n      // @ts-ignore\n      { httpClient }\n    );\n}\n\ninterface TypedQueryCollectionsSignature {\n  /** */\n  (query: CollectionQuery, options?: QueryCollectionsOptions): Promise<\n    NonNullablePaths<\n      QueryCollectionsResponse,\n      | `collections`\n      | `collections.${number}.coverImage.focalPoint.x`\n      | `collections.${number}.coverImage.focalPoint.y`\n      | `collections.${number}.seoData.settings.preventAutoRedirect`,\n      6\n    >\n  >;\n}\n\nexport const onCollectionCreated = EventDefinition(\n  'wix.portfolio.collections.v1.collection_created',\n  true,\n  (event: CollectionCreatedEnvelope) =>\n    renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(event, [\n        {\n          transformFn: transformRESTFloatToSDKFloat,\n          paths: [\n            { path: 'entity.sortOrder' },\n            { path: 'entity.coverImage.focalPoint.x' },\n            { path: 'entity.coverImage.focalPoint.y' },\n            { path: 'entity.coverImage.unsharpMasking.amount' },\n            { path: 'entity.coverImage.unsharpMasking.radius' },\n            { path: 'entity.coverImage.unsharpMasking.threshold' },\n          ],\n        },\n        {\n          transformFn: transformRESTTimestampToSDKTimestamp,\n          paths: [\n            { path: 'entity.createdDate' },\n            { path: 'entity.updatedDate' },\n            { path: 'metadata.eventTime' },\n          ],\n        },\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'entity.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'entity.coverImage.imageInfo' }],\n        },\n      ])\n    )\n)<CollectionCreatedEnvelope>();\nexport const onCollectionDeleted = EventDefinition(\n  'wix.portfolio.collections.v1.collection_deleted',\n  true,\n  (event: CollectionDeletedEnvelope) =>\n    renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(event, [\n        {\n          transformFn: transformRESTFloatToSDKFloat,\n          paths: [\n            { path: 'undefined.sortOrder' },\n            { path: 'undefined.coverImage.focalPoint.x' },\n            { path: 'undefined.coverImage.focalPoint.y' },\n            { path: 'undefined.coverImage.unsharpMasking.amount' },\n            { path: 'undefined.coverImage.unsharpMasking.radius' },\n            { path: 'undefined.coverImage.unsharpMasking.threshold' },\n          ],\n        },\n        {\n          transformFn: transformRESTTimestampToSDKTimestamp,\n          paths: [\n            { path: 'undefined.createdDate' },\n            { path: 'undefined.updatedDate' },\n            { path: 'metadata.eventTime' },\n          ],\n        },\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'undefined.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'undefined.coverImage.imageInfo' }],\n        },\n      ])\n    )\n)<CollectionDeletedEnvelope>();\nexport const onCollectionUpdated = EventDefinition(\n  'wix.portfolio.collections.v1.collection_updated',\n  true,\n  (event: CollectionUpdatedEnvelope) =>\n    renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(event, [\n        {\n          transformFn: transformRESTFloatToSDKFloat,\n          paths: [\n            { path: 'entity.sortOrder' },\n            { path: 'entity.coverImage.focalPoint.x' },\n            { path: 'entity.coverImage.focalPoint.y' },\n            { path: 'entity.coverImage.unsharpMasking.amount' },\n            { path: 'entity.coverImage.unsharpMasking.radius' },\n            { path: 'entity.coverImage.unsharpMasking.threshold' },\n          ],\n        },\n        {\n          transformFn: transformRESTTimestampToSDKTimestamp,\n          paths: [\n            { path: 'entity.createdDate' },\n            { path: 'entity.updatedDate' },\n            { path: 'metadata.eventTime' },\n          ],\n        },\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'entity.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'entity.coverImage.imageInfo' }],\n        },\n      ])\n    )\n)<CollectionUpdatedEnvelope>();\n\nexport {\n  AccountInfo,\n  AccountInfoMetadata,\n  ActionEvent,\n  AdminRemoveMenuItemsResponse,\n  App,\n  BaseEventMetadata,\n  Collection,\n  CollectionCreatedEnvelope,\n  CollectionDeletedEnvelope,\n  CollectionQuerySpec,\n  CollectionUpdatedEnvelope,\n  CollectionsQueryBuilder,\n  CollectionsQueryResult,\n  CreateCollectionRequest,\n  CreateCollectionResponse,\n  CursorPaging,\n  Cursors,\n  CustomTag,\n  DeleteCollectionRequest,\n  DeleteCollectionResponse,\n  DomainEvent,\n  DomainEventBodyOneOf,\n  Empty,\n  EntityCreatedEvent,\n  EntityDeletedEvent,\n  EntityUpdatedEvent,\n  EventMetadata,\n  File,\n  GetCollectionOptions,\n  GetCollectionRequest,\n  GetCollectionResponse,\n  IdentificationData,\n  IdentificationDataIdOneOf,\n  Image,\n  ImageType,\n  InvalidateCache,\n  InvalidateCacheGetByOneOf,\n  Keyword,\n  ListCollectionsOptions,\n  ListCollectionsRequest,\n  ListCollectionsResponse,\n  MessageEnvelope,\n  Page,\n  Pages,\n  Paging,\n  PagingMetadataV2,\n  Point,\n  QueryCollectionsOptions,\n  QueryCollectionsRequest,\n  QueryCollectionsResponse,\n  QueryV2,\n  QueryV2PagingMethodOneOf,\n  RestoreInfo,\n  SeoSchema,\n  Settings,\n  SortOrder,\n  Sorting,\n  Tag,\n  URI,\n  URIs,\n  UnsharpMasking,\n  UpdateCollection,\n  UpdateCollectionRequest,\n  UpdateCollectionResponse,\n  WebhookIdentityType,\n  utils,\n} from './portfolio-collections-v1-collection-collections.universal.js';\n","import { transformError as sdkTransformError } from '@wix/sdk-runtime/transform-error';\nimport { queryBuilder } from '@wix/sdk-runtime/query-builder';\nimport {\n  renameKeysFromSDKRequestToRESTRequest,\n  renameKeysFromRESTResponseToSDKResponse,\n} from '@wix/sdk-runtime/rename-all-nested-keys';\nimport {\n  HttpClient,\n  HttpResponse,\n  NonNullablePaths,\n  QuerySpec,\n  Query as QuerySdkType,\n} from '@wix/sdk-types';\nimport * as ambassadorWixPortfolioCollectionsV1Collection from './portfolio-collections-v1-collection-collections.http.js';\n// @ts-ignore\nimport { transformSDKImageToRESTImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformRESTImageToSDKImage } from '@wix/sdk-runtime/transformations/image';\nimport { transformSDKPageURLV2ToRESTPageURLV2 } from '@wix/sdk-runtime/transformations/page-url-v2';\nimport { transformRESTPageURLV2ToSDKPageURLV2 } from '@wix/sdk-runtime/transformations/page-url-v2';\nimport { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';\nimport { createQueryUtils } from '@wix/sdk-runtime/query-builder-utils';\n\nexport interface Collection {\n  /**\n   * Collection ID.\n   * @readonly\n   * @format GUID\n   */\n  _id?: string | null;\n  /**\n   * Revision number, which increments by 1 each time the collection is updated. To prevent conflicting changes, the existing revision must be passed when updating the collection object.\n   * @readonly\n   */\n  revision?: string | null;\n  /**\n   * Collection title.\n   * @maxLength 100\n   */\n  title?: string | null;\n  /** Collection description. */\n  description?: string | null;\n  /** Collection slug. */\n  slug?: string | null;\n  /** Collection cover image. */\n  coverImage?: Image;\n  /** Whether the collection is hidden from the portfolio. Default: `false` */\n  hidden?: boolean | null;\n  /**\n   * Index that determines which position a collection is displayed in the portfolio. <br />\n   *\n   * Default: [Epoch](https://www.epoch101.com/) timestamp. <br />\n   */\n  sortOrder?: number | null;\n  /**\n   * Date and time the collection was created.\n   * @readonly\n   */\n  _createdDate?: Date | null;\n  /**\n   * Date and time the collection was updated.\n   * @readonly\n   */\n  _updatedDate?: Date | null;\n  /**\n   * Collection page URL and relative path. Returned when `includePageUrl` is `true` in the request.\n   * @readonly\n   */\n  url?: string;\n  /** Collection SEO data. */\n  seoData?: SeoSchema;\n}\n\nexport interface Image {\n  /** Information about the Wix Media image. */\n  imageInfo?: string;\n  /** Focal point of the image. */\n  focalPoint?: Point;\n}\n\nexport enum ImageType {\n  UNDEFINED = 'UNDEFINED',\n  WIX_MEDIA = 'WIX_MEDIA',\n  EXTERNAL = 'EXTERNAL',\n}\n\n/** @enumType */\nexport type ImageTypeWithLiterals =\n  | ImageType\n  | 'UNDEFINED'\n  | 'WIX_MEDIA'\n  | 'EXTERNAL';\n\nexport interface Point {\n  /** X-coordinate of the focal point. */\n  x?: number;\n  /** Y-coordinate of the focal point. */\n  y?: number;\n}\n\nexport interface UnsharpMasking {\n  /**\n   * Unsharp masking amount. Controls the sharpening strength. <br />\n   *\n   * Min: `0` <br />\n   * Max: `5`\n   * @max 5\n   */\n  amount?: number | null;\n  /** Unsharp masking radius in pixels. Controls the sharpening width. */\n  radius?: number | null;\n  /**\n   * Unsharp masking threshold. Controls how different neighboring pixels must be for shapening to apply. <br />\n   *\n   * Min: `0` <br />\n   * Max: `1`\n   * @max 1\n   */\n  threshold?: number | null;\n}\n\n/**\n * The SEO schema object contains data about different types of meta tags. It makes sure that the information about your page is presented properly to search engines.\n * The search engines use this information for ranking purposes, or to display snippets in the search results.\n * This data will override other sources of tags (for example patterns) and will be included in the <head> section of the HTML document, while not being displayed on the page itself.\n */\nexport interface SeoSchema {\n  /** SEO tag information. */\n  tags?: Tag[];\n  /** SEO general settings. */\n  settings?: Settings;\n}\n\nexport interface Keyword {\n  /** Keyword value. */\n  term?: string;\n  /** Whether the keyword is the main focus keyword. */\n  isMain?: boolean;\n  /**\n   * The source that added the keyword terms to the SEO settings.\n   * @maxLength 1000\n   */\n  origin?: string | null;\n}\n\nexport interface Tag {\n  /**\n   * SEO tag type.\n   *\n   *\n   * Supported values: `title`, `meta`, `script`, `link`.\n   */\n  type?: string;\n  /**\n   * A `{\"key\": \"value\"}` pair object where each SEO tag property (`\"name\"`, `\"content\"`, `\"rel\"`, `\"href\"`) contains a value.\n   * For example: `{\"name\": \"description\", \"content\": \"the description itself\"}`.\n   */\n  props?: Record<string, any> | null;\n  /** SEO tag metadata. For example, `{\"height\": 300, \"width\": 240}`. */\n  meta?: Record<string, any> | null;\n  /** SEO tag inner content. For example, `<title> inner content </title>`. */\n  children?: string;\n  /** Whether the tag is a [custom tag](https://support.wix.com/en/article/adding-additional-meta-tags-to-your-sites-pages). */\n  custom?: boolean;\n  /** Whether the tag is disabled. If the tag is disabled, people can't find your page when searching for this phrase in search engines. */\n  disabled?: boolean;\n}\n\nexport interface Settings {\n  /**\n   * Whether the [automatical redirect visits](https://support.wix.com/en/article/customizing-your-pages-seo-settings-in-the-seo-panel) from the old URL to the new one is enabled.\n   *\n   *\n   * Default: `false` (automatical redirect is enabled).\n   */\n  preventAutoRedirect?: boolean;\n  /**\n   * User-selected keyword terms for a specific page.\n   * @maxSize 5\n   */\n  keywords?: Keyword[];\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 Empty {}\n\nexport interface AdminRemoveMenuItemsResponse {\n  /** number of items queried for deletion */\n  numItems?: number;\n  /** number of items sucessfully deleted */\n  numItemsSuccessfullyDeleted?: number;\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\nexport interface InvalidateCache extends InvalidateCacheGetByOneOf {\n  /**\n   * Invalidate by msId. NOT recommended, as this will invalidate the entire site cache!\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache!\n   * @format GUID\n   */\n  siteId?: string;\n  /** Invalidate by App */\n  app?: App;\n  /** Invalidate by page id */\n  page?: Page;\n  /** Invalidate by URI path */\n  uri?: URI;\n  /** Invalidate by file (for media files such as PDFs) */\n  file?: File;\n  /** Invalidate by custom tag. Tags used in BO invalidation are disabled for this endpoint (more info: https://wix-bo.com/dev/clear-ssr-cache) */\n  customTag?: CustomTag;\n  /** Invalidate by multiple page ids */\n  pages?: Pages;\n  /** Invalidate by multiple URI paths */\n  uris?: URIs;\n  /**\n   * tell us why you're invalidating the cache. You don't need to add your app name\n   * @maxLength 256\n   */\n  reason?: string | null;\n  /** Is local DS */\n  localDc?: boolean;\n  hardPurge?: boolean;\n  /**\n   * Optional caller-provided ID for tracking this invalidation through the system.\n   * When set, the corresponding CDN purge completion event will include this ID,\n   * allowing you to confirm when the invalidation has fully propagated.\n   * Example: generate a UUID, pass it here, and later match it in the CDN purge completion event.\n   * @maxLength 256\n   */\n  correlationId?: string | null;\n}\n\n/** @oneof */\nexport interface InvalidateCacheGetByOneOf {\n  /**\n   * Invalidate by msId. NOT recommended, as this will invalidate the entire site cache!\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache!\n   * @format GUID\n   */\n  siteId?: string;\n  /** Invalidate by App */\n  app?: App;\n  /** Invalidate by page id */\n  page?: Page;\n  /** Invalidate by URI path */\n  uri?: URI;\n  /** Invalidate by file (for media files such as PDFs) */\n  file?: File;\n  /** Invalidate by custom tag. Tags used in BO invalidation are disabled for this endpoint (more info: https://wix-bo.com/dev/clear-ssr-cache) */\n  customTag?: CustomTag;\n  /** Invalidate by multiple page ids */\n  pages?: Pages;\n  /** Invalidate by multiple URI paths */\n  uris?: URIs;\n}\n\nexport interface App {\n  /**\n   * The AppDefId\n   * @minLength 1\n   */\n  appDefId?: string;\n  /**\n   * The instance Id\n   * @format GUID\n   */\n  instanceId?: string;\n}\n\nexport interface Page {\n  /**\n   * the msid the page is on\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * Invalidate by Page ID\n   * @minLength 1\n   */\n  pageId?: string;\n}\n\nexport interface URI {\n  /**\n   * the msid the URI is on\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * URI path to invalidate (e.g. page/my/path) - without leading/trailing slashes\n   * @minLength 1\n   */\n  uriPath?: string;\n}\n\nexport interface File {\n  /**\n   * the msid the file is related to\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * Invalidate by filename (for media files such as PDFs)\n   * @minLength 1\n   * @maxLength 256\n   */\n  fileName?: string;\n}\n\nexport interface CustomTag {\n  /**\n   * the msid the tag is related to\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * Tag to invalidate by\n   * @minLength 1\n   * @maxLength 256\n   */\n  tag?: string;\n}\n\nexport interface Pages {\n  /**\n   * the msid the pages are on\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * Invalidate by multiple Page IDs in a single message\n   * @maxSize 100\n   * @minLength 1\n   */\n  pageIds?: string[];\n}\n\nexport interface URIs {\n  /**\n   * the msid the URIs are on\n   * @format GUID\n   */\n  metaSiteId?: string;\n  /**\n   * URI paths to invalidate (e.g. page/my/path) - without leading/trailing slashes\n   * @maxSize 100\n   * @minLength 1\n   */\n  uriPaths?: string[];\n}\n\nexport interface CreateCollectionRequest {\n  /** Collection to create. */\n  collection: Collection;\n}\n\nexport interface CreateCollectionResponse {\n  /** Created collection. */\n  collection?: Collection;\n}\n\nexport interface GetCollectionRequest {\n  /**\n   * ID of the collection to retrieve.\n   * @format GUID\n   */\n  collectionId: string;\n  /** Whether to include the collection's page URL and relative path in the response. Default: `false` */\n  includePageUrl?: boolean | null;\n}\n\nexport interface GetCollectionResponse {\n  /** The requested collection. */\n  collection?: Collection;\n}\n\nexport interface ListCollectionsRequest {\n  paging?: CursorPaging;\n  /** Whether to include the collection's page URL and relative path in the response. Default: `false` */\n  includePageUrl?: boolean | null;\n}\n\nexport interface CursorPaging {\n  /**\n   * Maximum number of items to return in the results.\n   * @max 100\n   */\n  limit?: number | null;\n  /**\n   * Pointer to the next or previous page in the list of results.\n   *\n   * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n   * Not relevant for the first request.\n   * @maxLength 16000\n   */\n  cursor?: string | null;\n}\n\nexport interface ListCollectionsResponse {\n  /** List of collections. */\n  collections?: Collection[];\n  /** Paging metadata. */\n  metadata?: PagingMetadataV2;\n}\n\nexport interface PagingMetadataV2 {\n  /** Number of items returned in the response. */\n  count?: number | null;\n  /** Offset that was requested. */\n  offset?: number | null;\n  /** Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set. */\n  total?: number | null;\n  /** Flag that indicates the server failed to calculate the `total` field. */\n  tooManyToCount?: boolean | null;\n  /** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */\n  cursors?: Cursors;\n}\n\nexport interface Cursors {\n  /**\n   * Cursor string pointing to the next page in the list of results.\n   * @maxLength 16000\n   */\n  next?: string | null;\n  /**\n   * Cursor pointing to the previous page in the list of results.\n   * @maxLength 16000\n   */\n  prev?: string | null;\n}\n\nexport interface UpdateCollectionRequest {\n  /** Collection to update. */\n  collection: Collection;\n}\n\nexport interface UpdateCollectionResponse {\n  /** Updated collection. */\n  collection?: Collection;\n}\n\nexport interface DeleteCollectionRequest {\n  /**\n   * ID of the collection to delete.\n   * @format GUID\n   */\n  collectionId: string;\n}\n\nexport interface DeleteCollectionResponse {\n  /**\n   * ID of the deleted collection.\n   * @format GUID\n   */\n  collectionId?: string;\n}\n\nexport interface QueryCollectionsRequest {\n  /** Query options. */\n  query: QueryV2;\n  /** Whether to include the collection's page URL and relative path in the response. Default: `false` */\n  includePageUrl?: boolean | null;\n}\n\nexport interface QueryV2 extends QueryV2PagingMethodOneOf {\n  /** Paging options to limit and offset the number of items. */\n  paging?: Paging;\n  /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */\n  cursorPaging?: CursorPaging;\n  /**\n   * Filter object.\n   *\n   * Learn more about [filtering](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#filters).\n   */\n  filter?: Record<string, any> | null;\n  /**\n   * Sort object.\n   *\n   * Learn more about [sorting](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#sorting).\n   */\n  sort?: Sorting[];\n  /** Array of projected fields. A list of specific field names to return. If `fieldsets` are also specified, the union of `fieldsets` and `fields` is returned. */\n  fields?: string[];\n  /** Array of named, predefined sets of projected fields. A array of predefined named sets of fields to be returned. Specifying multiple `fieldsets` will return the union of fields from all sets. If `fields` are also specified, the union of `fieldsets` and `fields` is returned. */\n  fieldsets?: string[];\n}\n\n/** @oneof */\nexport interface QueryV2PagingMethodOneOf {\n  /** Paging options to limit and offset the number of items. */\n  paging?: Paging;\n  /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */\n  cursorPaging?: CursorPaging;\n}\n\nexport interface Sorting {\n  /**\n   * Name of the field to sort by.\n   * @maxLength 512\n   */\n  fieldName?: string;\n  /** Sort order. */\n  order?: SortOrderWithLiterals;\n}\n\nexport enum SortOrder {\n  ASC = 'ASC',\n  DESC = 'DESC',\n}\n\n/** @enumType */\nexport type SortOrderWithLiterals = SortOrder | 'ASC' | 'DESC';\n\nexport interface Paging {\n  /** Number of items to load. */\n  limit?: number | null;\n  /** Number of items to skip in the current sort order. */\n  offset?: number | null;\n}\n\nexport interface QueryCollectionsResponse {\n  /** List of collections. */\n  collections?: Collection[];\n  /** Paging metadata. */\n  metadata?: PagingMetadataV2;\n}\n\nexport interface BaseEventMetadata {\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  /** Details related to the account */\n  accountInfo?: AccountInfo;\n}\n\nexport interface EventMetadata extends BaseEventMetadata {\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  accountInfo?: AccountInfoMetadata;\n}\n\nexport interface AccountInfoMetadata {\n  /** ID of the Wix account associated with the event */\n  accountId: string;\n  /** ID of the Wix site associated with the event. Only included when the event is tied to a specific site. */\n  siteId?: string;\n  /** ID of the parent Wix account. Only included when 'accountId' belongs to a child account. */\n  parentAccountId?: string;\n}\n\nexport interface CollectionCreatedEnvelope {\n  entity: Collection;\n  metadata: EventMetadata;\n}\n\n/**\n * Triggered when a collection is created.\n * @permissionScope Wix Multilingual - Nile Wrapper Domain Events Read\n * @permissionScopeId SCOPE.MULTILINGUAL.NILE_WRAPPER_DOMAIN_EVENTS_READ\n * @permissionScope Manage Portfolio\n * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO\n * @permissionId PORTFOLIO.COLLECTION_READ\n * @webhook\n * @eventType wix.portfolio.collections.v1.collection_created\n * @slug created\n */\nexport declare function onCollectionCreated(\n  handler: (event: CollectionCreatedEnvelope) => void | Promise<void>\n): void;\n\nexport interface CollectionDeletedEnvelope {\n  metadata: EventMetadata;\n}\n\n/**\n * Triggered when a collection is deleted.\n * @permissionScope Wix Multilingual - Nile Wrapper Domain Events Read\n * @permissionScopeId SCOPE.MULTILINGUAL.NILE_WRAPPER_DOMAIN_EVENTS_READ\n * @permissionScope Manage Portfolio\n * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO\n * @permissionId PORTFOLIO.COLLECTION_READ\n * @webhook\n * @eventType wix.portfolio.collections.v1.collection_deleted\n * @slug deleted\n */\nexport declare function onCollectionDeleted(\n  handler: (event: CollectionDeletedEnvelope) => void | Promise<void>\n): void;\n\nexport interface CollectionUpdatedEnvelope {\n  entity: Collection;\n  metadata: EventMetadata;\n}\n\n/**\n * Triggered when a collection is updated.\n * @permissionScope Wix Multilingual - Nile Wrapper Domain Events Read\n * @permissionScopeId SCOPE.MULTILINGUAL.NILE_WRAPPER_DOMAIN_EVENTS_READ\n * @permissionScope Manage Portfolio\n * @permissionScopeId SCOPE.PORTFOLIO.MANAGE-PORTFOLIO\n * @permissionId PORTFOLIO.COLLECTION_READ\n * @webhook\n * @eventType wix.portfolio.collections.v1.collection_updated\n * @slug updated\n */\nexport declare function onCollectionUpdated(\n  handler: (event: CollectionUpdatedEnvelope) => void | Promise<void>\n): void;\n\n/**\n * Creates a collection.\n * @param collection - Collection to create.\n * @public\n * @requiredField collection\n * @permissionId PORTFOLIO.COLLECTION_CREATE\n * @applicableIdentity APP\n * @returns Created collection.\n * @fqn com.wixpress.portfolio.collections.CollectionsService.CreateCollection\n */\nexport async function createCollection(\n  collection: Collection\n): Promise<\n  NonNullablePaths<\n    Collection,\n    | `coverImage.focalPoint.x`\n    | `coverImage.focalPoint.y`\n    | `seoData.tags`\n    | `seoData.tags.${number}.type`\n    | `seoData.tags.${number}.children`\n    | `seoData.tags.${number}.custom`\n    | `seoData.tags.${number}.disabled`\n    | `seoData.settings.preventAutoRedirect`\n    | `seoData.settings.keywords`\n    | `seoData.settings.keywords.${number}.term`\n    | `seoData.settings.keywords.${number}.isMain`,\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 = transformPaths(\n    renameKeysFromSDKRequestToRESTRequest({ collection: collection }),\n    [\n      {\n        transformFn: transformSDKPageURLV2ToRESTPageURLV2,\n        paths: [{ path: 'collection.url' }],\n      },\n      {\n        transformFn: transformSDKImageToRESTImage,\n        paths: [{ path: 'collection.coverImage.imageInfo' }],\n      },\n    ]\n  );\n\n  const reqOpts =\n    ambassadorWixPortfolioCollectionsV1Collection.createCollection(payload);\n\n  sideEffects?.onSiteCall?.();\n  try {\n    const result = await httpClient.request(reqOpts);\n    sideEffects?.onSuccess?.(result);\n\n    return renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(result.data, [\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'collection.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'collection.coverImage.imageInfo' }],\n        },\n      ])\n    )?.collection!;\n  } catch (err: any) {\n    const transformedError = sdkTransformError(\n      err,\n      {\n        spreadPathsToArguments: {},\n        explicitPathsToArguments: { collection: '$[0]' },\n        singleArgumentUnchanged: false,\n      },\n      ['collection']\n    );\n    sideEffects?.onError?.(err);\n\n    throw transformedError;\n  }\n}\n\n/**\n * Retrieves a collection.\n * @param collectionId - ID of the collection to retrieve.\n * @public\n * @requiredField collectionId\n * @permissionId PORTFOLIO.COLLECTION_READ\n * @applicableIdentity APP\n * @returns The requested collection.\n * @fqn com.wixpress.portfolio.collections.CollectionsService.GetCollection\n */\nexport async function getCollection(\n  collectionId: string,\n  options?: GetCollectionOptions\n): Promise<\n  NonNullablePaths<\n    Collection,\n    | `coverImage.focalPoint.x`\n    | `coverImage.focalPoint.y`\n    | `seoData.tags`\n    | `seoData.tags.${number}.type`\n    | `seoData.tags.${number}.children`\n    | `seoData.tags.${number}.custom`\n    | `seoData.tags.${number}.disabled`\n    | `seoData.settings.preventAutoRedirect`\n    | `seoData.settings.keywords`\n    | `seoData.settings.keywords.${number}.term`\n    | `seoData.settings.keywords.${number}.isMain`,\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    collectionId: collectionId,\n    includePageUrl: options?.includePageUrl,\n  });\n\n  const reqOpts =\n    ambassadorWixPortfolioCollectionsV1Collection.getCollection(payload);\n\n  sideEffects?.onSiteCall?.();\n  try {\n    const result = await httpClient.request(reqOpts);\n    sideEffects?.onSuccess?.(result);\n\n    return renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(result.data, [\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'collection.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'collection.coverImage.imageInfo' }],\n        },\n      ])\n    )?.collection!;\n  } catch (err: any) {\n    const transformedError = sdkTransformError(\n      err,\n      {\n        spreadPathsToArguments: {},\n        explicitPathsToArguments: {\n          collectionId: '$[0]',\n          includePageUrl: '$[1].includePageUrl',\n        },\n        singleArgumentUnchanged: false,\n      },\n      ['collectionId', 'options']\n    );\n    sideEffects?.onError?.(err);\n\n    throw transformedError;\n  }\n}\n\nexport interface GetCollectionOptions {\n  /** Whether to include the collection's page URL and relative path in the response. Default: `false` */\n  includePageUrl?: boolean | null;\n}\n\n/**\n * Retrieves a list all collections in a portfolio.\n * @public\n * @permissionId PORTFOLIO.COLLECTION_READ\n * @applicableIdentity APP\n * @fqn com.wixpress.portfolio.collections.CollectionsService.ListCollections\n */\nexport async function listCollections(\n  options?: ListCollectionsOptions\n): Promise<\n  NonNullablePaths<\n    ListCollectionsResponse,\n    | `collections`\n    | `collections.${number}.coverImage.focalPoint.x`\n    | `collections.${number}.coverImage.focalPoint.y`\n    | `collections.${number}.seoData.settings.preventAutoRedirect`,\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    paging: options?.paging,\n    includePageUrl: options?.includePageUrl,\n  });\n\n  const reqOpts =\n    ambassadorWixPortfolioCollectionsV1Collection.listCollections(payload);\n\n  sideEffects?.onSiteCall?.();\n  try {\n    const result = await httpClient.request(reqOpts);\n    sideEffects?.onSuccess?.(result);\n\n    return renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(result.data, [\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'collections.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'collections.coverImage.imageInfo' }],\n        },\n      ])\n    )!;\n  } catch (err: any) {\n    const transformedError = sdkTransformError(\n      err,\n      {\n        spreadPathsToArguments: {},\n        explicitPathsToArguments: {\n          paging: '$[0].paging',\n          includePageUrl: '$[0].includePageUrl',\n        },\n        singleArgumentUnchanged: false,\n      },\n      ['options']\n    );\n    sideEffects?.onError?.(err);\n\n    throw transformedError;\n  }\n}\n\nexport interface ListCollectionsOptions {\n  paging?: CursorPaging;\n  /** Whether to include the collection's page URL and relative path in the response. Default: `false` */\n  includePageUrl?: boolean | null;\n}\n\n/**\n * Updates a collection.\n * @param _id - Collection ID.\n * @public\n * @requiredField _id\n * @requiredField collection\n * @requiredField collection.revision\n * @permissionId PORTFOLIO.COLLECTION_UPDATE\n * @applicableIdentity APP\n * @returns Updated collection.\n * @fqn com.wixpress.portfolio.collections.CollectionsService.UpdateCollection\n */\nexport async function updateCollection(\n  _id: string,\n  collection: NonNullablePaths<UpdateCollection, `revision`, 2>\n): Promise<\n  NonNullablePaths<\n    Collection,\n    | `coverImage.focalPoint.x`\n    | `coverImage.focalPoint.y`\n    | `seoData.tags`\n    | `seoData.tags.${number}.type`\n    | `seoData.tags.${number}.children`\n    | `seoData.tags.${number}.custom`\n    | `seoData.tags.${number}.disabled`\n    | `seoData.settings.preventAutoRedirect`\n    | `seoData.settings.keywords`\n    | `seoData.settings.keywords.${number}.term`\n    | `seoData.settings.keywords.${number}.isMain`,\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 = transformPaths(\n    renameKeysFromSDKRequestToRESTRequest({\n      collection: { ...collection, id: _id },\n    }),\n    [\n      {\n        transformFn: transformSDKPageURLV2ToRESTPageURLV2,\n        paths: [{ path: 'collection.url' }],\n      },\n      {\n        transformFn: transformSDKImageToRESTImage,\n        paths: [{ path: 'collection.coverImage.imageInfo' }],\n      },\n    ]\n  );\n\n  const reqOpts =\n    ambassadorWixPortfolioCollectionsV1Collection.updateCollection(payload);\n\n  sideEffects?.onSiteCall?.();\n  try {\n    const result = await httpClient.request(reqOpts);\n    sideEffects?.onSuccess?.(result);\n\n    return renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(result.data, [\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'collection.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'collection.coverImage.imageInfo' }],\n        },\n      ])\n    )?.collection!;\n  } catch (err: any) {\n    const transformedError = sdkTransformError(\n      err,\n      {\n        spreadPathsToArguments: { collection: '$[1]' },\n        explicitPathsToArguments: { 'collection.id': '$[0]' },\n        singleArgumentUnchanged: false,\n      },\n      ['_id', 'collection']\n    );\n    sideEffects?.onError?.(err);\n\n    throw transformedError;\n  }\n}\n\nexport interface UpdateCollection {\n  /**\n   * Collection ID.\n   * @readonly\n   * @format GUID\n   */\n  _id?: string | null;\n  /**\n   * Revision number, which increments by 1 each time the collection is updated. To prevent conflicting changes, the existing revision must be passed when updating the collection object.\n   * @readonly\n   */\n  revision?: string | null;\n  /**\n   * Collection title.\n   * @maxLength 100\n   */\n  title?: string | null;\n  /** Collection description. */\n  description?: string | null;\n  /** Collection slug. */\n  slug?: string | null;\n  /** Collection cover image. */\n  coverImage?: Image;\n  /** Whether the collection is hidden from the portfolio. Default: `false` */\n  hidden?: boolean | null;\n  /**\n   * Index that determines which position a collection is displayed in the portfolio. <br />\n   *\n   * Default: [Epoch](https://www.epoch101.com/) timestamp. <br />\n   */\n  sortOrder?: number | null;\n  /**\n   * Date and time the collection was created.\n   * @readonly\n   */\n  _createdDate?: Date | null;\n  /**\n   * Date and time the collection was updated.\n   * @readonly\n   */\n  _updatedDate?: Date | null;\n  /**\n   * Collection page URL and relative path. Returned when `includePageUrl` is `true` in the request.\n   * @readonly\n   */\n  url?: string;\n  /** Collection SEO data. */\n  seoData?: SeoSchema;\n}\n\n/**\n * Deletes a collection.\n * @param collectionId - ID of the collection to delete.\n * @public\n * @requiredField collectionId\n * @permissionId PORTFOLIO.COLLECTION_DELETE\n * @applicableIdentity APP\n * @fqn com.wixpress.portfolio.collections.CollectionsService.DeleteCollection\n */\nexport async function deleteCollection(\n  collectionId: string\n): Promise<NonNullablePaths<DeleteCollectionResponse, `collectionId`, 2>> {\n  // @ts-ignore\n  const { httpClient, sideEffects } = arguments[1] as {\n    httpClient: HttpClient;\n    sideEffects?: any;\n  };\n\n  const payload = renameKeysFromSDKRequestToRESTRequest({\n    collectionId: collectionId,\n  });\n\n  const reqOpts =\n    ambassadorWixPortfolioCollectionsV1Collection.deleteCollection(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: { collectionId: '$[0]' },\n        singleArgumentUnchanged: false,\n      },\n      ['collectionId']\n    );\n    sideEffects?.onError?.(err);\n\n    throw transformedError;\n  }\n}\n\n/**\n * Creates a query to retrieve a list of collections.\n *\n * The `queryCollections()` method builds a query to retrieve a list of collections and returns a `CollectionsQueryBuilder` object.\n *\n * The returned object contains the query definition, which is used to run the query using the [`find()`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/find) method.\n *\n * You can refine the query by chaining `CollectionsQueryBuilder` methods onto the query. `CollectionsQueryBuilder` methods enable you to filter, sort, and control the results that `queryCollections()` returns.\n *\n * `queryCollections()`  runs with the following `CollectionsQueryBuilder` defaults which you can override:\n *\n * + [`limit(100)`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/limit)\n * + [`ascending('_id')`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/ascending)\n *\n * The following `CollectionsQueryBuilder` methods are supported for `queryCollections()`. For a full description of the operations object, see the object returned for the [`items`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-result/items) property in `CollectionsQueryResult`.\n * @public\n * @permissionId PORTFOLIO.COLLECTION_READ\n * @applicableIdentity APP\n * @fqn com.wixpress.portfolio.collections.CollectionsService.QueryCollections\n */\nexport function queryCollections(\n  options?: QueryCollectionsOptions\n): CollectionsQueryBuilder {\n  // @ts-ignore\n  const { httpClient, sideEffects } = arguments[1] as {\n    httpClient: HttpClient;\n    sideEffects?: any;\n  };\n\n  return queryBuilder<\n    Collection,\n    'CURSOR',\n    QueryCollectionsRequest,\n    QueryCollectionsResponse\n  >({\n    func: async (payload: QueryCollectionsRequest) => {\n      const reqOpts =\n        ambassadorWixPortfolioCollectionsV1Collection.queryCollections({\n          ...payload,\n          ...(options ?? {}),\n        });\n\n      sideEffects?.onSiteCall?.();\n      try {\n        const result = await httpClient.request(reqOpts);\n        sideEffects?.onSuccess?.(result);\n        return result;\n      } catch (err) {\n        sideEffects?.onError?.(err);\n        throw err;\n      }\n    },\n    requestTransformer: (query: QueryCollectionsRequest['query']) => {\n      const args = [query, options] as [\n        QueryCollectionsRequest['query'],\n        QueryCollectionsOptions\n      ];\n      return renameKeysFromSDKRequestToRESTRequest({\n        ...args?.[1],\n        query: args?.[0],\n      });\n    },\n    responseTransformer: ({ data }: HttpResponse<QueryCollectionsResponse>) => {\n      const transformedData = renameKeysFromRESTResponseToSDKResponse(\n        transformPaths(data, [\n          {\n            transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n            paths: [{ path: 'collections.url' }],\n          },\n          {\n            transformFn: transformRESTImageToSDKImage,\n            paths: [{ path: 'collections.coverImage.imageInfo' }],\n          },\n        ])\n      );\n\n      return {\n        items: transformedData?.collections,\n        pagingMetadata: transformedData?.metadata,\n      };\n    },\n    errorTransformer: (err: unknown) => {\n      const transformedError = sdkTransformError(err, {\n        spreadPathsToArguments: {},\n        explicitPathsToArguments: { query: '$[0]' },\n        singleArgumentUnchanged: false,\n      });\n\n      throw transformedError;\n    },\n    pagingMethod: 'CURSOR',\n    transformationPaths: {},\n  });\n}\n\nexport interface QueryCollectionsOptions {\n  /** Whether to include the collection's page URL and relative path in the response. Default: `false` */\n  includePageUrl?: boolean | null | undefined;\n}\n\ninterface QueryCursorResult {\n  cursors: Cursors;\n  hasNext: () => boolean;\n  hasPrev: () => boolean;\n  length: number;\n  pageSize: number;\n}\n\nexport interface CollectionsQueryResult extends QueryCursorResult {\n  items: Collection[];\n  query: CollectionsQueryBuilder;\n  next: () => Promise<CollectionsQueryResult>;\n  prev: () => Promise<CollectionsQueryResult>;\n}\n\nexport interface CollectionsQueryBuilder {\n  /** @param propertyName - Property whose value is compared with `value`.\n   * @param value - Value to compare against.\n   */\n  eq: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'hidden'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any\n  ) => CollectionsQueryBuilder;\n  /** @param propertyName - Property whose value is compared with `value`.\n   * @param value - Value to compare against.\n   */\n  ne: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'hidden'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any\n  ) => CollectionsQueryBuilder;\n  /** @param propertyName - Property whose value is compared with `value`.\n   * @param value - Value to compare against.\n   */\n  ge: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any\n  ) => CollectionsQueryBuilder;\n  /** @param propertyName - Property whose value is compared with `value`.\n   * @param value - Value to compare against.\n   */\n  gt: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any\n  ) => CollectionsQueryBuilder;\n  /** @param propertyName - Property whose value is compared with `value`.\n   * @param value - Value to compare against.\n   */\n  le: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any\n  ) => CollectionsQueryBuilder;\n  /** @param propertyName - Property whose value is compared with `value`.\n   * @param value - Value to compare against.\n   */\n  lt: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any\n  ) => CollectionsQueryBuilder;\n  /** @param propertyName - Property whose value is compared with `string`.\n   * @param string - String to compare against. Case-insensitive.\n   */\n  startsWith: (\n    propertyName: '_id' | 'title' | 'description' | 'slug',\n    value: string\n  ) => CollectionsQueryBuilder;\n  /** @param propertyName - Property whose value is compared with `values`.\n   * @param values - List of values to compare against.\n   */\n  hasSome: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'hidden'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any[]\n  ) => CollectionsQueryBuilder;\n  in: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'hidden'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: any\n  ) => CollectionsQueryBuilder;\n  exists: (\n    propertyName:\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'hidden'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate',\n    value: boolean\n  ) => CollectionsQueryBuilder;\n  /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. */\n  ascending: (\n    ...propertyNames: Array<\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate'\n    >\n  ) => CollectionsQueryBuilder;\n  /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. */\n  descending: (\n    ...propertyNames: Array<\n      | '_id'\n      | 'title'\n      | 'description'\n      | 'slug'\n      | 'sortOrder'\n      | '_createdDate'\n      | '_updatedDate'\n    >\n  ) => CollectionsQueryBuilder;\n  /** @param limit - Number of items to return, which is also the `pageSize` of the results object. */\n  limit: (limit: number) => CollectionsQueryBuilder;\n  /** @param cursor - A pointer to specific record */\n  skipTo: (cursor: string) => CollectionsQueryBuilder;\n  find: () => Promise<CollectionsQueryResult>;\n}\n\n/**\n * @hidden\n * @fqn com.wixpress.portfolio.collections.CollectionsService.QueryCollections\n * @requiredField query\n */\nexport async function typedQueryCollections(\n  query: CollectionQuery,\n  options?: QueryCollectionsOptions\n): Promise<\n  NonNullablePaths<\n    QueryCollectionsResponse,\n    | `collections`\n    | `collections.${number}.coverImage.focalPoint.x`\n    | `collections.${number}.coverImage.focalPoint.y`\n    | `collections.${number}.seoData.settings.preventAutoRedirect`,\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    query: query,\n    ...options,\n  });\n\n  const reqOpts =\n    ambassadorWixPortfolioCollectionsV1Collection.queryCollections(payload);\n\n  sideEffects?.onSiteCall?.();\n  try {\n    const result = await httpClient.request(reqOpts);\n    sideEffects?.onSuccess?.(result);\n\n    return renameKeysFromRESTResponseToSDKResponse(\n      transformPaths(result.data, [\n        {\n          transformFn: transformRESTPageURLV2ToSDKPageURLV2,\n          paths: [{ path: 'collections.url' }],\n        },\n        {\n          transformFn: transformRESTImageToSDKImage,\n          paths: [{ path: 'collections.coverImage.imageInfo' }],\n        },\n      ])\n    )!;\n  } catch (err: any) {\n    const transformedError = sdkTransformError(\n      err,\n      {\n        spreadPathsToArguments: {},\n        explicitPathsToArguments: { query: '$[0]' },\n        singleArgumentUnchanged: false,\n      },\n      ['query', 'options']\n    );\n    sideEffects?.onError?.(err);\n\n    throw transformedError;\n  }\n}\n\nexport interface CollectionQuerySpec extends QuerySpec {\n  paging: 'cursor';\n  wql: [\n    {\n      fields: ['_id'];\n      operators: '*';\n      sort: 'BOTH';\n    },\n    {\n      fields: ['description', 'slug', 'title'];\n      operators: '*';\n      sort: 'BOTH';\n    },\n    {\n      fields: ['sortOrder'];\n      operators: '*';\n      sort: 'BOTH';\n    },\n    {\n      fields: ['hidden'];\n      operators: '*';\n      sort: 'NONE';\n    },\n    {\n      fields: ['_createdDate', '_updatedDate'];\n      operators: '*';\n      sort: 'BOTH';\n    }\n  ];\n}\n\nexport type CommonQueryWithEntityContext = QuerySdkType<\n  Collection,\n  CollectionQuerySpec\n>;\nexport type CollectionQuery = {\n  /** \n  Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`.  \n  */\n  cursorPaging?: {\n    /** \n  Maximum number of items to return in the results. \n  @max: 100 \n  */\n    limit?:\n      | NonNullable<CommonQueryWithEntityContext['cursorPaging']>['limit']\n      | null;\n    /** \n  Pointer to the next or previous page in the list of results.\n\n  Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.\n  Not relevant for the first request. \n  @maxLength: 16000 \n  */\n    cursor?:\n      | NonNullable<CommonQueryWithEntityContext['cursorPaging']>['cursor']\n      | null;\n  };\n  /** \n  Filter object.\n\n  Learn more about [filtering](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#filters).  \n  */\n  filter?: CommonQueryWithEntityContext['filter'] | null;\n  /** \n  Sort object.\n\n  Learn more about [sorting](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#sorting).  \n  */\n  sort?: {\n    /** \n  Name of the field to sort by. \n  @maxLength: 512 \n  */\n    fieldName?: NonNullable<\n      CommonQueryWithEntityContext['sort']\n    >[number]['fieldName'];\n    /** \n  Sort order.  \n  */\n    order?: NonNullable<CommonQueryWithEntityContext['sort']>[number]['order'];\n  }[];\n};\n\nexport const utils = {\n  ...createQueryUtils<Collection, CollectionQuerySpec, CollectionQuery>(),\n};\n","import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { transformSDKFloatToRESTFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformRESTFloatToSDKFloat } from '@wix/sdk-runtime/transformations/float';\nimport { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';\nimport { transformSDKFieldMaskToRESTFieldMask } from '@wix/sdk-runtime/transformations/field-mask';\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 resolveComWixpressPortfolioCollectionsCollectionsServiceUrl(\n  opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n  const domainToMappings = {\n    '*.dev.wix-code.com': [\n      {\n        srcPath: '/_api/collections-service',\n        destPath: '/api',\n      },\n    ],\n    'editor._base_domain_': [\n      {\n        srcPath: '/_api/collections-service',\n        destPath: '/api',\n      },\n    ],\n    'blocks._base_domain_': [\n      {\n        srcPath: '/_api/collections-service',\n        destPath: '/api',\n      },\n    ],\n    'create.editorx': [\n      {\n        srcPath: '/_api/collections-service',\n        destPath: '/api',\n      },\n    ],\n    'manage._base_domain_': [\n      {\n        srcPath: '/_api/collections-service',\n        destPath: '/api',\n      },\n    ],\n    _: [\n      {\n        srcPath: '/_api/collections-service',\n        destPath: '/api',\n      },\n    ],\n    'www._base_domain_': [\n      {\n        srcPath: '/_api/collections-service',\n        destPath: '/api',\n      },\n    ],\n    'www.wixapis.com': [\n      {\n        srcPath: '/portfolio/v1/collections',\n        destPath: '/api/v1/portfolio/collections',\n      },\n      {\n        srcPath: '/portfolio/collections/api/v1/portfolio/collections',\n        destPath: '/api/v1/portfolio/collections',\n      },\n    ],\n    'api._api_base_domain_': [\n      {\n        srcPath: '/collections-service',\n        destPath: '',\n      },\n    ],\n  };\n\n  return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_portfolio_collections';\n\n/** Creates a collection. */\nexport function createCollection(payload: object): RequestOptionsFactory<any> {\n  function __createCollection({ host }: any) {\n    const serializedData = transformPaths(payload, [\n      {\n        transformFn: transformSDKFloatToRESTFloat,\n        paths: [\n          { path: 'collection.sortOrder' },\n          { path: 'collection.coverImage.focalPoint.x' },\n          { path: 'collection.coverImage.focalPoint.y' },\n          { path: 'collection.coverImage.unsharpMasking.amount' },\n          { path: 'collection.coverImage.unsharpMasking.radius' },\n          { path: 'collection.coverImage.unsharpMasking.threshold' },\n        ],\n      },\n      {\n        transformFn: transformSDKTimestampToRESTTimestamp,\n        paths: [\n          { path: 'collection.createdDate' },\n          { path: 'collection.updatedDate' },\n          { path: 'collection.coverImage.imageInfo.urlExpirationDate' },\n        ],\n      },\n    ]);\n    const metadata = {\n      entityFqdn: 'wix.portfolio.collections.v1.collection',\n      method: 'POST' as any,\n      methodFqn:\n        'com.wixpress.portfolio.collections.CollectionsService.CreateCollection',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveComWixpressPortfolioCollectionsCollectionsServiceUrl({\n        protoPath: '/api/v1/portfolio/collections',\n        data: serializedData,\n        host,\n      }),\n      data: serializedData,\n      transformResponse: (payload: any) =>\n        transformPaths(payload, [\n          {\n            transformFn: transformRESTFloatToSDKFloat,\n            paths: [\n              { path: 'collection.sortOrder' },\n              { path: 'collection.coverImage.focalPoint.x' },\n              { path: 'collection.coverImage.focalPoint.y' },\n              { path: 'collection.coverImage.unsharpMasking.amount' },\n              { path: 'collection.coverImage.unsharpMasking.radius' },\n              { path: 'collection.coverImage.unsharpMasking.threshold' },\n            ],\n          },\n          {\n            transformFn: transformRESTTimestampToSDKTimestamp,\n            paths: [\n              { path: 'collection.createdDate' },\n              { path: 'collection.updatedDate' },\n              { path: 'collection.coverImage.imageInfo.urlExpirationDate' },\n            ],\n          },\n        ]),\n    };\n\n    return metadata;\n  }\n\n  return __createCollection;\n}\n\n/** Retrieves a collection. */\nexport function getCollection(payload: object): RequestOptionsFactory<any> {\n  function __getCollection({ host }: any) {\n    const metadata = {\n      entityFqdn: 'wix.portfolio.collections.v1.collection',\n      method: 'GET' as any,\n      methodFqn:\n        'com.wixpress.portfolio.collections.CollectionsService.GetCollection',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveComWixpressPortfolioCollectionsCollectionsServiceUrl({\n        protoPath: '/api/v1/portfolio/collections/{collectionId}',\n        data: payload,\n        host,\n      }),\n      params: toURLSearchParams(payload),\n      transformResponse: (payload: any) =>\n        transformPaths(payload, [\n          {\n            transformFn: transformRESTFloatToSDKFloat,\n            paths: [\n              { path: 'collection.sortOrder' },\n              { path: 'collection.coverImage.focalPoint.x' },\n              { path: 'collection.coverImage.focalPoint.y' },\n              { path: 'collection.coverImage.unsharpMasking.amount' },\n              { path: 'collection.coverImage.unsharpMasking.radius' },\n              { path: 'collection.coverImage.unsharpMasking.threshold' },\n            ],\n          },\n          {\n            transformFn: transformRESTTimestampToSDKTimestamp,\n            paths: [\n              { path: 'collection.createdDate' },\n              { path: 'collection.updatedDate' },\n              { path: 'collection.coverImage.imageInfo.urlExpirationDate' },\n            ],\n          },\n        ]),\n    };\n\n    return metadata;\n  }\n\n  return __getCollection;\n}\n\n/** Retrieves a list all collections in a portfolio. */\nexport function listCollections(payload: object): RequestOptionsFactory<any> {\n  function __listCollections({ host }: any) {\n    const metadata = {\n      entityFqdn: 'wix.portfolio.collections.v1.collection',\n      method: 'GET' as any,\n      methodFqn:\n        'com.wixpress.portfolio.collections.CollectionsService.ListCollections',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveComWixpressPortfolioCollectionsCollectionsServiceUrl({\n        protoPath: '/api/v1/portfolio/collections',\n        data: payload,\n        host,\n      }),\n      params: toURLSearchParams(payload),\n      transformResponse: (payload: any) =>\n        transformPaths(payload, [\n          {\n            transformFn: transformRESTFloatToSDKFloat,\n            paths: [\n              { path: 'collections.sortOrder' },\n              { path: 'collections.coverImage.focalPoint.x' },\n              { path: 'collections.coverImage.focalPoint.y' },\n              { path: 'collections.coverImage.unsharpMasking.amount' },\n              { path: 'collections.coverImage.unsharpMasking.radius' },\n              { path: 'collections.coverImage.unsharpMasking.threshold' },\n            ],\n          },\n          {\n            transformFn: transformRESTTimestampToSDKTimestamp,\n            paths: [\n              { path: 'collections.createdDate' },\n              { path: 'collections.updatedDate' },\n              { path: 'collections.coverImage.imageInfo.urlExpirationDate' },\n            ],\n          },\n        ]),\n    };\n\n    return metadata;\n  }\n\n  return __listCollections;\n}\n\n/** Updates a collection. */\nexport function updateCollection(payload: object): RequestOptionsFactory<any> {\n  function __updateCollection({ host }: any) {\n    const serializedData = transformPaths(payload, [\n      {\n        transformFn: transformSDKFieldMaskToRESTFieldMask,\n        paths: [{ path: 'mask' }],\n      },\n      {\n        transformFn: transformSDKFloatToRESTFloat,\n        paths: [\n          { path: 'collection.sortOrder' },\n          { path: 'collection.coverImage.focalPoint.x' },\n          { path: 'collection.coverImage.focalPoint.y' },\n          { path: 'collection.coverImage.unsharpMasking.amount' },\n          { path: 'collection.coverImage.unsharpMasking.radius' },\n          { path: 'collection.coverImage.unsharpMasking.threshold' },\n        ],\n      },\n      {\n        transformFn: transformSDKTimestampToRESTTimestamp,\n        paths: [\n          { path: 'collection.createdDate' },\n          { path: 'collection.updatedDate' },\n          { path: 'collection.coverImage.imageInfo.urlExpirationDate' },\n        ],\n      },\n    ]);\n    const metadata = {\n      entityFqdn: 'wix.portfolio.collections.v1.collection',\n      method: 'PATCH' as any,\n      methodFqn:\n        'com.wixpress.portfolio.collections.CollectionsService.UpdateCollection',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveComWixpressPortfolioCollectionsCollectionsServiceUrl({\n        protoPath: '/api/v1/portfolio/collections/{collection.id}',\n        data: serializedData,\n        host,\n      }),\n      data: serializedData,\n      transformResponse: (payload: any) =>\n        transformPaths(payload, [\n          {\n            transformFn: transformRESTFloatToSDKFloat,\n            paths: [\n              { path: 'collection.sortOrder' },\n              { path: 'collection.coverImage.focalPoint.x' },\n              { path: 'collection.coverImage.focalPoint.y' },\n              { path: 'collection.coverImage.unsharpMasking.amount' },\n              { path: 'collection.coverImage.unsharpMasking.radius' },\n              { path: 'collection.coverImage.unsharpMasking.threshold' },\n            ],\n          },\n          {\n            transformFn: transformRESTTimestampToSDKTimestamp,\n            paths: [\n              { path: 'collection.createdDate' },\n              { path: 'collection.updatedDate' },\n              { path: 'collection.coverImage.imageInfo.urlExpirationDate' },\n            ],\n          },\n        ]),\n    };\n\n    return metadata;\n  }\n\n  return __updateCollection;\n}\n\n/** Deletes a collection. */\nexport function deleteCollection(payload: object): RequestOptionsFactory<any> {\n  function __deleteCollection({ host }: any) {\n    const metadata = {\n      entityFqdn: 'wix.portfolio.collections.v1.collection',\n      method: 'DELETE' as any,\n      methodFqn:\n        'com.wixpress.portfolio.collections.CollectionsService.DeleteCollection',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveComWixpressPortfolioCollectionsCollectionsServiceUrl({\n        protoPath: '/api/v1/portfolio/collections/{collectionId}',\n        data: payload,\n        host,\n      }),\n      params: toURLSearchParams(payload),\n    };\n\n    return metadata;\n  }\n\n  return __deleteCollection;\n}\n\n/**\n * Creates a query to retrieve a list of collections.\n *\n * The `queryCollections()` method builds a query to retrieve a list of collections and returns a `CollectionsQueryBuilder` object.\n *\n * The returned object contains the query definition, which is used to run the query using the [`find()`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/find) method.\n *\n * You can refine the query by chaining `CollectionsQueryBuilder` methods onto the query. `CollectionsQueryBuilder` methods enable you to filter, sort, and control the results that `queryCollections()` returns.\n *\n * `queryCollections()`  runs with the following `CollectionsQueryBuilder` defaults which you can override:\n *\n * + [`limit(100)`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/limit)\n * + [`ascending('_id')`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-builder/ascending)\n *\n * The following `CollectionsQueryBuilder` methods are supported for `queryCollections()`. For a full description of the operations object, see the object returned for the [`items`](https://dev.wix.com/docs/sdk/backend-modules/portfolio/collections/collections-query-result/items) property in `CollectionsQueryResult`.\n */\nexport function queryCollections(payload: object): RequestOptionsFactory<any> {\n  function __queryCollections({ host }: any) {\n    const metadata = {\n      entityFqdn: 'wix.portfolio.collections.v1.collection',\n      method: 'POST' as any,\n      methodFqn:\n        'com.wixpress.portfolio.collections.CollectionsService.QueryCollections',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveComWixpressPortfolioCollectionsCollectionsServiceUrl({\n        protoPath: '/api/v1/portfolio/collections/query',\n        data: payload,\n        host,\n      }),\n      data: payload,\n      transformResponse: (payload: any) =>\n        transformPaths(payload, [\n          {\n            transformFn: transformRESTFloatToSDKFloat,\n            paths: [\n              { path: 'collections.sortOrder' },\n              { path: 'collections.coverImage.focalPoint.x' },\n              { path: 'collections.coverImage.focalPoint.y' },\n              { path: 'collections.coverImage.unsharpMasking.amount' },\n              { path: 'collections.coverImage.unsharpMasking.radius' },\n              { path: 'collections.coverImage.unsharpMasking.threshold' },\n            ],\n          },\n          {\n            transformFn: transformRESTTimestampToSDKTimestamp,\n            paths: [\n              { path: 'collections.createdDate' },\n              { path: 'collections.updatedDate' },\n              { path: 'collections.coverImage.imageInfo.urlExpirationDate' },\n            ],\n          },\n        ]),\n    };\n\n    return metadata;\n  }\n\n  return __queryCollections;\n}\n","import {\n  createCollection as publicCreateCollection,\n  getCollection as publicGetCollection,\n  listCollections as publicListCollections,\n  updateCollection as publicUpdateCollection,\n  deleteCollection as publicDeleteCollection,\n  queryCollections as publicQueryCollections,\n  typedQueryCollections as publicTypedQueryCollections,\n} from './portfolio-collections-v1-collection-collections.public.js';\nimport { createRESTModule } from '@wix/sdk-runtime/rest-modules';\nimport { createEventModule } from '@wix/sdk-runtime/event-definition-modules';\nimport {\n  BuildRESTFunction,\n  MaybeContext,\n  BuildEventDefinition,\n} from '@wix/sdk-types';\nimport { HttpClient } from '@wix/sdk-types';\nimport { createQueryOverloadRouter } from '@wix/sdk-runtime/query-method-router';\nimport {\n  CollectionQuery,\n  CollectionsQueryBuilder,\n  QueryCollectionsOptions,\n  typedQueryCollections as universalTypedQueryCollections,\n} from './portfolio-collections-v1-collection-collections.universal.js';\nimport { onCollectionCreated as publicOnCollectionCreated } from './portfolio-collections-v1-collection-collections.public.js';\nimport { onCollectionDeleted as publicOnCollectionDeleted } from './portfolio-collections-v1-collection-collections.public.js';\nimport { onCollectionUpdated as publicOnCollectionUpdated } from './portfolio-collections-v1-collection-collections.public.js';\n\nfunction customQueryCollections(httpClient: HttpClient) {\n  const router = createQueryOverloadRouter({\n    builderQueryFunction: (options?: QueryCollectionsOptions) =>\n      publicQueryCollections(httpClient)(options),\n    typedQueryFunction: (\n      query: CollectionQuery,\n      options?: QueryCollectionsOptions\n    ) => publicTypedQueryCollections(httpClient)(query, options),\n    hasOptionsParameter: true,\n  });\n\n  function overloadedQuery(\n    query: CollectionQuery,\n    options?: QueryCollectionsOptions\n  ): ReturnType<typeof universalTypedQueryCollections>;\n  function overloadedQuery(\n    options?: QueryCollectionsOptions\n  ): CollectionsQueryBuilder;\n  function overloadedQuery(\n    queryOrOptions?: CollectionQuery | QueryCollectionsOptions,\n    options?: QueryCollectionsOptions\n  ): any {\n    return router(...arguments);\n  }\n\n  return overloadedQuery;\n}\n\nexport const createCollection: MaybeContext<\n  BuildRESTFunction<typeof publicCreateCollection> &\n    typeof publicCreateCollection\n> = /*#__PURE__*/ createRESTModule(publicCreateCollection);\nexport const getCollection: MaybeContext<\n  BuildRESTFunction<typeof publicGetCollection> & typeof publicGetCollection\n> = /*#__PURE__*/ createRESTModule(publicGetCollection);\nexport const listCollections: MaybeContext<\n  BuildRESTFunction<typeof publicListCollections> & typeof publicListCollections\n> = /*#__PURE__*/ createRESTModule(publicListCollections);\nexport const updateCollection: MaybeContext<\n  BuildRESTFunction<typeof publicUpdateCollection> &\n    typeof publicUpdateCollection\n> = /*#__PURE__*/ createRESTModule(publicUpdateCollection);\nexport const deleteCollection: MaybeContext<\n  BuildRESTFunction<typeof publicDeleteCollection> &\n    typeof publicDeleteCollection\n> = /*#__PURE__*/ createRESTModule(publicDeleteCollection);\nexport const queryCollections: MaybeContext<\n  BuildRESTFunction<typeof customQueryCollections> &\n    typeof customQueryCollections\n> = /*#__PURE__*/ createRESTModule(customQueryCollections);\n/**\n * Triggered when a collection is created.\n */\nexport const onCollectionCreated: BuildEventDefinition<\n  typeof publicOnCollectionCreated\n> &\n  typeof publicOnCollectionCreated = createEventModule(\n  publicOnCollectionCreated\n);\n/**\n * Triggered when a collection is deleted.\n */\nexport const onCollectionDeleted: BuildEventDefinition<\n  typeof publicOnCollectionDeleted\n> &\n  typeof publicOnCollectionDeleted = createEventModule(\n  publicOnCollectionDeleted\n);\n/**\n * Triggered when a collection is updated.\n */\nexport const onCollectionUpdated: BuildEventDefinition<\n  typeof publicOnCollectionUpdated\n> &\n  typeof publicOnCollectionUpdated = createEventModule(\n  publicOnCollectionUpdated\n);\n\nexport {\n  ImageType,\n  WebhookIdentityType,\n  SortOrder,\n} from './portfolio-collections-v1-collection-collections.universal.js';\nexport {\n  Collection,\n  Image,\n  Point,\n  UnsharpMasking,\n  SeoSchema,\n  Keyword,\n  Tag,\n  Settings,\n  DomainEvent,\n  DomainEventBodyOneOf,\n  EntityCreatedEvent,\n  RestoreInfo,\n  EntityUpdatedEvent,\n  EntityDeletedEvent,\n  ActionEvent,\n  Empty,\n  AdminRemoveMenuItemsResponse,\n  MessageEnvelope,\n  IdentificationData,\n  IdentificationDataIdOneOf,\n  AccountInfo,\n  InvalidateCache,\n  InvalidateCacheGetByOneOf,\n  App,\n  Page,\n  URI,\n  File,\n  CustomTag,\n  Pages,\n  URIs,\n  CreateCollectionRequest,\n  CreateCollectionResponse,\n  GetCollectionRequest,\n  GetCollectionResponse,\n  ListCollectionsRequest,\n  CursorPaging,\n  ListCollectionsResponse,\n  PagingMetadataV2,\n  Cursors,\n  UpdateCollectionRequest,\n  UpdateCollectionResponse,\n  DeleteCollectionRequest,\n  DeleteCollectionResponse,\n  QueryCollectionsRequest,\n  QueryV2,\n  QueryV2PagingMethodOneOf,\n  Sorting,\n  Paging,\n  QueryCollectionsResponse,\n  BaseEventMetadata,\n  EventMetadata,\n  AccountInfoMetadata,\n  CollectionCreatedEnvelope,\n  CollectionDeletedEnvelope,\n  CollectionUpdatedEnvelope,\n  GetCollectionOptions,\n  ListCollectionsOptions,\n  UpdateCollection,\n  QueryCollectionsOptions,\n  CollectionsQueryResult,\n  CollectionsQueryBuilder,\n  CollectionQuerySpec,\n} from './portfolio-collections-v1-collection-collections.universal.js';\nexport { utils } from './portfolio-collections-v1-collection-collections.universal.js';\nexport {\n  ImageTypeWithLiterals,\n  WebhookIdentityTypeWithLiterals,\n  SortOrderWithLiterals,\n  CommonQueryWithEntityContext,\n  CollectionQuery,\n} from './portfolio-collections-v1-collection-collections.universal.js';\n"],"mappings":";AAAA,SAAS,2CAAAA,gDAA+C;AACxD,SAAS,gCAAAC,qCAAoC;AAC7C,SAAS,gCAAAC,qCAAoC;AAC7C,SAAS,wCAAAC,6CAA4C;AACrD,SAAS,wCAAAC,6CAA4C;AACrD,SAAS,kBAAAC,uBAAsB;AAC/B,SAAS,uBAAqD;;;ACN9D,SAAS,kBAAkB,yBAAyB;AACpD,SAAS,oBAAoB;AAC7B;AAAA,EACE;AAAA,EACA;AAAA,OACK;;;ACLP,SAAS,yBAAyB;AAClC,SAAS,oCAAoC;AAC7C,SAAS,oCAAoC;AAC7C,SAAS,4CAA4C;AACrD,SAAS,4CAA4C;AACrD,SAAS,4CAA4C;AACrD,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAI3B,SAAS,4DACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,sBAAsB;AAAA,MACpB;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,wBAAwB;AAAA,MACtB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,GAAG;AAAA,MACD;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,qBAAqB;AAAA,MACnB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;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AAA,QACb,OAAO,CAAC,EAAE,MAAM,8BAA8B,CAAC;AAAA,MACjD;AAAA,IACF,CAAC;AAAA,EACH;AACJ,EAA6B;;;AG7V7B,SAAS,wBAAwB;AACjC,SAAS,yBAAyB;AAOlC,SAAS,iCAAiC;AAW1C,SAAS,uBAAuB,YAAwB;AACtD,QAAM,SAAS,0BAA0B;AAAA,IACvC,sBAAsB,CAAC,YACrBC,kBAAuB,UAAU,EAAE,OAAO;AAAA,IAC5C,oBAAoB,CAClB,OACA,YACGC,uBAA4B,UAAU,EAAE,OAAO,OAAO;AAAA,IAC3D,qBAAqB;AAAA,EACvB,CAAC;AASD,WAAS,gBACP,gBACA,SACK;AACL,WAAO,OAAO,GAAG,SAAS;AAAA,EAC5B;AAEA,SAAO;AACT;AAEO,IAAMC,oBAGK,iCAAiBA,iBAAsB;AAClD,IAAMC,iBAEK,iCAAiBA,cAAmB;AAC/C,IAAMC,mBAEK,iCAAiBA,gBAAqB;AACjD,IAAMC,oBAGK,iCAAiBA,iBAAsB;AAClD,IAAMC,oBAGK,iCAAiBA,iBAAsB;AAClD,IAAMN,oBAGK,iCAAiB,sBAAsB;AAIlD,IAAMO,uBAGwB;AAAA,EACnC;AACF;AAIO,IAAMC,uBAGwB;AAAA,EACnC;AACF;AAIO,IAAMC,uBAGwB;AAAA,EACnC;AACF;","names":["renameKeysFromRESTResponseToSDKResponse","transformRESTFloatToSDKFloat","transformRESTImageToSDKImage","transformRESTPageURLV2ToSDKPageURLV2","transformRESTTimestampToSDKTimestamp","transformPaths","payload","transformPaths","ImageType","WebhookIdentityType","SortOrder","createCollection","getCollection","listCollections","updateCollection","deleteCollection","queryCollections","createCollection","getCollection","listCollections","updateCollection","deleteCollection","queryCollections","typedQueryCollections","renameKeysFromRESTResponseToSDKResponse","transformPaths","transformRESTFloatToSDKFloat","transformRESTTimestampToSDKTimestamp","transformRESTPageURLV2ToSDKPageURLV2","transformRESTImageToSDKImage","queryCollections","typedQueryCollections","createCollection","getCollection","listCollections","updateCollection","deleteCollection","onCollectionCreated","onCollectionDeleted","onCollectionUpdated"]}