New API endpoints to manage Dataset Sets
see #1712 (closed)
New endpoints are introduced to manage a dataset's sets, CreateDatasetSet
, [Partial]UpdateDatasetSet
and DestroyDatasetSet
, under /api/v1/dataset/<id>/sets/
and /api/v1/dataset/<id>/sets/<id>/
. They take a name
as their request body. They must return an HTTP 404 if the dataset is not on a readable corpus. They must return an HTTP 400 if the dataset is readable but the user does not have admin access to the corpus, or if the dataset is not open
.
DestroyDatasetSet
should also return an HTTP 400 if this is the last set of the dataset, or if the set is selected by a dataset process. It should destroy all of the related DatasetElements
before destroying the set.