Skip to main content
PATCH
Error

Authorizations

X-API-Key
string
header
required

Path Parameters

dataset_id
string<uuid>
required

Body

application/json

Update class for Dataset.

name
default:{"__missing__":"__missing__"}

New dataset name. Must be unique in the workspace; a name already used by another dataset returns 409. Null returns 400. Omit to keep the current name.

description
default:{"__missing__":"__missing__"}

New dataset description. Null clears it. Omit to keep the current description.

inputs_schema_definition
Inputs Schema Definition · object

JSON Schema that example inputs must match. Replaces the current inputs schema as a whole; null removes it, which returns 400 while transformations still point into inputs. Only key-value datasets support schemas. Every existing example must match the new schema, otherwise the request returns 400 with the IDs of the examples that do not, and nothing is changed. Omit to keep the current schema.

outputs_schema_definition
Outputs Schema Definition · object

JSON Schema that example outputs must match. Replaces the current outputs schema as a whole; null removes it, which returns 400 while transformations still point into outputs. Only key-value datasets support schemas. Every existing example must match the new schema, otherwise the request returns 400 with the IDs of the examples that do not, and nothing is changed. Omit to keep the current schema.

patch_examples
Patch Examples · object | null

Example updates keyed by example ID, applied in the same transaction so existing examples can be fixed to match a new schema. Only used when the request also sets inputs_schema_definition, outputs_schema_definition, or transformations and the dataset ends up with at least one schema; otherwise it is ignored. Each update replaces the inputs, outputs, metadata, or split it sets and keeps the rest; attachment operations are ignored. An ID that is not an example in this dataset returns 404.

transformations
DatasetTransformation · object
metadata
Metadata · object

Dataset metadata as a JSON object. Replaces the current metadata as a whole; keys are not merged. Send an empty object to clear it. Omit to keep the current metadata.

baseline_experiment_id
default:{"__missing__":"__missing__"}

ID of the experiment used as the baseline when comparing experiments on this dataset. Must be an experiment run on this dataset, otherwise returns 400. Null clears it. Omit to keep the current baseline.

Response

Dataset updated successfully

name
string
required
id
string<uuid>
required
tenant_id
string<uuid>
required
description
string | null
created_at
string<date-time>
inputs_schema_definition
Inputs Schema Definition · object | null
outputs_schema_definition
Outputs Schema Definition · object | null
externally_managed
boolean | null
default:false
transformations
DatasetTransformation · object[] | null
data_type
enum<string> | null
default:kv

Enum for dataset data types.

Available options:
kv,
llm,
chat