Skip to main content

POST /api/domain/resubmit-sitemap/

Resubmits the sitemap to Google Search Console. Used after deploying new boosted pages.

Purpose

This endpoint notifies Google that the sitemap has been updated, typically called:
  • After new boosted pages are deployed
  • After site content is regenerated
  • As part of cron job workflows

Architecture

Flexible ID Lookup

The org_id parameter can be either:
  • clerk_org_id - Used by frontend
  • org_slug (business_id) - Used by cron services
The endpoint tries both lookups to support different callers.

Internal Services

submit_sitemap

Submits the sitemap URL to Google Search Console API. Location: src/app/shared/google_search_console.py

Response Fields

FieldTypeDescription
statusstring”success”, β€œskipped”, or β€œerror”
sitemap_submittedbooleanWhether sitemap was submitted
messagestringHuman-readable status

Non-Blocking Behavior

This endpoint returns β€œskipped” (not error) when:
  • Domain is not verified
  • Organization not found
This allows cron jobs to call it without failing on unverified domains.

Code Location

src/app/apis/domain/google_verification/routes.py