Question about generating XML sitemaps with aem-boilerplate-commerce
Hi everyone,
I'm working on a project using the aem-boilerplate-commerce in Edge Delivery Services and need to generate a sitemap-index.xml that references other sitemaps like categorias-sitemap.xml, productos-sitemap.xml, etc.
Here’s an example of what I’m trying to achieve:
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap>
<loc>https://mydomain.com/sitemap-content.xml</loc>
</sitemap>
<sitemap>
<loc>https://mydomain.com/categorias-sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://mydomain.com/productos-sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://mydomain.com/content-sitemap.xml</loc>
</sitemap>
</sitemapindex>
In addition to serving this index, I’d also like to ask for suggestions on how to generate the content of each individual sitemap — especially for categories and products.
Are there any best practices or examples on how to fetch and structure this data in the context of aem-boilerplate-commerce?
For instance:
Should the product and category data be fetched from Adobe Commerce APIs and written to XML manually?
Is there a preferred way to automate this or generate it as part of the build/deploy process?
Any guidance, tips, or examples would be greatly appreciated.
Thanks in advance!

