REFACTOR API gateway fix 4
This commit is contained in:
@@ -88,16 +88,23 @@ class TokenResponse(BaseModel):
|
||||
}
|
||||
|
||||
class UserResponse(BaseModel):
|
||||
"""User response for user management endpoints"""
|
||||
"""User response for user management endpoints - FIXED"""
|
||||
id: str
|
||||
email: str
|
||||
full_name: str
|
||||
is_active: bool
|
||||
is_verified: bool
|
||||
created_at: str
|
||||
created_at: datetime # ✅ Changed from str to datetime
|
||||
last_login: Optional[datetime] = None # ✅ Added missing field
|
||||
phone: Optional[str] = None # ✅ Added missing field
|
||||
language: Optional[str] = None # ✅ Added missing field
|
||||
timezone: Optional[str] = None # ✅ Added missing field
|
||||
tenant_id: Optional[str] = None
|
||||
role: Optional[str] = "user"
|
||||
|
||||
class Config:
|
||||
from_attributes = True # ✅ Enable ORM mode for SQLAlchemy objects
|
||||
|
||||
class TokenVerification(BaseModel):
|
||||
"""Token verification response"""
|
||||
valid: bool
|
||||
|
||||
Reference in New Issue
Block a user