---
title: "Update the list of roles of specified member."
method: PATCH
path: "/workspaces/{workspace_id}/members/{user_id}"
tags: ["workspaces"]
---

# Update the list of roles of specified member.

`PATCH /workspaces/{workspace_id}/members/{user_id}`

Only `roles` attribute can be updated. You need `workspaces.workspace.edit` or `tenant.workspace.edit_membership` permissions to access this resource

## Path parameters

- `workspace_id` string, required
- `user_id` string, required

## Request body

- object
  - `data` object, required
    - `id` string, required — ID of an already registered user, who will be added as a member of the Workspace
    - `type` 'member', required — Allowed value “member”.
    - `attributes` object, required
      - `roles` string[], required

## Response `200`

OK

- object
  - `data` object, required
    - `id` string, required
    - `type` 'member', required
    - `links` object, required
      - `self` string, required
    - `attributes` object, required
      - `first_name` string, required
      - `last_name` string, required
      - `roles` string[], required
      - `email` string, required
  - `meta` object, required

## Other responses

- `401` — Unauthorized
- `404` — Not Found

---

[API](https://skmtc.net/elastic/apis/elastic-io-rest-api-documentation-v2.md) · [All operations](https://skmtc.net/elastic/apis/elastic-io-rest-api-documentation-v2/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/elastic/elastic-io-rest-api-documentation-v2/revisions/411f9f98c01e/schema)
