{"version":3,"sources":["../../src/promote-seo-v1-headless-sitemap-entry-seo-sitemap-entries.http.ts","../../src/promote-seo-v1-headless-sitemap-entry-seo-sitemap-entries.types.ts","../../src/promote-seo-v1-headless-sitemap-entry-seo-sitemap-entries.meta.ts"],"sourcesContent":["import { toURLSearchParams } from '@wix/sdk-runtime/rest-modules';\nimport { resolveUrl } from '@wix/sdk-runtime/rest-modules';\nimport { ResolveUrlOpts } from '@wix/sdk-runtime/rest-modules';\nimport { RequestOptionsFactory } from '@wix/sdk-types';\n\nfunction resolveWixPromoteSeoHeadlessSitemapServiceV1SeoHeadlessSitemapServiceUrl(\n  opts: Omit<ResolveUrlOpts, 'domainToMappings'>\n) {\n  const domainToMappings = {\n    'manage._base_domain_': [\n      {\n        srcPath: '/_api/seo-headless-sitemap/v1/list-static-sitemap-pages',\n        destPath: '/v1/list-static-sitemap-pages',\n      },\n    ],\n    _: [\n      {\n        srcPath: '/_api/seo-headless-sitemap/v1/list-sitemap-pages',\n        destPath: '/v1/list-sitemap-pages',\n      },\n    ],\n    '*.dev.wix-code.com': [\n      {\n        srcPath: '/_api/seo-headless-sitemap/v1/list-sitemap-pages',\n        destPath: '/v1/list-sitemap-pages',\n      },\n    ],\n    'www.wixapis.com': [\n      {\n        srcPath: '/v1/list-sitemap-pages',\n        destPath: '/v1/list-sitemap-pages',\n      },\n    ],\n    'api._api_base_domain_': [\n      {\n        srcPath: '/seo-headless-sitemap',\n        destPath: '',\n      },\n    ],\n  };\n\n  return resolveUrl(Object.assign(opts, { domainToMappings }));\n}\n\nconst PACKAGE_NAME = '@wix/auto_sdk_seo_seo-sitemap-entries';\n\n/**\n * Lists sitemap pages for a given item type with optional pagination.\n * `item_type` only covers dynamic, repeater-generated items (Stores products, Blog posts,\n * Bookings services, etc. - see ItemType). It does NOT cover a site's static/main pages\n * (e.g. classic Editor \"Home\", \"About\", \"Contact\" pages) - those aren't represented by any\n * ItemType value and are never returned here, even for a fully published site. An empty or\n * partial `pages` result for a given itemType is not a signal that the site's static pages\n * are missing or unpublished.\n * This method is intended for headless sites, which fetch these entries to build and serve\n * their own sitemap.xml. Classic Editor/Studio sites don't need it - Wix generates and serves\n * their sitemap.xml for them. Note that the method does not detect or reject a site's editor\n * type; it reads the site's live Site Structure either way. So it is not a way to distinguish\n * headless from classic sites, and it is not the right tool for diagnosing a classic site's\n * auto-generated sitemap - inspect the sitemap XML served on that site's own domain instead.\n *\n * Returns NOT_FOUND when the site is not indexable or is not published.\n */\nexport function listSitemapPages(payload: object): RequestOptionsFactory<any> {\n  function __listSitemapPages({ host }: any) {\n    const metadata = {\n      entityFqdn: 'wix.promote.seo.v1.headless_sitemap_entry',\n      method: 'GET' as any,\n      methodFqn:\n        'wix.promote.seo.headless.sitemap.service.v1.SeoHeadlessSitemapService.ListSitemapPages',\n      packageName: PACKAGE_NAME,\n      migrationOptions: {\n        optInTransformResponse: true,\n      },\n      url: resolveWixPromoteSeoHeadlessSitemapServiceV1SeoHeadlessSitemapServiceUrl(\n        { protoPath: '/v1/list-sitemap-pages', data: payload, host }\n      ),\n      params: toURLSearchParams(payload),\n    };\n\n    return metadata;\n  }\n\n  return __listSitemapPages;\n}\n","/** Sitemap entry containing page information */\nexport interface SitemapEntry {\n  /**\n   * Entity identifier (e.g., productId, pageId)\n   * @minLength 1\n   * @maxLength 255\n   */\n  id?: string;\n  /** Indicates if the entry should be included in the generated sitemap. */\n  shouldBeIncludedInSitemap?: boolean;\n  /**\n   * Optional last modification date in ISO 8601 format\n   * @maxLength 50\n   */\n  updatedDate?: string;\n  /**\n   * Optional list of images\n   * @maxSize 1000\n   */\n  images?: Image[];\n  /**\n   * Optional list of video data\n   * @maxSize 100\n   */\n  videos?: Video[];\n}\n\n/** Image information for sitemap entries */\nexport interface Image {\n  /**\n   * Image URL\n   * @format WEB_URL\n   * @maxLength 2048\n   * @minLength 1\n   */\n  url?: string;\n  /**\n   * Optional image alt text\n   * @maxLength 2048\n   */\n  altText?: string;\n}\n\n/** Video information for sitemap entries */\nexport interface Video {\n  /**\n   * Video content location URL\n   * @format WEB_URL\n   * @maxLength 2048\n   * @minLength 1\n   */\n  url?: string;\n  /**\n   * Video thumbnail location URL\n   * @format WEB_URL\n   * @maxLength 2048\n   * @minLength 1\n   */\n  thumbnailUrl?: string;\n  /**\n   * Optional video title\n   * @maxLength 255\n   */\n  title?: string;\n  /**\n   * Optional video description\n   * @maxLength 1000\n   */\n  description?: string;\n}\n\n/** Request message for getting sitemap pages */\nexport interface ListSitemapPagesRequest {\n  /** Item type identifier - must be a valid enum value */\n  itemType?: ItemTypeWithLiterals;\n  /** Optional cursor for pagination */\n  paging?: CursorPaging;\n}\n\n/**\n * Enum representing different types of items that can have sitemap entries.\n * Covers dynamic, repeater-generated business-solution items only. A site's static/main pages\n * (classic Editor \"Home\", \"About\", \"Contact\", etc.) have no corresponding value here.\n */\nexport enum ItemType {\n  /** Stores products */\n  STORES_PRODUCT = 'STORES_PRODUCT',\n  /** Blog posts */\n  BLOG_POST = 'BLOG_POST',\n  /** Blog categories */\n  BLOG_CATEGORY = 'BLOG_CATEGORY',\n  /** Blog tags */\n  BLOG_TAGS = 'BLOG_TAGS',\n  /** Blog archives */\n  BLOG_ARCHIVE = 'BLOG_ARCHIVE',\n  /** Forum posts */\n  FORUM_POST = 'FORUM_POST',\n  /** Forum categories */\n  FORUM_CATEGORY = 'FORUM_CATEGORY',\n  /** Groups posts */\n  GROUPS_POST = 'GROUPS_POST',\n  /** Groups pages */\n  GROUPS_PAGE = 'GROUPS_PAGE',\n  /** Events pages */\n  EVENTS_PAGE = 'EVENTS_PAGE',\n  /** Bookings services */\n  BOOKINGS_SERVICE = 'BOOKINGS_SERVICE',\n  /** Members area profiles */\n  MEMBERS_AREA_PROFILE = 'MEMBERS_AREA_PROFILE',\n  /** Challenges/online programs pages */\n  CHALLENGES_PAGE = 'CHALLENGES_PAGE',\n  /** Store categories */\n  STORES_CATEGORY = 'STORES_CATEGORY',\n  /** Store sub-categories */\n  STORES_SUB_CATEGORY = 'STORES_SUB_CATEGORY',\n  /** Portfolio collections */\n  PORTFOLIO_COLLECTIONS = 'PORTFOLIO_COLLECTIONS',\n  /** Portfolio projects */\n  PORTFOLIO_PROJECTS = 'PORTFOLIO_PROJECTS',\n  /** Pricing plans */\n  PRICING_PLANS = 'PRICING_PLANS',\n  /** Restaurant menu pages */\n  RESTAURANTS_MENU_PAGE = 'RESTAURANTS_MENU_PAGE',\n}\n\n/** @enumType */\nexport type ItemTypeWithLiterals =\n  | ItemType\n  | 'STORES_PRODUCT'\n  | 'BLOG_POST'\n  | 'BLOG_CATEGORY'\n  | 'BLOG_TAGS'\n  | 'BLOG_ARCHIVE'\n  | 'FORUM_POST'\n  | 'FORUM_CATEGORY'\n  | 'GROUPS_POST'\n  | 'GROUPS_PAGE'\n  | 'EVENTS_PAGE'\n  | 'BOOKINGS_SERVICE'\n  | 'MEMBERS_AREA_PROFILE'\n  | 'CHALLENGES_PAGE'\n  | 'STORES_CATEGORY'\n  | 'STORES_SUB_CATEGORY'\n  | 'PORTFOLIO_COLLECTIONS'\n  | 'PORTFOLIO_PROJECTS'\n  | 'PRICING_PLANS'\n  | 'RESTAURANTS_MENU_PAGE';\n\nexport interface CursorPaging {\n  /**\n   * Maximum number of items to return in the results.\n   * @max 200\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\n/** Response message for getting sitemap pages */\nexport interface ListSitemapPagesResponse {\n  /** List of sitemap entries */\n  pages?: SitemapEntry[];\n  /** Paging metadata for next page of results */\n  pagingMetadata?: 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   * Indicates if there are more results after the current page.\n   * If `true`, another page of results can be retrieved.\n   * If `false`, this is the last page.\n   * @internal\n   */\n  hasNext?: boolean | null;\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\n/** Request message for getting static sitemap pages */\nexport interface ListStaticSitemapPagesRequest {\n  /** Optional cursor for pagination */\n  paging?: CursorPaging;\n}\n\n/** Response message for getting sitemap pages */\nexport interface ListStaticSitemapPagesResponse {\n  /** List of sitemap entries */\n  pages?: SitemapEntry[];\n  /** Paging metadata for next page of results */\n  pagingMetadata?: PagingMetadataV2;\n}\n","import * as ambassadorWixPromoteSeoV1HeadlessSitemapEntry from './promote-seo-v1-headless-sitemap-entry-seo-sitemap-entries.http.js';\nimport * as ambassadorWixPromoteSeoV1HeadlessSitemapEntryTypes from './promote-seo-v1-headless-sitemap-entry-seo-sitemap-entries.types.js';\nimport * as ambassadorWixPromoteSeoV1HeadlessSitemapEntryUniversalTypes from './promote-seo-v1-headless-sitemap-entry-seo-sitemap-entries.universal.js';\n\nexport type __PublicMethodMetaInfo<\n  K = string,\n  M = unknown,\n  T = unknown,\n  S = unknown,\n  Q = unknown,\n  R = unknown\n> = {\n  getUrl: (context: any) => string;\n  httpMethod: K;\n  path: string;\n  pathParams: M;\n  __requestType: T;\n  __originalRequestType: S;\n  __responseType: Q;\n  __originalResponseType: R;\n};\n\nexport function listSitemapPages(): __PublicMethodMetaInfo<\n  'GET',\n  {},\n  ambassadorWixPromoteSeoV1HeadlessSitemapEntryUniversalTypes.ListSitemapPagesRequest,\n  ambassadorWixPromoteSeoV1HeadlessSitemapEntryTypes.ListSitemapPagesRequest,\n  ambassadorWixPromoteSeoV1HeadlessSitemapEntryUniversalTypes.ListSitemapPagesResponse,\n  ambassadorWixPromoteSeoV1HeadlessSitemapEntryTypes.ListSitemapPagesResponse\n> {\n  const payload = {} as any;\n\n  const getRequestOptions =\n    ambassadorWixPromoteSeoV1HeadlessSitemapEntry.listSitemapPages(payload);\n\n  const getUrl = (context: any): string => {\n    const { url } = getRequestOptions(context);\n    return url!;\n  };\n\n  return {\n    getUrl,\n    httpMethod: 'GET',\n    path: '/v1/list-sitemap-pages',\n    pathParams: {},\n    __requestType: null as any,\n    __originalRequestType: null as any,\n    __responseType: null as any,\n    __originalResponseType: null as any,\n  };\n}\n\nexport {\n  SitemapEntry as SitemapEntryOriginal,\n  Image as ImageOriginal,\n  Video as VideoOriginal,\n  ListSitemapPagesRequest as ListSitemapPagesRequestOriginal,\n  ItemType as ItemTypeOriginal,\n  ItemTypeWithLiterals as ItemTypeWithLiteralsOriginal,\n  CursorPaging as CursorPagingOriginal,\n  ListSitemapPagesResponse as ListSitemapPagesResponseOriginal,\n  PagingMetadataV2 as PagingMetadataV2Original,\n  Cursors as CursorsOriginal,\n  ListStaticSitemapPagesRequest as ListStaticSitemapPagesRequestOriginal,\n  ListStaticSitemapPagesResponse as ListStaticSitemapPagesResponseOriginal,\n} from './promote-seo-v1-headless-sitemap-entry-seo-sitemap-entries.types.js';\n"],"mappings":";AAAA,SAAS,yBAAyB;AAClC,SAAS,kBAAkB;AAI3B,SAAS,yEACP,MACA;AACA,QAAM,mBAAmB;AAAA,IACvB,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,sBAAsB;AAAA,MACpB;AAAA,QACE,SAAS;AAAA,QACT,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,mBAAmB;AAAA,MACjB;AAAA,QACE,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