mirror of
https://github.com/utopia-os/utopia-ui.git
synced 2026-03-01 12:44:17 +00:00
16 lines
498 B
TypeScript
16 lines
498 B
TypeScript
import type { UserItem } from './UserItem'
|
|
|
|
/**
|
|
* @category Types
|
|
*/
|
|
export interface UserApi {
|
|
register(email: string, password: string, userName: string): Promise<void>
|
|
login(email: string, password: string): Promise<UserItem | undefined>
|
|
logout(): Promise<void>
|
|
getUser(): Promise<UserItem>
|
|
getToken(): Promise<string | null>
|
|
updateUser(user: UserItem): Promise<void>
|
|
requestPasswordReset(email: string, reset_url?: string)
|
|
passwordReset(token: string, new_password: string)
|
|
}
|