Change return code for DELETE task to ACCEPTED

The task is not yet actually deleted when this returns, so ACCEPTED is
the more fitting return code.
Return early on bad request
Docstring for delete task
If query fits on just one line