Invalidate CDN cache
- POST
- /workspaces
- /:workspace
- /distributions
- /:distribution_id
- /routes
- /:route_id
- /cache
Invalidate CDN cache for a route
Examples
Example: Purge entire route cache
curl -X POST "https://api.buddy.works/workspaces/:workspace/distributions/:distribution_id/routes/:route_id/cache" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "Content-Type: application/json" \
-d '{
"purge_all": true
}'Example: Purge specific paths
curl -X POST "https://api.buddy.works/workspaces/:workspace/distributions/:distribution_id/routes/:route_id/cache" \
-H "Authorization: Bearer <YOUR-TOKEN>" \
-H "Content-Type: application/json" \
-d '{
"purge_all": false,
"purge_paths": [
"/index.html",
"/assets/*"
]
}'STATUS204 Route cache invalidation triggered