Delete version
delete_versionPermanently delete a version created by mistake; close the version instead for finished releases or sprints. Work packages are not deleted but lose the version.
Instructions
Permanently delete a version.
Use it only for a version created by mistake. For a finished release or sprint,
update_version(status='closed') is almost always the right answer: it keeps the
history and stops new assignments.
Returns a small confirmation once OpenProject accepts the deletion. Work packages are NOT deleted — they simply lose their version — but that only happens on instances that allow the deletion at all.
Pitfalls: OpenProject refuses (422) to delete a version that work packages still reference; the error hint explains how to find them. Deleting a shared version affects every project that used it. The 'manage versions' permission is required, so a 403 is about the account.
Cross-references: list_versions for the id; update_version(status='closed')
for the reversible alternative; list_work_packages to find what still points at
the version before removing it.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| confirm | No | Must be true. Ask the user first: there is no undo. Calling with confirm=false returns a confirmation_required error and deletes nothing. | |
| version_id | Yes | Numeric version id to delete. Read it back with list_versions first — version names repeat across projects, ids do not. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Id of the version that was deleted. | |
| deleted | Yes | True once OpenProject accepted the deletion. | |
| message | Yes | Human-readable confirmation. |