Auth & users
LioranClient exposes authentication + user management methods.
Login
connect(): Promise<void>(auto-detects from URI)login(username: string, password: string): Promise<{ user; token; ... }>superAdminLogin(secret: string): Promise<{ user; token; ... }>
Session helpers
setToken(token: string): voidgetToken(): string | nullsetConnectionString(connectionString: string): voidgetConnectionString(): string | nulllogout(): voidisAuthenticated(): booleangetUser(): LioranUser | null
User APIs
Requires authentication.
me(): Promise<{ user }>register(username: string, password: string): Promise<{ user; token; ... }>register(input: { userId; username?; password?; role?; externalUserId? }): Promise<{ user; token; ... }>listUsers(): Promise<LioranManagedUser[]>issueUserToken(userId: string): Promise<{ user; token }>