Skip to content

Undo a Keep

POST
/tasks/{id}/unkeep
curl --request POST \
--url http://127.0.0.1:7700/api/tasks/t3k9x2a1b2/unkeep \
--header 'Authorization: Bearer <token>'

Preview, owner only. Puts the owner’s files back as they were before a Keep, from the copies saved under BOX_HOME/timemachine/<id>/: kept files get their old content, owner and mode back, and files the Keep added are removed. If the owner edited a kept file since, nothing changes and the response lists the files. The task’s review becomes undone, and a keep event with result: reverted goes into the log.

id
required
string

The task id.

Example

t3k9x2a1b2

The files put back, or the conflicts that stopped it.

Media typeapplication/json
One of:
object
reverted
required
Array<object>
object
path
required

Path inside the workspace.

string
change
required
string
Allowed values: added modified deleted

Examples

{
"reverted": [
{
"path": "intro.md",
"change": "modified"
}
]
}

No such task, or the task has no Keep to undo.

Media typeapplication/json
object
error
required

What went wrong

string

Example

{
"error": "task t3k9x2a1b2 has no Keep to undo"
}

The owner’s route, called by someone who is not the box’s own screen or a device paired as the owner.

Media typeapplication/json
object
error
required

What went wrong

string

Example

{
"error": "only the box's own screen or the owner's paired device can do this"
}

GurtOS is open source under the Apache License 2.0.Source code on GitHub.