---
title: "Clear Database"
method: POST
path: "/api/admin/database/clear"
tags: ["Admin"]
---

# Clear Database

`POST /api/admin/database/clear`

## Request

- The document declares no server URL.
- Auth: none declared

Clear all database tables without dropping them.

## Headers

- `x-prefect-api-version` string

## Request body

- BodyClearDatabaseAdminDatabaseClearPost
  - `confirm` boolean: Pass confirm=True to confirm you want to modify the database.

## Response `204`

Successful Response

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/prefecthq/apis/prefect-versions-api.md) - [All operations](https://skmtc.dev/prefecthq/apis/prefect-versions-api/llms.txt) - [OpenAPI document](https://skmtc.dev/prefecthq/apis/prefect-versions-api/revisions/a7958ce57e96?raw)
