diff options
author | Colin Okay <okay@toyful.space> | 2022-02-12 14:50:35 -0600 |
---|---|---|
committer | Colin Okay <okay@toyful.space> | 2022-02-12 14:50:35 -0600 |
commit | 0833f316144d5a8097c37b944b709ec20aa0f046 (patch) | |
tree | ff43354657ff3f703b410f8f4cf1663088bb9d24 /example/lazybones-test.lisp | |
parent | 3ba4da76e44e61e78a04aadcc88853e2ddee5d13 (diff) |
formatting and comments in example
Diffstat (limited to 'example/lazybones-test.lisp')
-rw-r--r-- | example/lazybones-test.lisp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/example/lazybones-test.lisp b/example/lazybones-test.lisp index aca7a56..9300467 100644 --- a/example/lazybones-test.lisp +++ b/example/lazybones-test.lisp @@ -68,7 +68,8 @@ "Echos back Hello WHO" (http-ok (format nil "Hello ~a~%" who))) ; use the route variable here -(defendpoint* :post "/hello/:who:" () (:auth t) ; use the default authorizor for the app +(defendpoint* :post "/hello/:who:" () + (:auth t) ; use the app's default authorizor "Echo's back 'Hello WHO, I got your message BODY' where BODY is the post body." (print (lzb:request-header :content-type)) (let ((body (lzb:request-body))) @@ -97,7 +98,8 @@ "Randomly decides that the request is authorized" (< 5 (random 10))) -(defendpoint* :post "/crapshoot" () (:auth 'crapshoot-authorizer) ; use custom authorizer +(defendpoint* :post "/crapshoot" () + (:auth 'crapshoot-authorizer) ; use a custom authorizer "Echos back 'You made it' if the request was authorized" (http-ok "You made it")) |