---
title: "Update User"
method: PUT
path: "/users/{userId}"
tags: ["Users"]
---

# Update User

`PUT /users/{userId}`

Updates a single user. Partial updates are supported. To delete a specific custom attribute, pass null for that attribute.
### Authorization Required:
  - Designer Administrator

## Path parameters

- `userId` string, required

## Query parameters

- `shouldNotify` boolean

## Request body

- UserPut
  - `userId` string — The unique identifier of the user account. The userId can only include letters, numbers, and the following characters @,+-_. **Immutable**: This value cannot be modified. If provided in the request body, it must match the `userId` in the path, or it will be ignored.
  - `name` string — The name can only include letters, numbers, and the following characters @,+-_.'
  - `email` string, email — Quotes and special characters `"(),:;<>@[]\` are not allowed. The local portion of the email (e.g. local@domain.com) must be > 0 characters and < 64 charaters. There cannot be consecutive dots (e.g. `..`) in the email
  - `phone` string — Must be a valid US phone number unless the country code is specified, in which case it is validated with [libphonenumber-js](https://gitlab.com/catamphetamine/libphonenumber-js#definitions)
  - `role` string — One of the roles configured in Unqork
  - `expressRoles` string[] — Express roles configured in Unqork
  - `groups` string[] — List of groups configured in Unqork OR comma-separated list of groups configured in Unqork (e.g. "group1,group2")
  - `applicationRoles` object — Map of applications to roles OR comma-separated list of application-role mappings (e.g. "application1:role1,application2:role2")
  - `password` string, password
  - `isServiceUser` boolean
  - `...customAttributes` string — Custom attributes can be included as additional keys in the request body. Only string values of custom attributes are supported.

## Response `200`

User updated

- UserResponse
  - `userId` string, required
  - `name` string, required
  - `email` string, required
  - `phone` string
  - `role` string — One of the roles configured in Unqork
  - `expressRoles` string[] — Express roles configured in Unqork
  - `groups` string[] — List of groups configured in Unqork
  - `applicationRoles` object — Map of applications to roles
  - `created` string, date-time, required
  - `modified` string, date-time, required
  - `isServiceUser` boolean
  - `lastLogin` string, date-time
  - `...customAttributes` string — Custom attributes will be included as additional keys in the response body.

## Other responses

- `default` — Error

---

[API](https://skmtc.net/unqork/apis/unqork-customer-api.md) · [All operations](https://skmtc.net/unqork/apis/unqork-customer-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/unqork/unqork-customer-api/revisions/112399a67ebb/schema)
