17 lines
488 B
Python
17 lines
488 B
Python
|
|
from typing import Any, Dict
|
||
|
|
|
||
|
|
from fastapi import APIRouter
|
||
|
|
|
||
|
|
from app.core.response import success_response
|
||
|
|
from app.core.security import verify_access_password
|
||
|
|
from app.schemas.platform import PasswordVerifyIn
|
||
|
|
|
||
|
|
|
||
|
|
router = APIRouter(prefix="/auth", tags=["auth"])
|
||
|
|
|
||
|
|
|
||
|
|
@router.post("/verify-password")
|
||
|
|
def verify_password_api(payload: PasswordVerifyIn) -> Dict[str, Any]:
|
||
|
|
is_valid = verify_access_password(payload.password)
|
||
|
|
return success_response(is_valid, msg="密码校验完成")
|