👤 Admin User Management v1.0 🔐
🛡️ Admin Access Only

User Management
& Access Control

Secure API for complete user administration. CRUD operations, role-based model, JWT authentication and bcrypt hashing — everything for secure access control to monitoring and web interfaces.

1
API Endpoint
4
CRUD Operations
3
Roles
8
User Fields
🔐 JWT Authentication
🔒 bcrypt Hashing
👥 Role-Based Model
🐘 PostgreSQL

⚠️ Problems Without Access Control

Why centralized user management is essential

🚪

Uncontrolled Access

Without a unified system, it's unclear who has access to monitoring and databases. Everyone creates their own accounts.

🔓

Plain Text Passwords

Storing passwords without hashing is a direct path to system compromise in case of database leak.

👤

No Role Model

All users have the same rights. Impossible to separate administrators, managers and viewers.

📋

No Audit Trail

Who created the user? When did they last login? Who changed the role? Without a system — no answers.

Complex Deletion

Employee left — need to manually find all their accounts across all systems. Often forgotten.

No Validation

Weak passwords, duplicate usernames, invalid emails — without validation the database fills with garbage.

🔄 CRUD Operations

Complete user management cycle through a single API

action: "create"

Create

Create new users with full validation and secure password hashing.

  • Username validation (min. 3 chars)
  • bcrypt password hashing
  • Role assignment
  • Email and full name
action: "list"
📋

Read

Get list of all users with complete data, sorted by creation date.

  • All system users
  • Sorted (newest first)
  • Full profile data
  • Activity status
action: "update"
✏️

Update

Modify any user fields, including secure password change and roles.

  • Update any fields
  • Secure password change
  • Role modification
  • Activate/deactivate
action: "delete"
🗑️

Delete

Permanently delete user from the system with operation confirmation.

  • Permanent deletion
  • By user ID
  • Response confirmation
  • Cascade cleanup

👥 Role-Based Model

Three access levels for different user types

🛡️

Admin

Full access to all system functions. Can manage users, settings and data.

Create Read Update Delete Settings
👔

Manager

Extended access for managers. Can view data and manage content.

Read Update Monitoring Reports
👁️

Viewer

Basic view-only access. Can see dashboards and reports without editing.

Read Dashboards Reports

🔐 Security

Multi-layer access protection

🎫

JWT Bearer Token

Authentication via JSON Web Token. Every request is checked for token presence and validity.

🔒

bcrypt Hashing

Passwords are stored as bcrypt hashes using PostgreSQL crypt() and gen_salt('bf') functions.

🛡️

Admin Role Check

All user management operations require admin role. HTTP 403 for unauthorized requests.

Data Validation

Username check (min. 3 chars, lowercase), password (min. 6 chars), email and other field validation.

🚫

Duplicate Protection

Username uniqueness guaranteed at database level. Impossible to create two identical users.

📊

Operation Audit

All actions are logged: creation, modification, deletion of users with timestamps.

📋 User Fields

8 fields for a complete profile

🔑 id UUID
👤 username VARCHAR(50)
🔒 password_hash VARCHAR(255)
📧 email VARCHAR(255)
🎭 role VARCHAR(20)
📝 full_name VARCHAR(100)
is_active BOOLEAN
📅 created_at TIMESTAMP

🌐 Integrations

Single entry point for all web interfaces

📊

AI Monitoring System

Access control for AI agent monitoring dashboards, dialog statistics and analytics.

🗄️

RAG Vector Base Writer

Access management for the web interface of AI knowledge base vector editing.

⚙️

CRM Settings

Access to Bitrix24, KommoCRM and other CRM system integration settings.

📧

Email System

Email system settings management, templates and follow-up campaigns.

🛡️

GDPR Compliance

Access to GDPR functions: data export, deletion, audit reports for regulators.

🤖

AI Self-Learning

AI self-learning system management: improvement approval, validation settings.

💎 Advantages

Why a unified user management system

🎯

Single Entry Point

One API for access management to all web interfaces and monitoring systems.

Instant Management

Create, modify, block user — all through a single API request.

🔐

Reliable Security

JWT + bcrypt + role checking — three levels of protection against unauthorized access.

📋

Full Audit

When created, when logged in, who changed — complete history for each user.

🧩

Easy Integration

REST API easily integrates with any web interface or external system.

🐘

PostgreSQL Reliability

Data stored in reliable PostgreSQL with indexes, constraints and UUID keys.

📋 Technical Specifications

Key system parameters

1
Workflow
4
Operations
3
Roles
8
Fields
JWT
Token
bcrypt
Hashing