A Deno-based tool for submitting URLs to Google's Indexing API and checking their indexing status.
- Parse XML sitemaps (including sitemap index files) to extract URLs
- Submit URLs to Google's Indexing API for indexing/updating
- Check indexing status of submitted URLs
- Support for both single sitemaps and sitemap index files
- Deno installed
- Google Search Console API access
- Service account credentials with Indexing API permissions
- Create a service account in Google Cloud Console
- The Indexing API is enabled by default – no need to attach any policies to the service account
- Download the service account credentials JSON file
- Place the credentials file as
service-account.json
in the project root - Head over to the Google Search Console and add the email of the service account as a user (with "Owner" access)
- Update the
sitemapUrls
array inmain.ts
with your sitemap URL(s):
// main.ts
const sitemapUrls = [
'https://example.org/sitemap.xml',
]
// Sitemap index files are supported as well:
const sitemapUrls = [
'https://example.org/sitemap-index.xml',
]
- Run the script:
deno run start
- Add support for more Search Engines