Skip to main content
PATCH
/
api
/
users
/
{id}
Update user
curl --request PATCH \
  --url https://api.example.com/api/users/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "email": "<string>",
  "groups": [
    123
  ],
  "permissions": [
    123
  ]
}
'
{
  "id": 123,
  "name": "<string>",
  "email": "[email protected]",
  "is_active": true,
  "groups": [
    123
  ],
  "permissions": [
    123
  ],
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}

Authorizations

Authorization
string
header
required

JWT token obtained from AWS Cognito or custom authentication service

Path Parameters

id
integer
required

A unique integer value identifying this user.

Body

application/json
name
string
email
string
groups
integer[]
permissions
integer[]

Response

User updated successfully

User object with all details

id
integer
required

User ID

name
string
required

User full name

email
string<email>
required

User email address

is_active
boolean
required

Whether the user is active

groups
integer[]

List of group IDs

permissions
integer[]

List of permission IDs

created_at
string<date-time>

User creation timestamp

updated_at
string<date-time>

User last update timestamp