Delete a domain from a workspace. It cannot be undone. This will also delete all the links associated with the domain.
TypeScript
import { Dub } from "dub"; const dub = new Dub({ token: "DUB_API_KEY", }); async function run() { const result = await dub.domains.delete("acme.com"); console.log(result); } run();
{ "slug": "acme.com" }
Default authentication mechanism
The domain name.
"acme.com"
The domain was deleted.
Was this page helpful?