---
updatedAt: 2026-10-25T15:46:36.000Z
agentTools:
  projectIndex: https://docs.superwise.ai/llms.txt
---

# Update Dataset

Update an existing Dataset

- **payload** (DatasetUpdate): Required. The payload that includes:
    - **name** (str or None): Updated name of the dataset.
    - **description** (str or None): A revised description about the dataset.
    - **id** (str or None): Unique identifier of the dataset.
    - **model_version_id** (str or None): Updated model version identifier.
    - **created_by** (str or None): Identifier of the user who updated the dataset.
    - **tags** (list of str or None): A list of updated tags related to the dataset.
    - **schema** (SchemaUpdate or None): The updated schema of the dataset.

Updates a dataset's name, description, or schema, and returns the updated dataset. All body fields are optional.

## When to use it

Use it to rename a dataset or edit its schema. Schema changes, especially to data types, may result in historical data loss.

## Required parameters

* `dataset_id` (path): the ID of the dataset.

Optional body fields: `name`, `description`, `schema`.

## Response

A successful call returns `200 OK` with the `DatasetResponse` object: `id`, `name`, `description`, `schema`, `tags`, `created_by`, and timestamps.

**Related:** [Get a dataset](https://docs.superwise.ai/reference/get_dataset), [Delete a dataset](https://docs.superwise.ai/reference/delete_dataset), [Update a record in a dataset](https://docs.superwise.ai/reference/update_record_v1_datasets__dataset_id__update_post)

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "paths": {
    "/v1/datasets/{dataset_id}": {
      "patch": {
        "tags": [
          "Dataset"
        ],
        "summary": "Update Dataset",
        "description": "Update an existing Dataset\n\n- **payload** (DatasetUpdate): Required. The payload that includes:\n    - **name** (str or None): Updated name of the dataset.\n    - **description** (str or None): A revised description about the dataset.\n    - **id** (str or None): Unique identifier of the dataset.\n    - **model_version_id** (str or None): Updated model version identifier.\n    - **created_by** (str or None): Identifier of the user who updated the dataset.\n    - **tags** (list of str or None): A list of updated tags related to the dataset.\n    - **schema** (SchemaUpdate or None): The updated schema of the dataset.",
        "operationId": "update_dataset",
        "parameters": [
          {
            "name": "dataset_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Dataset Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DatasetUpdate"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DatasetResponse"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    }
  },
  "info": {
    "title": "Superwise Main Entities",
    "description": "API reference",
    "version": "0.1.0"
  },
  "components": {
    "schemas": {
      "HTTPValidationError": {
        "properties": {
          "detail": {
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            },
            "type": "array",
            "title": "Detail"
          }
        },
        "type": "object",
        "title": "HTTPValidationError"
      },
      "ValidationError": {
        "properties": {
          "loc": {
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "type": "array",
            "title": "Location"
          },
          "msg": {
            "type": "string",
            "title": "Message"
          },
          "type": {
            "type": "string",
            "title": "Error Type"
          },
          "input": {
            "title": "Input"
          },
          "ctx": {
            "type": "object",
            "title": "Context"
          }
        },
        "type": "object",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError"
      },
      "DatasetResponse": {
        "properties": {
          "_id": {
            "type": "string",
            "title": "Id"
          },
          "id": {
            "type": "string",
            "title": "Id"
          },
          "name": {
            "type": "string",
            "title": "Dataset Name",
            "description": "A descriptive name for this dataset"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Dataset Description",
            "description": "Relevant information about the context of this dataset"
          },
          "model_version_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model Version Id"
          },
          "created_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created At"
          },
          "updated_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Updated At"
          },
          "created_by": {
            "type": "string",
            "title": "Created By"
          },
          "updated_by": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Updated By",
            "description": "User who last updated this dataset"
          },
          "tags": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/DatasetTag"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tags"
          },
          "schema": {
            "$ref": "#/components/schemas/Schema-Output",
            "default": {}
          },
          "tenant_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Tenant Id"
          },
          "tag_ids": {
            "items": {
              "type": "string",
              "format": "uuid4"
            },
            "type": "array",
            "title": "Tag Ids"
          },
          "archived_at": {
            "anyOf": [
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "null"
              }
            ],
            "title": "Archived At"
          }
        },
        "type": "object",
        "required": [
          "_id",
          "id",
          "name",
          "created_by"
        ],
        "title": "DatasetResponse",
        "example": {
          "_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
          "created_by": "1514f337-7b42-435d-bc19-99be46c13098",
          "description": "Some Dataset Description",
          "id": "Training_16101988",
          "model_version_id": "catboost_v365",
          "name": "Name for Some Dataset",
          "tags": {
            "project": "churn_prediction",
            "type": "training"
          }
        }
      },
      "DatasetTag": {
        "properties": {
          "key": {
            "type": "string",
            "title": "Key"
          },
          "value": {
            "type": "string",
            "title": "Value"
          }
        },
        "type": "object",
        "required": [
          "key",
          "value"
        ],
        "title": "DatasetTag"
      },
      "DatasetUpdate": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 100,
                "minLength": 1
              },
              {
                "type": "null"
              }
            ],
            "title": "Name",
            "default": "NOT_SET"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "schema": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/SchemaUpdate"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "additionalProperties": false,
        "type": "object",
        "title": "DatasetUpdate"
      },
      "Schema-Output": {
        "properties": {
          "fields": {
            "anyOf": [
              {
                "additionalProperties": {
                  "$ref": "#/components/schemas/SchemaItem"
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Fields"
          },
          "key_field": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Key Field"
          }
        },
        "type": "object",
        "title": "Schema"
      },
      "SchemaItem": {
        "properties": {
          "type": {
            "$ref": "#/components/schemas/Type"
          },
          "default_value": {
            "title": "Default Value"
          }
        },
        "type": "object",
        "required": [
          "type"
        ],
        "title": "SchemaItem"
      },
      "SchemaUpdate": {
        "properties": {
          "fields": {
            "anyOf": [
              {
                "additionalProperties": {
                  "anyOf": [
                    {
                      "$ref": "#/components/schemas/SchemaUpdateItem"
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Fields"
          }
        },
        "type": "object",
        "title": "SchemaUpdate"
      },
      "SchemaUpdateItem": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "type": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/Type"
              },
              {
                "type": "null"
              }
            ]
          },
          "default_value": {
            "title": "Default Value"
          }
        },
        "additionalProperties": false,
        "type": "object",
        "title": "SchemaUpdateItem"
      },
      "Type": {
        "type": "string",
        "enum": [
          "numeric",
          "string",
          "boolean",
          "datetime",
          "date",
          "json",
          "image",
          "image_link"
        ],
        "title": "Type"
      }
    },
    "securitySchemes": {
      "implicit": {
        "type": "oauth2",
        "flows": {
          "implicit": {
            "authorizationUrl": "https://authentication.superwise.ai/identity/resources/auth/v1/api-token",
            "scopes": {}
          }
        }
      }
    }
  },
  "security": [
    {
      "implicit": []
    }
  ],
  "servers": [
    {
      "url": "api.superwise.ai",
      "description": "Superwise Api Gateway"
    }
  ]
}
```