Add a sitemap or feed
Add an XML sitemap or Google Shopping feed URL to a site. CacheBoost downloads and parses it automatically in the background. Sitemap indexes are supported — child sitemaps are followed automatically.
POST
/v1/sites/{id}/sitemaps
Requires scope: sites:write
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
id |
integer | Required | Site ID. |
Body parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
url |
string | Required | Full URL of an XML sitemap or Google Shopping feed (RSS/Atom). Must belong to the site's domain. |
Example request
curl -X POST https://api.cache-boost.com/v1/sites/42/sitemaps \
-H "Authorization: Bearer cb_live_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"url": "https://www.example.com/sitemap.xml"}'
Response
Returns 201 Created with the new sitemap object.
{
"id": 7,
"url": "https://www.example.com/sitemap.xml",
"status": "waiting",
"status_message": null,
"last_processed_at": null,
"created_at": "2025-01-15T10:30:00Z"
}
Errors
| Code | Description |
|---|---|
401 | Missing or invalid API key. |
403 | Insufficient scope or access denied. |
404 | Site not found. |
409 | Sitemap URL already exists for this site. |
422 | Validation error — missing or invalid url. |