Roles & Permissions
The multi-user role-based access control (RBAC) system described on this page is a premium feature that requires a valid Docunara license. Without a license, only the single admin account (defined by ADMIN_EMAIL / ADMIN_PASSWORD) is available. See Licensing for details.
When the database is enabled (DB_ENABLED=true) and a valid license is configured, Docunara uses a role-based access control system to manage what each user can do. There are four predefined roles.
User Roles
| Role | Code | User Management | Document Access | Description |
|---|---|---|---|---|
| Admin | admin | All users | Full access | Full system administration |
| Operator | operator | All except admin | Full access | User management + full document access |
| Content Operator | content_operator | None | Full access | Can edit all documents |
| Content Manager | content_manager | None | Assigned scope only | Limited to specific locales/paths |
Admin
The admin role has unrestricted access to everything in the system:
- Create, edit, and delete all users (including other admins)
- Access and edit all documents across all locales
- Manage system settings
Operator
Operators can manage users and access all documents, but they cannot modify admin accounts:
- Create, edit, and delete users (except admin users)
- Access and edit all documents across all locales
Content Operator
Content operators have full document access but no user management capabilities:
- Access and edit all documents across all locales
- Cannot manage users or system settings
Content Manager
Content managers have the most restricted access — they can only access documents within their assigned scope:
- Access and edit only the documents they have been granted permission for
- Cannot manage users or system settings
Permission Scope
Permissions for the content_manager role are defined by three dimensions:
| Dimension | Description | Example |
|---|---|---|
| Locale | Language/locale restriction | en, ko, or null (all locales) |
| Document Path | Folder path restriction | Signer/, Otpkey/guides/, or null (all documents) |
| Actions | Allowed operations | ["read"], ["read", "write"], ["read", "write", "create", "delete"] |
Available Actions
| Action | Description | HTTP Methods |
|---|---|---|
read | View documents and folder contents | GET |
write | Edit existing documents and folders | PUT, PATCH |
create | Create new documents and folders | POST |
delete | Delete documents and folders | DELETE |
How Permissions Work
Each content manager can have one or more permission entries. A request is allowed if any permission entry matches the requested locale, document path, and action.
Example permissions for a user:
| Locale | Document Path | Actions |
|---|---|---|
en | Signer/ | ["read", "write", "create"] |
ko | Signer/ | ["read"] |
null | Otpkey/guides/ | ["read", "write", "create", "delete"] |
This user can:
- Read, write, and create English documents under
Signer/ - Read Korean documents under
Signer/ - Read, write, create, and delete documents under
Otpkey/guides/in any locale
Path Matching
- A path like
Signer/grants access to the entireSigner/directory and all subdirectories - A
nullpath grants access to all documents - A
nulllocale grants access across all locales
Managing Users
Admins and operators can manage users through the User Management panel in the editor UI:
- Create new user accounts with a role assignment
- Edit user details (name, role, active status)
- Deactivate users without deleting their accounts (set inactive)
- Reset passwords for other users
- Delete user accounts
Users can also change their own password from the editor.
Managing Permissions
Admins and operators can manage content_manager permissions through the editor UI:
- Open the User Management panel (available to admin and operator roles)
- Select a user to view or edit their permissions
- Add or remove permission entries specifying locale, document path, and allowed actions
Only content_manager users require explicit permission entries. The admin, operator, and content_operator roles have full document access by default.
Without a License
When no valid license is configured, the RBAC system is not active:
- Only the single admin account (
ADMIN_ID/ADMIN_EMAIL+ADMIN_PASSWORD) can access the editor - The admin has full access to all documents
- User management UI is not available
- Document search remains available if
DB_ENABLED=true