HomeDocsFeaturesUser Management
Features

User Management

Manage users, roles, permissions, and account settings.

bthavanishBy bthavanish

User Management

User Model

FieldTypeDescription
idIntAuto-incrementing ID
emailStringUnique email address
usernameStringUnique display name
passwordStringbcrypt hash
isAdminBooleanAdmin flag
roleStringRole name (FK to Role)
descriptionStringBio text
avatarStringAvatar URL
serverLimitIntMax servers
maxMemoryIntTotal memory limit (MB)
maxCpuIntTotal CPU limit
maxStorageIntTotal storage limit (MB)
maxDatabasesIntTotal database limit
preferredNodeIdIntPreferred node for server creation
totpEnabledBooleanTOTP 2FA enabled
passkeyEnabledBooleanPasskey 2FA enabled
onboardingCompletedBooleanOnboarding finished
onboardingSkippedBooleanOnboarding skipped

Roles

Roles define a set of permissions. Each user has one role. Default roles:

  • admin (full access, system role, cannot be deleted)
  • user (standard user, system role, cannot be deleted)
  • Custom roles (created by admins)

Roles are managed via /api/v2/admin/roles. See admin/roles-and-permissions.md for the full permission tree.

Resource Quotas

Each user has resource quotas that limit what they can create:

QuotaDefaultDescription
serverLimit0Max servers (0 = use panel default)
maxMemory0Total memory across servers (MB)
maxCpu0Total CPU across servers
maxStorage0Total storage across servers (MB)
maxDatabases0Total databases across servers

When a quota is 0, the panel default from settings applies.

Admins have separate “privileged” defaults that are higher.

Sub-Users

Server owners can grant other users access to specific servers. Sub-users get granular permissions per server.

Adding a Sub-User

POST /api/v2/servers/:id/subusers
{
  "userId": 42,
  "permissions": ["console", "files.read", "backups"]
}

Available Permissions

PermissionDescription
consoleView console output
console.sendSend commands
filesAll file operations
files.readRead files
files.writeWrite/delete files
backupsView backups
backups.createCreate backups
backups.deleteDelete backups
schedule.readView schedules
schedule.createCreate/update schedules
schedule.deleteDelete schedules
databasesView databases
databases.createCreate databases
databases.deleteDelete databases
startStart server
stopStop server
restartRestart server
killKill server
reinstallReinstall server

Wildcards work: files.* grants all file permissions, backups.* grants all backup permissions.

Sub-User Access Resolution

When a request comes in, the panel checks:

  1. Is the user an admin? → Full access
  2. Is the user the server owner? → Full access
  3. Is the user a sub-user? → Check specific permission

User Creation

Self-Registration

If allowRegistration is enabled, users can register at /register. The first user becomes the admin.

Admin Creation

Admins can create users via the admin panel or API:

POST /api/v2/admin/users
{
  "email": "new@example.com",
  "password": "securepassword",
  "username": "newuser",
  "isAdmin": false,
  "serverLimit": 5,
  "maxMemory": 4096
}

User Deletion

Admins can delete users, but only if:

  • The user has no servers (transfer ownership first)
  • The admin is not deleting themselves

Ownership Transfer

Admins can transfer all servers from one user to another:

POST /api/v2/admin/users/:id/transfer
{ "newOwnerId": 5 }

Login History

Every login is recorded with:

  • IP address
  • User agent
  • Timestamp

This data is viewable in the admin panel.

Account Lockout

After loginMaxAttempts failed attempts (default 5), the account is locked for loginLockoutMinutes (default 15 minutes). The lockout is time-based and auto-expires.

Password Requirements

  • Minimum 8 characters
  • Maximum 128 characters
  • Must contain uppercase, lowercase, and a number
  • Hashed with bcrypt (cost factor 12).