---
title: "Discard uncommitted (staged) changes"
method: POST
path: "/version/undo"
tags: ["versioning"]
---

# Discard uncommitted (staged) changes

`POST /version/undo`

Discard all uncommitted (staged) configuration changes, resetting the working directory to the last committed state. Use only if you are certain that you do not need to preserve your local changes.<br/><br/>When applied globally (no group), triggers a Cribl restart to reload the reverted configuration. Returns <code>false</code> if the working directory is already clean.

## Response `200`

The created boolean object in a single-item list.

- CountedBoolean
  - `count` integer, required — number of items present in the items array
  - `items` boolean[], required — List of items in this response.

## Other responses

- `401` — Authentication failed (missing or invalid credentials or Bearer token).
- `500` — Unexpected server error.

## Changes

- **2026-07-21** `e9bef570d106` — 6 info
  - added the media type `application/json` for the response with the status `401`
  - added the optional property `details` to the response with the `500` status
  - the response property `count` became required for the status `200`
  - the response property `items` became required for the status `200`
  - …2 more
- **2026-03-06** `11df16b26c1d` — 1 breaking, 1 warning
  - the `items/items/` response's property type/format changed from `object`/`` to `boolean`/`` for status `200`
  - deleted the `query` request parameter `groupId`
- **2025-11-14** `72b542d3fe49` — 1 breaking
  - the `items/items/` response's property type/format changed from `string`/`` to `object`/`` for status `200`
- **2025-08-26** `72f306103a82` — 1 warning, 1 info
  - deleted the `query` request parameter `group`
  - added the new optional `query` request parameter `groupId`

[Change history](https://skmtc.dev/criblio/apis/cribl-api-reference/changes/version/undo/post.md)

---

[API](https://skmtc.dev/criblio/apis/cribl-api-reference.md) · [All operations](https://skmtc.dev/criblio/apis/cribl-api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/criblio/cribl-api-reference/revisions/56cb25079271/schema)
