timeline.purgecommandsince 0.1
Removes every row of a discarded draft. Confirmed history is never deleted.
Request
umwelt call story.umw timeline.purge '{
"projectId": "ball",
"timelineId": "other-ending"
}'Request
const result = await client.timelinePurge({ projectId: 'ball', timelineId: 'other-ending' });Request
var result = engine.TimelinePurge(new TimelineRef { ProjectId = "ball", TimelineId = "other-ending" });Response
{
"purged": true,
"removed": { "attempts": 1, "events": 1, "records": 1, "transitions": 0 }
}Payload
| Field | Type | Description |
|---|---|---|
projectIdrequired | string | The project to write to. |
timelineIdrequired | stringdefault "main" | The timeline to write to. |
Result
| Field | Type | Description |
|---|---|---|
purgedalways | boolean | True once the draft is purged. |
removedalways | PurgeCounts | How many attempts, events, records and transitions were removed. |
Rules
Only discarded drafts. Main and promoted drafts cannot be purged: confirmed history is never deleted.
Safe to retry. Purging a purged draft removes nothing and reports zeros. Its ids and attempt ids can be used again.
Errors
NOT_FOUNDThe project or draft does not exist.INVALID_STATEThe timeline is main, the draft was promoted or is still active, or a discarded descendant still reads it (details.descendants).HANDSHAKE_REQUIREDOver the protocol, hello was not sent first.Every code is listed in Errors.
See also
Was this page helpful?