Use our AI agent to crawl your website and create a comprehensive, SEO-optimized XML sitemap with a single API call. Keep search engines up-to-date with your latest content effortlessly.
import { Do } from '@do-inc/sdk';
// Assumes DO_API_KEY is set in your environment
const client = new Do();
// Generate a sitemap by providing a root URL
const { url } = await client.sitemap('xml').create({
url: 'https://example.com',
options: {
follow: true, // Follow all internal links
limit: 50000, // Max number of URLs
ignoreGlobs: ['/admin/**', '/private/*']
}
});
console.log(`Sitemap generated successfully: ${url}`);