You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13 lines
297 B
Django/Jinja
13 lines
297 B
Django/Jinja
from fastapi import APIRouter, Depends
|
|
|
|
from iti.auth import require_permission
|
|
from iti.responses import ok
|
|
|
|
|
|
router = APIRouter(prefix="/example", tags=["example"])
|
|
|
|
|
|
@router.get("/ping", dependencies=[Depends(require_permission("example:item:list"))])
|
|
def ping():
|
|
return ok({"pong": True})
|