Skip to content

Service: User Group List

Eliza Margaretha Illig edited this page Oct 25, 2024 · 17 revisions

** WARNING: Group member status is DEPRECATED and has been removed starting from Kustvakt version 0.75.

** WARNING: This service is experimental and may change without any notice.

Lists all user-groups in which the authenticated user is a member. Information about members is restricted only to group admins with GROUP_ADMIN role.

To use this service, authorization scope user_group_info is required.

Available in: full version

Method: GET

Service URL: root/group

Parameters

Header Parameter

Name Required Authentication scheme Value
Authorization yes HTTP authentication with scheme: Bearer OAuth2 access token

Response Codes

HTTP Status Code Description
200 OK successful request
401 Unauthorized when the operation is not permitted, e.g. user doesn't log in.

Examples

Request with cURL:

curl -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJleHAiOj' 
      http://localhost:8089/api/v1.0/group

Request with Basic authentication (for testing only):

Retrieve user-groups of marlin

curl -H 'Authorization: Basic bWFybGluOnBhc3N3b3Jk' 
      http://localhost:8089/api/v1.0/group

The first group belongs to marlin so he has the GROUP_ADMIN role and may see the members of the group. The status of the group is active.

In the 2nd group, marlin is not a group admin, so members are not shown.

[
    {
        "id": 1,
        "name": "marlin group",
        "owner": "marlin",
        "description" : "This group belongs to marlin."
        "status": "ACTIVE",
        "members": [
            {
                "userId": "marlin",
                "roles": [
                    "GROUP_ADMIN"
                ],
                "privileges" : [
                    "READ_MEMBER",
                    "WRITE_MEMBER",
                    "DELETE_MEMBER",
                    "SHARE_QUERY",
                    "DELETE_QUERY"
                ]
            },
            {
                "userId": "dory",
                "roles": [
                    "GROUP_ADMIN"
                ]
            }
        ]
    },
    {
        "id": 2,
        "name": "dory group",
        "owner": "dory"        
    }
]

Advanced Setting

Developer Setting

Search services

Metadata services

Authentication and Authorization services

Client services

Super client services

Plugin services

User services

User group services

Virtual corpus (VC) services

VC sharing services

Administrative services

Description services

Clone this wiki locally