From 098ba98a7c3df829405ace46d69fc680ec61f3d6 Mon Sep 17 00:00:00 2001 From: DingZQ Date: Thu, 6 Apr 2023 23:14:05 +0800 Subject: [PATCH] Refine --- main.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/main.py b/main.py index d724460..354885f 100644 --- a/main.py +++ b/main.py @@ -163,6 +163,10 @@ async def fastapi_undo(network: str): async def fastapi_redo(network: str): return execute_redo(network) +@app.get('/getsnapshots/') +def fastapi_list_snapshot(network: str) -> list[tuple[int, str]]: + return list_snapshot(network) + @app.get('/havesnapshot/') async def fastapi_have_snapshot(network: str, tag: str) -> bool: return have_snapshot(network, tag)