feat: DB-driven whitelist with is_admin, auto-register on /start, admin commands (/adduser /removeuser /users)

This commit is contained in:
2026-06-16 19:24:51 +02:00
parent 7c9db4d705
commit 89a00c3295
3 changed files with 166 additions and 58 deletions
+1
View File
@@ -10,6 +10,7 @@ CREATE TABLE IF NOT EXISTS users (
telegram_id bigint UNIQUE NOT NULL,
username text,
first_name text,
is_admin boolean NOT NULL DEFAULT false,
is_active boolean NOT NULL DEFAULT true,
created_at timestamptz NOT NULL DEFAULT now()
);