Paginated list of resource groups available to the user.
GET/api/v1/analytics/groupsHeaders |
Authorization | Bearer token |
Accept | application/json |
X-Client | ios-cctv|android-cctv|thick-legal|web |
X-UUID | unique device id |
Body |
pagerequired | int | Pagination page number |
per_pagerequired | int | Number of items per page in pagination. Default is 25 |
analytic_groupsrequired | array | Array of resource group IDs to exclude. Excluded IDs will not be reflected in the output |
analytic_typerequired | str | Search by analytics case type |
filesrequired | int | Search for resource groups containing resource IDs |
analytic_caserequired | int | Search for resource groups related to an analytics case |
Response |
200 | Returns a list of resource groups on page i of pagination |
JSON
{
"data": [
{
"id": 1,
"name": "name",
"type": "type",
"type_pretty": "type_pretty",
"uuid": "0906deb6-b1b1-11ec-8995-a3b0e5228375",
"created_at": "2022-04-01 14:44:06",
"updated_at": "2022-04-01 14:44:06",
"files_count": 1
}
],
"links": {
"first": "https://vms.local/api/v1/analytics/groups?page=1",
"last": "https://vms.local/api/v1/analytics/groups?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "pagination.previous",
"active": false
},
{
"url": "https://vms.local/api/v1/analytics/groups?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "pagination.next",
"active": false
}
],
"path": "https://vms.local/api/v1/analytics/groups",
"per_page": 25,
"to": 1,
"total": 1
}
}
|
401 | Authorization token not provided or invalid, see Obtaining a token |
422 | Returns a JSON object with an error, see Validation |
JSON
{
"message": "There won't be any informative message here",
"errors": {
"any_key": [
"Here the error cause will be described"
]
}
}
|
Example |
JSON
curl -k --location --request GET 'https://vms.local/api/v1/analytics/groups?page=int&per_page=int&analytic_groups=array&analytic_type=str&files=int&analytic_case=int' \
--header 'Authorization:Bearer token' \
--header 'Accept:application/json' \
--header 'X-Client:ios-cctv|android-cctv|thick-legal|web' \
--header 'X-UUID:unique device id'
|