Get your free beta license ↗
API operation · domains group
DELETE

/domains/{name}

First published 3 Oct 20260.1.0Unchanged since publication

Delete a domain and its subdomains

Who may call it
AdministratorResellerCustomer
Token scope, any of
domainsall
Answers200 OK

UrbeStack removes the Apache virtual hosts, PHP-FPM pools, mailboxes, certificates and statistics for the domain and its subdomains. It clears current logs, removes rotated logs and preserves files in the document roots. It also updates DNS and mail configuration.

An unknown domain returns 404. Access to an existing domain is limited to administrators, the domain owner and the owner's reseller. Other callers receive 403.

As a command

Run as root on the server

Parameters

namepath ·DomainNameRequired

Example

See the API overview for how to set $API and $TOKEN.
Request
curl -sS -X DELETE "$API/domains/example.com" \
  -H "Authorization: Bearer $TOKEN"
Response · 200 OK
The response body is the file itself.

Errors

13 errors, each a status and a sentence
400Domain name required
400Domain name too long
400Invalid IPv4 address
400Invalid IPv6 address
400Invalid domain name
400Invalid port
400Invalid setting key
400Invalid username: 2 to 32 lowercase letters, digits or underscores, starting with a letter
400Username '<value>' is reserved
401Authentication required
403Insufficient privileges
404Domain '<name>' not found
404Setting '<key>' not found
Generated from release 0.2.35 (current) · the API’s own descriptionThis entry has been unchanged since it was first published in release 0.1.0 on 3 Oct 2026.
urbestack.com/docs/api/delete-domains-name/