Magidoc

deleteBox
Mutation

Deletes a box. The deleteTodos argument selects one of two distinct behaviors. With deleteTodos: true the box and all of its non-deleted todos are soft-deleted together and can be restored with undoDeleteBox. With deleteTodos: false or omitted, the box record is deleted permanently and its todos are kept: they lose their boxId and become loose todos directly on the slice - this path cannot be undone.

If the slice is a board and this was its last remaining box, the slice's boardView flag is reset to false.

Access control matches createBox (permission to create todos in the box's project). Returns the deleted Box; fails with not_allowed when the caller lacks permission.

Arguments

#

deleteTodos

True: soft-delete the box together with its todos (restorable via undoDeleteBox). False or omitted: permanently delete the box but keep its todos as loose slice todos.

id

Non-null

Response

#

Returns Box .

Example

#