---
title: "Update dataset"
method: PATCH
path: "/datahub/v1/datasets/{name}"
tags: ["DataHub"]
---

# Update dataset

`PATCH /datahub/v1/datasets/{name}`

Updates an existing DataHub dataset's metadata. Only the description field can be updated.
The dataset name is immutable and serves as the resource identifier. To rename a dataset, delete it and create a new one.
If `name` is included in the request body, it must match the dataset name in the URL path. A mismatched name will be rejected with a 400 error.

## Path parameters

- `name` string, required

## Request body

- object
  - `name` string — Must match the dataset name in the URL path. Included for idempotency; the name cannot be changed.
  - `description` string — The new description for the dataset.

## Response `200`

OK - Dataset updated successfully.

- object
  - `name` string — The name of the dataset.
  - `description` string — The description of the dataset.
  - `records` integer, nullable — The number of records in the dataset.
  - `updatedBy` string — The email of the user who last updated the dataset.
  - `lastUpdated` string — The timestamp of the last update.

## Other responses

- `400` — Bad Request - The server cannot process the request, often due to a malformed request.
- `401` — Unauthorized - Invalid API key.
- `403` — Forbidden - The client is not authorized to perform the request.
- `404` — Not Found - The requested resource does not exist.
- `500` — Internal Server Error - Something went wrong with the DoiT API server.

---

[API](https://skmtc.net/doit/apis/doit-cloud-intelligence.md) · [All operations](https://skmtc.net/doit/apis/doit-cloud-intelligence/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/doit/doit-cloud-intelligence/revisions/9416402fc119/schema)
