Undo a whole session
const url = 'https://beta-api.plune.ai/v1/audit/sessions/example/restore';const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
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://beta-api.plune.ai/v1/audit/sessions/example/restore \ --header 'Authorization: Bearer <token>'Walks the session backwards — the changes were applied forwards, so the state before the FIRST change is what the earliest entry holds. A record someone else has touched since is skipped and named rather than overwritten: the point of undo is to remove one actor’s work, not everyone who came after them. Always 200 with a report, never a stop at the first refusal. A create is undone by deleting the record through the ordinary delete, so its refusals hold: a case with results stays, and so does a node that still holds something. That is what takes a filed case’s derived folders and suite with it (B-7) — and leaves a suite someone has filled since, named in the report.
Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ”Responses
Section titled “ Responses ”How many were put back, and what was not
object
object
Example generated
{ "restored": 1, "skipped": [ { "entryId": "example", "reason": "example" } ]}No / invalid token or session
Rate limited