---
title: "Assign roles to user."
method: PUT
path: "/api/study/{studyId}/user/{userId}/role"
tags: ["Memberships"]
---

# Assign roles to user.

`PUT /api/study/{studyId}/user/{userId}/role`

## Request

- Base URL: `https://connectapi.medrio.com` (the document declares no server; this is the origin it was published from)
- URL: `https://connectapi.medrio.com/api/study/{studyId}/user/{userId}/role`
- Auth: API key in header `Authorization`

## Path parameters

- `studyId` string, uuid, required: Study ID.
- `userId` integer, required: User ID.

## Request body

- MemberRolesIdsRequest
  - `roles` string[], nullable

## Response `201`

Success

- StringEventResultWithResponse
  - `processedSuccessfully` boolean
  - `processMessage` string, nullable
  - `response` string, nullable

---

[API](https://skmtc.dev/medrio/apis/medrio-openapi-v-42-14-0-201.md) - [All operations](https://skmtc.dev/medrio/apis/medrio-openapi-v-42-14-0-201/llms.txt) - [OpenAPI document](https://skmtc.dev/medrio/apis/medrio-openapi-v-42-14-0-201/revisions/17293ddcbc0b?raw)
