Skip to main content
PATCH
/
api
/
users
/
{id}
curl -X PATCH "https://api.hitler.app/api/users/user-uuid-123" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "role": "manager"
  }'
{
  "id": "user-uuid-123",
  "email": "john@acme.com",
  "name": "John Doe",
  "role": "manager",
  "isActive": true,
  "organizationId": "org-uuid",
  "createdAt": "2024-01-10T15:30:00.000Z",
  "updatedAt": "2024-01-15T14:00:00.000Z"
}
This endpoint requires Admin role to change roles. Users can update their own non-role fields via /api/users/me.

Path Parameters

id
string
required
User UUID

Request

name
string
New display name
role
string
New role: employee, manager, admin (Admin only)
preferences
object
User preferences

Response

Returns the updated user.
curl -X PATCH "https://api.hitler.app/api/users/user-uuid-123" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "role": "manager"
  }'
{
  "id": "user-uuid-123",
  "email": "john@acme.com",
  "name": "John Doe",
  "role": "manager",
  "isActive": true,
  "organizationId": "org-uuid",
  "createdAt": "2024-01-10T15:30:00.000Z",
  "updatedAt": "2024-01-15T14:00:00.000Z"
}