web api 初稿

This commit is contained in:
suyiiyii 2024-09-19 21:16:56 +08:00
parent 76f271584f
commit d890d32bba

View File

@ -201,31 +201,31 @@ async def update_weigth_config(platformName: str, target: str, weight_config: We
return StatusResp(ok=True, msg="") return StatusResp(ok=True, msg="")
@router.get("/cookie") @router.get("/cookie", dependencies=[Depends(check_is_superuser)])
async def get_cookie() -> list[Cookie]: async def get_cookie() -> list[Cookie]:
pass pass
@router.post("/cookie") @router.post("/cookie", dependencies=[Depends(check_is_superuser)])
async def add_cookie(site_name: str, content: str) -> StatusResp: async def add_cookie(site_name: str, content: str) -> StatusResp:
pass pass
@router.delete("/cookie") @router.delete("/cookie", dependencies=[Depends(check_is_superuser)])
async def del_cookie(site_name: str, content: str) -> StatusResp: async def del_cookie(site_name: str, content: str) -> StatusResp:
pass pass
@router.get("/cookie_target") @router.get("/cookie_target", dependencies=[Depends(check_is_superuser)])
async def get_cookie_target() -> list[CookieTarget]: async def get_cookie_target() -> list[CookieTarget]:
pass pass
@router.post("/cookie_target") @router.post("/cookie_target", dependencies=[Depends(check_is_superuser)])
async def add_cookie_target(site_name: str, target: str) -> StatusResp: async def add_cookie_target(site_name: str, target: str) -> StatusResp:
pass pass
@router.delete("/cookie_target") @router.delete("/cookie_target", dependencies=[Depends(check_is_superuser)])
async def del_cookie_target(site_name: str, target: str) -> StatusResp: async def del_cookie_target(site_name: str, target: str) -> StatusResp:
pass pass