from typing import Literal
from pydantic import EmailStr, Field
from app.utils.schemas_utils import CustomModel

class UserCreate(CustomModel):
    first_name: str
    last_name: str
    email_id: str
    password: str
    role: Literal["superadmin", "admin"] = Field(default="admin")
    
class UserLoginBase(CustomModel):
    email_id: EmailStr
    password: str
    
class UserPassUpdate(CustomModel):
    current_password: str
    new_password: str
    confirm_password: str

class UserResponse(CustomModel):
    first_name: str
    last_name: str
    email_id: str
    password: str
    role: Literal["superadmin", "admin"] = Field(default="admin")

class ForgotPasswordRequest(CustomModel):
    email_id: EmailStr

class VerifyOTPRequest(CustomModel):
    email_id: EmailStr
    otp: str
    new_password: str    