@defikitdotnet/x-ai-combat
Version:
XCombatAI - Social Media Engagement Template for the Agent Framework
29 lines • 774 B
TypeScript
import React, { ReactNode } from "react";
interface User {
id: string;
twitterId: string;
username: string;
}
interface AuthContextType {
user: User | null;
token: string | null;
isAuthenticated: boolean;
isLoading: boolean;
error: string | null;
login: (_newToken: string) => Promise<void>;
logout: () => Promise<void>;
}
declare const AuthContext: React.Context<AuthContextType>;
interface AuthProviderProps {
children: ReactNode;
}
/**
* Auth provider component to manage authentication state
*/
export declare const AuthProvider: React.FC<AuthProviderProps>;
/**
* Custom hook to use auth context
*/
export declare const useAuth: () => AuthContextType;
export default AuthContext;
//# sourceMappingURL=AuthContext.d.ts.map