User Groups

View and manage groups to which a user belongs in your account or your client accounts.

GET /users/{id}/groups

DescriptionRetrieve the list of groups to which the specified user belongs in the company or client account.
Permissionsuser.manage
Resource URLhttps://app.klipfolio.com/api/1.0/users/{id}/groups
Parametersuser id
optional: client_id

Example Request

GET https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/groups
GET https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/groups?client_id=0123456789abcdef0123456789abcdef

Example Response

{
   "data": {
       "groups": [
           {
               "description": All managers in the company,
               "id": "0123456789abcdef0123456789abcdef",
               "name": "Managers"
           },
           {
               "description": "All users in the company",
               "id": "0123456789abcdef0123456789abcdef",
               "name": "All"
           }
       ]
   },
   "meta": {
       "status": 200,
       "success": true
   }

PUT /users/{id}/groups/{id}

DescriptionAdd a specified user to one group at a time in the company or client account.
Permissionsuser.manage
Resource URLhttps://app.klipfolio.com/api/1.0/users/{id}/groups
Fieldsuser id, group_id, can_edit (true/false)
optional: client_id

Example Request

PUT https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/groups/0123456789abcdef0123456789abcdef
PUT https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/groups/0123456789abcdef0123456789abcdef?client_id=0123456789abcdef0123456789abcdef

Example Response

{
   "meta": {
       "status": 200,
       "success": true
   }
}

DELETE /users/{id}/groups/{id}

DescriptionDelete a specified user from specified groups in the company or client account.
Permissionsuser.manage
Resource URLhttps://app.klipfolio.com/api/1.0/users/{id}/groups/{groupId}
Parametersuser id, group id
optional: client_id

Example Request

DELETE https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/groups/0123456789abcdef0123456789abcdef
DELETE https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/groups/0123456789abcdef0123456789abcdef?client_id=0123456789abcdef0123456789abcdef

Example Response

{
"meta": {
      "status": 200,
      "success": true
  }
}