Update

Description

Update a Role.

Request

HTTP Method: PATCH

Body Parameter Description
description Optional Role description.
permissions Optional Array of permission names, from the list of available permissions.
Path Parameter Description
role_id ID or name of the role.

Sample request


curl -X PATCH \
  https://<<META.tenant.domain>>/api/v1/admin/roles/<<role_id>> \
  -H 'content-type: application/json' \
  -H 'Authorization: Bearer <<CREDENTIAL.tines_api_key>>' \
  -d '{
       "permissions": ["CASE_CREATE"]
      }'

Response

A successful request will return a JSON object describing the updated role.

Field description

Parameter Description
id Role ID.
name Role name.
type Role type - custom.
description Role description.
permissions Array of applied permissions.
created_at Timestamp describing when the role was created.
updated_at Timestamp describing when the role was last updated.
builder Boolean indicating whether this role grants builder / story editing permissions.

Sample response

{
  "id": "123",
  "name": "MY_ROLE",
  "type": "custom",
  "description": "My fantastic role",
  "permissions": ["CASE_CREATE"],
  "created_at": "2019-11-03T09:57:49.537Z",
  "updated_at": "2019-11-03T09:57:49.537Z",
  "builder": false
}
Was this helpful?