I have a web-service that reply at some get request, something like this: http://developer.echonest.com/api/v4/artist/reviews?api_key=N6E4NIOVYMTHNDM8J&id=ARH6W4X1187B99274F&format=json&results=1&start=2 if a parameter in the request is wrong: http://developer.echonest.com/api/v4/artist/reviews?api_key=N6E4NIOVYMTHNDM8J&id=ARH6W4X1187B99274F&format=json&results=1&start=WRONG-STRING the server reply with a 400 and some json explain what is went wrong.
Now in clojure I want to read the json to know exactly what is went wrong, i tried with (clojure.java.io/reader wrong-url) but it thrown an exception
Server returned HTTP response code: 400 for URL:
http://developer.echonest.com/api/v4/artist/reviews? api_key=N6E4NIOVYMTHNDM8J&id=ARH6W4X1187B99274F&format=json&results=1&start=e1 [Thrown class java.io.IOException]
How can i read the json ?