summaryrefslogtreecommitdiff
path: root/api.lisp
diff options
context:
space:
mode:
authorGrant Shoshin Shangreaux <shoshin@cicadas.surf>2023-01-07 11:12:15 -0600
committerGrant Shoshin Shangreaux <shoshin@cicadas.surf>2023-01-07 11:12:15 -0600
commitaee7f487f97c10c15b6c7b48156cc95db19d9137 (patch)
tree9ccdb9b7a3e356ed39f2ed71b2d04b7e2718df20 /api.lisp
parent9a040d4e78ab07eb9c482a40042f2ba92d2a8e3b (diff)
First Draft of hero creation and login
Diffstat (limited to 'api.lisp')
-rw-r--r--api.lisp25
1 files changed, 0 insertions, 25 deletions
diff --git a/api.lisp b/api.lisp
deleted file mode 100644
index cecacb4..0000000
--- a/api.lisp
+++ /dev/null
@@ -1,25 +0,0 @@
-;;;; api.lisp -- http routes for dnd
-
-(in-package :dnd)
-
-(lzb:provision-app (api)
- :title "Dungeons & Deadlines"
- :version "0.1.0"
- :prefix "/api"
- :content-type "application/json"
- :auth 'default-auth)
-
-(defun default-auth (&rest ignore)
- (declare (ignore ignore))
- t)
-
-
-
-(defendpoint* :get "/hall-of-legends" ((filter-by identity))
- (:auth t)
- "Get a list of heros sorted by renown"
- (json:to-json
- (list :heroes
- (sort (copy-seq (db:store-objects-with-class 'hero))
- #'>
- :key #'renown))))