Undo the latest local PCD change
const url = 'https://example.com/api/v1/pcd/1/overrides/undo';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"expectedActionId":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/v1/pcd/1/overrides/undo \ --header 'Content-Type: application/json' \ --data '{ "expectedActionId": "example" }'Soft-drops exactly the latest published user-action unit and recompiles the PCD. Every mutating HTTP request is one action_id unit; a scheduled or manual job run is its own unit, and each automatic conflict override applied during recompilation is a separate unit. Legacy ops fall back to group_id, then a single op. Previously applied edits superseded by this action are reactivated when undoing it; undoing a manual or automatic conflict override reactivates the original published op it replaced, and its previously pending conflict may return after the recompile. No automatic snapshot is created. API tokens require admin scope. The request body is limited to 8 KB. snapshot is created. API tokens require admin scope. The request body is limited to 8 KB.
Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”PCD database ID
Request Body
Section titled “Request Body”object
LastAction.actionId from the last read; mismatch is rejected as stale_action
Examplegenerated
{ "expectedActionId": "example"}Responses
Section titled “Responses”Latest user action undone and cache recompiled
object
Previously applied edits superseded by the undone action and now restored, including the original published op behind an undone manual or automatic conflict override
object
Resolved config entity type
Explicit Arr app for scoped entities; null for Arr-agnostic entities
Current resolved entity name, preserved exactly without trimming
Example
{ "entities": [ { "entityType": "delayProfile", "arrType": "radarr" } ]}Invalid databaseId or JSON body, oversized body, disabled database, or unbuilt cache
object
Error message
Stable machine-readable code present on 5xx responses; error is a fixed user-safe message, raw detail is logged server-side only
Example
{ "code": "cleanup_failed"}Authentication required
object
Error message
Stable machine-readable code present on 5xx responses; error is a fixed user-safe message, raw detail is logged server-side only
Example
{ "code": "cleanup_failed"}The API token lacks the admin scope.
An authenticated API token lacks the scope the requested route requires.
object
Always Forbidden.
The API token scope this request requires.
Example
{ "requiredScope": "read"}Nothing_to_undo means there are no published user ops to undo
object
Machine-readable missing-target (404) or fail-closed conflict (409) reason
object
Resolved config entity type
Explicit Arr app for scoped entities; null for Arr-agnostic entities
Current resolved entity name, preserved exactly without trimming
Example
{ "reason": "entity_not_found", "entities": [ { "entityType": "delayProfile", "arrType": "radarr" } ]}Undo rejected without changing the published-op set:
- stale_action: expectedActionId no longer identifies the latest undoable action.
- conflict_after_revert: recompilation would introduce a new conflict on a remaining op.
- collateral_ops: recompilation would change ops outside the explicitly planned set.
object
Machine-readable missing-target (404) or fail-closed conflict (409) reason
object
Resolved config entity type
Explicit Arr app for scoped entities; null for Arr-agnostic entities
Current resolved entity name, preserved exactly without trimming
Example
{ "reason": "entity_not_found", "entities": [ { "entityType": "delayProfile", "arrType": "radarr" } ]}Failed to undo the latest local change
object
Error message
Stable machine-readable code present on 5xx responses; error is a fixed user-safe message, raw detail is logged server-side only
Example
{ "code": "cleanup_failed"}