FastAPI Integration
Example Usage
from python_json_rbac.auth import get_current_user
from fastapi import Depends
@app.get("/me")
def get_me(user=Depends(get_current_user)):
return {"user": user}
from python_json_rbac.auth import get_current_user
from fastapi import Depends
@app.get("/me")
def get_me(user=Depends(get_current_user)):
return {"user": user}