@defikitdotnet/education-module-ai
Version:
AI Education Module using Agent Framework
22 lines (21 loc) • 565 B
TypeScript
interface StudentAuth {
id: string;
email: string;
name: string;
createdAt: string;
}
export declare function useAuth(apiBaseUrl?: string): {
isLoading: boolean;
isAuthenticated: boolean;
user: StudentAuth | null;
error: string | null;
login: (email: string, password: string) => Promise<boolean>;
register: (name: string, email: string, password: string) => Promise<boolean>;
logout: () => void;
getAuthHeader: () => {
Authorization: string;
} | {
Authorization?: undefined;
};
};
export {};