/auth/v1/groups: GET

Gets the list of groups that are created in the system.

The following table shows which roles can access this REST API endpoint:
Table 1. Access by role
Data admin Data user Collection Admin Admin Service user
1 1 1
1The specified group must be one that is assigned to the requesting user ID. Otherwise the command fails with error 403, "Not authorized".

Synopsis of the request URL

curl -k  -H ‘Authorization: Bearer <token>’ https://<spectrum_discover_host>/auth/v1/groups

Supported request types and response formats

Supported request types:
  • GET
Supported response formats:
  • JSON

Examples

The following example shows how to get the details of the uses that are created in the system.

Request:
curl -k  -H ‘Authorization: Bearer <token>’ https://<spectrum_discover_host>/auth/v1/groups

Response:

(200 OK): 
{ 
    "groups": [ 
        { 
"id": "a51f84bfeb034b12a9a362109d78bec3", 
            "name": "test-group1", 
            "description": "Test Group 1", 
            "domain": "default" 
        }, 
        { 
"id": "b62g95bfeb034b12a9a362109d89cfd4", 
            "name": "test-group2", 
            "description": "Test Group 2", 
            "domain": "default" 
        } 
    ] 
}