aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/main.lisp18
1 files changed, 8 insertions, 10 deletions
diff --git a/src/main.lisp b/src/main.lisp
index 0dcc5cd..3c9092d 100644
--- a/src/main.lisp
+++ b/src/main.lisp
@@ -246,13 +246,12 @@
(defparameter +oneliners-description+
"TBD")
-(defun init-app ()
- (lzb:provision-app ()
- :title "Oneliners Wiki API"
- :version "0.0.1"
- :desc +oneliners-description+
- :content-type "application/json"
- :auth 'api-token-authorization))
+(lzb:provision-app ()
+ :title "Oneliners Wiki API"
+ :version "0.0.1"
+ :desc +oneliners-description+
+ :content-type "application/json"
+ :auth 'api-token-authorization)
(defun api-token-authorization ()
;; presently if the token merely exists then that's good enough.
@@ -280,18 +279,17 @@
;;; ENDPOINT DEFINITIONS
(defendpoint* :get "/search" ((commands a-csl)
- (keywords a-cls)
+ (keywords a-csl )
(limit an-int)
(page a-page-key)
(nextpage a-boolean)
(notflagged a-boolean)
(onlyaudited a-boolean))
- ()
+ (:content-type "application/json")
"A search endpoint returning a JSON encoded array of Oneliner Entries.
**Note**: either command or keywords are required.
"
- (print commands)
(cond
;; if page is incluced, ignore everything, fetch the next page,
;; and return it.