added login and register

This commit is contained in:
lusixing
2026-01-27 19:52:36 -08:00
parent b8c241c1a0
commit 4d94888bb8
10 changed files with 960 additions and 151 deletions

View File

@@ -13,7 +13,7 @@ export interface FlowRecord {
}
// Vault Types
export type VaultAssetType =
export type VaultAssetType =
| 'game_account'
| 'private_key'
| 'document'
@@ -72,3 +72,32 @@ export interface ProtocolInfo {
version: string;
lastUpdated: Date;
}
// Auth Types
export interface User {
id: number;
username: string;
public_key: string;
is_admin: boolean;
guale: boolean;
tier: string;
tier_expires_at: string;
last_active_at: string;
}
export interface LoginRequest {
username: string;
password: string;
}
export interface RegisterRequest {
username: string;
password: string;
email: string;
}
export interface LoginResponse {
access_token: string;
token_type: string;
user: User;
}