rosa/Main.hs

11 lines
249 B
Haskell
Raw Normal View History

2014-11-20 21:39:25 +01:00
import Network.Wreq
import Control.Lens
import Data.Aeson
import Json
main = do
req <- get "http://namecoin.dns:8088/id/rnhmjoj"
case decode (req ^. responseBody) of
Just res -> putStrLn $ repr res 0
Nothing -> putStrLn "Error parsing data"