Skip to content

Commit 73555b0

Browse files
committed
bump up versions
1 parent 51574a7 commit 73555b0

File tree

2 files changed

+20
-19
lines changed

2 files changed

+20
-19
lines changed

project.clj

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1-
(defproject metosin/compojure-api-examples "0.15.0"
1+
(defproject metosin/compojure-api-examples "0.16.0"
22
:description "Compojure-api-examples"
33
:dependencies [[org.clojure/clojure "1.6.0"]
4-
[metosin/compojure-api "0.15.0"]
5-
[metosin/ring-http-response "0.4.1"]
4+
[metosin/ring-swagger "0.13.0"]
5+
[metosin/compojure-api "0.16.0"]
6+
[metosin/ring-http-response "0.5.0"]
67
[metosin/ring-swagger-ui "2.0.17"]
78
[clj-time "0.8.0"]]
89
:ring {:handler compojure.api.examples.handler/app}

src/compojure/api/examples/handler.clj

+16-16
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
:path-params [x :- Long y :- Long]
3030
:summary "x*y with path-parameters"
3131
(ok {:total (* x y)}))
32-
(GET* "/power" []
32+
(GET* "/power" []
3333
:return Total
3434
:header-params [x :- Long y :- Long]
3535
:summary "x^y with header-parameters"
@@ -40,47 +40,47 @@
4040
(context "/echo" []
4141
(GET* "/request" req (ok (dissoc req :body)))
4242
(GET* "/pizza" []
43-
:return NewSingleToppingPizza
44-
:query [pizza NewSingleToppingPizza]
45-
:summary "get echo of a pizza"
43+
:return NewSingleToppingPizza
44+
:query [pizza NewSingleToppingPizza]
45+
:summary "get echo of a pizza"
4646
(ok pizza))
4747
(PUT* "/anonymous" []
4848
:return [{:secret Boolean s/Keyword s/Any}]
49-
:body [body [{:secret Boolean s/Keyword s/Any}]]
49+
:body [body [{:secret Boolean s/Keyword s/Any}]]
5050
(ok body))
5151
(GET* "/hello" []
5252
:return String
5353
:query-params [name :- String]
5454
(ok (str "Hello, " name)))
5555
(POST* "/pizza" []
56-
:return NewSingleToppingPizza
57-
:body [pizza NewSingleToppingPizza]
58-
:summary "post echo of a pizza"
56+
:return NewSingleToppingPizza
57+
:body [pizza NewSingleToppingPizza]
58+
:summary "post echo of a pizza"
5959
(ok pizza))))
6060

6161
(swaggered "pizza"
6262
:description "Pizza Api it is."
6363
(context "/api/pizzas" []
6464
(GET* "/" []
65-
:return [Pizza]
65+
:return [Pizza]
6666
:summary "Gets all Pizzas"
6767
(ok (get-pizzas)))
6868
(POST* "/" []
69-
:return Pizza
70-
:body [pizza NewPizza {:description "new pizza"}]
69+
:return Pizza
70+
:body [pizza NewPizza {:description "new pizza"}]
7171
:summary "Adds a pizza"
7272
(ok (add! pizza)))
7373
(PUT* "/" []
74-
:return Pizza
75-
:body [pizza Pizza]
74+
:return Pizza
75+
:body [pizza Pizza]
7676
:summary "Updates a pizza"
7777
(ok (update! pizza)))
7878
(GET* "/:id" []
79-
:return Pizza
79+
:return Pizza
8080
:path-params [id :- Long]
81-
:summary "Gets a pizza"
81+
:summary "Gets a pizza"
8282
(ok (get-pizza id)))
8383
(DELETE* "/:id" []
8484
:path-params [id :- Long]
85-
:summary "Deletes a Pizza"
85+
:summary "Deletes a Pizza"
8686
(ok (delete! id))))))

0 commit comments

Comments
 (0)