[dbs] Implement /tasks api endpoint

We prolly only want to return tasks that are pending/running,
but for now...
[dbs] Fix regexp, add /task/<task_id>/info endpoint