feat(types): add User type

This commit is contained in:
Nora
2026-06-22 15:09:10 -06:00
parent 064909e1cd
commit 5cdfc05b41
+15
View File
@@ -831,3 +831,18 @@ export interface InboxClaimRow {
totalLines: number; totalLines: number;
} | null; } | null;
} }
// ---------------------------------------------------------------------------
// Auth (admin/user/viewer). Mirrors `users.to_public()` on the backend
// (backend/src/cyclone/auth/users.py). Role is the triple ("admin" |
// "user" | "viewer"); `disabledAt` is non-null when the account has been
// disabled by an admin. `createdAt` mirrors the original DB column.
// ---------------------------------------------------------------------------
export interface User {
id: number;
username: string;
role: "admin" | "user" | "viewer";
createdAt: string | null;
disabledAt?: string | null;
}