View, update and manage user roles.

GET /users/{id}/roles

Description
Permissions
Resource URL
Parameters
Response codes

Get a list of the user’s roles.
user.manage
https://app.klipfolio.com/api/1.0/users/{id}/roles
user id={id}
401 — access denied
404 — user id not found

Permissions

user.manage

Resource URL

https://app.klipfolio.com/api/1.0/users/{id}/roles

Parameters

user id={id}

Example Request

GET https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/roles

Example Response

{
 "data": {
       "id":"fedcba9876543210fedcba9876543210",
       "name":"Admin",
       "description":"Manage all assets, users, groups, roles, and account settings."
  },
 "meta": {
     "status": 200,
     "success": true
 }
}

PUT /users/{id}/roles/{id}

Description

Assign a user to a role.

Permissions

user.manage

Resource URL

https://app.klipfolio.com/api/1.0/users/{id}/roles/{id}

Parameters

user id={id}, roles id={id}

Example Request

PUT https://app.klipfolio.com/api/1/users/fedcba9876543210fedcba9876543210/roles/abcdef123456 -d “{'id': ['f70a1cd9817b85ffa252a7b4280f0223’]}”

Example Response

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

DELETE /users/{id}/roles/{id}

Description

Delete the user from a specified role.

Permissions

user.manage

Resource URL

https://app.klipfolio.com/api/1.0/users/{id}/roles{roleid}

Parameters

None.

Example Request

DELETE https://app.klipfolio.com/api/1/users/0123456789abc/roles/0123456789abdef0123456789abcdef
###Example Response

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