Skip to content

Change a member's role

PATCH
/api/v1/users/{id}

Requires the admin role. The account owner’s role cannot be changed. Omitting the role leaves the member unchanged — it is never defaulted.

NameType
id
required
string

The record’s prefixed ID

Media typeapplication/json
object
user
object
role
string
Allowed values: admin member viewer

200

The updated member

Response body
Media typeapplication/json
object
id
string
email
string format: email
name
string
first_name
string
last_name
string
role
string
Allowed values: admin member viewer
roles
Array<string>
owner
boolean

True for the account owner

created_at
string format: date-time

When the membership was created

updated_at
string format: date-time

403

Insufficient scope, role, or credits

Response body
Media typeapplication/json
object
error
object
code
string

A stable machine-readable code

message
string
details
Array<string>

Present on validation errors; one entry per failed validation

422

The record could not be saved

Response body
Media typeapplication/json
object
error
object
code
string

A stable machine-readable code

message
string
details
Array<string>

Present on validation errors; one entry per failed validation