---
title: "Batch update dataset items"
method: PATCH
path: "/v1/private/datasets/items/batch"
tags: ["Datasets"]
---

# Batch update dataset items

`PATCH /v1/private/datasets/items/batch`

Update multiple dataset items

## Request body

- DatasetItemBatchUpdate — Request to batch update multiple dataset items
  - `ids` string[] — List of dataset item IDs to update (max 1000). Mutually exclusive with 'filters'.
  - `filters` DatasetItemFilter[]
    - `field` string
    - `operator` 'contains' | 'not_contains' | 'starts_with' | 'ends_with' | '=' | '!=' | '>' | '>=' | '<' | '<=' | 'is_empty' | 'is_not_empty' | 'in' | 'not_in'
    - `key` string
    - `value` string
  - `dataset_id` string, uuid — Dataset ID. Required when using 'filters', optional when using 'ids'.
  - `update` DatasetItemUpdate, required — Dataset item update request
    - `input` string — Dataset item input
    - `expected_output` string — Dataset item expected output
    - `metadata` JsonNode
    - `data` JsonNode
    - `description` string — Dataset item description
    - `tags` string[] — Tags
    - `tags_to_add` string[] — Tags to add
    - `tags_to_remove` string[] — Tags to remove
    - `evaluators` EvaluatorItem[] — Evaluators
      - `name` string, required
      - `type` 'llm_judge' | 'code_metric', required
      - `config` JsonNode, required
    - `execution_policy` ExecutionPolicy
      - `runs_per_item` integer
      - `pass_threshold` integer
    - `clear_execution_policy` boolean — When true, clears the item-level execution policy (falls back to dataset-level)
  - `merge_tags` boolean — If true, merge tags with existing tags instead of replacing them. Default: false. When using 'filters', this is automatically set to true.

## Response `204`

No Content

## Other responses

- `400` — Bad Request

---

[API](https://skmtc.net/comet-ml/apis/opik-rest-api.md) · [All operations](https://skmtc.net/comet-ml/apis/opik-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/comet-ml/opik-rest-api/versions/4ed2fbc97cc3/schema)
