Groups the overlays of a project are organised in, served from
/new_api/projects/{projectId}/overlay_groups.
1. List overlay groups
Returns the overlay groups of the project that belong to the calling user.
|
Note
|
The result is paged - use the page and size query parameters to
walk through it.
|
1.1. HTTP request
GET /minerva/new_api/projects/test_project/overlay_groups/ HTTP/1.1
1.2. Path Parameters
| Parameter | Description |
|---|---|
|
project identifier |
1.3. Query Parameters
| Parameter | Description |
|---|---|
|
index of the page to fetch, counted from 0; 0 by default |
|
number of entries on a page; 20 by default, 10000 at most |
1.4. CURL sample
$ curl 'https://minerva-dev.lcsb.uni.lu/minerva/new_api/projects/test_project/overlay_groups/' -X GET \
-H 'Authorization: Bearer xxxxxxxx'
1.5. HTTP response
HTTP/1.1 200 OK
1.6. Response Fields
| Path | Type | Description |
|---|---|---|
|
|
list of overlay groups on the page |
|
|
unique group identifier |
|
|
human readable name of the group |
|
|
position of the group on the list of groups |
|
|
total number of pages |
|
|
total number of elements |
|
|
number of elements on this page |
|
|
page size |
|
|
page number |
1.7. Sample Response
{
"content" : [ {
"id" : 16,
"name" : "Isidro Huels III",
"order" : 3
} ],
"totalPages" : 1,
"totalElements" : 1,
"numberOfElements" : 1,
"size" : 20,
"number" : 0
}
2. Get overlay group
Returns a single overlay group by id.
2.1. HTTP request
GET /minerva/new_api/projects/test_project/overlay_groups/14 HTTP/1.1
2.2. Path Parameters
| Parameter | Description |
|---|---|
|
project identifier |
|
group identifier |
2.3. CURL sample
$ curl 'https://minerva-dev.lcsb.uni.lu/minerva/new_api/projects/test_project/overlay_groups/14' -X GET \
-H 'Authorization: Bearer xxxxxxxx'
2.4. HTTP response
HTTP/1.1 200 OK
2.5. Response Fields
| Path | Type | Description |
|---|---|---|
|
|
unique group identifier |
|
|
human readable name of the group |
|
|
position of the group on the list of groups |
2.6. Sample Response
{
"id" : 14,
"name" : "Jordan Leuschke",
"order" : 2
}
3. Add overlay group
Creates a new overlay group for the given project.
3.1. HTTP request
POST /minerva/new_api/projects/test_project/overlay_groups/ HTTP/1.1
3.2. Path Parameters
| Parameter | Description |
|---|---|
|
project identifier |
3.3. Request Fields
| Path | Type | Description |
|---|---|---|
|
|
human readable name of the group |
|
|
position of the group on the list of groups |
3.4. CURL sample
$ curl 'https://minerva-dev.lcsb.uni.lu/minerva/new_api/projects/test_project/overlay_groups/' -X POST \
-H 'Authorization: Bearer xxxxxxxx' \
-d '{"name":"Gaylord Gottlieb","order":74}' \
-H 'Content-Type: application/json'
3.5. HTTP response
HTTP/1.1 201 Created
3.6. Response Fields
| Path | Type | Description |
|---|---|---|
|
|
unique group identifier |
|
|
human readable name of the group |
|
|
position of the group on the list of groups |
3.7. Sample Response
{
"id" : 13,
"name" : "Gaylord Gottlieb",
"order" : 74
}
4. Update overlay group
Overwrites both properties of the group: its name and its order, which decides where the group is placed in the list of overlay groups.
Both fields have to be sent, only the owner of the group can update it, and the call is rejected if the project is readonly.
|
Note
|
Supports optimistic locking via the If-Match header.
|
4.1. HTTP request
PUT /minerva/new_api/projects/test_project/overlay_groups/11 HTTP/1.1
4.2. Path Parameters
| Parameter | Description |
|---|---|
|
project identifier |
|
group identifier |
4.3. Request Fields
| Path | Type | Description |
|---|---|---|
|
|
human readable name of the group |
|
|
position of the group on the list of groups |
4.4. CURL sample
$ curl 'https://minerva-dev.lcsb.uni.lu/minerva/new_api/projects/test_project/overlay_groups/11' -X PUT \
-H 'Authorization: Bearer xxxxxxxx' \
-d '{"name":"Maire Robel","order":39}' \
-H 'Content-Type: application/json'
4.5. HTTP response
HTTP/1.1 200 OK
4.6. Response Fields
| Path | Type | Description |
|---|---|---|
|
|
unique group identifier |
|
|
human readable name of the group |
|
|
position of the group on the list of groups |
4.7. Sample Response
{
"id" : 11,
"name" : "Maire Robel",
"order" : 39
}
5. Delete overlay group
Removes the group together with all overlays assigned to it - the overlays are deleted, not moved out of the group - so move any overlay that should survive to another group first. Only the owner of the group can delete it, and the call is rejected if the project is readonly.
|
Note
|
Supports optimistic locking via the If-Match header.
|
5.1. HTTP request
DELETE /minerva/new_api/projects/test_project/overlay_groups/15 HTTP/1.1
5.2. Path Parameters
| Parameter | Description |
|---|---|
|
project identifier |
|
group identifier |
5.3. CURL sample
$ curl 'https://minerva-dev.lcsb.uni.lu/minerva/new_api/projects/test_project/overlay_groups/15' -X DELETE \
-H 'Authorization: Bearer xxxxxxxx'
5.4. HTTP response
HTTP/1.1 200 OK