let url = "http://localhost:1234/" <> formatYearMonth dt <> "/" <> formatDate dt <> ".xml"
res <- get document url
case res of
Left err -> do
liftEffect $ log $ "TCMB exchange request error:" <> printError err
pure Nothing
Right response@{body} -> do
...
get function is from Affjax module.
This code writes TCMB exchange request error:There was a problem with the response body: Type mismatch: expected Document, found XMLDocument
to the console.
How can I receive and process xml resources?
Thanks in advance.