Dangerously delete by tag
POST
https://api.vercel.com/v1/edge-cache/dangerously-delete-by-tagsMarks a cache tag as deleted, causing cache entries associated with that tag to be revalidated in the foreground on the next request. Use this method with caution because one tag can be associated with many paths and deleting the cache can cause many concurrent requests to the origin leading to cache stampede problem. This method is for advanced use cases and is not recommended; prefer using
invalidateByTag instead.Request
import { Vercel } from "@vercel/sdk";
const vercel = new Vercel({ bearerToken: "<YOUR_BEARER_TOKEN_HERE>",});
async function run() { await vercel.edgeCache.dangerouslyDeleteByTags({ projectIdOrName: "<value>", teamId: "team_1a2b3c4d5e6f7g8h9i0j1k2l", slug: "my-team-url-slug", });
}
run();Response
{}AuthorizationbearerToken
Default authentication mechanism