---
title: "List the deleted sites that can be restored"
method: GET
path: "/sites/deleted"
tags: ["Sites"]
---

# List the deleted sites that can be restored

`GET /sites/deleted`

## Request

- Base URL: `https://api.hypamoon.com/api/v1`
- URL: `https://api.hypamoon.com/api/v1/sites/deleted`
- Auth: one of:
  - HTTP bearer
  - OAuth 2 (authorization code, authorization URL `https://app.hypamoon.com/oauth/authorize`, token URL `https://api.hypamoon.com/oauth/token`, scopes: `sites:read`)

The sites deleted in the last 30 days that can still be restored with POST /sites/{id}/restore, most recently deleted first, each with restore_until. A site deleted with permanent=true is not listed.

## Response `200`

The deleted sites.

- DeletedSiteList
  - `data` DeletedSite[], required: The deleted sites that can still be restored, most recently deleted first.
    - `id` string, uuid, required: The id of the site. Send it to POST /sites/{id}/restore.
    - `slug` string, required: The address it had and will get back: https://<slug>.hypamoon.app. It stays reserved for this project.
    - `name` string, required: Your name for the site.
    - `deleted_at` string, date-time, required: When the site was deleted.
    - `restore_until` string, date-time, required: Until when the site can be restored. After that its files are erased for good.
    - `test` boolean, required: true for a site of a test project.

## Other responses

- `401`: Unauthorized: unauthorized, missing_api_key, invalid_api_key, api_key_revoked, project_deleted.
- `403`: Forbidden: project_not_enabled, key_mode_mismatch, missing_scope, verification_required.
- `429`: Too Many Requests: rate_limited.
- `500`: Internal Server Error: internal_error.
- `503`: Service Unavailable: service_unavailable.

---

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