This application was designed to convert your XML to a pretty one JSON.
- To start the application you must have docker.
- Go to project folder.
- Open terminal and type
gradle build. This command will create a docker image "xml-to-json". - To run this image type
docker run -p 80:80 xml-to-json. This command will run application at port 80.
Converter wait a POST request at port 80. To send such request we can just use
curl.
Open terminal and type next command
curl -X POST -H "Content-type: application-xml" -d @yourXml.xml http://localhost:80
In response you will receive converted JSON or "Not valid" message if your XML is not valid.