Skip to content

Create Sitemap

Creates a sitemap definition — the Create Sitemap action on the admin Marketing → Search & SEO → Sitemaps screen.

TIP

New here? Read the Sitemaps overview for what a sitemap does and how its fields behave.

Creating does not build the XML

Saving the row only stores the definition. To write the actual XML files, call the generate mutation explicitly — generatedAt, indexFile, and generatedSitemaps stay empty until then.

Operation

OperationTypePurpose
createAdminMarketingSitemapMutationCreate a sitemap definition

Details

  • Requires an admin Bearer token and the marketing.search_seo.sitemaps.create permission.
  • The mutation returns the full sitemap payload.

Input fields

FieldTypeRequiredNotes
fileNameStringYesIndex file name — letters, digits, -, _, .; must end with .xml
pathStringYesDirectory the index file lives in — must start and end with /, no //

Released under the MIT License.