Skip to main content
PUT
/
users
/
{id}
curl -X PUT https://api.arca.example.com/users/123e4567-e89b-12d3-a456-426614174000 \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -d '{
    "nome": "John Updated",
    "email": "[email protected]"
  }'
{
  "id_User": "123e4567-e89b-12d3-a456-426614174000",
  "nome": "John Updated",
  "email": "[email protected]",
  "roleId": 2
}
Update an existing user’s information.

Authentication

Requires a valid JWT token in the Authorization header:
Authorization: Bearer {token}

Authorization

You can only update users with a role level lower than your own, except:
  • Admins (roleId 1) can update other Admins

Path Parameters

id
string
required
The user’s unique identifier (UUID).

Request Body

All fields are optional. Only include the fields you want to update.
nome
string
User’s name. Maximum 50 characters.
email
string
User’s email address. Must be a valid email format and not exceed 100 characters. Must be unique.
senha
string
User’s new password. Must be between 8 and 255 characters.

Response

id_User
string
The user’s unique identifier (UUID).
nome
string
The updated user’s name.
email
string
The updated user’s email address.
roleId
number
The user’s role ID.
curl -X PUT https://api.arca.example.com/users/123e4567-e89b-12d3-a456-426614174000 \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_JWT_TOKEN" \
  -d '{
    "nome": "John Updated",
    "email": "[email protected]"
  }'
{
  "id_User": "123e4567-e89b-12d3-a456-426614174000",
  "nome": "John Updated",
  "email": "[email protected]",
  "roleId": 2
}

Build docs developers (and LLMs) love