Finished most of the webhook UI

This commit is contained in:
Donald Zou
2025-08-26 00:41:37 +08:00
parent c83a075886
commit f865317600
4 changed files with 217 additions and 9 deletions

View File

@@ -1401,6 +1401,18 @@ def API_WebHooks_DeleteWebHook():
status, msg = DashboardWebHooks.DeleteWebHook(data)
return ResponseObject(status, msg)
@app.get(f'{APP_PREFIX}/api/webHooks/getWebHookSessions')
def API_WebHooks_GetWebHookSessions():
webhookID = request.args.get('WebHookID')
if not webhookID:
return ResponseObject(False, "Please provide WebHookID")
webHook = DashboardWebHooks.SearchWebHookByID(webhookID)
if not webHook:
return ResponseObject(False, "Webhook does not exist")
return ResponseObject(data=DashboardWebHooks.GetWebHookSessions(webHook))
'''
Index Page