Controller for serving XML sitemaps with XSL styling.
Endpoints
- GET /{prefix}/sitemap.xml - sitemapindex (always)
- GET /{prefix}/sitemap.xml?format=html - Server-rendered HTML (for iframe previews)
- GET /{prefix}/sitemap.html - Redirects to sitemap.xml (deprecated)
- GET /{prefix}/sitemaps/:filename - Per-module sitemap files
- GET /{prefix}/assets/sitemap/:style - XSL stylesheets for urlset files
- GET /{prefix}/assets/sitemap-index/:style - XSL stylesheets for sitemapindex
Architecture
/sitemap.xml always returns a <sitemapindex> referencing per-module
sitemap files at /sitemaps/sitemap-{source}.xml. Each module file
contains a <urlset> with URLs from that source.
Summary
Functions
Redirects to XML sitemap (deprecated).
Legacy: Serves sitemap index part files.
Serves per-module sitemap files from /sitemaps/:filename.
Serves the sitemapindex XML.
Serves XSL stylesheet files for sitemapindex display.
Serves XSL stylesheet files for urlset display.
Functions
Redirects to XML sitemap (deprecated).
Legacy: Serves sitemap index part files.
Kept for backward compatibility. New architecture uses /sitemaps/:filename.
Serves per-module sitemap files from /sitemaps/:filename.
Filename is validated to contain only [a-z0-9-] characters.
The .xml extension is appended automatically.
Serves the sitemapindex XML.
Always returns a <sitemapindex>. Generate on first request if missing.
Query parameters:
style- Override XSL style (table, minimal)format=html- Force server-side HTML rendering (for iframe previews)
Serves XSL stylesheet files for sitemapindex display.
Serves XSL stylesheet files for urlset display.
Available styles: table, minimal