---
title: "Clear Dataset"
method: PUT
path: "/api/dataset/clear/{dataset_id}"
tags: ["Dataset"]
---

# Clear Dataset

`PUT /api/dataset/clear/{dataset_id}`

Removes all chunks, files, and groups from the dataset while retaining the analytics and dataset itself. The auth'ed user must be an owner of the organization to clear a dataset.

## Path parameters

- `dataset_id` string, uuid, required

## Headers

- `TR-Dataset` string, uuid, required

## Response `204`

Dataset cleared successfully

## Other responses

- `400` — Service error relating to deleting the dataset
- `404` — Dataset not found

---

[API](https://skmtc.net/devflowinc/apis/trieve-api.md) · [All operations](https://skmtc.net/devflowinc/apis/trieve-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/devflowinc/trieve-api/revisions/84583e7c9fc1/schema)
