/users/{name}
0.1.0Unchanged since publicationUpdate a user account
usersallAny user can change their own email address and password. Administrators can manage any account. Resellers can change their customers' email addresses, passwords, status, packages, shell access and nightly backup settings. Changing role or owner requires an administrator. The API returns 403 for a change the caller lacks permission to make. It returns 400 if the request specifies no changes or if an administrator tries to change their own role, status, shell, backups or owner. An administrator can change their own package.
Changing your own password requires current_password. It revokes your other sessions and preserves the calling token and manually created tokens. Resetting another account's password or suspending an account revokes all of that account's tokens. A new password must contain 8 to 128 printable characters. For a customer, it also sets the password used for SFTP and shell access.
Pass an empty string in email to clear the email address or in package to remove the package and its limits. An invalid package name returns 400. Changing an administrator's email address or moving an account into or out of the administrator role updates delivery of root's mail.
Use active or suspended for status. Other values return 400. For a customer, suspension also disables their mailboxes in Dovecot and their domains' senders in Postfix. Reactivation restores both. Accounts suspended for a server move must be reactivated through the move workflow. For a copy awaiting cutover, use the Move section of the web interface or urbestack-move-cutover --user NAME. For a frozen account on the source server, use urbestack-move-source-release --user NAME. Add --take-back to the latter if the account has already moved.
For an account with a Linux account, set shell to true to enable Bash access and remove the SFTP jail. Set shell to false to restore jailed SFTP access and end running system sessions. For an account with a home directory, set backups to false to exclude it from nightly server backups. Set it to true to restore the default inclusion. Customers can still request backups.
Set owner to a reseller's name to transfer the customer, or pass an empty string to transfer the customer to the administrator. Change or clear a package belonging to the former reseller before or during the transfer. A transfer to a reseller must fit their customer count, disk and bandwidth limits. Increasing a customer's disk or bandwidth allowance must also fit their reseller's limits. To change a customer's role, first place the customer under the administrator. To change a reseller's role, first reassign all their customers.
The response contains the updated account in user. For customers and resellers, home gives the path configured through home_base and uid gives the Linux user ID, or null if the Linux account is missing. Both fields are null for administrators.
As a command
Run as root on the serverParameters
namepath ·UsernameRequiredbackupsbooleancurrent_passwordstring, up to 128 charactersemailstring, up to 254 characters or nullownerstring, up to 32 characters or nullpackagestring, up to 64 characters or nullpasswordstring, up to 128 charactersroleRoleshellbooleanstatusstring, one of active, suspendedExample
See the API overview for how to set $API and $TOKEN.curl -sS -X PATCH "$API/users/alice" \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{
"backups": true,
"current_password": "text",
"email": "alice@example.com",
"owner": "text",
"package": "basic",
"password": "Sup3r-Secret-Passphrase",
"role": "user",
"shell": true,
"status": "active"
}'200 OK{
"user": {
"backups": true,
"bandwidth_bytes": 1,
"bandwidth_cut": true,
"bandwidth_cut_at": "text",
"bandwidth_limit_bytes": 1,
"created_at": "2026-09-09T10:15:00Z",
"customers": 1,
"disk_limit_bytes": 1,
"email": "alice@example.com",
"home": "text",
"id": 1,
"move_state": "leaving",
"name": "alice",
"owner": "text",
"owner_id": 1,
"package": "basic",
"package_backups": true,
"package_id": 1,
"package_shell": true,
"role": "user",
"second_factor": true,
"shell": true,
"status": "active",
"system_password": true,
"uid": 1
}
}Errors
40 errors, each a status and a sentence400--name is required400<name> has an owner: move them to the administrator before changing their role400<name> is an administrator: administrators have no home, so nothing to back up400<name> is an administrator: administrators have no system account400<name> is an administrator: administrators have no system account, so no shell400Cannot demote or suspend the last active administrator400Domain name required400Domain name too long400Invalid IPv4 address400Invalid IPv6 address400Invalid boolean400Invalid domain name400Invalid email address400Invalid id400Invalid package name400Invalid password hash400Invalid password: 8 to 128 printable characters400Invalid port400Invalid role: admin, user or reseller400Invalid setting key400Invalid status400Invalid system password hash400Invalid username: 2 to 32 lowercase letters, digits or underscores, starting with a letter400Nothing to change400Only a customer has an owner: an administrator or a reseller is the administrator's own400The second factor can only be turned off here; a user enrols from their own page400Username '<value>' is reserved400You cannot change your own role, status, shell, backups or owner400status must be active or suspended401Authentication required401The password is not the panel password403Only an administrator changes a user's <k>403Only an administrator or the customer's reseller changes a user's <k>404Setting '<key>' not found404User '<name>' not found409<name> is on the package <p.name> of the reseller <p.owner>: change the package before the move409<name> owns <owned> 409<who> and its bandwidth for the month is used up: 409<who> and its disk is used up: 409The package <p.name> allows <limit> urbestack.com/docs/api/patch-users-name/