export type UserRole =
  | "student"
  | "teacher"
  | "admin"
  | "corporate"
  | "mastercorporate"
  | "agent"
  | "developer";

export interface User {
  id: number;
  name: string;
  email: string;
  login: string;
  user_type: UserRole;
  avatar?: string;
  phone?: string;
  country?: string;
  timezone?: string;
  bio?: string;
  gender?: string;
  student_id?: string;
  is_verified: boolean;
  entities: UserEntity[];
  classrooms: string[];
  expiry_date?: string;
}

export interface UserEntity {
  id: number;
  name: string;
  role?: string;
}

export interface LoginRequest {
  login: string;
  password: string;
}

export interface LoginResponse {
  token: string;
  user: User;
  permissions?: string[];
}

/** Matches Odoo `encoach_api` `GET /api/user` payload */
export interface CurrentUserResponse {
  user: User;
  permissions?: string[];
}

export interface ResetPasswordRequest {
  email: string;
}
