---
title: "Delete a content key from the draft"
method: DELETE
path: "/api/v1/sites/{slug}/content/{key}"
tags: ["Content"]
---

# Delete a content key from the draft

`DELETE /api/v1/sites/{slug}/content/{key}`

## Request

- Base URL: `https://api.dotsy.ai`
- URL: `https://api.dotsy.ai/api/v1/sites/{slug}/content/{key}`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

Stages a delete: the key disappears from the draft, and from the live site after the next publish. Page briefs under `_intent/` can be deleted. The site brief and other reserved keys (`.dotsy/`, `.structure/`, `_data/`) cannot (400 `reserved_key`).

## Path parameters

- `slug` string, required
- `key` string, required

## Response `200`

Staged for deletion.

- DeleteContentResponse
  - `ok` true, required
  - `written` string[], required: The key whose removal was staged. Publish it to make the delete live.
  - `published` false, required: Always false: the change is staged in the draft until you publish.
  - `hint` string, required: Reminder that the change is staged and how to make it live.

## Other responses

- `400`: `invalid_key` or `reserved_key`.
- `401`: Missing or invalid credentials.
- `403`: The key or token cannot write to this site.
- `404`: No such site (`site_not_found`) or no such key (`content_not_found`).
- `409`: A shared section (`fragments/<name>.html`) that pages, a layout or another section still place (`section_in_use`), or the site's index can't tell yet (`index_warming` — retry in a minute).

---

[API](https://skmtc.dev/dotsy/apis/dotsy-api.md) · [All operations](https://skmtc.dev/dotsy/apis/dotsy-api/llms.txt) · [OpenAPI document](https://skmtc.dev/dotsy/apis/dotsy-api/revisions/4272ed3b85d7?raw)
