From 3dc20a35736e42c516fcf27e05e1cc3429ff0d85 Mon Sep 17 00:00:00 2001 From: Colin Okay Date: Fri, 4 Mar 2022 15:52:55 -0600 Subject: added admin only snapshot endpoint --- src/main.lisp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src') diff --git a/src/main.lisp b/src/main.lisp index 6dc2c7b..b0031e8 100644 --- a/src/main.lisp +++ b/src/main.lisp @@ -606,6 +606,12 @@ mentioned in th config file. ;;; ENDPOINT DEFINITIONS +(defendpoint* :post "/snapshot" ((token an-api-token)) + (:auth 'admin-only) + "Snapshot the datastore. Do this after upgrade" + (db:snapshot) + "ok") + (defendpoint* :get "/contributor/:who a-contributor-by-handle:" () () "Return a [contributor](#contributor) data object." (to-json who)) -- cgit v1.2.3