Core Responsibilities
Administrators are responsible for:- System Configuration: Setting up loan types, company settings, email templates
- User Management: Creating and managing all user accounts across all roles
- Global Oversight: Monitoring operations across all supervisors and officers
- Data Integrity: Managing backups, maintenance mode, and system health
- Security: Resetting passwords, managing access, reviewing audit logs
User Management
Creating Users
Admins can create users of any role, including other admins:When creating a Credit Officer, set the
supervisorId to establish the reporting hierarchy.Managing Users
Admin-only user operations include:| Operation | Endpoint | Description |
|---|---|---|
| List all users | GET /api/users | View all users with filters |
| View user details | GET /api/users/:id | See complete user profile |
| Update any user | PUT /api/users/:id | Modify user information |
| Delete users | DELETE /api/users/:id | Remove users (checks dependencies) |
| Reset passwords | PUT /api/users/:id/reset-password | Force password reset |
| Bulk operations | POST /api/users/bulk-operation | Activate/deactivate multiple users |
| Export users | GET /api/users/export | Download user list |
| Import users | POST /api/users/import | Bulk user creation |
Password Reset Authority
Only admins can reset user passwords:System Configuration
Company Settings
Admins configure global system settings:Maintenance Mode
Admins can enable maintenance mode to block non-admin access:Loan Type Configuration
Admins define available loan products:Email Template Management
Admins customize system email templates:Union Management
Full Union Control
Admins have complete control over unions:| Operation | Endpoint | Permission |
|---|---|---|
| Create unions | POST /api/unions | ❌ Admin-only |
| View all unions | GET /api/unions | ✅ All roles |
| Update unions | PUT /api/unions/:id | ❌ Admin-only |
| Delete unions | DELETE /api/unions/:id | ❌ Admin-only |
| Reassign unions | POST /api/unions/:unionId/assign | ❌ Admin-only |
Reassigning Unions
Only admins can reassign unions to different Credit Officers:- Updates the
Union.creditOfficerIdfield - Creates a record in
UnionAssignmentHistory - Triggers audit logs
Loan Operations
Admin Loan Powers
Admins have special loan management capabilities:Schedule Management
Loan Approval Override
Admins can approve or reject loans at any stage, bypassing supervisor hierarchy.Reporting & Analytics
Supervisor Reports Access
Admins have full access to supervisor reports:- Generate reports for any supervisor
- View all report sessions
- Access officer performance metrics
- See territory-wide analytics
Audit Log Access
Admins can review the complete audit trail:Backup & Restore
Admins manage system backups:Regular backups are critical. Set up automated backups through the BackupScheduleSettings.
Admin-Only Endpoints
Here’s a summary of admin-exclusive endpoints:User Routes (user.routes.ts)
POST /api/users/bulk-operation- Bulk user operationsGET /api/users/export- Export usersPOST /api/users/import- Import usersGET /api/users/:id/dependencies- Check user dependenciesDELETE /api/users/:id- Delete usersPUT /api/users/:id/reset-password- Reset passwords
Union Routes (union.routes.ts)
PUT /api/unions/:id- Update unionsDELETE /api/unions/:id- Delete unionsPOST /api/unions/:unionId/assign- Reassign unions
Loan Routes (loan.routes.ts)
POST /api/loans/generate-missing-schedules- Generate missing schedulesPOST /api/loans/regenerate-schedule/:loanId- Regenerate loan schedule
System Routes
- All routes under
/api/settings - All routes under
/api/email-templates - All routes under
/api/backup
Security Considerations
Limit Admin Accounts
Limit Admin Accounts
Only create admin accounts for trusted executives and system managers. Too many admins increase security risk.
Monitor Admin Actions
Monitor Admin Actions
Regularly review audit logs for admin actions, especially user deletions and system configuration changes.
Use Strong Authentication
Use Strong Authentication
Admins should use strong passwords and enable two-factor authentication when available.
Maintenance Mode Protocol
Maintenance Mode Protocol
Before enabling maintenance mode, notify all users. Only use it during critical updates or data migrations.
Related Resources
Supervisor Role
Learn about supervisor capabilities and team management
Credit Officer Role
Understand field operations and day-to-day loan management
