# delete_subdomain

> Delete a subdomain.

- Tier: D
- Required scope: delete:hosting + write:hosting
- Annotations: destructiveHint, idempotentHint
- Docs: https://api.inleed.com/tools/delete-subdomain

## Description

Delete a subdomain. This can take down a live entry point and, with `delete_contents`, remove its document root, so it does not delete on this call: it confirms the subdomain exists, then returns `{status:"confirmation_required", confirmationUrl, …}`. Show the human the `confirmationUrl` to approve in the client area; do not approve it yourself. Then poll `get_pending_action`.

## Input schema

- `input` — string (required). A domain, email address, website URL, numeric service id, or hosting-account username the customer actually owns. Resolved to the owning account automatically; the resolved target is echoed back in the response.
- `label` — string (required). The subdomain label to delete — one DNS label like blog, not a full hostname.
- `delete_contents` — boolean. Whether to also delete the subdomain's document root and its files. Defaults to false (files kept).
- `attempt_key` — string. An idempotency key you choose. Reusing it within an hour returns the same held deletion.

## Example call

```json
{
  "name": "delete_subdomain",
  "arguments": {
    "input": "example.se",
    "label": "example.se"
  }
}
```

