BoldSales

API Documentation

Update a user

patch/api/v1/users/{id}

Updates one or more field values for an existing user. Supports updating personal information, contact details, role assignments, reporting structure, and account settings.

Code snippet

curl -X 'PATCH' \
  'https://{yourdomain}/api/v1/users/{id}' \
  -H 'accept: text/plain; x-api-version=1.0' \
  -H 'x-api-key: {your API key}' \
  -H 'Content-Type: application/json-patch+json; x-api-version=1.0' \
  -d '{
    "data": {
      "firstName": "John",
      "lastName": "Smith",
      "reportsTo": {
        "id": 101
      },
      "status": {
        "id": 2
      },
      "timezone": {
        "id": 15
      },
      "role": {
        "id": 2
      },
      "permissionSet": {
        "id": 1
      }
    }
  }'

Path parameters

idintegerRequiredUnique identifier of the user to update. Must be a valid user ID that exists in the organization.

Request body

firstNamestringFirst name of the user. Used for display purposes and identification within the organization.
lastNamestringLast name of the user. Combined with first name for full display name and identification.

reportsToobject

Manager or supervisor that this user reports to in the organizational hierarchy.

idintegerUnique identifier of the manager or supervisor user.

statusobject

Current status of the user account such as Active or Inactive.

idintegerUnique identifier of the status to assign to the user.

timezoneobject

The user's time zone, used to display dates and times in local time.

idintegerUnique identifier of the timezone to assign to the user.

roleobject

Role assignment that defines the user's job function and responsibilities.

idintegerUnique identifier of the role to assign to the user.

permissionSetobject

Permission set that defines access levels and capabilities for the user account.

idintegerUnique identifier of the permission set to assign to the user.

Example response

200 Success

{
  "message": "User updated successfully.",
  "data": {
    "id": 1234
  }
}