]> git.ipfire.org Git - dbl.git/commitdiff
api: Deprecate the old reports endpoints in the lists handler
authorMichael Tremer <michael.tremer@ipfire.org>
Mon, 2 Mar 2026 17:57:20 +0000 (17:57 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Mon, 2 Mar 2026 17:57:20 +0000 (17:57 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/dbl/api/lists.py

index 95c98279f76d40f79ad8415acd0502aa517384ab..558d5c3adcba7bf390752c5b974cedad4d1624f7 100644 (file)
@@ -76,7 +76,7 @@ async def get_list_history(
 async def get_list_sources(list = fastapi.Depends(get_list_from_path)) -> typing.List[sources.Source]:
        return list.sources
 
-@router.get("/{list}/reports")
+@router.get("/{list}/reports", deprecated=True)
 async def get_list_reports(
                list = fastapi.Depends(get_list_from_path),
                open: bool | None = None,
@@ -104,7 +104,7 @@ class CreateReport(pydantic.BaseModel):
        block : bool = True
 
 
-@router.post("/{list}/reports")
+@router.post("/{list}/reports", deprecated=True)
 async def list_report(
        report: CreateReport,
        list = fastapi.Depends(get_list_from_path),