---
title: "Update a Role"
method: PUT
path: "/roles/{roleId}"
tags: ["Permissions"]
---

# Update a Role

`PUT /roles/{roleId}`

This endpoint updates a role for the given organisation.

## Request body

- object
  - `name` string — Display name of the role, shown in the admin UI when managing user permissions. Pick a name that summarises the role's responsibilities (e.g. "Spa Manager"). 1-120 characters.
  - `description` string, nullable — Free-text description of what the role is for, shown underneath the role name in the admin UI. Use it to record the scope and intent of the permission bundle. Plain text, up to 500 characters.
  - `permissions` string[], nullable — The permissions assigned to this role.

## Response `200`

The role was successfully retrieved.

- object — Single-item envelope mixin. `allOf` this into any show response that wraps its `data` payload in an outer object; the concrete schema (e.g. `ShowUser`) adds its own `data` property with the appropriate `$ref` and keeps its own title so the SDK surface is unchanged.
  - `data` SchemasRole, required
    - `id` string, uuid, required — The ID of the role.
    - `name` string, required — The name of the role.
    - `description` string, nullable, required — The description of the role.
    - `permissions` string[], nullable, required — The permissions assigned to this role.
    - `is_org_role` boolean, required — Whether this role is organisation-level. Other permissions are applied at the Site level.
    - `organisation_id` string, uuid, required — The ID of the organisation this role relates to

## Other responses

- `401` — The user is unauthenticated
- `403` — The authenticated user does not have permission.
- `404` — The resource couldn't be found
- `422` — The request didn't pass validation

---

[API](https://skmtc.dev/try/apis/trybe-api.md) · [All operations](https://skmtc.dev/try/apis/trybe-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/try/trybe-api/revisions/f37f92702da5/schema)
