# DELETE /v1/projects/:id (/docs/api/reference/projects/archive-project)



<Endpoint method="DELETE" path="/v1/projects/:id" auth="Bearer" scope="projects:write" phase="1" />

Flips `status` to `archived`. The project's data is retained — layers, influencers, content, metrics, social accounts all stay queryable — but no new work starts: cron-triggered content generation pauses, scheduled posts stop dispatching, and the scheduler skips the project on its next tick.

Archive is reversible. To reactivate, `PATCH` with `status: "active"`. Use this instead of a hard delete whenever the end-customer may return; it keeps your references and analytics intact.

<Parameters
  title="Path"
  rows="[
  { name: 'id', type: 'string', required: true, description: 'Project ID.' },
]"
/>

## Example request [#example-request]

<Tabs items="['curl', 'TypeScript', 'Python']">
  <Tab value="curl">
    ```bash
    curl -X DELETE https://api.layers.com/v1/projects/prj_01HX9Y7K8M2P4RSTUV56789AB \
      -H "Authorization: Bearer lp_live_01HX9Y6K7EJ4T2_4QZpN..."
    ```
  </Tab>

  <Tab value="TypeScript">
    ```ts
    await layers.projects.archive("prj_01HX9Y7K8M2P4RSTUV56789AB");
    ```
  </Tab>

  <Tab value="Python">
    ```python
    layers.projects.archive("prj_01HX9Y7K8M2P4RSTUV56789AB")
    ```
  </Tab>
</Tabs>

## Response [#response]

<Response status="200" description="OK">
  ```json
  {
    "id": "8a1639a0-ce5b-4565-9ed1-c55ed2d82dc6",
    "status": "archived",
    "archivedAt": "2026-04-18T19:11:02.413Z",
    "canceledScheduledPosts": 0
  }
  ```

  `canceledScheduledPosts` is the count of pending scheduled posts that were canceled as part of the archive. Already-published posts are unaffected.

  Archive is idempotent — a second `DELETE` against an already-archived project returns `200` with a refreshed `archivedAt`, not `409`.
</Response>

## Errors [#errors]

| Status | Code              | When                                                                |
| ------ | ----------------- | ------------------------------------------------------------------- |
| 401    | `UNAUTHENTICATED` | Missing or invalid key.                                             |
| 403    | `FORBIDDEN_SCOPE` | Key lacks `projects:write`.                                         |
| 404    | `NOT_FOUND`       | Project does not exist in the key's organization.                   |
| 422    | `VALIDATION`      | `:id` is not a UUID, or the optional archive body fails validation. |
| 429    | `RATE_LIMITED`    | Write budget exhausted.                                             |

## See also [#see-also]

* [`PATCH /v1/projects/:id`](/docs/api/reference/projects/patch-project) — restore via `status: "active"`
* [`GET /v1/projects`](/docs/api/reference/projects/list-projects) — filter with `?status=archived`
