> Portal Navigation:
> 
> - Append `.md` to any URL under `https://dev.wix.com/docs/` to get its markdown version.
> - Pages are either content pages (article or reference text) or menu pages (a list of links to child pages).
> - To get a menu page, truncate any URL to a parent path and append `.md` (e.g. `https://dev.wix.com/docs/sdk.md`, `https://dev.wix.com/docs/sdk/core-modules.md`).
> - Top-level index of all portals: https://dev.wix.com/docs/llms.txt
> - Full concatenated docs: https://dev.wix.com/docs/llms-full.txt

# GetSitemap

# Package: googleSearchConsole

# Namespace: GscService

# Method link: https://dev.wix.com/docs/api-reference/business-management/seo/google-search-console/site-readiness-v1/get-sitemap.md

## Permission Scopes:
View SEO Settings: SCOPE.PROMOTE.VIEW-SEO

## Introduction

Retrieves one submitted sitemap, with Google's processing details: content
counts, warnings, errors, and download dates. To list every sitemap
submitted for the site, use List Sitemaps.

---

## REST API

### Schema

```
 Method: getSitemap
 Description: Retrieves one submitted sitemap, with Google's processing details: content counts, warnings, errors, and download dates. To list every sitemap submitted for the site, use List Sitemaps.
 URL: https://www.wixapis.com/gsc/connection/v1/sitemap
 Method: GET
 # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present.
 Required parameters:  sitemapUrl
 Method parameters: 
   query param name: siteUrl | type: siteUrl | description: URL of a site that isn't hosted on Wix, exactly as its URL-prefix property appears in Google Search Console. For example, `https://example.com/`. Leave empty for the Wix site the call is made on: setting it for a Wix site fails with `INVALID_ARGUMENT`. Domain properties (`sc-domain:example.com`) aren't supported.  | validation: format WEB_URL
   query param name: sitemapUrl | type: sitemapUrl | description: Full URL of the sitemap, as submitted. | required: true | validation: format WEB_URL
 Return type: GetSitemapResponse
  - name: sitemap | type: Sitemap | description: The requested sitemap, with Google's processing details.  
     - name: url | type: string | description: URL of the sitemap.  | read-only: true | validation: format WEB_URL
     - name: type | type: string | description: Type of the sitemap. For example, `sitemap` or `rssFeed`.  | read-only: true | validation: maxLength 100
     - name: pending | type: boolean | description: Whether the sitemap hasn't been processed by Google yet.  | read-only: true 
     - name: sitemapsIndex | type: boolean | description: Whether the sitemap is an index of other sitemaps.  | read-only: true 
     - name: lastDownloadedDate | type: string | description: Date and time Google last downloaded the sitemap.  | read-only: true | validation: format date-time
     - name: lastSubmittedDate | type: string | description: Date and time the sitemap was last submitted.  | read-only: true | validation: format date-time
     - name: errorCount | type: string | description: Number of issues with the sitemap itself. Errors must be fixed before Google can process the sitemap correctly.  | read-only: true 
     - name: warningCount | type: string | description: Number of non-critical issues with URLs in the sitemap.  | read-only: true 
     - name: contents | type: array<SitemapContent> | description: Breakdown of the sitemap's contents by content type.  | read-only: true | validation: maxItems 100
        - name: type | type: string | description: Content type. For example, `web` or `image`.  | read-only: true | validation: maxLength 100
        - name: submittedCount | type: string | description: Number of URLs of this content type in the sitemap.  | read-only: true 
        - name: indexedCount | type: string | description: Number of URLs of this content type that Google has indexed.  | read-only: true 

 Possible Errors:
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: SITEMAP_NOT_FOUND | Description: No sitemap with this `sitemapUrl` was submitted for the property. Submit it first, or list the submitted sitemaps with List Sitemaps.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: SITE_PROPERTY_NOT_OWNED | Description: `siteUrl` is set and the connected Google account doesn't own that Search Console property. Verify it in Google Search Console first.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: MISSING_TOKEN | Description: No Google account is connected for this site. Connect first with the GSC Connection API.
   HTTP Code: 429 | Status Code: RESOURCE_EXHAUSTED | Application Code: GOOGLE_QUOTA_EXCEEDED | Description: Google's API quota for the property is used up. Retry after the quota window resets.
   HTTP Code: 503 | Status Code: UNAVAILABLE | Application Code: GOOGLE_UNAVAILABLE | Description: Google answered with a temporary server error. Retry with backoff.


```

### Examples

### Get Sitemap
```curl
curl -X GET \
'https://www.wixapis.com/gsc/v1/sitemap?sitemapUrl=https%3A%2F%2Fwww.my-fashion-store.com%2Fsitemap.xml' \
-H 'Authorization: <AUTH>'
```

---

## JavaScript SDK

### Schema

```
 Method: wixClientAdmin.gsc.siteReadiness.getSitemap(sitemapUrl, options)
 Description: Retrieves one submitted sitemap, with Google's processing details: content counts, warnings, errors, and download dates. To list every sitemap submitted for the site, use List Sitemaps.
 # Note: If the parameter `a.b` is listed under required parameters, `b` is only required if `a` is also present.
 Required parameters:  sitemapUrl
 Method parameters: 
   param name: options | type: GetSitemapOptions  none  
        - name: siteUrl | type: string | description: URL of a site that isn't hosted on Wix, exactly as its URL-prefix property appears in Google Search Console. For example, `https://example.com/`. Leave empty for the Wix site the call is made on: setting it for a Wix site fails with `INVALID_ARGUMENT`. Domain properties (`sc-domain:example.com`) aren't supported.  | validation: format WEB_URL
   param name: sitemapUrl | type: string | description: Full URL of the sitemap, as submitted. | required: true | validation: format WEB_URL
 Return type: PROMISE<GetSitemapResponse>
  - name: sitemap | type: Sitemap | description: The requested sitemap, with Google's processing details.  
     - name: url | type: string | description: URL of the sitemap.  | read-only: true | validation: format WEB_URL
     - name: type | type: string | description: Type of the sitemap. For example, `sitemap` or `rssFeed`.  | read-only: true | validation: maxLength 100
     - name: pending | type: boolean | description: Whether the sitemap hasn't been processed by Google yet.  | read-only: true 
     - name: sitemapsIndex | type: boolean | description: Whether the sitemap is an index of other sitemaps.  | read-only: true 
     - name: lastDownloadedDate | type: Date | description: Date and time Google last downloaded the sitemap.  | read-only: true 
     - name: lastSubmittedDate | type: Date | description: Date and time the sitemap was last submitted.  | read-only: true 
     - name: errorCount | type: string | description: Number of issues with the sitemap itself. Errors must be fixed before Google can process the sitemap correctly.  | read-only: true 
     - name: warningCount | type: string | description: Number of non-critical issues with URLs in the sitemap.  | read-only: true 
     - name: contents | type: array<SitemapContent> | description: Breakdown of the sitemap's contents by content type.  | read-only: true | validation: maxItems 100
        - name: type | type: string | description: Content type. For example, `web` or `image`.  | read-only: true | validation: maxLength 100
        - name: submittedCount | type: string | description: Number of URLs of this content type in the sitemap.  | read-only: true 
        - name: indexedCount | type: string | description: Number of URLs of this content type that Google has indexed.  | read-only: true 

 Possible Errors:
   HTTP Code: 404 | Status Code: NOT_FOUND | Application Code: SITEMAP_NOT_FOUND | Description: No sitemap with this `sitemapUrl` was submitted for the property. Submit it first, or list the submitted sitemaps with List Sitemaps.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: SITE_PROPERTY_NOT_OWNED | Description: `siteUrl` is set and the connected Google account doesn't own that Search Console property. Verify it in Google Search Console first.
   HTTP Code: 428 | Status Code: FAILED_PRECONDITION | Application Code: MISSING_TOKEN | Description: No Google account is connected for this site. Connect first with the GSC Connection API.
   HTTP Code: 429 | Status Code: RESOURCE_EXHAUSTED | Application Code: GOOGLE_QUOTA_EXCEEDED | Description: Google's API quota for the property is used up. Retry after the quota window resets.
   HTTP Code: 503 | Status Code: UNAVAILABLE | Application Code: GOOGLE_UNAVAILABLE | Description: Google answered with a temporary server error. Retry with backoff.


```

### Examples

### Get one submitted sitemap with Google's processing details
```javascript
import { siteReadiness } from "@wix/gsc";

async function getSitemap() {
  const response = await siteReadiness.getSitemap(
    "https://www.my-fashion-store.com/sitemap.xml"
  );
}

/* Promise resolves to:
 * {
 *   "sitemap": {
 *     "url": "https://www.my-fashion-store.com/sitemap.xml",
 *     "type": "sitemap",
 *     "pending": false,
 *     "sitemapsIndex": true,
 *     "lastDownloadedDate": "2026-08-30T06:12:44.000Z",
 *     "lastSubmittedDate": "2026-08-28T09:03:17.000Z",
 *     "errorCount": "0",
 *     "warningCount": "2",
 *     "contents": [
 *       {
 *         "type": "web",
 *         "submittedCount": "24",
 *         "indexedCount": "18"
 *       },
 *       {
 *         "type": "image",
 *         "submittedCount": "63",
 *         "indexedCount": "41"
 *       }
 *     ]
 *   }
 * }
 */

```

### getSitemap (self-hosted)
Self-hosted SDK calls require you to [create a client](https://dev.wix.com/docs/sdk/articles/work-with-the-sdk/about-the-wix-client.md).

```javascript
import { createClient } from '@wix/sdk';
import { siteReadiness } from '@wix/gsc';
// Import the auth strategy for the relevant access type
// Import the relevant host module if needed

const myWixClient = createClient ({
  modules: { siteReadiness },
  // Include the auth strategy and host as relevant
});


async function getSitemap(sitemapUrl,options) {
  const response = await myWixClient.siteReadiness.getSitemap(sitemapUrl,options);
};
```

---